:root {
    --green: #006644; --green-light: #00875a; --green-dark: #004d33;
    --gold: #c9a227; --gold-light: #f0c94d; --cream: #fdf6e3;
    --white: #fff; --text: #2d2d2d; --muted: #666;
    --border: #e0d8c0; --shadow: 0 4px 24px rgba(0,100,68,0.10);
    --radius: 14px; --header-h: 72px;
  }
  *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
  html { scroll-behavior: smooth; }
  body { font-family: 'Lato', sans-serif; background: var(--cream); color: var(--text); font-size: 16px; line-height: 1.8; }

  /* ── HEADER ── */
  header { background: linear-gradient(135deg, var(--green-dark), var(--green) 60%, var(--green-light)); position: sticky; top: 0; z-index: 1000; box-shadow: 0 2px 16px rgba(0,0,0,0.18); }
  .header-inner { max-width: 1200px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; padding: 0 20px; height: var(--header-h); }
  .logo-wrap { display: flex; align-items: center; gap: 12px; text-decoration: none; }
  .logo-wrap img { width: 52px; height: 52px; border-radius: 50%; border: 2px solid var(--gold); object-fit: cover; }
  .logo-text .site-name { font-family: 'Playfair Display', serif; font-size: 1.15rem; font-weight: 900; color: #fff; line-height: 1.2; }
  .logo-text .site-tagline { font-size: 0.7rem; color: var(--gold-light); letter-spacing: 1px; text-transform: uppercase; }
  nav { display: flex; gap: 4px; }
  nav a { color: rgba(255,255,255,0.88); text-decoration: none; font-size: 0.85rem; font-weight: 700; padding: 6px 11px; border-radius: 6px; transition: background 0.2s; }
  nav a:hover, nav a.active { background: rgba(255,255,255,0.15); color: var(--gold-light); }
  .hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px; }
  .hamburger span { display: block; width: 24px; height: 2px; background: #fff; border-radius: 2px; }
  .mobile-nav { display: none; flex-direction: column; background: var(--green-dark); padding: 12px 20px 16px; }
  .mobile-nav a { color: rgba(255,255,255,0.88); text-decoration: none; font-size: 0.9rem; font-weight: 700; padding: 9px 0; border-bottom: 1px solid rgba(255,255,255,0.08); }
  .mobile-nav.open { display: flex; }

  /* ── BREADCRUMB ── */
  .breadcrumb { background: #fff; border-bottom: 1px solid var(--border); padding: 10px 20px; font-size: 0.82rem; color: var(--muted); }
  .breadcrumb a { color: var(--green); text-decoration: none; }
  .breadcrumb span { margin: 0 6px; }

  /* ── HERO ── */
  .page-hero { background: linear-gradient(135deg, var(--green-dark), var(--green)); padding: 52px 20px 40px; text-align: center; }
  .page-hero .hero-badge { display: inline-block; background: var(--gold); color: #1a1a1a; font-size: 0.72rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; padding: 4px 14px; border-radius: 20px; margin-bottom: 14px; }
  .page-hero h1 { font-family: 'Playfair Display', serif; font-size: clamp(1.7rem, 4vw, 2.6rem); font-weight: 900; color: #fff; margin-bottom: 12px; line-height: 1.25; }
  .page-hero p { color: rgba(255,255,255,0.82); font-size: 1rem; max-width: 520px; margin: 0 auto; }

  /* ── LAYOUT ── */
  .page-layout { max-width: 1100px; margin: 0 auto; padding: 40px 20px 60px; display: grid; grid-template-columns: 1fr 300px; gap: 36px; }

  /* ── TOOL CARD ── */
  .tool-card { background: #fff; border-radius: var(--radius); padding: 36px; box-shadow: var(--shadow); }
  .tool-card h2 { font-family: 'Playfair Display', serif; font-size: 1.25rem; color: var(--green-dark); margin-bottom: 6px; }
  .tool-card .tool-sub { font-size: 0.87rem; color: var(--muted); margin-bottom: 28px; }

  /* DOB INPUT */
  .dob-group { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; margin-bottom: 24px; }
  .input-wrap label { display: block; font-size: 0.78rem; font-weight: 700; color: var(--green-dark); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 6px; }
  .input-wrap select,
  .input-wrap input[type="number"] {
    width: 100%; padding: 11px 14px; border: 2px solid var(--border); border-radius: 8px;
    font-family: 'Lato', sans-serif; font-size: 0.95rem; color: var(--text);
    background: var(--cream); transition: border 0.2s; appearance: none; -webkit-appearance: none;
  }
  .input-wrap select:focus,
  .input-wrap input[type="number"]:focus { outline: none; border-color: var(--green); background: #fff; }
  .select-wrap { position: relative; }
  .select-wrap::after { content: '▾'; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--green); pointer-events: none; font-size: 0.85rem; }

  /* CALCULATE BTN */
  .calc-btn {
    width: 100%; padding: 14px; background: linear-gradient(135deg, var(--green-dark), var(--green));
    color: #fff; border: none; border-radius: 10px; font-family: 'Playfair Display', serif;
    font-size: 1.05rem; font-weight: 700; cursor: pointer; letter-spacing: 0.5px;
    transition: opacity 0.2s, transform 0.1s; margin-bottom: 28px;
  }
  .calc-btn:hover { opacity: 0.92; }
  .calc-btn:active { transform: scale(0.99); }

  /* RESULT BOX */
  .result-box { display: none; border-radius: 12px; padding: 28px; text-align: center; margin-bottom: 20px; }
  .result-box.eligible { background: linear-gradient(135deg, #e8f5f0, #d4ede5); border: 2px solid var(--green); }
  .result-box.not-eligible { background: linear-gradient(135deg, #fff5f5, #ffe8e8); border: 2px solid #e53935; }
  .result-box.show { display: block; animation: fadeIn 0.4s ease; }
  @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

  .result-icon { font-size: 3rem; margin-bottom: 10px; }
  .result-status { font-family: 'Playfair Display', serif; font-size: 1.5rem; font-weight: 900; margin-bottom: 6px; }
  .result-box.eligible .result-status { color: var(--green-dark); }
  .result-box.not-eligible .result-status { color: #c62828; }
  .result-age { font-size: 2.2rem; font-weight: 900; color: var(--green-dark); margin: 8px 0; }
  .result-box.not-eligible .result-age { color: #c62828; }
  .result-detail { font-size: 0.88rem; color: var(--muted); line-height: 1.6; }
  .result-detail strong { color: var(--text); }

  /* AGE BREAKDOWN */
  .age-breakdown { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 18px 0 0; }
  .age-unit { background: rgba(255,255,255,0.7); border-radius: 8px; padding: 12px 8px; text-align: center; }
  .age-unit .unit-val { font-size: 1.5rem; font-weight: 900; color: var(--green-dark); line-height: 1; }
  .result-box.not-eligible .age-unit .unit-val { color: #c62828; }
  .age-unit .unit-label { font-size: 0.72rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.5px; margin-top: 3px; }

  /* NEXT BIRTHDAY */
  .next-bday { background: var(--cream); border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; margin-top: 18px; font-size: 0.87rem; color: var(--text); display: none; }
  .next-bday.show { display: block; }
  .next-bday strong { color: var(--green-dark); }

  /* ELIGIBILITY METER */
  .meter-wrap { margin-top: 20px; display: none; }
  .meter-wrap.show { display: block; }
  .meter-label { display: flex; justify-content: space-between; font-size: 0.78rem; color: var(--muted); margin-bottom: 5px; }
  .meter-bar { height: 10px; background: var(--border); border-radius: 10px; overflow: hidden; }
  .meter-fill { height: 100%; border-radius: 10px; background: linear-gradient(90deg, var(--green-dark), var(--green-light)); transition: width 0.8s ease; }

  /* RESET */
  .reset-btn { display: block; width: 100%; padding: 10px; background: none; border: 2px solid var(--border); border-radius: 8px; font-family: 'Lato', sans-serif; font-size: 0.87rem; font-weight: 700; color: var(--muted); cursor: pointer; transition: border 0.2s, color 0.2s; display: none; }
  .reset-btn:hover { border-color: var(--green); color: var(--green); }
  .reset-btn.show { display: block; }

  /* INFO CARDS */
  .info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 28px; }
  .info-item { background: var(--cream); border-radius: 10px; padding: 16px; border-left: 4px solid var(--gold); }
  .info-item .i-label { font-size: 0.75rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 4px; }
  .info-item .i-value { font-size: 1.05rem; font-weight: 700; color: var(--green-dark); }

  /* ARTICLE CONTENT */
  .article-card { background: #fff; border-radius: var(--radius); padding: 36px; box-shadow: var(--shadow); margin-top: 28px; }
  .article-card h2 { font-family: 'Playfair Display', serif; font-size: 1.2rem; color: var(--green-dark); margin: 28px 0 10px; border-left: 4px solid var(--gold); padding-left: 12px; }
  .article-card h2:first-of-type { margin-top: 0; }
  .article-card h3 { font-size: 1rem; color: var(--green); margin: 18px 0 6px; font-weight: 700; }
  .article-card p { margin-bottom: 14px; font-size: 0.93rem; color: var(--text); }
  .article-card ul { padding-left: 20px; margin-bottom: 14px; }
  .article-card li { margin-bottom: 6px; font-size: 0.93rem; }
  .article-card strong { color: var(--green-dark); }
  .article-card a { color: var(--green); }
  .article-card table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 0.88rem; }
  .article-card th { background: var(--green); color: #fff; padding: 9px 12px; text-align: left; }
  .article-card td { padding: 9px 12px; border-bottom: 1px solid var(--border); }
  .article-card tr:nth-child(even) td { background: #f8fdf6; }
  .highlight { background: #e8f5f0; border-left: 4px solid var(--green); padding: 14px 16px; border-radius: 0 10px 10px 0; margin: 16px 0; font-size: 0.9rem; }
  .warning { background: #fff8e1; border-left: 4px solid var(--gold); padding: 14px 16px; border-radius: 0 10px 10px 0; margin: 16px 0; font-size: 0.9rem; }

  /* SIDEBAR */
  .sidebar { display: flex; flex-direction: column; gap: 22px; }
  .sidebar-box { background: #fff; border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
  .sidebar-box h3 { font-family: 'Playfair Display', serif; font-size: 0.95rem; color: var(--green-dark); margin-bottom: 14px; padding-bottom: 8px; border-bottom: 2px solid var(--gold); }
  .sidebar-links a { display: flex; align-items: center; gap: 6px; text-decoration: none; color: var(--text); font-size: 0.83rem; padding: 7px 0; border-bottom: 1px solid var(--border); }
  .sidebar-links a:last-child { border-bottom: none; }
  .sidebar-links a:hover { color: var(--green); }
  .sidebar-links a::before { content: '›'; color: var(--gold); font-weight: 700; }
  .related-post { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); text-decoration: none; color: var(--text); }
  .related-post:last-child { border-bottom: none; }
  .related-thumb { width: 56px; height: 56px; border-radius: 8px; background: linear-gradient(135deg, var(--green-dark), var(--green)); display: flex; align-items: center; justify-content: center; font-size: 1.4rem; flex-shrink: 0; }
  .related-title { font-size: 0.82rem; font-weight: 700; color: var(--green-dark); line-height: 1.4; }
  .related-date { font-size: 0.75rem; color: var(--muted); margin-top: 3px; }
  .join-box { background: linear-gradient(135deg, var(--green-dark), var(--green)); color: #fff; border-radius: var(--radius); padding: 20px; text-align: center; }
  .join-box h3 { color: var(--gold-light); font-size: 0.95rem; margin-bottom: 8px; border: none; padding: 0; }
  .join-box p { font-size: 0.8rem; color: rgba(255,255,255,0.8); margin-bottom: 12px; }
  .join-btn { display: block; padding: 8px 14px; border-radius: 8px; text-decoration: none; font-size: 0.82rem; font-weight: 700; margin-bottom: 8px; }
  .join-tg { background: #229ed9; color: #fff; }
  .join-wa { background: #25d366; color: #fff; }

  /* FACT BOX */
  .fact-box { background: linear-gradient(135deg, var(--green-dark), var(--green)); color: #fff; border-radius: var(--radius); padding: 18px; }
  .fact-box h3 { color: var(--gold-light); font-size: 0.88rem; margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.5px; }
  .fact-row { display: flex; justify-content: space-between; padding: 7px 0; border-bottom: 1px solid rgba(255,255,255,0.1); font-size: 0.82rem; }
  .fact-row:last-child { border-bottom: none; }
  .fact-row .f-label { color: rgba(255,255,255,0.7); }
  .fact-row .f-val { color: var(--gold-light); font-weight: 700; }

  /* FLOAT */
  .float-btns { position: fixed; bottom: 28px; right: 20px; display: flex; flex-direction: column; gap: 12px; z-index: 9999; }
  .float-btn { width: 52px; height: 52px; border-radius: 50%; display: flex; align-items: center; justify-content: center; text-decoration: none; box-shadow: 0 4px 16px rgba(0,0,0,0.22); transition: transform 0.2s; }
  .float-btn:hover { transform: scale(1.12); }
  .float-wa { background: #25d366; } .float-tg { background: #229ed9; }
  .float-btn svg { width: 26px; height: 26px; fill: #fff; }

  /* FOOTER */
  footer { background: #0d1f17; color: rgba(255,255,255,0.5); padding: 28px 20px; margin-top: 40px; }
  .footer-inner { max-width: 1160px; margin: 0 auto; }
  .footer-links { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 16px; font-size: 0.82rem; }
  .footer-links a { color: var(--gold-light); text-decoration: none; }
  .footer-bottom { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; font-size: 0.8rem; border-top: 1px solid rgba(255,255,255,0.08); padding-top: 14px; }
  .footer-bottom a { color: var(--gold-light); text-decoration: none; }

  @media (max-width: 900px) {
    nav { display: none; } .hamburger { display: flex; }
    .page-layout { grid-template-columns: 1fr; }
  }
  @media (max-width: 560px) {
    .dob-group { grid-template-columns: 1fr; }
    .info-grid { grid-template-columns: 1fr; }
    .age-breakdown { grid-template-columns: repeat(3, 1fr); }
    .tool-card { padding: 24px 16px; }
    .article-card { padding: 24px 16px; }
  }