/* ── Reset & base ── */
:root {
  color-scheme: light;
  --bg: #f7faf8;
  --card: #ffffff;
  --text: #1f2923;
  --muted: #5b665f;
  --accent: #008c45;
  --accent-hover: #006d35;
  --border: #d8e4dc;
  --radius: 12px;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

.container {
  width: min(920px, 92%);
  margin: 0 auto;
}

/* ── Site header / navbar ── */
.site-header {
  background: #ffffff;
  border-bottom: 3px solid var(--accent);
  padding: 0.55rem 0;
  box-shadow: 0 2px 8px rgba(0, 140, 69, 0.08);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  position: relative;
}

.site-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}

.site-logo img {
  height: 46px;
  width: auto;
  display: block;
}

/* ── Desktop nav ── */
.top-nav {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  align-items: center;
}

.top-nav a {
  color: #1f3028;
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.28rem 0.75rem;
  font-size: 0.875rem;
  background: var(--bg);
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
}

.top-nav a:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* ── Hamburger button (hidden on desktop) ── */
.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  padding: 0;
  margin: 0;
  flex-shrink: 0;
}

.nav-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.2s;
}

/* Animated X when open */
.nav-burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-burger.is-open span:nth-child(2) { opacity: 0; }
.nav-burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Hero ── */
.hero {
  background: linear-gradient(120deg, #008c45, #f4f7f5 52%, #cd212a);
  color: #132019;
  padding: 2rem 0;
}

.hero h1 {
  margin: 0;
  font-size: clamp(1.5rem, 5vw, 2.4rem);
  line-height: 1.25;
}

.hero p {
  margin: 0.6rem 0 0;
  font-size: clamp(0.9rem, 2.5vw, 1rem);
  max-width: 600px;
}

/* ── Main content ── */
main {
  padding: 1.2rem 0 2.5rem;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem;
  margin-bottom: 1rem;
  box-shadow: 0 4px 14px rgba(26, 59, 40, 0.07);
}

h2 {
  margin-top: 0;
  font-size: clamp(1.1rem, 3vw, 1.4rem);
  line-height: 1.3;
}

h3 {
  font-size: clamp(1rem, 2.5vw, 1.15rem);
  line-height: 1.3;
}

/* ── Form grid ── */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 0.85rem;
}

label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  font-weight: 600;
  font-size: 0.93rem;
}

input,
select,
button {
  font: inherit;
}

input,
select {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.65rem 0.75rem;
  background: #fff;
  font-size: 1rem;
  min-height: 44px;
  -webkit-appearance: none;
  appearance: none;
}

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%235b665f' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  padding-right: 2.2rem;
}

button {
  display: block;
  width: 100%;
  margin-top: 1rem;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  padding: 0.85rem 1rem;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  min-height: 48px;
  transition: background 0.15s;
}

button:hover,
button:focus-visible {
  background: var(--accent-hover);
}

#downloadReport {
  background: #cd212a;
}

#downloadReport:hover {
  background: #a41921;
}

.hint {
  margin-top: 0.75rem;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

/* ── Result cards ── */
.result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
  gap: 0.75rem;
}

.result-grid article {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.85rem;
  background: #fcfdfc;
}

.result-grid h3 {
  margin: 0 0 0.35rem;
  font-size: 0.9rem;
  color: var(--muted);
  font-weight: 600;
}

.result-grid p {
  margin: 0;
  font-size: clamp(1.1rem, 4vw, 1.3rem);
  font-weight: 700;
  color: var(--accent);
}

/* ── SEO / FAQ content ── */
.seo-content p {
  margin: 0.5rem 0;
  font-size: 0.97rem;
}

.seo-content h2 {
  margin-top: 1.4rem;
}

.seo-content h2:first-child {
  margin-top: 0;
}

.faq-list {
  display: grid;
  gap: 0.6rem;
}

.faq-list article {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.85rem;
  background: #fcfdfc;
}

.faq-list h3,
.faq-list h4 {
  margin: 0 0 0.35rem;
  font-size: 0.97rem;
  line-height: 1.4;
}

.faq-list p {
  margin: 0;
  color: var(--muted);
  font-size: 0.93rem;
}

/* ── Link grid ── */
.link-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
  gap: 0.55rem;
}

.link-grid a {
  display: flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.7rem 0.85rem;
  text-decoration: none;
  color: var(--text);
  background: #fcfdfc;
  font-size: 0.93rem;
  min-height: 44px;
  transition: border-color 0.15s, background 0.15s;
}

.link-grid a:hover {
  border-color: var(--accent);
  background: #f2f9f5;
  color: var(--accent);
}

/* ── CTA button link ── */
.btn-link {
  display: inline-flex;
  align-items: center;
  margin-top: 1rem;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  padding: 0.7rem 1.2rem;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.97rem;
  min-height: 44px;
  transition: background 0.15s;
}

.btn-link:hover {
  background: var(--accent-hover);
}

/* ── Details / breakdown ── */
details {
  margin-top: 0.85rem;
}

details summary {
  cursor: pointer;
  font-weight: 600;
  padding: 0.4rem 0;
  min-height: 44px;
  display: flex;
  align-items: center;
}

#breakdown {
  margin: 0.75rem 0 0;
  padding-left: 1rem;
  font-size: 0.93rem;
  line-height: 1.7;
}

/* ── Footer ── */
.footer {
  border-top: 1px solid var(--border);
  background: #fff;
  padding: 1rem 0;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}

/* ── Cookie banner ── */
.cookie-banner {
  position: fixed;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  width: min(900px, 94%);
  background: #1f2f24;
  color: #fff;
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.28);
  z-index: 200;
  font-size: 0.9rem;
}

.cookie-banner p {
  margin: 0;
}

.cookie-actions {
  margin-top: 0.6rem;
  display: flex;
  gap: 0.7rem;
  align-items: center;
  flex-wrap: wrap;
}

.cookie-actions button {
  width: auto;
  margin-top: 0;
  padding: 0.45rem 1rem;
  font-size: 0.9rem;
  min-height: 38px;
}

.cookie-actions a {
  color: #c4f4d8;
  font-size: 0.88rem;
}

/* ─────────────────────────────────────────
   RESPONSIVE BREAKPOINTS
───────────────────────────────────────── */

/* Tablet & small desktop */
@media (max-width: 768px) {
  /* Hamburger appears */
  .nav-burger {
    display: flex;
  }

  /* Nav hidden by default on mobile */
  .top-nav {
    display: none;
    position: absolute;
    top: calc(100% + 3px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--border);
    border-top: none;
    border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    padding: 0.75rem;
    flex-direction: column;
    gap: 0.4rem;
    z-index: 99;
  }

  /* Nav open state */
  .top-nav.nav-open {
    display: flex;
  }

  .top-nav a {
    border-radius: 8px;
    padding: 0.65rem 0.85rem;
    font-size: 0.97rem;
    min-height: 46px;
    width: 100%;
    justify-content: flex-start;
  }

  .top-nav a:hover {
    background: #f2f9f5;
    color: var(--accent);
    border-color: var(--accent);
  }

  /* Hero */
  .hero {
    padding: 1.5rem 0;
  }

  /* Cards */
  .card {
    padding: 1rem;
    border-radius: 10px;
  }

  /* Grids: 2 cols on tablet */
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .link-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Small phones */
@media (max-width: 480px) {
  .site-logo img {
    height: 38px;
  }

  .hero {
    padding: 1.2rem 0;
  }

  /* Single column on small phones */
  .grid {
    grid-template-columns: 1fr;
  }

  .result-grid {
    grid-template-columns: 1fr;
  }

  .link-grid {
    grid-template-columns: 1fr;
  }

  .card {
    padding: 0.9rem;
  }

  main {
    padding: 0.9rem 0 2rem;
  }

  /* Full-width CTA */
  .btn-link {
    display: flex;
    justify-content: center;
    width: 100%;
    text-align: center;
  }
}

/* SEO: breadcrumbs, trust footer, disclaimers */
.breadcrumbs {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.breadcrumbs ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
}

.breadcrumbs li:not(:last-child)::after {
  content: "›";
  margin-left: 0.5rem;
  color: #9aa89f;
}

.breadcrumbs a {
  color: var(--accent);
  text-decoration: none;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

.trust-footer {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

.trust-footer-meta {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

.trust-footer-meta a {
  color: var(--accent);
}

.calc-disclaimer {
  margin: 0.75rem 0 1rem;
  padding: 0.75rem 1rem;
  background: #f0f7f2;
  border-left: 4px solid var(--accent);
  font-size: 0.92rem;
  color: var(--muted);
}

.btn-secondary {
  background: #fff;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: #f3f7f4;
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 0.95rem;
}

.compare-table th,
.compare-table td {
  border: 1px solid var(--border);
  padding: 0.65rem 0.75rem;
  text-align: left;
}

.compare-table th {
  background: #f0f7f2;
  font-weight: 700;
}

.compare-table tbody tr:nth-child(even) {
  background: #fafcfb;
}

.compare-table a {
  color: var(--accent);
  font-weight: 600;
}
