/* #region Global Theme */
/* ===== Global Theme======== */

:root {
  --bg: #f7f7f9;
  --bg-alt: #ffffff;
  --text: #222222;
  --muted: #666666;
  --accent: #2563eb;
  --border: #e1e1e6;
  --radius: 10px;
  --shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
  --max-width: 960px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

/* #endregion */

/* #region Layout Containers */
/* === Layout Containers======== */
.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

.video-container {
  position: relative;
  width: 100%;
  max-width: 800px; /* limite la largeur sur desktop */
  margin: 20px auto;
  padding-bottom: 56.25%; /* ratio 16:9 */
  height: 0;
  overflow: hidden;
  border-radius: 8px; /* optionnel */
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* #endregion */ 


/* #region Header + navigation  */
/* ===== HEADER + NAVIGATION ===== */
header {
  background: #cee0f2;
  border-bottom: 1px solid var(--border);
}

.nav-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 32px; /* adds clean space between brand and menu */
}

/* ===== BRAND SECTION: proofile and logo ===== */
.brand-section {
  display: flex;
  align-items: center;
  margin-bottom: 0;      /* remove vertical spacing */
  margin-right: 24px;    /* add horizontal spacing */
}


.profile-pic {
  width: 55px;
  height: 55px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 12px;
  border: 2px solid var(--accent);
}

.farm-logo {
  width: 120px;
  margin-bottom: 20px;
  opacity: 0.9;
}

.farm-watermark {
  position: relative;
}

.farm-watermark::after {
  content: "";
  position: absolute;
  bottom: 10px;
  right: 10px;
  width: 180px;
  height: 180px;
  background-image: url('/assets/images/LogoAlain.png');
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.08;
  pointer-events: none;
}

.farm-title-row {
  display: flex;
  align-items: center;
  justify-content: flex-start; /* aligné à gauche */
  gap: 12px;
}

.farm-logo-small {
  width: 250px;
  height: auto;
  opacity: 0.95;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-text .name {
  font-weight: 600;
  letter-spacing: 0.03em;
  font-size: 1rem;
  text-transform: uppercase;
  color: var(--muted);
}

.brand-text .tagline {
  font-size: 0.85rem;
  color: var(--muted);
}

/* ===== NAVIGATION ===== */
nav {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap; /* ⭐ REQUIRED */
}

nav a {
  text-decoration: none;
  color: var(--muted);
  font-size: 0.9rem;
}

nav a:hover {
  color: var(--accent);
}

/* ===== DROPDOWN ===== */
.dropdown {
  position: relative;
}

.dropbtn {
  background: none;
  border: none;
  font-size: 0.9rem;
  cursor: pointer;
  color: var(--muted);
}

.dropbtn:hover {
  color: var(--accent);
}

.dropdown-content {
  display: none;
  position: absolute;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  min-width: 180px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  z-index: 10;
}

.dropdown-content a {
  display: block;
  padding: 10px;
  color: var(--muted);
  text-decoration: none;
}

.dropdown-content a:hover {
  background: var(--border);
}

.dropdown:hover .dropdown-content {
  display: block;
}

/* ===  top-contact-bar ==== */
.top-contact-bar {
  width: 100%;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
     
}

.contact-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 6px 20px;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.top-contact-bar a {
  margin-left: 16px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.8rem;   /* smaller */
  opacity: 0.85;       /* softer */
}

.top-contact-bar a:hover {
  opacity: 1;
  color: var(--accent);
}

.subtagline {
  font-size: 0.9rem;          /* bigger */
  font-style: italic;         /* cursive */
  font-weight: bold;
  color: var(--muted);
  margin-right: auto;
  line-height: 1.3;
}

/* #endregion Header + navigation  */

/* #region   Larger profile photo on homepage only */
/* ===== Larger profile photo on homepage only ===== */
body.home .profile-pic {
  width: 85px;
  height: 85px;
}

body.home .brand-text .name {
  font-size: 1.25rem;
}

body.home .brand-text .tagline {
  font-size: 0.95rem;
}

body.home header { 
  padding: 2px 0; 
}
/* #endregion */

/* =====   Banne Section ==== */
.banner {
  width: 100%;
  height: 160px; /* adjust to taste */
  background-image: url("/assets/images/bannerlake.jpeg");
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--border);
}


/* #region Hero section  */
/* ====Hero Section============ */
.hero {
  max-width: var(--max-width);
  margin: 32px auto 0;
  padding: 24px 20px 40px;
}

.hero-card {
  background: var(--bg-alt);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px 24px 32px;
  border: 1px solid var(--border);
}

/* old version of hero
.hero-title {
  font-size: 1.8rem;
  margin: 0 0 8px;
} */

.hero-title { /*new version: Your name becomes the first thing people see — strong, confident, professional.*/
  font-size: 3rem;
  font-weight: 700;
  letter-spacing: -1px;
  text-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

.hero-subtitle {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 0.98rem;
}


/* #endregion Hero section  */

/* #region Tags  */
/* ===== Tags =======*/
.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.tag {
  font-size: 0.82rem;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #f3f4ff;
  color: #1d4ed8;
}

.tag i {
  margin-right: 6px;
}


/* #endregion Tags  */

/* #region Buttons  */
/* ====== Buttons ======*/
.btn {
  display: inline-block;
  padding: 7px 14px;
  font-size: 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
  background: #f9fafb;
}

.btn:hover {
  border-color: var(--accent);
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
  border-color: var(--accent);
}

.btn-primary:hover {
  background: #1d4ed8;
}
/* #endregion Buttons  */

/* #region Grid Cards  */
/* ===== Grid Cards============= */
.grid {
  max-width: var(--max-width);
  margin: 0 auto 40px;
  padding: 0 20px 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.card {
  background: var(--bg-alt);
  border-radius: var(--radius);
  padding: 16px 16px 18px;
  border: 1px solid var(--border);
  transition: transform .2s ease, box-shadow .2s ease; /* NEW */
}

.card h2 {
  font-size: 1.05rem;
  margin: 0 0 6px;
}

.card p {
  margin: 0 0 10px;
  font-size: 0.9rem;
  color: var(--muted);
}

.card a {
  font-size: 0.88rem;
  color: var(--accent);
  text-decoration: none;
}

/* Hover underline for links inside cards */
.card a:hover {
  text-decoration: underline;
}
/* NEW: Hover elevation + shadow */ 
.card:hover { 
  transform: translateY(-4px); 
  box-shadow: 0 8px 18px rgba(0,0,0,0.15); 
} 

/* Optional: thumbnail/icon inside cards */ 
.card-icon { 
  width: 48px; 
  height: 48px; 
  margin-bottom: 12px; 
  opacity: 0.9; 
}

.disabled-link {
  color: #bbb;
  pointer-events: none; /* makes it unclickable */
  cursor: default;
  text-decoration: none;
}

.menu-icon {
  width: 50px;
  height: auto;
  vertical-align: middle;
  margin-right: 6px;
  opacity: 0.9;
}

/* #endregion Grid Cards  */

/* #region footer  */
/* ====  Footer================ */
footer {
  border-top: 1px solid var(--border);
  background: var(--bg-alt);
  font-size: 0.8rem;
  color: var(--muted);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 10px 20px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.footer-right a i { 
  margin-right: 6px; 
}

.footer-right a[title]:hover::after {
  content: attr(title);
  position: absolute;
  background: #333;
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
  margin-left: 6px;
}

.tech-icons i {
  font-size: 32px;
  margin-right: 12px;
}

.farm-footer-logo {
  text-align: center;
  margin-top: 20px;
  margin-bottom: 20px;
}

.farm-footer-logo img {
  width: 80px;
  opacity: 0.85;
}

/* #endregion tooltip  */

/* #region Content Card */
/* === General Content Wrapper ======= */
.content { 
  max-width: var(--max-width); 
  margin: 32px auto; 
  padding: 28px 24px 32px; 
  background: var(--bg-alt); 
  border-radius: var(--radius); 
  box-shadow: var(--shadow); 
  border: 1px solid var(--border);
}

.content-card {
  background: var(--bg-alt);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  padding: 28px 24px 32px;
}
/* #endregion Content Card */

/* === floating button=== */
.floating-btn {
  position: fixed;
  right: 24px;
  bottom: 24px;
  background: var(--accent);
  color: white;
  padding: 12px 20px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  text-decoration: none;
  font-weight: 600;
}

/* === input for the images=== */
.input-select {
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid #ccc;
  font-size: 1rem;
  margin-bottom: 15px;
}

/* === Demo disclaimere === */
.demo-banner {
  background: #fff3cd;
  color: #856404;
  padding: 12px 16px;
  border-left: 4px solid #ffecb5;
  border-radius: 4px;
  margin-bottom: 20px;
  font-size: 0.95rem;
}

.level2-image {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 20px auto;
  border: 1px solid #ccc;
  border-radius: 6px;
}

/* #region tooltip  */
/* === tooltip in the core-logging === */
.tooltip-icon {
  cursor: pointer;
  font-size: 1.1rem;
  margin-left: 6px;
}

.tooltip-box {
  display: none;
  background: #f8f9fa;
  border-left: 4px solid #007bff;
  padding: 12px 16px;
  margin: 10px 0 20px 0;
  border-radius: 4px;
  font-size: 0.9rem;
}
/* #endregion tooltip  */


/* #region unit grid project/phoenix/index */
/* === unit grid project/phoenix/index === */
.unit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  margin: 20px 0;
}

.project-card {
  background: #ffffff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.project-card h3 {
  margin-top: 0;
}

.project-desc {
  color: #555;
  font-size: 0.95rem;
  margin-bottom: 16px;
}
/* #endregion*/

/* #region === project cards === */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  padding: 20px;
}

/* #endregion unit grid project/phoenix/index */

/* #region arrow */
/* ===  arrow alignment === */
.collapsible-btn {
  width: 100%;
  text-align: left;
  padding: 12px;
  background: #f1f1f1;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.collapsible-btn .icon {
  margin-right: 8px;
}

.collapsible-btn .arrow {
  transition: transform 0.3s ease;
}

.collapsible-btn.active .arrow {
  transform: rotate(180deg);
}
/* #endregion icon + arrow */

/* #region info Boxes & collapsible section */
/* ====== Collapsible Content (Final Version) + Smooth Slide‑Down Animation ===== */
.info-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
  background: #fafafa;
  border-left: 4px solid #007bff;
  border-radius: 4px;
  margin-bottom: 20px;
  padding: 0 12px; /* collapsed padding */
  }

.info-content.open {
  max-height: none; /* It works no matter how long the content is*/
  padding: 12px;     /* expanded padding */
}
/* #endregion info-content */

/*  #region === Old Engine Info Box === */
.info-box {
  margin-bottom: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-alt);
  box-shadow: var(--shadow);
}

.info-toggle {
  width: 100%;
  text-align: left;
  padding: 12px 16px;
  background: var(--bg);
  border: none;
  font-weight: 600;
  cursor: pointer;
  border-radius: var(--radius) var(--radius) 0 0;
}
/* #endregion */

/* #region === New Collapsible Section Button === */
.info-box-collapsible button {
  width: 100%;
  text-align: left;
  padding: 12px;
  background: #f1f1f1;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
}
/* #endregion info-content */

/* #region Unit Cards */
/*=== Animation to Unit Cards (Optional but nice) ===== */
.unit-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 12px;
  text-align: center;

  /* Animation */
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.unit-card img {
  max-width: 100%;
  border-radius: 4px;
  margin-bottom: 8px;
}

.unit-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
/* #endregion */

/* #region confidenceBar */
#confidenceBarContainer {
  width: 100%;
  height: 10px;
  background: #eee;
  border-radius: 6px;
  margin-top: 6px;
}

#confidenceBar {
  height: 100%;
  width: 0%;
  background: #4caf50;
  border-radius: 6px;
  transition: width 0.4s ease;
}
/* #endregion */

/* #region bagde*/
.status {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: -6px;
  margin-bottom: 10px;
}

.badge {
  display: inline-block;
  padding: 2px 6px;
  font-size: 0.7rem;
  font-weight: bold;
  border-radius: 4px;
  margin-left: 6px;
}

.badge.new {
  background: #ff4757;
  color: white;
}

.badge.updated {
  background: #1e90ff;
  color: white;
}

.badge.soon {
  background: #ffa502;
  color: white;
  padding: 2px 6px;
  font-size: 0.7rem;
  font-weight: bold;
  border-radius: 4px;
  margin-left: 6px;
}

/* #endregion*/

/* #region Page Background */
.page-background-sky {
  position: relative;
  min-height: 100vh; /* ✔ Ensures the background covers the full screen.*/ 
  z-index: 0; /* ⭐ REQUIRED: creates stacking context */
}

/* The blurred + darkened background layer */
.page-background-sky::before { /* ::before creates a separate layer */
  content: "";
  position: fixed; /* stays in place while scrolling */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: /*To make the sky more visible, you want: lighter gradient & higher brightness*/
    linear-gradient(rgba(0,0,0,0.15), rgba(0,0,0,0.15)),
    url("/assets/images/bannerSky.jpeg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: brightness(1.05) blur(2px);/* <— HERE is your filter and 1.05 slightly boosts the blue*/
  z-index: -10; /* ⭐ push FAR behind everything */
}

body.page-background-sky {
  background: none !important;
}


.page-background-rocks {
  background-image: url("/assets/images/geologyRocks.jpeg");
}

.page-background-farm {
  background-image: url("/assets/images/farmField.jpeg");
}

.page-background-hobby {
  background-image: url("/assets/images/hobbyMountains.jpeg");
}


/* #endregion */

/* #region source note*/
.source-note {
  font-size: 0.85rem;
  color: #777;
  margin-top: 5px;
}

/* #endregion*/

/* #region About*/
.about-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 40px;
  padding: 40px 20px;
}

.about-sidebar {
  background: var(--card-bg);
  padding: 20px;
  border-radius: 12px;
}

.about-sidebar h2 {
  margin-bottom: 12px;
}

.about-sidebar h3 {
  margin-top: 20px;
  margin-bottom: 8px;
}

.about-sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.about-sidebar li {
  margin-bottom: 6px;
  color: var(--muted);
}

p {
  text-align: justify;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.section-text {
  max-width: 800px;
  margin: 20px auto;
  line-height: 1.6;
  font-size: 1rem;
  color: #333;
}

section {
  margin-bottom: 40px;
}

.about-content h1 {
  margin-bottom: 20px;
}

.about-content p {
  margin-bottom: 16px;
  line-height: 1.6;
}


/* #endregion*/

/* #region Responsive Tweaks */
/* ===== Responsive Tweaks ======== */
@media (max-width: 600px) {

  /* Hero adjustments */
  .hero-card {
    padding: 20px 18px 24px;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  nav a {
    margin-left: 10px;
  }

  /* Unit cards */
  .unit-card { padding: 8px; } 
  .unit-card img { max-width: 90%; }

  /* Header fixes */
  .nav-container {
    flex-direction: column;
    align-items: flex-start;
    gap: 32px;
  }

  nav {
    flex-wrap: wrap;
    gap: 12px;
  }
}

.caption {
  font-size: 0.85rem;
  color: #666;
  font-style: italic;
  margin-top: 4px;
  display: block;
}


/* #endregion Responsive Tweaks */
/* Reset icon color so FA brand colors can apply */ 

/* #region Brand colors */
.fa-python { color: #3776AB !important; }
.fa-html5 { color: #E34F26 !important; }
.fa-css3-alt { color: #1572B6 !important; }
.fa-js { color: #F7DF1E !important; }
.fa-git-alt { color: #F05033 !important; }
.fa-linux { color: #FCC624 !important; }

/*#endregion*/