  :root {
    /* ── Palette: Jonquil accent on clean dark neutrals ── */
    --jonquil:       #EAC800;   /* primary accent yellow               */
    --arylide:       #EAD465;   /* soft yellow, secondary highlight    */
    --vanilla:       #F5EAB9;   /* warm cream, used sparingly          */
    --olive:         #7E8407;   /* only for badges/tags                */
    --moss:          #1a1c24;   /* only for deep accent panels         */

    /* Semantic aliases — neutralised, no green tint */
    --green-dark:    #111318;   /* near-black neutral dark             */
    --green-mid:     #1e2028;   /* dark neutral mid                    */
    --green-light:   #7E8407;   /* kept for badge/pill uses only       */
    --yellow-bright: #EAC800;   /* Jonquil                             */
    --yellow-soft:   #EAD465;   /* Arylide Yellow                      */
    --yellow-pale:   #18191f;   /* dark neutral background tint        */
    --cream:         #0e0f13;
    --text-dark:     #FFFFFF;   /* pure white — primary readable text  */
    --text-mid:      #C8CAD0;   /* light grey — secondary text         */
    --text-light:    #7A7D88;   /* muted grey — labels                 */
    --white:         #FFFFFF;
    /* dark surface layers — neutral charcoal, no green cast */
    --surface-1:     #0e0f13;
    --surface-2:     #13141a;
    --surface-3:     #1a1c24;
    --surface-4:     #20222d;
    --border:        rgba(255,255,255,0.08);
    --border-accent: rgba(234,200,0,0.32);
    --shadow-sm:     0 2px 8px rgba(0,0,0,0.5);
    --shadow-md:     0 6px 24px rgba(0,0,0,0.6);
    --shadow-lg:     0 16px 48px rgba(0,0,0,0.7);
    --radius:        14px;
    --radius-sm:     8px;
  }

  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

  html { scroll-behavior: smooth; }

  body {
    font-family: 'DM Sans', sans-serif;
    background: var(--surface-1);
    color: var(--text-dark);
    min-height: 100vh;
    overflow-x: hidden;
  }

  /* ─── AUTH SCREEN ─── */
  #auth-screen {
    position: fixed; inset: 0; z-index: 1000;
    display: flex;
    overflow: hidden;
  }

  /* ── Left panel — login form ── */
  .auth-left {
    width: 45%;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 48px 56px;
    background: var(--surface-1);
    position: relative;
    z-index: 2;
    overflow-y: auto;
  }

  /* ── Right panel — rice field hero ── */
  .auth-right {
    flex: 1;
    position: relative;
    overflow: hidden;
  }

  .auth-right-img {
    position: absolute; inset: 0;
    background-image: url("images/ate.jpg");
    background-size: cover;
    background-position: center;
    transform: scale(1.04);
    animation: authImgZoom 12s ease-in-out infinite alternate;
  }
  @keyframes authImgZoom {
    from { transform: scale(1.04); }
    to   { transform: scale(1.10); }
  }

  /* Dark overlay on image */
  .auth-right-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(
      135deg,
      rgba(10,20,5,0.55) 0%,
      rgba(10,10,16,0.4) 40%,
      rgba(10,10,16,0.2) 100%
    );
    z-index: 1;
  }

  /* Text block on the right image */
  .auth-right-content {
    position: absolute; bottom: 52px; left: 48px; right: 48px;
    z-index: 2;
  }

  .auth-right-tag {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(234,200,0,0.18);
    border: 1px solid rgba(234,200,0,0.35);
    backdrop-filter: blur(8px);
    border-radius: 100px;
    padding: 6px 14px;
    font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.08em;
    color: var(--yellow-bright);
    margin-bottom: 16px;
  }
  .auth-right-tag-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--yellow-bright);
    animation: pulse 2s ease-in-out infinite;
  }
  @keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
  }

  .auth-right-headline {
    font-family: 'Playfair Display', serif;
    font-size: clamp(28px, 3vw, 42px);
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
    margin-bottom: 12px;
    text-shadow: 0 2px 20px rgba(0,0,0,0.4);
  }
  .auth-right-headline span { color: var(--yellow-bright); }

  .auth-right-sub {
    font-size: 14px; color: rgba(255,255,255,0.65);
    line-height: 1.65; max-width: 380px;
    text-shadow: 0 1px 8px rgba(0,0,0,0.5);
  }

  /* Stats row on image */
  .auth-right-stats {
    display: flex; gap: 24px; margin-top: 24px;
  }
  .auth-right-stat {
    display: flex; flex-direction: column;
  }
  .auth-right-stat-num {
    font-family: 'Playfair Display', serif;
    font-size: 22px; font-weight: 700;
    color: var(--yellow-bright);
    line-height: 1;
  }
  .auth-right-stat-label {
    font-size: 11px; color: rgba(255,255,255,0.55);
    margin-top: 3px;
  }

  /* ── Left panel content ── */
  .auth-logo {
    display: flex; align-items: center; gap: 11px;
    margin-bottom: 44px;
  }

  .auth-logo-icon {
  width: 60px;
  height: 60px;
}

.logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}


  .auth-logo-text {
    font-family: 'Playfair Display', serif;
    font-size: 22px; font-weight: 700;
    color: var(--text-dark);
    letter-spacing: -0.3px;
  }
  .auth-logo-text span { color: var(--yellow-bright); }

  .auth-headline {
    font-family: 'Playfair Display', serif;
    font-size: 30px; font-weight: 700;
    color: #FFFFFF; line-height: 1.2;
    margin-bottom: 8px;
  }

  .auth-sub {
    font-size: 14px; color: #7A7D88;
    line-height: 1.65; margin-bottom: 36px;
  }

  .auth-divider {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 20px;
  }
  .auth-divider-line { flex: 1; height: 1px; background: var(--border); }
  .auth-divider-text { font-size: 12px; color: var(--text-light); white-space: nowrap; }

  .btn-google {
    width: 100%;
    display: flex; align-items: center; justify-content: center; gap: 10px;
    padding: 13px 20px;
    background: var(--surface-3);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px; font-weight: 500;
    color: var(--text-dark); cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 12px;
  }
  .btn-google:hover {
    border-color: var(--border-accent);
    background: var(--surface-4);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  }

  .btn-google-icon { width: 18px; height: 18px; flex-shrink: 0; }

  .btn-guest {
    width: 100%;
    display: flex; align-items: center; justify-content: center;
    padding: 12px 20px;
    background: transparent;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px; font-weight: 400;
    color: var(--text-light); cursor: pointer;
    transition: all 0.2s;
  }
  .btn-guest:hover {
    border-color: rgba(234,200,0,0.4);
    color: var(--yellow-bright);
  }

  .auth-footer {
    margin-top: 32px;
    font-size: 11px; color: var(--text-light);
    text-align: center; line-height: 1.7;
  }

  @keyframes authFadeUp {
    from { opacity: 0; transform: translateX(-24px); }
    to   { opacity: 1; transform: translateX(0); }
  }
  .auth-left { animation: authFadeUp 0.7s cubic-bezier(0.16,1,0.3,1) both; }
  .auth-right { animation: authFadeIn 1s ease both 0.2s; }
  @keyframes authFadeIn { from { opacity: 0; } to { opacity: 1; } }

  /* Auth responsive */
  @media (max-width: 860px) {
    #auth-screen { flex-direction: column; }
    .auth-left {
      width: 100%; padding: 36px 28px;
      justify-content: flex-start;
    }
    .auth-right { min-height: 240px; flex: none; }
    .auth-right-content { bottom: 24px; left: 24px; right: 24px; }
    .auth-right-headline { font-size: 24px; }
    .auth-right-stats { gap: 16px; }
  }
  @media (max-width: 480px) {
    .auth-left { padding: 28px 20px; }
    .auth-right { min-height: 200px; }
  }

  /* ─── MAIN APP (hidden until auth) ─── */
  #app { display: none; }
  #app.visible { display: block; animation: appFadeIn 0.5s ease both; }
  @keyframes appFadeIn { from { opacity: 0; } to { opacity: 1; } }

  /* ─── NAV ─── */
  nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 100;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 32px;
    height: 64px;
    background: rgba(10,11,16,0.96);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,0.07);
    box-shadow: 0 2px 20px rgba(0,0,0,0.4);
    transition: background 0.3s;
  }

  .nav-logo {
    display: flex; align-items: center; gap: 10px;
    text-decoration: none;
  }

  .nav-logo-icon {
  width: 50px;   
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

  .nav-logo-text {
    font-family: 'Playfair Display', serif;
    font-size: 20px; font-weight: 700;
    color: var(--text-dark);
    letter-spacing: -0.3px;
  }
  .nav-logo-text span { color: var(--yellow-bright); }

  .nav-links {
    display: flex; align-items: center; gap: 8px;
    list-style: none;
  }

  .nav-links a {
    text-decoration: none;
    font-size: 14px; font-weight: 500;
    color: var(--text-light);
    padding: 8px 14px; border-radius: var(--radius-sm);
    transition: all 0.2s;
  }
  .nav-links a:hover { background: var(--surface-4); color: var(--text-dark); }
  .nav-links a.active { background: var(--surface-4); color: var(--yellow-bright); }

  .nav-user {
    display: flex; align-items: center; gap: 10px;
  }

  .nav-user-avatar {
    width: 34px; height: 34px; border-radius: 50%;
    background: linear-gradient(135deg, var(--yellow-bright), var(--green-light));
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 600; color: var(--green-dark);
  }

  .nav-user-name {
    font-size: 13px; font-weight: 500; color: var(--text-light);
  }

  .btn-logout {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 7px 14px; border-radius: var(--radius-sm);
    background: transparent;
    border: 1.5px solid rgba(234,200,0,0.25);
    color: var(--text-light); font-family: 'DM Sans', sans-serif;
    font-size: 13px; font-weight: 500;
    cursor: pointer; transition: all 0.2s;
  }
  .btn-logout:hover {
    border-color: rgba(220,80,60,0.5);
    color: #f87171;
    background: rgba(220,80,60,0.08);
  }
  .btn-logout svg { width: 14px; height: 14px; }

  .nav-hamburger {
    display: none;
    background: none; border: none; cursor: pointer;
    flex-direction: column; gap: 5px; padding: 4px;
  }
  .nav-hamburger span {
    display: block; width: 22px; height: 2px;
    background: var(--text-dark); border-radius: 2px;
    transition: all 0.3s;
  }

  /* ─── MOBILE NAV ─── */
  .mobile-menu {
    display: none;
    position: fixed; top: 64px; left: 0; right: 0; z-index: 99;
    background: var(--surface-2);
    border-bottom: 1px solid rgba(255,255,255,0.07);
    padding: 12px 20px 20px;
    box-shadow: var(--shadow-md);
    flex-direction: column; gap: 4px;
  }
  .mobile-menu.open { display: flex; }
  .mobile-menu a {
    text-decoration: none; font-size: 15px; font-weight: 500;
    color: var(--text-mid); padding: 12px 16px; border-radius: var(--radius-sm);
    transition: background 0.2s;
  }
  .mobile-menu a:hover { background: var(--surface-4); }

  /* ─── HERO ─── */
  #home {
    position: relative; min-height: 100vh;
    display: flex; align-items: center;
    padding-top: 64px; overflow: hidden;
  }

  .hero-bg {
    position: absolute; inset: 0;
    background:
      linear-gradient(170deg, rgba(8,9,12,0.72) 0%, rgba(12,13,18,0.45) 50%, rgba(8,9,12,0.25) 100%),
      url("images/magsasaka.jpg") center/cover no-repeat;
  }

  .hero-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to bottom, transparent 60%, var(--surface-1) 100%);
  }

  .hero-content {
    position: relative; z-index: 2;
    max-width: 1100px; margin: 0 auto;
    padding: 80px 32px 100px;
    width: 100%;
  }

  .hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(234,200,0,0.18);
    border: 1px solid rgba(234,200,0,0.45);
    border-radius: 100px;
    padding: 6px 16px;
    font-size: 12px; font-weight: 600;
    color: var(--yellow-bright);
    letter-spacing: 0.08em; text-transform: uppercase;
    margin-bottom: 24px;
    animation: fadeSlideUp 0.6s 0.1s cubic-bezier(0.16,1,0.3,1) both;
  }

  .hero-badge-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--yellow-bright);
    animation: pulse 2s infinite;
  }

  @keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
  }

  .hero-headline {
    font-family: 'Playfair Display', serif;
    font-size: clamp(36px, 6vw, 68px);
    font-weight: 700; line-height: 1.08;
    color: var(--white);
    margin-bottom: 20px;
    max-width: 700px;
    animation: fadeSlideUp 0.6s 0.2s cubic-bezier(0.16,1,0.3,1) both;
  }

  .hero-headline .accent { color: var(--yellow-bright); }

  .hero-sub {
    font-size: clamp(15px, 2vw, 17px);
    color: rgba(255,255,255,0.75);
    line-height: 1.7; max-width: 520px;
    margin-bottom: 40px;
    animation: fadeSlideUp 0.6s 0.3s cubic-bezier(0.16,1,0.3,1) both;
  }

  .hero-stats {
    display: flex; flex-wrap: wrap; gap: 20px;
    margin-bottom: 44px;
    animation: fadeSlideUp 0.6s 0.4s cubic-bezier(0.16,1,0.3,1) both;
  }

  .hero-stat {
    background: rgba(255,255,255,0.06);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: var(--radius-sm);
    padding: 14px 20px;
  }

  .hero-stat-num {
    font-family: 'Playfair Display', serif;
    font-size: 26px; font-weight: 700;
    color: var(--yellow-bright); line-height: 1;
    margin-bottom: 4px;
  }

  .hero-stat-label {
    font-size: 11px; color: rgba(255,255,255,0.6);
    font-weight: 500; text-transform: uppercase; letter-spacing: 0.06em;
  }

  .hero-actions {
    display: flex; flex-wrap: wrap; gap: 14px;
    animation: fadeSlideUp 0.6s 0.5s cubic-bezier(0.16,1,0.3,1) both;
  }

  .btn-primary {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 14px 28px; border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--yellow-bright), #c8a800);
    color: var(--green-dark); font-family: 'DM Sans', sans-serif;
    font-size: 15px; font-weight: 600;
    border: none; cursor: pointer;
    box-shadow: 0 4px 20px rgba(234,200,0,0.4);
    transition: all 0.25s;
    text-decoration: none;
  }
  .btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(234,200,0,0.5); }
  .btn-primary:active { transform: translateY(0); }

  .btn-secondary {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 14px 28px; border-radius: var(--radius-sm);
    background: transparent;
    border: 1.5px solid rgba(255,255,255,0.4);
    color: var(--white); font-family: 'DM Sans', sans-serif;
    font-size: 15px; font-weight: 500;
    cursor: pointer; transition: all 0.25s;
    text-decoration: none;
  }
  .btn-secondary:hover { border-color: var(--white); background: rgba(255,255,255,0.08); }

  @keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  /* ─── SECTIONS COMMON ─── */
  section { padding: 80px 20px; }

  .section-inner {
    max-width: 1100px; margin: 0 auto;
  }

  .section-label {
    font-size: 11px; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.1em; color: var(--green-light);
    margin-bottom: 10px;
  }

  .section-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(26px, 4vw, 38px); font-weight: 700;
    color: #FFFFFF; line-height: 1.2;
    margin-bottom: 16px;
  }

  .section-desc {
    font-size: 16px; color: #8A8D99;
    line-height: 1.7; max-width: 560px;
    margin-bottom: 48px;
  }
  #advisory .section-desc { margin-left: auto; margin-right: auto; }

  /* ─── DASHBOARD SECTION ─── */
  #dashboard {
    background: var(--surface-2);
    position: relative; overflow: hidden;
  }

  #dashboard::before {
    content: '';
    position: absolute; inset: 0;
    background:
      radial-gradient(ellipse 60% 50% at 20% 40%, rgba(255,255,255,0.03) 0%, transparent 70%),
      radial-gradient(ellipse 50% 60% at 80% 70%, rgba(234,200,0,0.05) 0%, transparent 70%);
    pointer-events: none;
  }

  #dashboard .section-inner { position: relative; z-index: 1; }
  #dashboard .section-label { color: var(--yellow-bright); }
  #dashboard .section-title { color: #FFFFFF; }
  #dashboard .section-desc { color: #8A8D99; }

  .dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }

  .dashboard-card {
    background: var(--surface-3);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.45);
    transition: box-shadow 0.25s, border-color 0.25s;
  }
  .dashboard-card:hover {
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
    border-color: rgba(255,255,255,0.16);
  }

  .dashboard-card.full { grid-column: 1 / -1; }
  .dashboard-card.accent {
    background: linear-gradient(135deg, rgba(14,15,19,0.97), rgba(26,28,36,0.85));
    border: 1px solid var(--border-accent);
  }

  .card-label {
    font-size: 11px; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.08em; margin-bottom: 10px;
  }
  .dashboard-card .card-label { color: rgba(234,200,0,0.85); }
  .dashboard-card.accent .card-label { color: rgba(255,255,255,0.6); }

  .card-value {
    font-family: 'Playfair Display', serif;
    font-size: clamp(22px, 3.5vw, 36px); font-weight: 700; line-height: 1.1;
    margin-bottom: 6px; word-break: break-word;
  }
  .dashboard-card .card-value { color: var(--white); }
  .dashboard-card.accent .card-value { color: var(--white); }

  .card-sub {
    font-size: 13px; color: rgba(255,255,255,0.55);
  }
  .dashboard-card.accent .card-sub { color: rgba(255,255,255,0.65); }

  .decision-badge {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 18px; border-radius: 100px;
    font-size: 14px; font-weight: 600;
    margin-top: 14px;
  }
  .decision-badge.ok { background: rgba(100,180,0,0.2); color: #a8d840; border: 1px solid rgba(100,180,0,0.3); }
  .decision-badge.reduce { background: rgba(220,160,0,0.18); color: #f0c840; border: 1px solid rgba(220,160,0,0.3); }
  .decision-badge.stop { background: rgba(220,60,60,0.18); color: #f08080; border: 1px solid rgba(220,60,60,0.3); }
  .decision-badge-dot { width: 8px; height: 8px; border-radius: 50%; }
  .decision-badge.ok .decision-badge-dot { background: #a8d840; }
  .decision-badge.reduce .decision-badge-dot { background: #f0c840; }
  .decision-badge.stop .decision-badge-dot { background: #f08080; }

  /* ─── RISK SCORE ─── */
  .risk-score-display {
    display: flex; align-items: center; gap: 20px;
    margin-bottom: 20px;
    min-width: 0;
  }

  .risk-circle {
    width: 90px; height: 90px; border-radius: 50%; flex-shrink: 0;
    background: conic-gradient(var(--yellow-bright) 0% 38%, #e0e8c0 38% 100%);
    display: flex; align-items: center; justify-content: center;
    position: relative;
  }

  .risk-circle-inner {
    width: 66px; height: 66px; border-radius: 50%;
    background: var(--surface-3);
    display: flex; flex-direction: column; align-items: center; justify-content: center;
  }

  .risk-circle-num {
    font-family: 'Playfair Display', serif;
    font-size: 22px; font-weight: 700; color: var(--white); line-height: 1;
  }

  .risk-circle-label { font-size: 9px; color: rgba(255,255,255,0.45); text-transform: uppercase; }

  .risk-sub-bars { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }

  .risk-bar-item { }
  .risk-bar-header {
    display: flex; justify-content: space-between;
    font-size: 12px; font-weight: 500; color: rgba(255,255,255,0.7);
    margin-bottom: 5px;
  }
  .risk-bar-track {
    height: 6px; background: rgba(255,255,255,0.08); border-radius: 3px; overflow: hidden;
  }
  .risk-bar-fill {
    height: 100%; border-radius: 3px;
    transition: width 1s cubic-bezier(0.16,1,0.3,1);
  }
  .risk-bar-fill.flood  { background: linear-gradient(90deg, #6fa832, #EAC800); }
  .risk-bar-fill.stress { background: linear-gradient(90deg, #d4a000, #f0c840); }
  .risk-bar-fill.uncertainty { background: linear-gradient(90deg, #a0b820, #EAC800); }

  /* ─── WEATHER STRIP ─── */
  .weather-strip {
    display: grid; grid-template-columns: repeat(5, 1fr);
    gap: 10px; margin-top: 16px;
  }

  .weather-day {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-sm);
    padding: 12px 8px; text-align: center;
    transition: all 0.2s;
  }
  .weather-day:hover { background: rgba(234,200,0,0.08); border-color: rgba(234,200,0,0.3); }
  .weather-day.today {
    background: linear-gradient(135deg, rgba(20,22,30,0.95), rgba(26,28,36,0.85));
    border-color: rgba(234,200,0,0.35);
  }

  .weather-day-name { font-size: 10px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: rgba(255,255,255,0.4); margin-bottom: 8px; }
  .weather-day.today .weather-day-name { color: rgba(255,255,255,0.7); }

  .weather-day-icon { font-size: 0; margin-bottom: 8px; }
  .weather-icon-svg { width: 28px; height: 28px; }

  .weather-day-temp { font-family: 'Playfair Display', serif; font-size: 18px; font-weight: 600; color: var(--white); }
  .weather-day.today .weather-day-temp { color: var(--yellow-bright); }
  .weather-day-rain { font-size: 11px; color: rgba(255,255,255,0.35); margin-top: 4px; }
  .weather-day.today .weather-day-rain { color: rgba(255,255,255,0.6); }

  /* ─── ADVISORY SECTION ─── */
  #advisory { background: var(--surface-1); }
  #advisory .section-label,
  #advisory .section-title,
  #advisory .section-desc { text-align: center; max-width: 100%; }

  /* ── Step Progress Bar ── */
  .stepper-wrapper {
    max-width: 680px; margin: 0 auto 32px;
  }

  .stepper-track {
    display: flex; align-items: center; gap: 0;
    position: relative;
  }

  .stepper-item {
    flex: 1; display: flex; flex-direction: column; align-items: center;
    position: relative; z-index: 1;
  }

  .stepper-item:not(:last-child)::after {
    content: '';
    position: absolute; top: 18px; left: 50%; width: 100%; height: 2px;
    background: rgba(111,168,50,0.2);
    z-index: 0; transition: background 0.4s;
  }
  .stepper-item.completed:not(:last-child)::after {
    background: var(--green-light);
  }

  .stepper-dot {
    width: 36px; height: 36px; border-radius: 50%;
    border: 2px solid var(--border);
    background: var(--surface-3);
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 700; color: var(--text-light);
    transition: all 0.3s cubic-bezier(0.34,1.56,0.64,1);
    position: relative; z-index: 2;
  }
  .stepper-item.active .stepper-dot {
    border-color: var(--yellow-bright);
    background: var(--green-light);
    color: var(--white);
    box-shadow: 0 0 0 4px rgba(111,168,50,0.18);
    transform: scale(1.1);
  }
  .stepper-item.completed .stepper-dot {
    border-color: var(--green-mid);
    background: var(--green-mid);
    color: var(--white);
  }

  .stepper-label {
    margin-top: 8px; font-size: 11px; font-weight: 600;
    text-transform: uppercase; letter-spacing: 0.06em;
    color: var(--text-light); text-align: center;
    transition: color 0.3s;
  }
  .stepper-item.active .stepper-label { color: var(--green-mid); }
  .stepper-item.completed .stepper-label { color: var(--green-light); }

  /* ── Slider Viewport ── */
  .steps-viewport {
    overflow: hidden;
    position: relative;
    width: 100%;
  }

  .steps-track {
    display: flex;
    width: 100%;
    transition: transform 0.45s cubic-bezier(0.77,0,0.175,1);
    will-change: transform;
  }

  .form-step {
    width: 100%;
    min-width: 100%;
    flex-shrink: 0;
    padding: 0 2px;
    box-sizing: border-box;
  }

  /* ── Card inside each step ── */
  .step-card {
    background: var(--surface-3);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: var(--radius);
    padding: 32px 28px;
    box-shadow: var(--shadow-md);
    transition: box-shadow 0.25s;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
  }

  .step-card-header {
    margin-bottom: 24px;
  }
  .step-card-eyebrow {
    font-size: 10px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 0.1em; color: var(--yellow-bright);
    margin-bottom: 6px;
  }
  .step-card-title {
    font-family: 'Playfair Display', serif;
    font-size: 22px; font-weight: 700; color: var(--text-dark);
    margin-bottom: 4px;
  }
  .step-card-sub {
    font-size: 13px; color: #8A8D99; line-height: 1.5;
    word-break: break-word;
  }

  /* ── Form grid ── */
  .form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-bottom: 28px;
  }

  .form-group { display: flex; flex-direction: column; gap: 6px; }
  .form-group.full { grid-column: 1 / -1; }

  .form-label {
    font-size: 13px; font-weight: 600;
    color: #C8CAD0; letter-spacing: 0.02em;
  }
  .form-label .optional-tag {
    font-weight: 400; font-size: 11px; color: var(--text-light);
    margin-left: 6px;
  }

  .form-input, .form-select, .form-textarea {
    width: 100%; padding: 12px 16px;
    background: var(--surface-4);
    border: 1.5px solid rgba(255,255,255,0.10);
    border-radius: var(--radius-sm);
    font-family: 'DM Sans', sans-serif;
    font-size: 14px; color: #FFFFFF;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    outline: none;
  }
  .form-input:focus, .form-select:focus, .form-textarea:focus {
    border-color: var(--yellow-bright);
    background: var(--surface-1);
    box-shadow: 0 0 0 3px rgba(234,200,0,0.14);
  }
  .form-input.error, .form-select.error {
    border-color: #c03030;
    background: #1a0808;
    box-shadow: 0 0 0 3px rgba(192,48,48,0.1);
  }
  .form-select { cursor: pointer; color-scheme: dark; }
  .form-textarea { resize: vertical; min-height: 88px; line-height: 1.5; }
  .field-error-msg {
    font-size: 11px; color: #c03030; font-weight: 500; margin-top: 2px;
    display: none;
  }
  .field-error-msg.show { display: block; }

  /* ── Photo Upload ── */
  .form-upload {
    border: 2px dashed var(--border);
    border-radius: var(--radius-sm);
    padding: 24px 20px;
    text-align: center; cursor: pointer;
    background: var(--surface-2);
    transition: all 0.2s; position: relative;
  }
  .form-upload:hover { border-color: var(--yellow-bright); background: var(--surface-4); }
  .form-upload.has-image { padding: 0; border-style: solid; border-color: var(--yellow-bright); }
  .form-upload-icon { width: 34px; height: 34px; margin: 0 auto 10px; color: var(--text-light); display: block; }
  .form-upload-text { font-size: 13px; color: var(--text-light); }
  .form-upload-text strong { color: var(--green-mid); }

  .upload-preview-img {
    width: 100%; max-height: 220px; object-fit: cover;
    border-radius: calc(var(--radius-sm) - 2px);
    display: block;
  }
  .upload-preview-bar {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 14px;
    background: var(--surface-4);
    border-top: 1px solid var(--border);
    border-radius: 0 0 calc(var(--radius-sm) - 2px) calc(var(--radius-sm) - 2px);
  }
  .upload-preview-name { font-size: 12px; font-weight: 600; color: var(--green-light); }
  .upload-change-btn {
    font-size: 11px; font-weight: 600; color: var(--text-light);
    background: none; border: 1px solid rgba(111,168,50,0.3);
    border-radius: 4px; padding: 3px 8px; cursor: pointer;
    transition: all 0.15s;
  }
  .upload-change-btn:hover { border-color: var(--yellow-bright); color: var(--green-mid); }

  /* Analysis result strip */
  .analysis-strip {
    display: none; margin-top: 10px;
    background: var(--surface-4);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
  }
  .analysis-strip.show { display: block; }
  .analysis-strip-header { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }

  /* ── Image analysis mini-loader ── */
  .img-loader-orbit {
    position: relative; width: 36px; height: 36px; flex-shrink: 0;
  }
  .img-loader-ring {
    position: absolute; inset: 0; border-radius: 50%;
    border: 1.5px solid transparent;
    border-top-color: var(--yellow-bright);
    animation: orbitSpin 0.9s linear infinite;
  }
  .img-loader-ring.r2 {
    inset: 5px; border-top-color: var(--green-light);
    animation-duration: 1.4s; animation-direction: reverse;
  }
  .img-loader-core {
    position: absolute; inset: 10px; border-radius: 50%;
    background: var(--surface-4); border: 1px solid var(--border-accent);
    display: flex; align-items: center; justify-content: center;
  }

  .img-pill {
    font-size: 11px; font-weight: 600; padding: 4px 10px;
    border-radius: 100px; border: 1px solid var(--border);
    background: var(--surface-2); color: var(--text-light);
    transition: all 0.3s;
  }
  .img-pill.active {
    background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.16);
    color: var(--yellow-bright);
  }
  .img-pill.done {
    background: rgba(90,146,40,0.15); border-color: rgba(90,146,40,0.3);
    color: var(--green-light);
  }
  .analysis-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--green-light); flex-shrink: 0;
    transition: background 0.3s;
  }
  .analysis-status-lbl {
    font-size: 11px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 0.06em; color: var(--green-mid);
  }
  .analysis-body { font-size: 12px; color: var(--text-mid); line-height: 1.6; }

  /* ── Step Nav Buttons ── */
  .step-nav {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 28px; gap: 12px;
  }
  .step-nav-left { display: flex; gap: 10px; }
  .step-nav-right { display: flex; gap: 10px; }

  .btn-step-back {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 12px 20px; border-radius: var(--radius-sm);
    background: transparent;
    border: 1.5px solid var(--border);
    color: var(--text-mid); font-family: 'DM Sans', sans-serif;
    font-size: 14px; font-weight: 500; cursor: pointer;
    transition: all 0.2s;
  }
  .btn-step-back:hover { border-color: var(--yellow-bright); color: var(--text-dark); }

  .btn-step-next {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 12px 24px; border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--yellow-bright), #c8a800);
    color: var(--green-dark); border: none;
    font-family: 'DM Sans', sans-serif;
    font-size: 14px; font-weight: 700; cursor: pointer;
    box-shadow: 0 4px 16px rgba(234,200,0,0.35);
    transition: all 0.2s;
  }
  .btn-step-next:hover { transform: translateY(-1px); box-shadow: 0 6px 22px rgba(234,200,0,0.45); }
  .btn-step-next:active { transform: translateY(0); }

  .btn-step-reset {
    display: inline-flex; align-items: center; gap: 7px;
    padding: 12px 20px; border-radius: var(--radius-sm);
    background: transparent;
    border: 1.5px solid var(--border);
    color: var(--text-light); font-family: 'DM Sans', sans-serif;
    font-size: 13px; font-weight: 500; cursor: pointer;
    transition: all 0.2s;
  }
  .btn-step-reset:hover { border-color: var(--yellow-bright); color: var(--text-dark); }

  /* ── Result Card (Step 3) ── */
  .result-header {
    display: flex; align-items: flex-start; justify-content: space-between;
    margin-bottom: 20px; flex-wrap: wrap; gap: 12px;
  }
  .result-title {
    font-family: 'Playfair Display', serif;
    font-size: 21px; font-weight: 700; color: var(--text-dark);
  }
  .result-meta-lbl {
    font-size: 12px; color: var(--text-light); margin-top: 3px;
  }
  .result-body { font-size: 14px; color: var(--text-mid); line-height: 1.75; }

  /* ─── AI REC DASHBOARD CARD ─── */
  .ai-rec-body {
    display: flex; align-items: flex-start; gap: 16px;
    margin: 14px 0 12px;
  }
  .ai-rec-icon {
    flex-shrink: 0;
    width: 40px; height: 40px;
    background: linear-gradient(135deg, rgba(234,200,0,0.18), rgba(234,200,0,0.08));
    border: 1px solid var(--border-accent);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    color: var(--yellow-bright);
  }
  .ai-rec-icon svg { width: 20px; height: 20px; }
  .ai-rec-text-wrap { flex: 1; min-width: 0; }
  .ai-rec-en {
    font-size: 14px; color: var(--text-dark); line-height: 1.75;
    margin-bottom: 14px;
  }
  .ai-rec-tl-wrap {
    background: var(--surface-3);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
  }
  .ai-rec-tl-label {
    font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.08em;
    color: var(--yellow-bright); margin-bottom: 6px;
  }
  .ai-rec-tl {
    font-size: 13px; color: var(--text-mid); line-height: 1.7;
  }
  .ai-rec-meta {
    font-size: 11px; color: var(--text-light);
    border-top: 1px solid var(--border); padding-top: 10px;
  }

  .result-tagalog {
    margin-top: 16px;
    background: var(--surface-4);
    border-left: 3px solid var(--yellow-bright);
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    padding: 14px 16px;
    font-size: 14px; color: var(--text-mid); line-height: 1.7;
    font-style: italic;
  }
  .result-tagalog-label {
    font-style: normal; font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.08em;
    color: var(--text-light); margin-bottom: 6px;
  }

  /* Loading state for step 3 */
  .result-loading {
    text-align: center; padding: 48px 20px;
  }

  /* ─── RICH LOADER ─── */
  .agro-loader {
    display: flex; flex-direction: column; align-items: center; gap: 24px;
    padding: 40px 24px;
  }

  .loader-orbit {
    position: relative; width: 72px; height: 72px;
  }
  .loader-orbit-ring {
    position: absolute; inset: 0; border-radius: 50%;
    border: 2px solid transparent;
    border-top-color: var(--yellow-bright);
    animation: orbitSpin 1s linear infinite;
  }
  .loader-orbit-ring.ring2 {
    inset: 8px;
    border-top-color: var(--green-light);
    animation-duration: 1.5s;
    animation-direction: reverse;
  }
  .loader-orbit-core {
    position: absolute; inset: 20px; border-radius: 50%;
    background: radial-gradient(circle, var(--surface-4) 60%, transparent 100%);
    border: 1px solid var(--border-accent);
    display: flex; align-items: center; justify-content: center;
  }
  .loader-orbit-core svg { width: 14px; height: 14px; color: var(--yellow-bright); animation: corePulse 1.5s ease-in-out infinite; }

  @keyframes orbitSpin { to { transform: rotate(360deg); } }
  @keyframes corePulse { 0%,100% { opacity: 0.6; transform: scale(0.9); } 50% { opacity: 1; transform: scale(1.1); } }

  .loader-body { text-align: center; }
  .loader-title {
    font-family: 'Playfair Display', serif;
    font-size: 17px; font-weight: 600; color: var(--text-dark);
    margin-bottom: 6px;
  }
  .loader-subtitle {
    font-size: 13px; color: var(--text-light); line-height: 1.6;
    min-height: 40px;
  }

  .loader-steps {
    display: flex; flex-direction: column; gap: 8px; width: 100%; max-width: 320px;
  }
  .loader-step {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 14px; border-radius: var(--radius-sm);
    background: var(--surface-2); border: 1px solid var(--border);
    font-size: 13px; color: var(--text-light);
    transition: all 0.4s ease;
  }
  .loader-step.active {
    border-color: var(--border-accent);
    background: var(--surface-4);
    color: var(--text-dark);
  }
  .loader-step.done {
    border-color: rgba(90,146,40,0.35);
    color: var(--green-light);
  }
  .loader-step-icon {
    width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0;
    border: 1.5px solid currentColor;
    display: flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 700;
    transition: all 0.3s;
  }
  .loader-step.active .loader-step-icon {
    background: var(--yellow-bright); color: var(--green-dark);
    border-color: var(--yellow-bright);
    animation: stepPing 0.8s ease-in-out infinite;
  }
  .loader-step.done .loader-step-icon {
    background: var(--green-light); color: #fff; border-color: var(--yellow-bright);
  }
  @keyframes stepPing { 0%,100% { box-shadow: 0 0 0 0 rgba(234,200,0,0.4); } 50% { box-shadow: 0 0 0 5px rgba(234,200,0,0); } }

  .loader-timer {
    font-size: 12px; color: var(--text-light);
    display: flex; align-items: center; gap: 6px;
  }
  .loader-timer-bar-track {
    width: 100px; height: 3px; background: var(--surface-4);
    border-radius: 2px; overflow: hidden;
  }
  .loader-timer-bar-fill {
    height: 100%; background: linear-gradient(90deg, var(--green-light), var(--yellow-bright));
    border-radius: 2px; width: 0%;
    transition: width linear;
  }

  .result-loading-spinner {
    width: 44px; height: 44px; border-radius: 50%;
    border: 3px solid rgba(111,168,50,0.15);
    border-top-color: var(--green-light);
    animation: spin 0.8s linear infinite;
    margin: 0 auto 16px;
  }
  @keyframes spin { to { transform: rotate(360deg); } }
  .result-loading-text {
    font-size: 14px; color: var(--text-light); font-weight: 500;
  }

  /* Summary chips */
  .summary-chips {
    display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px;
  }
  .summary-chip {
    display: inline-flex; align-items: center; gap: 5px;
    background: var(--surface-4);
    border: 1px solid var(--border);
    border-radius: 100px;
    padding: 5px 12px;
    font-size: 12px; font-weight: 500; color: var(--text-mid);
  }
  .summary-chip svg { width: 12px; height: 12px; color: var(--green-light); }

  /* ─── FEATURES ─── */
  #features {
    background: var(--surface-2);
    position: relative;
    overflow: hidden;
  }
  #features::before {
    content: '';
    position: absolute; inset: 0; pointer-events: none;
    background:
      radial-gradient(ellipse 55% 60% at 15% 30%, rgba(255,255,255,0.03) 0%, transparent 65%),
      radial-gradient(ellipse 45% 50% at 85% 75%, rgba(234,200,0,0.07) 0%, transparent 65%),
      radial-gradient(ellipse 30% 40% at 50% 10%, rgba(90,146,40,0.08) 0%, transparent 60%);
  }
  #features .section-inner { position: relative; z-index: 1; }

  .features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }

  /* Glassmorphism card */
  .feature-card {
    position: relative;
    padding: 28px 24px 24px;
    border-radius: 20px;
    background: rgba(255,255,255,0.04);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow:
      0 4px 24px rgba(0,0,0,0.25),
      inset 0 1px 0 rgba(255,255,255,0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 0;
  }

  /* Subtle ambient glow on hover */
  .feature-card::before {
    content: '';
    position: absolute; inset: 0; border-radius: 20px;
    background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(234,200,0,0.07) 0%, transparent 70%);
    opacity: 0; transition: opacity 0.35s;
    pointer-events: none;
  }
  .feature-card:hover {
    transform: translateY(-6px);
    border-color: rgba(234,200,0,0.28);
    box-shadow:
      0 12px 40px rgba(0,0,0,0.35),
      0 0 0 1px rgba(234,200,0,0.1),
      inset 0 1px 0 rgba(255,255,255,0.09);
  }
  .feature-card:hover::before { opacity: 1; }

  /* Icon wrapper — coloured rounded square like the reference */
  .feature-icon-wrap {
    margin-bottom: 20px;
  }
  .feature-icon {
    width: 52px; height: 52px;
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    position: relative;
  }
  /* Each card gets a unique icon colour via nth-child */
  .feature-card:nth-child(1) .feature-icon {
    background: linear-gradient(135deg, #2d7dd2, #1a4fa8);
    box-shadow: 0 6px 20px rgba(45,125,210,0.4);
  }
  .feature-card:nth-child(2) .feature-icon {
    background: linear-gradient(135deg, #7E8407, #1a1c24);
    box-shadow: 0 6px 20px rgba(90,146,40,0.45);
  }
  .feature-card:nth-child(3) .feature-icon {
    background: linear-gradient(135deg, #EAC800, #8fa000);
    box-shadow: 0 6px 20px rgba(234,200,0,0.35);
  }
  .feature-card:nth-child(4) .feature-icon {
    background: linear-gradient(135deg, #e07830, #b85010);
    box-shadow: 0 6px 20px rgba(224,120,48,0.4);
  }
  .feature-icon svg { width: 24px; height: 24px; color: #fff; }
  .feature-card:nth-child(3) .feature-icon svg { color: var(--green-dark); }

  .feature-title {
    font-family: 'Playfair Display', serif;
    font-size: 16px; font-weight: 700; color: #FFFFFF;
    margin-bottom: 10px; line-height: 1.3;
  }

  .feature-desc {
    font-size: 13px; color: #8A8D99; line-height: 1.7;
    flex: 1;
  }

  /* ─── FOOTER ─── */
  footer {
    background: var(--green-dark);
    padding: 48px 20px;
    text-align: center;
  }

  .footer-inner { max-width: 600px; margin: 0 auto; }

  .footer-logo {
    font-family: 'Playfair Display', serif;
    font-size: 24px; font-weight: 700;
    color: var(--white); margin-bottom: 12px;
  }
  .footer-logo span { color: var(--yellow-bright); }

  .footer-tagline { font-size: 13px; color: rgba(255,255,255,0.5); margin-bottom: 28px; }

  .footer-links {
    display: flex; justify-content: center; flex-wrap: wrap; gap: 20px;
    margin-bottom: 24px; list-style: none;
  }
  .footer-links a { font-size: 13px; color: rgba(255,255,255,0.6); text-decoration: none; transition: color 0.2s; }
  .footer-links a:hover { color: var(--yellow-bright); }

  .footer-credit { font-size: 12px; color: rgba(255,255,255,0.3); }
  .footer-credit strong { color: rgba(255,255,255,0.5); }

  /* ─── RESULT CARD ENHANCEMENTS ─── */
  .result-risk-block {
    margin-top: 20px;
    padding: 18px 20px;
    background: var(--surface-2);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
  }
  .result-risk-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 10px;
  }
  .result-risk-label {
    font-size: 11px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 0.08em; color: var(--text-light);
  }
  .result-risk-score {
    font-family: 'Playfair Display', serif;
    font-size: 22px; font-weight: 700; color: var(--text-dark);
  }
  .result-risk-level {
    font-size: 12px; font-weight: 600; color: var(--text-light);
    text-align: right;
  }
  .result-risk-meter {
    width: 100%; height: 10px;
    background: rgba(111,168,50,0.12);
    border-radius: 5px; overflow: hidden;
    margin-bottom: 6px;
  }
  .result-risk-fill {
    height: 100%; border-radius: 5px;
    transition: width 1s cubic-bezier(0.16,1,0.3,1);
  }
  .result-risk-fill.low    { background: linear-gradient(90deg, #6fa832, #EAC800); }
  .result-risk-fill.medium { background: linear-gradient(90deg, #d4a000, #f0c840); }
  .result-risk-fill.high   { background: linear-gradient(90deg, #c03030, #e05050); }

  .result-weather-block {
    margin-top: 20px;
  }
  .result-weather-title {
    font-size: 12px; font-weight: 700; text-transform: uppercase;
    letter-spacing: 0.08em; color: var(--text-light);
    margin-bottom: 10px;
  }
  .result-weather-strip {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  }
  .result-weather-day {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 10px 8px; text-align: center;
  }
  .result-weather-day-name { font-size: 10px; font-weight: 700; text-transform: uppercase; color: var(--text-light); margin-bottom: 4px; }
  .result-weather-day-rain { font-size: 12px; font-weight: 600; color: #60a8f8; }
  .result-weather-day-chance { font-size: 11px; color: var(--text-light); }

  .result-actions {
    display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap;
  }
  .result-actions .btn-save {
    flex: 1; padding: 11px 16px;
    background: linear-gradient(135deg, var(--yellow-bright), #c8a800);
    color: var(--green-dark); border: none; border-radius: var(--radius-sm);
    font-family: 'DM Sans', sans-serif; font-size: 13px; font-weight: 600;
    cursor: pointer; transition: all 0.2s;
    display: flex; align-items: center; justify-content: center; gap: 6px;
  }
  .result-actions .btn-save:hover { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(234,200,0,0.4); }
  .result-actions .btn-sms {
    flex: 1; padding: 11px 16px;
    background: transparent;
    border: 1.5px solid var(--border); border-radius: var(--radius-sm);
    color: var(--text-mid); font-family: 'DM Sans', sans-serif; font-size: 13px; font-weight: 500;
    cursor: pointer; transition: all 0.2s;
    display: flex; align-items: center; justify-content: center; gap: 6px;
  }
  .result-actions .btn-sms:hover { border-color: var(--yellow-bright); color: var(--text-dark); }

  /* ─── TOAST ─── */
  #agro-toast {
    position: fixed; bottom: 28px; left: 50%; z-index: 9999;
    transform: translateX(-50%) translateY(80px);
    background: var(--green-dark);
    color: var(--white);
    padding: 14px 24px; border-radius: 100px;
    font-size: 14px; font-weight: 500;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
    display: flex; align-items: center; gap: 8px;
    transition: transform 0.35s cubic-bezier(0.16,1,0.3,1), opacity 0.35s;
    opacity: 0; pointer-events: none;
  }
  #agro-toast.show { transform: translateX(-50%) translateY(0); opacity: 1; }
  #agro-toast svg { width: 16px; height: 16px; flex-shrink: 0; }

  /* ─── SMS MODAL ─── */
  #sms-modal {
    display: none; position: fixed; inset: 0; z-index: 5000;
    align-items: center; justify-content: center;
    background: rgba(0,0,0,0.5); padding: 20px;
  }
  #sms-modal.show { display: flex; }
  .sms-modal-card {
    background: var(--surface-3); border-radius: var(--radius);
    padding: 32px 28px; width: 100%; max-width: 400px;
    animation: authFadeUp 0.35s cubic-bezier(0.16,1,0.3,1) both;
    box-shadow: 0 24px 64px rgba(0,0,0,0.5);
    border: 1px solid var(--border);
  }
  .sms-modal-title {
    font-family: 'Playfair Display', serif;
    font-size: 20px; font-weight: 700; color: var(--text-dark);
    margin-bottom: 8px;
  }
  .sms-modal-sub { font-size: 13px; color: var(--text-light); line-height: 1.6; margin-bottom: 20px; }
  .sms-modal-input {
    width: 100%; padding: 12px 16px;
    background: var(--surface-2); border: 1.5px solid var(--border);
    border-radius: var(--radius-sm); font-family: 'DM Sans', sans-serif;
    font-size: 15px; color: var(--text-dark); outline: none; margin-bottom: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
  }
  .sms-modal-input:focus { border-color: var(--yellow-bright); box-shadow: 0 0 0 3px rgba(234,200,0,0.14); }
  .sms-modal-actions { display: flex; gap: 10px; }
  .sms-modal-actions .btn-sub {
    flex: 1; padding: 12px;
    background: linear-gradient(135deg, var(--yellow-bright), #c8a800);
    color: var(--green-dark); border: none; border-radius: var(--radius-sm);
    font-family: 'DM Sans', sans-serif; font-size: 14px; font-weight: 600;
    cursor: pointer; transition: all 0.2s;
  }
  .sms-modal-actions .btn-sub:hover { transform: translateY(-1px); }
  .sms-modal-actions .btn-cancel {
    flex: 1; padding: 12px;
    background: transparent; border: 1.5px solid var(--border);
    border-radius: var(--radius-sm); color: var(--text-mid);
    font-family: 'DM Sans', sans-serif; font-size: 14px; cursor: pointer;
    transition: all 0.2s;
  }
  .sms-modal-actions .btn-cancel:hover { border-color: var(--yellow-bright); color: var(--text-dark); }

  /* ─── DASHBOARD UPDATE FLASH ─── */
  @keyframes dashFlash {
    0%   { box-shadow: inset 0 0 0 2px rgba(234,200,0,0); }
    30%  { box-shadow: inset 0 0 0 2px rgba(234,200,0,0.5); }
    100% { box-shadow: inset 0 0 0 2px rgba(234,200,0,0); }
  }
  .dashboard-card.just-updated {
    animation: dashFlash 1.2s ease both;
  }

  /* ─── ADVISORY FORM MAX WIDTH ─── */
  #advisory .section-inner > .stepper-wrapper {
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
  }
  #advisory .section-inner > .steps-viewport {
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
    /* ensure it never escapes section padding */
    width: calc(100% - 0px);
  }

  /* card-value wraps gracefully on small cards — defined in base styles */

  /* ─── RESPONSIVE ─── */
  @media (max-width: 900px) {
    .features-grid { grid-template-columns: 1fr 1fr; }
  }

  @media (max-width: 768px) {
    nav { padding: 0 16px; }
    .nav-links, .nav-user-name { display: none; }
    .nav-hamburger { display: flex; }

    section { padding: 60px 16px; }

    .hero-content { padding: 60px 16px 80px; }
    .hero-stats { gap: 10px; }
    .hero-stat { padding: 10px 14px; }
    .hero-stat-num { font-size: 22px; }

    .dashboard-grid { grid-template-columns: 1fr; }
    .dashboard-card.full { grid-column: 1; }

    .weather-strip { grid-template-columns: repeat(3, 1fr); }
    .weather-strip .weather-day:nth-child(4),
    .weather-strip .weather-day:nth-child(5) { display: none; }

    .form-grid { grid-template-columns: 1fr; gap: 14px; }
    .form-group.full { grid-column: 1; }

    .features-grid { grid-template-columns: 1fr 1fr; gap: 14px; }

    .risk-score-display { flex-direction: column; align-items: flex-start; gap: 14px; }
    .risk-sub-bars { width: 100%; }

    /* Stepper mobile */
    .stepper-wrapper { margin-bottom: 20px; }
    .stepper-label { display: none; }
    .step-card { padding: 20px 16px; }
    .step-nav {
      flex-direction: row; flex-wrap: wrap; gap: 10px;
      margin-top: 20px;
    }
    .step-nav-left { flex: 1; min-width: 0; }
    .step-nav-right { flex: 1; min-width: 0; }
    .btn-step-next,
    .btn-step-back,
    .btn-step-reset { width: 100%; justify-content: center; }

    .result-actions { flex-direction: column; }
    .result-weather-strip { grid-template-columns: repeat(3, 1fr); }

    .result-header { flex-direction: column; align-items: flex-start; }

    /* loader steps compact */
    .loader-steps { max-width: 100%; }
  }

  @media (max-width: 480px) {
    nav { padding: 0 12px; }
    section { padding: 48px 12px; }

    .auth-left { padding: 28px 20px; }

    .hero-content { padding: 48px 12px 64px; }
    .hero-actions { flex-direction: column; }
    .btn-primary, .btn-secondary { width: 100%; justify-content: center; }
    .hero-stats { flex-direction: column; gap: 8px; }
    .hero-stat { width: 100%; }

    .stepper-dot { width: 28px; height: 28px; font-size: 11px; }
    .step-card { padding: 16px 12px; }
    .step-card-title { font-size: 18px; }
    .summary-chips { gap: 6px; }

    .dashboard-card { padding: 18px 16px; }
    .weather-strip { grid-template-columns: repeat(2, 1fr); }
    .weather-strip .weather-day:nth-child(3),
    .weather-strip .weather-day:nth-child(4),
    .weather-strip .weather-day:nth-child(5) { display: none; }

    .features-grid { grid-template-columns: 1fr; gap: 12px; }
    .feature-card { padding: 22px 18px 18px; }
    .result-risk-block { padding: 14px; }
    .result-weather-strip { grid-template-columns: repeat(3, 1fr); }

    .loader-steps { gap: 6px; }
    .loader-step { padding: 7px 10px; font-size: 12px; }
  }