/* ===== GreenTea.st — main.css v2.0 ===== */
/* Complete replacement for assets/css/main.css */

/* ---------- Design Tokens ---------- */
:root {
  --ink: #111827;        /* near-black — high contrast */
  --body: #374151;       /* dark gray for body text — WCAG AA on white */
  --muted: #4b5563;      /* medium gray — still readable */
  --faint: #9ca3af;      /* light gray — captions only */
  --bg: #ffffff;         /* white base */
  --surface: #f9fafb;    /* light gray surface */
  --border: #e5e7eb;
  --brand: #0d7f4d;      /* green — passes AA on white */
  --brand-dark: #065f38;
  --brand-bg: #ecfdf5;   /* very light green tint */
  --accent: #1d4ed8;     /* links — blue */
  --meta-blue: #1d4ed8;
  --line-height: 1.7;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 16px;
  line-height: var(--line-height);
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
html, body { max-width: 100%; overflow-x: hidden; }
html { scroll-behavior: smooth; }

/* ---------- Layout ---------- */
.gt-container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* ---------- Buttons ---------- */
.gt-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--brand); color: #fff;
  padding: 12px 22px; border-radius: 10px;
  font-weight: 600; font-size: 15px;
  border: none; cursor: pointer;
  transition: background .15s, transform .15s;
}
.gt-btn:hover { background: var(--brand-dark); transform: translateY(-1px); }
.gt-btn-lg { padding: 14px 28px; font-size: 16px; }
.gt-btn-icon { font-size: 18px; }
.gt-btn-ghost {
  display: inline-flex; align-items: center;
  color: var(--brand); font-weight: 600; font-size: 15px;
  padding: 14px 8px;
  transition: color .15s;
}
.gt-btn-ghost:hover { color: var(--brand-dark); }

/* ---------- Header ---------- */
.gt-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--brand);
  border-bottom: none;
  box-shadow: 0 2px 8px rgba(0,0,0,.12);
}
.gt-header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 62px;
}
.gt-brand a, .gt-brand a strong,
.gt-header .gt-brand .custom-logo-link,
.gt-header .gt-brand { color: #fff !important; font-size: 20px; font-weight: 700; }
.gt-menu { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.gt-menu li a {
  padding: 8px 14px; border-radius: 8px;
  font-weight: 600; color: #fff !important; font-size: 15px;
  transition: background .15s;
}
.gt-menu li a:hover { background: rgba(255,255,255,.18); }

/* ---------- Hero ---------- */
.gt-hero {
  background: linear-gradient(170deg, #f0faf2 0%, #fff 50%, #f9fafb 100%);
  border-bottom: 1px solid var(--border);
  padding: 60px 0 52px;
  position: relative;
}
.gt-hero-layout {
  display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: center;
}
.gt-hero-copy h1 {
  font-size: clamp(32px, 4.5vw, 46px);
  line-height: 1.12; font-weight: 800;
  color: var(--ink); margin: 0 0 16px;
  letter-spacing: -0.5px;
}
.gt-hero-sub {
  font-size: 17px; color: var(--body); line-height: 1.65;
  margin: 0 0 28px; max-width: 480px;
}
.gt-hero-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.gt-hero .gt-btn-lg {
  padding: 15px 30px; font-size: 16px; border-radius: 12px;
  box-shadow: 0 4px 14px rgba(13,127,77,.3);
}
.gt-hero .gt-btn-lg:hover { box-shadow: 0 6px 20px rgba(13,127,77,.35); }
.gt-hero .gt-btn-ghost { font-size: 15px; padding: 15px 10px; }
.gt-hero-note {
  font-size: 13px; color: var(--faint); margin: 18px 0 0;
  letter-spacing: .2px;
}

/* Hero stats */
.gt-hero-stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px;
}
.gt-stat {
  background: #fff; border: 1px solid var(--border); border-radius: 14px;
  padding: 22px 14px; text-align: center;
  transition: transform .2s, box-shadow .2s;
}
.gt-stat:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,.06); }
.gt-stat-num {
  display: block; font-size: 24px; font-weight: 800; color: var(--brand);
  line-height: 1.2;
}
.gt-stat-label {
  display: block; font-size: 12px; color: var(--muted); margin-top: 6px;
  font-weight: 600; text-transform: uppercase; letter-spacing: .5px;
}

/* ---------- Section heads ---------- */
.gt-section-head-center {
  text-align: center; max-width: 640px; margin: 0 auto 32px;
}
.gt-section-head-center h2 {
  font-size: clamp(22px, 3vw, 30px); font-weight: 700;
  color: var(--ink); margin: 0 0 10px; line-height: 1.25;
}
.gt-section-head-center p {
  font-size: 16px; color: var(--body); margin: 0; line-height: 1.6;
}

/* ---------- Calculator Section ---------- */
.gt-calc-section {
  padding: 56px 0; background: #fff;
  border-bottom: 1px solid var(--border);
}

/* ---------- FAQ Section ---------- */
.gt-faq-section {
  padding: 56px 0; background: #f8faf8;
  border-bottom: 1px solid var(--border);
}
.gt-faq-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 32px;
}
.gt-faq-col h3 {
  font-size: 14px; font-weight: 700; color: var(--brand);
  text-transform: uppercase; letter-spacing: 1px;
  margin: 0 0 16px; padding-bottom: 10px;
  border-bottom: 2px solid var(--brand);
}
.gt-faq-item {
  background: #fff; border: 1px solid var(--border); border-radius: 10px;
  margin-bottom: 10px; overflow: hidden;
  transition: box-shadow .2s, border-color .2s;
}
.gt-faq-item[open] { box-shadow: 0 2px 12px rgba(0,0,0,.05); border-color: #c6e7d4; }
.gt-faq-item summary {
  padding: 15px 18px; font-weight: 600; font-size: 15px;
  color: var(--ink); cursor: pointer;
  list-style: none; display: flex; align-items: center; justify-content: space-between;
  transition: background .15s, color .15s;
}
.gt-faq-item summary:hover { background: #f0faf2; }
.gt-faq-item[open] summary { color: var(--brand); background: #f0faf2; }
.gt-faq-item summary::-webkit-details-marker { display: none; }
.gt-faq-item summary::after {
  content: '+'; font-size: 20px; font-weight: 400; color: var(--faint);
  flex-shrink: 0; margin-left: 12px;
  transition: transform .2s, color .2s;
}
.gt-faq-item[open] summary::after { content: '−'; color: var(--brand); }
.gt-faq-answer {
  padding: 0 18px 16px;
}
.gt-faq-answer p {
  margin: 0; font-size: 14.5px; color: var(--body); line-height: 1.7;
}
.gt-faq-answer strong { color: var(--ink); }

/* ---------- Newsletter ---------- */
.gt-newsletter-section {
  padding: 56px 0; background: #fff;
}
.gt-newsletter-box {
  max-width: 560px; margin: 0 auto; text-align: center;
  background: var(--brand-bg); border: 1px solid #bbf7d0;
  border-radius: 20px; padding: 44px 36px;
}
.gt-newsletter-copy h2 {
  font-size: 26px; font-weight: 700; color: var(--ink); margin: 0 0 8px;
}
.gt-newsletter-copy p {
  font-size: 15px; color: var(--body); margin: 0 0 24px;
}
.gt-newsletter-form {
  display: flex; gap: 8px;
}
.gt-newsletter-form input {
  flex: 1; min-width: 0; padding: 13px 16px;
  border: 1px solid var(--border); border-radius: 10px;
  font-size: 15px; background: #fff; color: var(--ink);
}
.gt-newsletter-form input::placeholder { color: var(--faint); }
.gt-newsletter-form input:focus {
  outline: none; border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(13,127,77,.12);
}
.gt-newsletter-form .gt-btn {
  padding: 13px 22px; white-space: nowrap;
}
.gt-newsletter-fine {
  font-size: 12px; color: var(--faint); margin: 14px 0 0;
}

/* ---------- Footer ---------- */
.gt-footer {
  background: var(--surface); border-top: 1px solid var(--border); margin-top: 0;
}
.gt-footer .gt-container {
  max-width: 1080px; margin: 0 auto; padding: 0 20px;
}
.gt-footer-grid {
  display: grid; grid-template-columns: 1.3fr 1fr 1fr;
  gap: 24px; padding: 32px 0;
}
.gt-footer-grid h4 {
  font-size: 14px; font-weight: 700; color: var(--ink); margin: 0 0 10px;
}
.gt-footer-logo { font-size: 18px; font-weight: 700; margin-bottom: 6px; }
.gt-footer-grid p { color: var(--muted); font-size: 14px; margin: 0; }
.gt-links {
  list-style: none; margin: 0; padding: 0;
  display: flex; gap: 16px; flex-wrap: wrap;
}
.gt-links li a {
  font-size: 14px; color: var(--muted); transition: color .15s;
}
.gt-links li a:hover { color: var(--brand); }

/* Footer newsletter (reuse) */
.gt-footer .gt-newsletter {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.gt-footer .gt-newsletter input {
  flex: 1; min-width: 0; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 8px;
  font-size: 14px; background: #fff;
}
.gt-footer .gt-newsletter button {
  background: var(--brand); color: #fff; border: none; border-radius: 8px;
  padding: 10px 16px; font-weight: 600; font-size: 14px; cursor: pointer;
}

/* Disclosure */
.gt-copy {
  padding: 16px 0; border-top: 1px solid var(--border);
  font-size: 13px; color: var(--muted);
}
.gt-footer-disclosure { font-size: 14px; line-height: 1.6; margin: 0 0 8px; }
.gt-owner-line { display: block; text-align: center; }
.gt-highlight {
  background: #fef08a; padding: 4px 10px; border-radius: 6px;
  display: inline-block; font-weight: 600; color: var(--ink);
}

/* ---------- Sticky Quiz Button (mobile) ---------- */
.gt-sticky-quiz {
  position: fixed; z-index: 999;
  left: 0; right: 0; bottom: 14px;
  display: none;
  max-width: 480px; margin: 0 auto;
  background: var(--brand); color: #fff;
  text-align: center; font-weight: 600;
  padding: 12px 18px; border-radius: 50px;
  box-shadow: 0 4px 16px rgba(0,0,0,.18);
  font-size: 15px;
  transform: translateZ(0);
}
@supports (bottom: max(0px)) {
  .gt-sticky-quiz { bottom: max(14px, env(safe-area-inset-bottom)); }
}
@media (max-width: 768px) { .gt-sticky-quiz { display: block; } }

/* ---------- Single Post ---------- */
.gt-article-header { margin: 0 0 1rem; }
.gt-title {
  margin: 0 0 .5rem;
  font-size: clamp(1.75rem, 2.2vw, 2.25rem);
  line-height: 1.2; color: var(--ink);
}
.gt-meta { color: var(--muted); font-size: .95rem; margin: 0 0 1.25rem; }
.gt-meta a { color: inherit; }
body.single .gt-meta time { color: var(--meta-blue); }
body.single .gt-meta .gt-author a { color: var(--meta-blue); text-decoration: underline; }
.gt-content > * + * { margin-top: 1rem; }

/* Content readability */
.gt-main p, .gt-main li {
  line-height: var(--line-height); color: var(--body);
}
.gt-main p { margin: 0 0 1.1rem; }
.gt-main { word-break: break-word; overflow-wrap: anywhere; }
sup, sub { font-size: .75em; line-height: 0; }

/* Content links on non-home pages */
body:not(.home) .gt-main a:not(.gt-btn):not(.wp-block-button__link) {
  color: var(--accent); text-decoration: underline;
}

/* Desktop single width */
@media (min-width: 1025px) {
  body.single .gt-main > .gt-container { max-width: 780px; margin: 0 auto; }
}

/* ========== RESPONSIVE ========== */

@media (max-width: 1024px) {
  .gt-hero-layout { grid-template-columns: 1fr; gap: 24px; }
  .gt-hero-stats { grid-template-columns: repeat(3, 1fr); }
  .gt-faq-grid { grid-template-columns: 1fr; gap: 24px; }
  .gt-footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .gt-hero { padding: 36px 0 32px; }
  .gt-hero-copy h1 { font-size: 28px; }
  .gt-calc-section, .gt-faq-section, .gt-newsletter-section { padding: 40px 0; }
  .gt-newsletter-form { flex-direction: column; }
  .gt-newsletter-form input, .gt-newsletter-form .gt-btn { width: 100%; justify-content: center; }
  .gt-newsletter-box { padding: 28px 20px; }
}

@media (max-width: 640px) {
  .gt-container { padding: 0 16px; }
  .gt-hero-layout { gap: 20px; }
  .gt-hero-stats { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .gt-stat { padding: 14px 8px; }
  .gt-stat-num { font-size: 18px; }
  .gt-stat-label { font-size: 11px; }
  .gt-hero-actions { flex-direction: column; align-items: stretch; }
  .gt-btn-ghost { justify-content: center; }
  .gt-footer-grid { grid-template-columns: 1fr; }
  .gt-footer .gt-newsletter { flex-direction: column; gap: 8px; }
  .gt-footer .gt-newsletter input { width: 100%; }

  /* Mobile content gutters */
  body.single .gt-main > .gt-container,
  body.page .gt-main > .gt-container {
    background: #fff; padding: 16px !important;
    margin: 0 8px !important; border-radius: 12px;
  }

  .gt-sticky-quiz {
    font-size: 14px; padding: 11px 16px;
    left: 16px; right: 16px; max-width: none;
  }
}

/* Homepage overflow clamp */
body.home, body.home .gt-main { max-width: 100%; overflow-x: hidden; }

/* ---------- Post cards (used on archive/category pages) ---------- */
.gt-post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.gt-post-card {
  background: #fff; border: 1px solid var(--border); border-radius: 12px;
  overflow: hidden; transition: box-shadow .2s;
}
.gt-post-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.06); }
.gt-post-card img { width: 100%; aspect-ratio: 1/1; object-fit: cover; }
.gt-post-card h3 { margin: 12px; font-size: 16px; color: var(--ink); }
.gt-post-card .gt-excerpt { margin: 0 12px 14px; color: var(--muted); font-size: 14px; }
.gt-section-head {
  display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px;
}
.gt-view-all { color: var(--accent); font-weight: 600; font-size: 14px; }
.gt-view-all:hover { text-decoration: underline; }

@media (max-width: 1024px) { .gt-post-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .gt-post-grid { grid-template-columns: 1fr; } }

/* ---------- Tea facts cards (kept for /teas or internal pages) ---------- */
.gt-tea-facts { padding: 40px 0; background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.gt-facts-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 12px; }
.gt-fact-card { background: #fff; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.gt-card-link { display: flex; flex-direction: column; gap: 8px; padding: 16px; transition: background .15s; }
.gt-card-link:hover { background: var(--surface); }
.gt-fact-card img { width: 100%; height: 160px; object-fit: cover; }
.gt-fact-card h3 { margin: 0; font-size: 16px; color: var(--ink); }
.gt-fact-desc { color: var(--body); margin: 0; font-size: 14px; }
.gt-cta { display: inline-block; margin-top: 6px; color: var(--accent); font-weight: 600; font-size: 14px; }
@media (max-width: 1024px) { .gt-facts-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .gt-facts-grid { grid-template-columns: 1fr; } }