/* ============================================================
   HonestBooks — Marketing website stylesheet
   Brand: #0F766E (primary teal) · #14B8A6 (light teal)
          #134E4A (dark) · #F0FDF4 (mint bg)
   ============================================================ */

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

:root {
  --teal:        #0F766E;
  --teal-light:  #14B8A6;
  --teal-dark:   #134E4A;
  --teal-mid:    #0D9488;
  --mint:        #F0FDF4;
  --mint-border: #d1fae5;
  --text:        #111827;
  --text-mid:    #374151;
  --text-muted:  #6B7280;
  --border:      #E5E7EB;
  --white:       #ffffff;
  --bg:          #ffffff;
  --bg-card:     #ffffff;
  --bg-raised:   #f9fafb;
  --bg-table-head: #f3f4f6;
  --nav-bg:      rgba(255,255,255,0.92);
  --radius:      12px;
  --shadow-sm:   0 1px 3px rgba(0,0,0,0.08);
  --shadow-md:   0 4px 16px rgba(0,0,0,0.10);
  --shadow-lg:   0 8px 32px rgba(0,0,0,0.12);
}

/* ── Dark mode ── */
html.dark {
  color-scheme: dark;
  --mint:           #042f2e;
  --mint-border:    #0d5c56;
  --text:           #f1f5f9;
  --text-mid:       #cbd5e1;
  --text-muted:     #94a3b8;
  --border:         #1e293b;
  --white:          #0f172a;
  --bg:             #020617;
  --bg-card:        #0f172a;
  --bg-raised:      #0f172a;
  --bg-table-head:  #1e293b;
  --nav-bg:         rgba(2,6,23,0.92);
  --shadow-sm:      0 1px 3px rgba(0,0,0,0.4);
  --shadow-md:      0 4px 16px rgba(0,0,0,0.5);
  --shadow-lg:      0 8px 32px rgba(0,0,0,0.6);
}

html { scroll-behavior: smooth; }

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  transition: background 0.2s, color 0.2s;
}

/* ── Layout ── */
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.section    { padding: 80px 0; }

.section-header {
  text-align: center;
  max-width: 620px;
  margin: 0 auto 56px;
}
.section-header h2 { font-size: clamp(1.75rem, 3vw, 2.25rem); font-weight: 700; color: var(--teal-dark); margin-bottom: 14px; }
.section-header p  { font-size: 1.0625rem; color: var(--text-muted); }

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.1s, box-shadow 0.15s;
  white-space: nowrap;
}
.btn:hover   { transform: translateY(-1px); }
.btn:active  { transform: translateY(0); }

.btn-primary {
  background: var(--teal);
  color: #ffffff;
  border-color: var(--teal);
}
.btn-primary:hover { background: var(--teal-dark); border-color: var(--teal-dark); box-shadow: 0 4px 14px rgba(15,118,110,0.35); }

.btn-outline {
  background: transparent;
  color: var(--teal);
  border-color: var(--teal);
}
.btn-outline:hover { background: var(--mint); }

.btn-ghost {
  background: transparent;
  color: var(--text-mid);
  border-color: transparent;
}
.btn-ghost:hover { background: var(--bg-table-head); }

.btn-lg  { padding: 13px 28px; font-size: 1rem; border-radius: 10px; }
.btn-sm  { padding: 7px 14px; font-size: 0.875rem; }
.btn-block { width: 100%; }

/* ── Nav ── */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  display: flex;
  align-items: center;
  height: 64px;
  gap: 8px;
}
.logo-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.wordmark {
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--teal-dark);
  letter-spacing: -0.3px;
}
.wordmark strong { font-weight: 700; color: var(--teal); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.nav-link {
  padding: 6px 12px;
  color: var(--text-mid);
  text-decoration: none;
  font-size: 0.9375rem;
  border-radius: 6px;
  transition: background 0.12s, color 0.12s;
}
.nav-link:hover { background: var(--bg-table-head); color: var(--teal); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  margin-left: auto;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-mid);
  border-radius: 2px;
  transition: 0.2s;
}
.nav-mobile {
  display: none;
  flex-direction: column;
  padding: 12px 24px 16px;
  gap: 4px;
  border-top: 1px solid var(--border);
}
.nav-mobile a {
  padding: 10px 0;
  color: var(--text-mid);
  text-decoration: none;
  font-size: 1rem;
  border-bottom: 1px solid var(--border);
}
.nav-mobile a:last-child { border-bottom: none; }
.nav-mobile.open { display: flex; }

/* ── Hero ── */
.hero {
  background: linear-gradient(160deg, var(--mint) 0%, var(--bg-raised) 40%, var(--bg) 100%);
  padding: 96px 0 80px;
  text-align: center;
}
.hero-inner { max-width: 720px; margin: 0 auto; }
.hero-badge {
  display: inline-block;
  background: var(--mint);
  border: 1px solid var(--mint-border);
  color: var(--teal-dark);
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 24px;
  letter-spacing: 0.2px;
}
.hero-heading {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.15;
  color: var(--teal-dark);
  letter-spacing: -0.5px;
  margin-bottom: 20px;
}
.hero-sub {
  font-size: clamp(1rem, 2vw, 1.1875rem);
  color: var(--text-mid);
  max-width: 540px;
  margin: 0 auto 32px;
}
.hero-sub strong { color: var(--teal-dark); }
.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.hero-note {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* ── Trust bar ── */
.trust-bar {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 20px 0;
}
.trust-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 28px;
}
.trust-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  color: var(--text-mid);
}
.trust-item svg { color: var(--teal); flex-shrink: 0; }

/* ── Features ── */
.features { background: var(--bg); }
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 24px;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: box-shadow 0.2s, transform 0.2s;
}
.feature-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.feature-icon {
  width: 44px;
  height: 44px;
  background: var(--mint);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--teal);
  margin-bottom: 16px;
}
.feature-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--teal-dark);
  margin-bottom: 8px;
}
.feature-card p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ── Comparison ── */
.comparison { background: var(--bg-raised); }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.comp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
  min-width: 640px;
}
.comp-table th, .comp-table td {
  padding: 12px 16px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}
.comp-table th:first-child,
.comp-table td:first-child {
  text-align: left;
  font-weight: 500;
  color: var(--text-mid);
}
.comp-table thead th {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  background: var(--bg-table-head);
  padding: 14px 16px;
}
.comp-table tbody tr:last-child td { border-bottom: none; }
.comp-table tbody tr:hover td { background: var(--mint); }

.highlight-col {
  background: var(--mint);
  border-left: 2px solid var(--mint-border);
  border-right: 2px solid var(--mint-border);
}
thead .highlight-col {
  background: var(--mint);
  color: var(--teal-dark) !important;
  font-weight: 700 !important;
}

.yes      { color: var(--teal); font-weight: 600; }
.no       { color: #EF4444; }
.partial  { color: #F59E0B; }

/* ── Pricing ── */
.pricing { background: var(--mint); }
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 24px;
  max-width: 780px;
  margin: 0 auto;
}
.pricing-grid--three {
  max-width: 1060px;
  grid-template-columns: repeat(3, 1fr);
}
@media (max-width: 900px) {
  .pricing-grid--three { grid-template-columns: 1fr; }
}
.pricing-card {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: 16px;
  padding: 36px 32px;
  position: relative;
  transition: box-shadow 0.2s;
}
.pricing-card:hover { box-shadow: var(--shadow-lg); }
.pricing-card--featured {
  border-color: var(--teal);
  box-shadow: 0 0 0 4px rgba(15,118,110,0.08);
}
.plan-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--teal);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 20px;
  letter-spacing: 0.3px;
  white-space: nowrap;
}
.plan-trial-badge {
  display: inline-block;
  background: var(--mint);
  border: 1px solid var(--mint-border);
  color: var(--teal-dark);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 10px;
  letter-spacing: 0.2px;
}
.plan-name {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--teal-dark);
  margin-bottom: 8px;
}
.plan-price {
  font-size: 2.75rem;
  font-weight: 800;
  color: var(--teal);
  line-height: 1;
  margin-bottom: 8px;
  letter-spacing: -1px;
}
.plan-price span { font-size: 1rem; font-weight: 500; color: var(--text-muted); }
.plan-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 24px;
  min-height: 42px;
}
.plan-features {
  list-style: none;
  margin-top: 24px;
}
.plan-features li {
  font-size: 0.9375rem;
  color: var(--text-mid);
  padding: 6px 0;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  border-bottom: 1px solid var(--border);
}
.plan-features li:last-child { border-bottom: none; }
.plan-features .check {
  color: var(--teal);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}
.feature-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.feature-desc {
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--text-muted);
}
.pricing-note {
  text-align: center;
  margin-top: 28px;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* ── FAQ Page ── */
details.faq-item {
  border-bottom: 1px solid var(--border);
}
details.faq-item summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  line-height: 1.4;
  user-select: none;
  transition: color 0.15s;
}
details.faq-item summary::-webkit-details-marker { display: none; }
details.faq-item summary::after {
  content: '';
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
  transition: transform 0.2s ease;
}
details.faq-item[open] summary::after {
  transform: rotate(180deg);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230F766E' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
}
details.faq-item summary:hover { color: var(--teal); }
details.faq-item[open] summary { color: var(--teal); }

details.faq-item > p,
details.faq-item > ul {
  margin-bottom: 12px;
  padding-bottom: 0;
}
details.faq-item > *:last-child { margin-bottom: 20px; }

.faq-support {
  margin-top: 48px;
  padding: 32px 36px;
  background: var(--mint);
  border: 1px solid var(--mint-border);
  border-radius: var(--radius);
}
.faq-support h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--teal-dark);
  margin-bottom: 10px;
}
.faq-support p { color: var(--text-muted); margin-bottom: 0; }

/* ── Support Callout ── */
.support-callout {
  background: var(--mint);
  border-top: 1px solid var(--mint-border);
  border-bottom: 1px solid var(--mint-border);
  padding: 48px 0;
}
.support-callout-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.support-callout-icon {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  background: var(--teal);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
}
.support-callout-text { flex: 1; min-width: 220px; }
.support-callout-text h3 { font-size: 1.2rem; font-weight: 700; color: var(--teal-dark); margin-bottom: 6px; }
.support-callout-text p  { font-size: 0.9375rem; color: var(--text-muted); }
@media (max-width: 640px) {
  .support-callout-inner { flex-direction: column; text-align: center; }
  .support-callout-icon { margin: 0 auto; }
}

/* ── CTA ── */
.cta {
  background: linear-gradient(135deg, var(--teal-dark) 0%, var(--teal) 50%, var(--teal-light) 100%);
  color: var(--white);
  text-align: center;
}
.cta-inner { max-width: 520px; margin: 0 auto; }
.cta-logo  { margin-bottom: 28px; }
.cta h2    { font-size: clamp(1.75rem, 3vw, 2.25rem); font-weight: 700; margin-bottom: 12px; }
.cta p     { font-size: 1.0625rem; opacity: 0.85; margin-bottom: 28px; }
.cta .btn-primary {
  background: var(--white);
  color: var(--teal-dark);
  border-color: var(--white);
  font-size: 1.0625rem;
  padding: 14px 32px;
}
.cta .btn-primary:hover { background: var(--mint); border-color: var(--mint); }
.cta-note {
  margin-top: 14px;
  font-size: 0.8125rem;
  opacity: 0.65;
}

/* ── Footer ── */
.footer { background: var(--teal-dark); color: rgba(255,255,255,0.75); padding: 56px 0 0; }
.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand .logo-link { margin-bottom: 10px; }
.footer-brand .wordmark        { color: rgba(255,255,255,0.85); }
.footer-brand .wordmark strong { color: var(--white); }
.footer-tagline  { font-size: 0.875rem; opacity: 0.6; margin: 6px 0 4px; }
.footer-company  { font-size: 0.8125rem; opacity: 0.45; }

.footer-links { display: flex; gap: 48px; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col h4 { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.6px; color: rgba(255,255,255,0.4); margin-bottom: 4px; }
.footer-col a { color: rgba(255,255,255,0.7); text-decoration: none; font-size: 0.9rem; transition: color 0.12s; }
.footer-col a:hover { color: var(--white); }

.footer-bottom {
  padding: 16px 0;
  font-size: 0.8125rem;
  opacity: 0.4;
}
.footer-bottom .container { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }

/* ── Cookie banner ── */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 200;
  background: var(--teal-dark);
  color: rgba(255,255,255,0.9);
  border-top: 1px solid rgba(255,255,255,0.12);
  padding: 16px 24px;
}
.cookie-inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.cookie-inner p { font-size: 0.9rem; flex: 1; min-width: 240px; }
.cookie-inner a { color: var(--teal-light); }
.cookie-actions { display: flex; gap: 8px; flex-shrink: 0; }
.cookie-banner .btn-ghost { color: rgba(255,255,255,0.7); }
.cookie-banner .btn-ghost:hover { background: rgba(255,255,255,0.1); }
.cookie-banner .btn-primary { background: var(--teal-light); border-color: var(--teal-light); color: var(--teal-dark); }
.cookie-banner .btn-primary:hover { background: var(--white); border-color: var(--white); }

/* ── Legal pages ── */
.legal-hero {
  background: var(--mint);
  border-bottom: 1px solid var(--mint-border);
  padding: 48px 0 40px;
}
.legal-hero h1 { font-size: clamp(1.75rem, 3vw, 2.5rem); font-weight: 800; color: var(--teal-dark); margin-bottom: 8px; }
.legal-hero .updated { font-size: 0.875rem; color: var(--text-muted); }

.legal-body { padding: 56px 0 80px; }
.legal-body .container { max-width: 760px; }
.legal-notice {
  background: #fffbeb;
  border: 1px solid #fde68a;
}
html.dark .legal-notice {
  background: #422006;
  border-color: #78350f;
}
.legal-notice {
  border-left: 4px solid #f59e0b;
  border-radius: 8px;
  padding: 14px 18px;
  font-size: 0.875rem;
  color: #78350f;
  margin-bottom: 40px;
}

.legal-content h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--teal-dark);
  margin: 40px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.legal-content h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin: 24px 0 8px;
}
.legal-content p     { color: var(--text-mid); margin-bottom: 14px; line-height: 1.7; }
.legal-content ul    { padding-left: 22px; margin-bottom: 14px; }
.legal-content ul li { color: var(--text-mid); margin-bottom: 6px; line-height: 1.7; }
.legal-content a     { color: var(--teal); }
.legal-content a:hover { color: var(--teal-dark); }
.legal-content strong { color: var(--text); }

.legal-table-wrap { overflow-x: auto; margin-bottom: 20px; }
.legal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  min-width: 440px;
}
.legal-table th {
  background: var(--bg-raised);
  font-weight: 600;
  font-size: 0.8125rem;
  padding: 10px 14px;
  text-align: left;
  border-bottom: 2px solid var(--border);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.legal-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  color: var(--text-mid);
  vertical-align: top;
}
.legal-table tr:last-child td { border-bottom: none; }
.legal-table code { font-family: monospace; font-size: 0.85em; background: var(--bg-table-head); color: var(--text-mid); padding: 2px 6px; border-radius: 4px; }

/* ── Dark mode toggle button ── */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  flex-shrink: 0;
}
.theme-toggle:hover {
  background: var(--mint);
  color: var(--teal);
  border-color: var(--mint-border);
}
.theme-toggle .icon-sun  { display: none; }
.theme-toggle .icon-moon { display: block; }
html.dark .theme-toggle .icon-sun  { display: block; }
html.dark .theme-toggle .icon-moon { display: none; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .nav-links   { display: none; }
  .nav-toggle  { display: flex; }
  .section     { padding: 56px 0; }
  .hero        { padding: 64px 0 56px; }
  .features-grid { grid-template-columns: 1fr; }
  .pricing-grid  { grid-template-columns: 1fr; }
  .footer-inner  { grid-template-columns: 1fr; }
  .footer-links  { flex-wrap: wrap; gap: 32px; }
  .footer-bottom .container { flex-direction: column; }
  .cookie-inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 480px) {
  .hero-actions { flex-direction: column; align-items: center; }
  .trust-inner  { flex-direction: column; align-items: flex-start; padding: 0 8px; }
}
