/*
Theme Name: AOA Child
Theme URI: https://artofarticle.com
Description: Art of Article child theme — Free Calculator Hub
Author: Art of Article
Author URI: https://artofarticle.com
Template: generatepress
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: aoa-child
*/

/* ============================================================
   1. CSS CUSTOM PROPERTIES
   ============================================================ */
:root {
  --color-primary:      #1b2d6b;
  --color-accent:       #4361ee;
  --color-success:      #10b981;
  --color-warning:      #f59e0b;
  --color-danger:       #ef4444;
  --color-bg:           #f0f4ff;
  --color-surface:      #ffffff;
  --color-border:       #dde3f4;
  --color-text:         #111827;
  --color-text-muted:   #64748b;
  --radius-sm:          8px;
  --radius-md:          12px;
  --radius-lg:          16px;
  --shadow-sm:          0 1px 4px rgba(27,45,107,.08);
  --shadow-md:          0 4px 20px rgba(27,45,107,.14);
  --container-max:      1200px;
  --gap:                16px;
  --transition:         0.18s ease;
  --header-height:      64px;
}

/* ============================================================
   2. BASE RESET + BODY
   ============================================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* GeneratePress compat: its .site-content is display:flex for sidebar layouts.
   Our theme is full-width on all pages — force block layout. */
.site-content,
#content.site-content,
.site-content.site-main {
  display: block !important;
  width: 100%;
  max-width: 100%;
  padding: 0 !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}
/* Remove any GeneratePress sidebar gutter */
.content-area {
  width: 100% !important;
  float: none !important;
}
/* Kill GP's own footer element and any body/page bottom spacing */
.site-footer { display: none !important; }
body { margin-bottom: 0 !important; padding-bottom: 0 !important; }
#page, .site { padding-bottom: 0 !important; margin-bottom: 0 !important; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--color-primary); }

img, svg { display: block; max-width: 100%; }

ul, ol { list-style: none; }

input, button, select, textarea {
  font-family: inherit;
  font-size: 16px; /* prevents iOS zoom */
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.25;
  color: var(--color-text);
}

/* ============================================================
   3. CONTAINER
   ============================================================ */
.container {
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
  width: 100%;
}

/* ============================================================
   4. HEADER
   ============================================================ */
.aoa-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #0d1a35;
  border-bottom: 1.5px solid rgba(79,99,255,.35);
  height: var(--header-height);
  transition: height var(--transition), box-shadow var(--transition);
  box-shadow: 0 2px 16px rgba(0,0,0,.3);
}

.aoa-header .container {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 24px;
}

.aoa-header.scrolled {
  height: 52px;
  box-shadow: 0 2px 20px rgba(0,0,0,.35);
  background: #0a1428;
}

/* Logo */
.aoa-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  color: white;
  font-weight: 700;
  font-size: 16px;
  text-decoration: none;
}
.aoa-logo:hover { color: rgba(255,255,255,.85); }

.aoa-logo__icon {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.aoa-logo__text { display: flex; flex-direction: column; line-height: 1.1; }
.aoa-logo__name { font-size: 15px; font-weight: 700; color: white; }
.aoa-logo__tagline { font-size: 10px; font-weight: 400; color: rgba(255,255,255,.55); letter-spacing: 0.02em; }

/* ============================================================
   5. NAVIGATION
   ============================================================ */
.aoa-nav {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.aoa-nav__list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.aoa-nav__item { position: relative; display: flex; align-items: center; }

.aoa-nav__link {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 13px;
  font-size: 13px;
  font-weight: 600;
  color: rgba(255,255,255,.8);
  border-radius: 100px;
  transition: color var(--transition), background var(--transition);
  white-space: nowrap;
  min-height: 36px;
  text-decoration: none;
  position: relative;
  border: none;
  background: transparent;
  cursor: pointer;
  letter-spacing: .01em;
  line-height: 1;
}
.aoa-nav__link::after { display: none; }
.aoa-nav__link:hover {
  color: white;
  background: rgba(255,255,255,.12);
}
.aoa-nav__link.is-active {
  color: white;
  background: rgba(255,255,255,.18);
}

.aoa-nav__arrow {
  width: 12px;
  height: 12px;
  transition: transform var(--transition);
}
.aoa-nav__item:hover .aoa-nav__arrow,
.aoa-nav__item.is-open .aoa-nav__arrow { transform: rotate(180deg); }

/* Mega menu */
.aoa-mega-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  width: 680px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: 20px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity var(--transition), visibility var(--transition), transform var(--transition);
  transform: translateX(-50%) translateY(-4px);
}
.aoa-nav__item:hover .aoa-mega-menu,
.aoa-nav__item.is-open .aoa-mega-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.aoa-mega-menu__col-title {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  padding: 0 8px 8px;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 4px;
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.aoa-mega-menu__col-title span { padding: 0 4px; }

.aoa-mega-menu__link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 8px;
  font-size: 13px;
  color: var(--color-text);
  border-radius: var(--radius-sm);
  transition: background var(--transition), color var(--transition);
  text-decoration: none;
}
.aoa-mega-menu__link:hover { background: var(--color-bg); color: var(--color-accent); }
.aoa-mega-menu__link-icon { font-size: 16px; line-height: 1; }

.aoa-mega-menu__footer {
  grid-column: 1 / -1;
  border-top: 1px solid var(--color-border);
  margin-top: 8px;
  padding-top: 12px;
  display: flex;
  justify-content: flex-end;
}

/* Hamburger */
.aoa-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius-sm);
  margin-left: auto;
}
.aoa-hamburger:hover { background: rgba(255,255,255,.12); }
.aoa-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,.85);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}
.aoa-hamburger.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.aoa-hamburger.is-active span:nth-child(2) { opacity: 0; }
.aoa-hamburger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav panel */
.aoa-nav__mobile {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-md);
  padding: 16px 20px;
  z-index: 999;
  max-height: calc(100vh - var(--header-height));
  overflow-y: auto;
  transform: translateY(-8px);
  opacity: 0;
  transition: transform var(--transition), opacity var(--transition);
}
.aoa-nav__mobile.is-open {
  display: block;
  transform: translateY(0);
  opacity: 1;
}
.aoa-nav__mobile-link {
  display: flex;
  align-items: center;
  padding: 12px 8px;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text);
  border-bottom: 1px solid var(--color-border);
  text-decoration: none;
}
.aoa-nav__mobile-link:last-child { border-bottom: none; }
.aoa-nav__mobile-link:hover { color: var(--color-accent); }

/* Header CTA */
.aoa-header-cta {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}
.aoa-header-cta__btn {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 16px;
  background: rgba(255,255,255,.15);
  color: white;
  font-size: 13px;
  font-weight: 600;
  border-radius: 100px;
  text-decoration: none;
  border: 1.5px solid rgba(255,255,255,.3);
  transition: background var(--transition), border-color var(--transition);
  white-space: nowrap;
}
.aoa-header-cta__btn:hover {
  background: rgba(255,255,255,.25);
  border-color: rgba(255,255,255,.5);
  color: white;
}

/* ============================================================
   6. HERO SECTION
   ============================================================ */
.aoa-hero {
  background: linear-gradient(135deg, #0f1f5c 0%, #1e40af 55%, #2563eb 100%);
  color: white;
  text-align: center;
  padding: 64px 20px 56px;
  position: relative;
  overflow: hidden;
}
/* Compact hero variant — cards visible on first visit */
.aoa-hero--compact { padding: 28px 20px 24px; }
.aoa-hero--compact .aoa-hero__title { font-size: clamp(22px, 4vw, 40px); margin-bottom: 10px; }
.aoa-hero--compact .aoa-hero__subtitle { margin-bottom: 18px; }
.aoa-hero--compact .aoa-hero__search { margin-bottom: 0; }
.aoa-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 20% 50%, rgba(255,255,255,.06) 0%, transparent 50%),
                    radial-gradient(circle at 80% 20%, rgba(255,255,255,.05) 0%, transparent 40%);
  pointer-events: none;
}

.aoa-hero__eyebrow {
  display: inline-block;
  background: rgba(255,255,255,.15);
  color: rgba(255,255,255,.9);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 100px;
  margin-bottom: 20px;
}

.aoa-hero__title {
  font-size: clamp(28px, 5vw, 52px);
  font-weight: 800;
  color: white;
  line-height: 1.15;
  margin-bottom: 16px;
}

.aoa-hero__title span { color: #7dd3fc; }

.aoa-hero__subtitle {
  font-size: clamp(15px, 2vw, 18px);
  color: rgba(255,255,255,.75);
  max-width: 540px;
  margin: 0 auto 32px;
}

/* Search bar */
.aoa-hero__search {
  max-width: 560px;
  margin: 0 auto 40px;
  position: relative;
}

.aoa-hero__search-input {
  width: 100%;
  height: 52px;
  padding: 0 140px 0 52px;
  background: white;
  border: none;
  border-radius: 100px;
  font-size: 15px;
  color: var(--color-text);
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
  outline: none;
}
.aoa-hero__search-input::placeholder { color: var(--color-text-muted); }
.aoa-hero__search-input:focus { box-shadow: 0 8px 32px rgba(0,0,0,.25), 0 0 0 3px rgba(79,99,255,.4); }

.aoa-hero__search-icon {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-muted);
  pointer-events: none;
}

.aoa-hero__search-btn {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  height: 40px;
  padding: 0 20px;
  background: var(--color-accent);
  color: white;
  border: none;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition);
}
.aoa-hero__search-btn:hover { background: #3d4fe0; }

/* Autocomplete */
.aoa-search-results {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: white;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  display: none;
  z-index: 100;
  text-align: left;
}
.aoa-search-results.is-open { display: block; }
.aoa-search-result-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  cursor: pointer;
  font-size: 14px;
  color: var(--color-text);
  transition: background var(--transition);
}
.aoa-search-result-item:hover { background: var(--color-bg); }

/* Hero stats */
.aoa-hero__stats {
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
}

.aoa-hero__stat { display: flex; flex-direction: column; align-items: center; }
.aoa-hero__stat-value {
  font-size: 24px;
  font-weight: 800;
  color: white;
  line-height: 1;
}
.aoa-hero__stat-label {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  margin-top: 4px;
}

/* ============================================================
   7. CALCULATOR GRID
   ============================================================ */
.aoa-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(172px, 1fr));
  gap: 12px;
}

@media (max-width: 480px) {
  .aoa-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
}

/* ============================================================
   8. CALCULATOR CARD
   ============================================================ */
.aoa-card {
  background: var(--color-surface);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
  position: relative;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  text-decoration: none;
  color: inherit;
  overflow: hidden;
}
.aoa-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(67,97,238,.18);
  border-color: var(--color-accent);
  color: inherit;
}

.aoa-card__icon,
.aoa-card__icon-wrap {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  margin-bottom: 2px;
}

/* Absolute badge overlay — top-right corner */
.aoa-card__badge {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 9px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 20px;
  letter-spacing: .04em;
  text-transform: uppercase;
  pointer-events: none;
  line-height: 1.6;
}
.aoa-card__badge--hot   { background: #ef4444; color: #fff; }
.aoa-card__badge--new   { background: var(--color-accent); color: #fff; }
.aoa-card__badge--india { background: #16a34a; color: #fff; }

.aoa-card__title {
  font-size: 14px;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.3;
}

.aoa-card__desc {
  font-size: 12px;
  color: var(--color-text-muted);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.aoa-card__badges {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-top: auto;
}

/* ============================================================
   9. FILTER PILLS
   ============================================================ */
.aoa-filter-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-bottom: 4px;
}
.aoa-filter-row::-webkit-scrollbar { display: none; }

.aoa-filter-pill {
  flex-shrink: 0;
  height: 32px;
  padding: 0 14px;
  border: 1px solid var(--color-border);
  border-radius: 100px;
  background: var(--color-surface);
  font-size: 13px;
  font-weight: 500;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.aoa-filter-pill:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}
.aoa-filter-pill.is-active {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: white;
  font-weight: 600;
  box-shadow: 0 2px 10px rgba(67,97,238,.35);
}

/* ============================================================
   10. BLOG SECTION
   ============================================================ */
.aoa-blog-section {
  padding: 60px 0;
  background: var(--color-bg);
}

.aoa-blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.aoa-blog-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition), box-shadow var(--transition);
}
.aoa-blog-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.aoa-blog-card__image {
  aspect-ratio: 16/9;
  object-fit: cover;
  width: 100%;
}

.aoa-blog-card__image-placeholder {
  aspect-ratio: 16/9;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
}

.aoa-blog-card__body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
}

.aoa-blog-card__category {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-accent);
}

.aoa-blog-card__title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
  color: var(--color-text);
}
.aoa-blog-card__title a { color: inherit; text-decoration: none; }
.aoa-blog-card__title a:hover { color: var(--color-accent); }

.aoa-blog-card__excerpt {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.6;
  flex: 1;
}

.aoa-blog-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
}

.aoa-blog-card__date { font-size: 12px; color: var(--color-text-muted); }

.aoa-blog-card__read-more {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-accent);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 4px;
}
.aoa-blog-card__read-more:hover { color: var(--color-primary); }

/* Featured blog post */
.aoa-blog-card--featured {
  grid-column: 1 / -1;
  flex-direction: row;
}
.aoa-blog-card--featured .aoa-blog-card__image-placeholder,
.aoa-blog-card--featured .aoa-blog-card__image {
  width: 50%;
  aspect-ratio: unset;
  flex-shrink: 0;
  min-height: 260px;
}
.aoa-blog-card--featured .aoa-blog-card__body { padding: 32px; justify-content: center; }
.aoa-blog-card--featured .aoa-blog-card__title { font-size: 22px; }

/* ============================================================
   11. CALCULATOR WIDGET
   ============================================================ */
.aoa-calc {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  width: 100%;
}

.aoa-calc__header {
  background: var(--color-primary);
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.aoa-calc__header-title {
  font-size: 16px;
  font-weight: 700;
  color: white;
  display: flex;
  align-items: center;
  gap: 8px;
}

.aoa-calc__header-badge {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(255,255,255,.15);
  color: rgba(255,255,255,.9);
  padding: 3px 8px;
  border-radius: 100px;
}

.aoa-calc__body {
  padding: 24px;
}

/* Calculators that use .aoa-calc__grid directly without .aoa-calc__body need
   padding so content is not clipped by .aoa-calc border-radius + overflow:hidden */
.aoa-calc > .aoa-calc__grid {
  padding: 24px;
}

.aoa-calc__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.aoa-calc__field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.aoa-calc__field--full { grid-column: 1 / -1; }

.aoa-calc__label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-text-muted);
}

.aoa-calc__input,
.aoa-calc__select {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 16px;
  color: var(--color-text);
  background: var(--color-surface);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.aoa-calc__input:focus,
.aoa-calc__select:focus {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(79,99,255,.15);
}
.aoa-calc__input::placeholder { color: var(--color-text-muted); font-size: 14px; }

.aoa-calc__input--prefix-wrap { position: relative; }
.aoa-calc__input-prefix {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  color: var(--color-text-muted);
  pointer-events: none;
}
.aoa-calc__input--has-prefix { padding-left: 28px; }

/* ── Alternative prefix/suffix wrappers (used by compound-interest, sip, emi etc.) ── */
.aoa-calc__input-wrap {
  position: relative;
}
.aoa-calc__prefix {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  color: var(--color-text-muted);
  pointer-events: none;
  z-index: 1;
}
.aoa-calc__input--prefix { padding-left: 28px; }
.aoa-calc__input--suffix { padding-right: 28px; }

.aoa-calc__hint {
  font-size: 11px;
  color: var(--color-text-muted);
  line-height: 1.4;
}

/* ── Section labels / titles ── */
.aoa-calc__section-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-accent);
  border-bottom: 1px solid var(--color-border);
  padding-bottom: 8px;
  margin-bottom: 4px;
  grid-column: 1 / -1;
}

.aoa-calc__section-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin-top: 16px;
  margin-bottom: 8px;
}

/* ── Calculator title / subtitle (used by header-body layout calculators) ── */
.aoa-calc__title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text);
  margin: 0;
  line-height: 1.3;
}

.aoa-calc__subtitle {
  font-size: 13px;
  color: var(--color-text-muted);
  margin: 4px 0 0;
  line-height: 1.5;
}

/* When title/subtitle sit inside the dark primary header — force white text
   and stack them vertically (header is flex-row by default, which would push
   subtitle to the top-right corner as a second flex item) */
.aoa-calc__header .aoa-calc__title {
  color: white;
}
.aoa-calc__header .aoa-calc__subtitle {
  color: rgba(255, 255, 255, 0.75);
}
.aoa-calc__header:has(.aoa-calc__title) {
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

/* ── Grid column variants ── */
.aoa-calc__grid--2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.aoa-calc__grid--3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
}

@media (max-width: 600px) {
  .aoa-calc__grid--2,
  .aoa-calc__grid--3 { grid-template-columns: 1fr; }
}

/* ── Tab pane (shown/hidden by JS) ── */
.aoa-calc__tab-pane { display: block; }

/* ── Table wrapper (overflow scroll on mobile) ── */
.aoa-calc__table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-sm);
}

/* Results area */
.aoa-calc__results {
  display: none;
  flex-direction: column;
  margin-top: 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  animation: fadeSlideIn 0.3s ease;
}
.aoa-calc__results.is-visible { display: flex; }

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.aoa-calc__results-header {
  background: var(--color-primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
}
.aoa-calc__results-header-label { font-size: 12px; font-weight: 600; opacity: .75; text-transform: uppercase; letter-spacing: 0.06em; }
.aoa-calc__results-total { font-size: 24px; font-weight: 800; }

.aoa-calc__result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  background: var(--color-surface);
}

.aoa-calc__result-card {
  padding: 14px 16px;
  text-align: center;
  border-right: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.aoa-calc__result-card:last-child { border-right: none; }

.aoa-calc__result-value {
  font-size: 20px;
  font-weight: 800;
  color: var(--color-primary);
  line-height: 1;
}

.aoa-calc__result-label {
  font-size: 11px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Share row */
.aoa-calc__share {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
}

.aoa-calc__share-btn,
.aoa-calc__share-copy,
.aoa-calc__share-native {
  flex: 1;
  height: 36px;
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all var(--transition);
  min-height: 44px;
}
.aoa-calc__share-btn:hover,
.aoa-calc__share-copy:hover,
.aoa-calc__share-native:hover {
  background: var(--color-accent);
  color: white;
}

/* ── Share bar variant (used by ~41 calculators with id=copy-btn pattern) ── */
.aoa-calc__share-bar {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
}

/* ── Generic calc button (add/remove rows, etc.) ── */
.aoa-calc__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 36px;
  padding: 0 14px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  transition: all var(--transition);
  min-height: 36px;
  white-space: nowrap;
}
.aoa-calc__btn:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: white;
}

/* Copy / share variants */
.aoa-calc__btn--copy,
.aoa-calc__btn--share {
  flex: 1;
  height: 36px;
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all var(--transition);
  min-height: 44px;
}
.aoa-calc__btn--copy:hover,
.aoa-calc__btn--share:hover {
  background: var(--color-accent);
  color: white;
}

/* ── Results combined grid: when aoa-calc__results IS the card grid (no separate header) ── */
/* Use :not(:has) for browsers supporting :has (Chrome 105+, Safari 15.4+, FF 121+)        */
.aoa-calc__results.is-visible:not(:has(.aoa-calc__results-header)) {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  flex-direction: unset; /* neutralise the flex-direction from the base rule */
}

/* ── Range slider ── */
.aoa-calc__range-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.aoa-calc__range-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.aoa-calc__range-value {
  font-size: 15px;
  font-weight: 700;
  color: var(--color-primary);
}
.aoa-calc__range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 100px;
  background: var(--color-border);
  outline: none;
  cursor: pointer;
  accent-color: var(--color-accent);
}
.aoa-calc__range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-accent);
  cursor: pointer;
  border: 2px solid white;
  box-shadow: 0 1px 4px rgba(0,0,0,.2);
}
.aoa-calc__range::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-accent);
  cursor: pointer;
  border: 2px solid white;
  box-shadow: 0 1px 4px rgba(0,0,0,.2);
}
.aoa-calc__range-ticks {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--color-text-muted);
  padding: 0 2px;
}

/* ── Warning / info strip ── */
.aoa-calc__warning {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  line-height: 1.5;
  margin-top: 8px;
  grid-column: 1 / -1;
}
.aoa-calc__warning--orange {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #92400e;
}
.aoa-calc__warning--blue {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
}
.aoa-calc__warning--green {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #14532d;
}
.aoa-calc__warning--red {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #7f1d1d;
}
.aoa-calc__warning-icon { font-size: 14px; flex-shrink: 0; margin-top: 1px; }

/* ── Mode / tab switcher (e.g. Percentage Calculator 3 modes) ── */
.aoa-calc__tabs {
  display: flex;
  gap: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  grid-column: 1 / -1;
  margin-bottom: 4px;
}
.aoa-calc__tab {
  flex: 1;
  height: 40px;
  border: none;
  border-right: 1px solid var(--color-border);
  background: var(--color-bg);
  color: var(--color-text-muted);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
  padding: 0 8px;
  line-height: 1.2;
  text-align: center;
}
.aoa-calc__tab:last-child { border-right: none; }
.aoa-calc__tab:hover { background: #f0f4ff; color: var(--color-accent); }
.aoa-calc__tab.is-active {
  background: var(--color-accent);
  color: white;
}

/* ── Comparison toggle (e.g. 15yr vs 30yr) ── */
.aoa-calc__compare {
  grid-column: 1 / -1;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-top: 8px;
}
.aoa-calc__compare-header {
  background: var(--color-bg);
  padding: 10px 16px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--color-text-muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.aoa-calc__compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.aoa-calc__compare-col {
  padding: 14px 16px;
  border-right: 1px solid var(--color-border);
}
.aoa-calc__compare-col:last-child { border-right: none; }
.aoa-calc__compare-col-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 10px;
  text-align: center;
}
.aoa-calc__compare-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 12px;
  border-bottom: 1px solid var(--color-border);
}
.aoa-calc__compare-row:last-child { border-bottom: none; }
.aoa-calc__compare-row-label { color: var(--color-text-muted); }
.aoa-calc__compare-row-value { font-weight: 700; color: var(--color-text); }
.aoa-calc__compare-saving {
  text-align: center;
  padding: 10px 16px;
  background: #f0fdf4;
  font-size: 13px;
  font-weight: 600;
  color: #14532d;
  border-top: 1px solid #bbf7d0;
}
.aoa-calc__compare-col--accent {
  background: rgba(79,99,255,.06);
  border: 1px solid var(--color-accent);
}
.aoa-calc__compare-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 8px 0;
  border-bottom: 1px solid var(--color-border);
}
.aoa-calc__compare-item:last-child { border-bottom: none; }
.aoa-calc__compare-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-text-muted);
  padding: 10px 16px;
  border-bottom: 1px solid var(--color-border);
}
.aoa-calc__divider {
  height: 1px;
  background: var(--color-border);
  margin: 12px 0;
  grid-column: 1 / -1;
}
.aoa-calc__range-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-primary);
  text-align: right;
  white-space: nowrap;
}
.aoa-calc__suffix {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  color: var(--color-text-muted);
  pointer-events: none;
}

/* ── Collapsible section (e.g. amortization table) ── */
.aoa-calc__collapsible-trigger {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  border-top: 1px solid var(--color-border);
  width: 100%;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-accent);
  cursor: pointer;
  text-align: left;
  transition: background var(--transition);
}
.aoa-calc__collapsible-trigger:hover { background: var(--color-bg); }
.aoa-calc__collapsible-trigger .aoa-calc__chevron {
  margin-left: auto;
  transition: transform var(--transition);
  font-size: 11px;
}
.aoa-calc__collapsible-trigger.is-open .aoa-calc__chevron { transform: rotate(180deg); }
.aoa-calc__collapsible-body {
  display: none;
  padding: 0 16px 16px;
  overflow-x: auto;
}
.aoa-calc__collapsible-body.is-open { display: block; }

/* ── Data table inside calculator ── */
.aoa-calc__table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-top: 4px;
}
.aoa-calc__table th {
  background: var(--color-bg);
  padding: 8px 10px;
  text-align: left;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}
.aoa-calc__table td {
  padding: 7px 10px;
  border: 1px solid var(--color-border);
  color: var(--color-text);
}
.aoa-calc__table tr:nth-child(even) td { background: var(--color-bg); }
.aoa-calc__table td:not(:first-child) { text-align: right; }

/* ── Unit toggle (kg/lbs, cm/ft) ── */
.aoa-calc__unit-toggle {
  display: inline-flex;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-left: auto;
}
.aoa-calc__unit-btn {
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
  border-right: 1px solid var(--color-border);
}
.aoa-calc__unit-btn:last-child { border-right: none; }
.aoa-calc__unit-btn.is-active { background: var(--color-accent); color: white; }

/* ── Result card highlight override for success/warn values ── */
.aoa-calc__result-card .aoa-calc__result-value--success { color: var(--color-success); }
.aoa-calc__result-card .aoa-calc__result-value--warn    { color: var(--color-warning); }
.aoa-calc__result-card .aoa-calc__result-value--danger  { color: var(--color-danger);  }

/* Mobile: collapse calc grid to 1 column below 480px */
@media (max-width: 480px) {
  .aoa-calc__grid { grid-template-columns: 1fr; }
  .aoa-calc__compare-grid { grid-template-columns: 1fr; }
  .aoa-calc__compare-col { border-right: none; border-bottom: 1px solid var(--color-border); }
  .aoa-calc__compare-col:last-child { border-bottom: none; }
  .aoa-calc__tabs .aoa-calc__tab { font-size: 11px; padding: 0 4px; }
}

/* ============================================================
   12. FOOTER
   ============================================================ */
.aoa-footer {
  background: var(--color-primary);
  color: rgba(255,255,255,.75);
  padding: 28px 0 0;
}

.aoa-footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 32px;
  padding-bottom: 24px;
}

.aoa-footer__col-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: white;
  margin-bottom: 10px;
}

.aoa-footer__logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.aoa-footer__logo-name {
  font-size: 18px;
  font-weight: 800;
  color: white;
}

.aoa-footer__about {
  font-size: 12px;
  line-height: 1.6;
  color: rgba(255,255,255,.6);
  margin-bottom: 14px;
}

.aoa-footer__social {
  display: flex;
  gap: 8px;
}
.aoa-footer__social-link {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,.65);
  font-size: 14px;
  transition: background var(--transition), color var(--transition);
  text-decoration: none;
}
.aoa-footer__social-link:hover { background: var(--color-accent); color: white; }

.aoa-footer__links { display: flex; flex-direction: column; gap: 6px; }
.aoa-footer__link {
  font-size: 12px;
  color: rgba(255,255,255,.6);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: color var(--transition);
}
.aoa-footer__link:hover { color: white; }
.aoa-footer__link::before {
  content: '→';
  color: var(--color-accent);
  font-size: 11px;
}

.aoa-footer__recent-post {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  margin-bottom: 10px;
}
.aoa-footer__recent-post:last-child { border-bottom: none; margin-bottom: 0; }
.aoa-footer__recent-post-title {
  font-size: 13px;
  color: rgba(255,255,255,.8);
  text-decoration: none;
  line-height: 1.4;
  transition: color var(--transition);
}
.aoa-footer__recent-post-title:hover { color: white; }
.aoa-footer__recent-post-date { font-size: 11px; color: rgba(255,255,255,.4); }

/* Footer bottom bar */
.aoa-footer__bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding: 12px 0;
}
.aoa-footer__bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.aoa-footer__copyright { font-size: 13px; color: rgba(255,255,255,.45); }
.aoa-footer__legal {
  display: flex;
  gap: 20px;
}
.aoa-footer__legal-link {
  font-size: 13px;
  color: rgba(255,255,255,.45);
  text-decoration: none;
  transition: color var(--transition);
}
.aoa-footer__legal-link:hover { color: white; }

/* ============================================================
   13. RESPONSIVE BREAKPOINTS
   ============================================================ */

/* Tablet */
@media (max-width: 1024px) {
  .aoa-hero--compact { padding: 20px 20px 16px; }
  .aoa-footer__grid { grid-template-columns: 1fr; }
  .aoa-blog-grid { grid-template-columns: repeat(2, 1fr); }
  .aoa-blog-card--featured { flex-direction: column; }
  .aoa-blog-card--featured .aoa-blog-card__image-placeholder,
  .aoa-blog-card--featured .aoa-blog-card__image { width: 100%; min-height: unset; aspect-ratio: 16/9; }
  .aoa-calc__grid { grid-template-columns: 1fr; }
}

/* Mobile */
@media (max-width: 768px) {
  :root { --header-height: 56px; }

  .aoa-nav { display: none; }
  .aoa-hamburger { display: flex; }
  .aoa-header-cta { display: none; }
  .aoa-header .container { justify-content: space-between; }

  .aoa-mega-menu { display: none !important; }

  .aoa-hero--compact { padding: 16px 16px 14px; }
  .aoa-hero__stats { gap: 20px; }
  .aoa-hero__stat-value { font-size: 20px; }

  .aoa-footer__grid { grid-template-columns: 1fr; gap: 32px; }
  .aoa-footer__grid > *:first-child { grid-column: unset; }

  .aoa-blog-grid { grid-template-columns: 1fr; }
  .aoa-blog-card--featured { grid-column: unset; }
}

/* Small mobile */
@media (max-width: 480px) {
  .aoa-hero__search-input { padding-right: 110px; }
  .aoa-hero__search-btn { padding: 0 14px; font-size: 13px; }
  .aoa-hero__stats { gap: 16px; }
  .aoa-hero__stat-value { font-size: 18px; }

  .aoa-calc__result-grid { grid-template-columns: repeat(2, 1fr); }
  .aoa-calc__share { flex-direction: column; }

  .aoa-footer__bottom-inner { flex-direction: column; align-items: flex-start; }
  .aoa-footer__legal { flex-wrap: wrap; gap: 12px; }
}

/* ============================================================
   14. UTILITY CLASSES
   ============================================================ */

/* Market badges */
.badge-usa   { background: #dbeafe; color: #1d4ed8; }
.badge-india { background: #fef3c7; color: #92400e; }
.badge-global{ background: #d1fae5; color: #065f46; }
.badge-hot   { background: #fee2e2; color: #991b1b; }
.badge-new   { background: #ede9fe; color: #5b21b6; }

.badge-usa, .badge-india, .badge-global, .badge-hot, .badge-new {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 100px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  line-height: 1.6;
}

/* New card accent */
.aoa-card--new {
  box-shadow: 0 0 0 2px #a78bfa inset;
}

/* ── Popular Quick-Access Strip ─────────────────────────────────── */
.aoa-popular-section {
  padding: 28px 0 8px;
}
.aoa-popular-section__title {
  font-size: 15px;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}
.aoa-popular-row {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-width: thin;
  scrollbar-color: #e2e8f0 transparent;
  -webkit-overflow-scrolling: touch;
}
.aoa-popular-row::-webkit-scrollbar { height: 4px; }
.aoa-popular-row::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 4px; }
.aoa-popular-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 100px;
  color: var(--color-text);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background .15s, border-color .15s, box-shadow .15s;
}
.aoa-popular-chip:hover {
  background: #eff6ff;
  border-color: #93c5fd;
  box-shadow: 0 2px 8px rgba(79,99,255,.10);
  text-decoration: none;
  color: var(--color-accent);
}
.aoa-popular-chip__icon { font-size: 16px; }
.aoa-popular-chip__cat {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: #94a3b8;
  padding-left: 2px;
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 40px;
  padding: 0 20px;
  background: var(--color-accent);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--transition), transform var(--transition);
  min-height: 44px;
  white-space: nowrap;
}
.btn-primary:hover { background: #3d4fe0; color: white; transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); }

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 40px;
  padding: 0 20px;
  background: transparent;
  color: var(--color-accent);
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: all var(--transition);
  min-height: 44px;
  white-space: nowrap;
}
.btn-outline:hover { background: var(--color-accent); color: white; }

/* Text helpers */
.text-muted  { color: var(--color-text-muted); }
.text-accent { color: var(--color-accent); }

/* Section title */
.section-title {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  color: var(--color-text);
  line-height: 1.2;
}
.section-title span { color: var(--color-accent); }

/* Divider with text */
.divider {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin: 24px 0;
}
.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--color-border);
}

/* AdSense placeholders */
.aoa-ad {
  background: var(--color-bg);
  border: 1px dashed var(--color-border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  min-height: 90px;
  width: 100%;
}

/* Misc layout helpers */
.section-pad { padding: 60px 0; }
.mt-32 { margin-top: 32px; }
.mb-32 { margin-bottom: 32px; }
.text-center { text-align: center; }

/* =============================================================
   NEW FEATURE COMPONENTS — AOA Calc v3.0
   Chart, Benchmark, Advice, Scenario, Progress, Print, Embed,
   Share-Link, Tool-Actions toolbar
   ============================================================= */

/* ── Chart wrapper ── */
.aoa-calc__chart-wrap {
  padding: 16px 16px 8px;
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
}
.aoa-calc__chart-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-text-muted);
  margin-bottom: 12px;
}
.aoa-calc__chart {
  max-height: 260px;
  width: 100%;
}

/* ── Benchmark badge ── */
.aoa-calc__bench {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 16px;
  background: var(--color-bg);
  border-left: 3px solid var(--color-border);
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.5;
}
.aoa-calc__bench--good {
  background: rgba(34, 201, 122, 0.07);
  border-left-color: var(--color-success);
  color: var(--color-text);
}
.aoa-calc__bench--warn {
  background: rgba(249, 115, 22, 0.07);
  border-left-color: var(--color-warning);
  color: var(--color-text);
}
.aoa-calc__bench-icon { flex-shrink: 0; font-size: 16px; line-height: 1.4; }
.aoa-calc__bench-text strong { color: var(--color-text); }

/* ── Advice block ── */
.aoa-calc__advice {
  padding: 14px 16px;
  border-top: 1px solid var(--color-border);
  background: var(--color-bg);
}
.aoa-calc__advice-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 10px;
}
.aoa-calc__advice-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.aoa-calc__advice-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  color: var(--color-text);
  line-height: 1.55;
}
.aoa-calc__advice-icon { flex-shrink: 0; font-size: 15px; margin-top: 1px; }
.aoa-calc__advice-text { flex: 1; }
.aoa-calc__advice-cta {
  display: inline-block;
  margin-left: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--color-accent);
  text-decoration: none;
  white-space: nowrap;
}
.aoa-calc__advice-cta:hover { text-decoration: underline; }

/* ── Scenario compare ── */
.aoa-calc__scenario {
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
}
.aoa-calc__scenario-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  border-bottom: 1px solid var(--color-border);
}
.aoa-calc__scenario-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-text-muted);
}
.aoa-calc__scenario-clear {
  font-size: 11px;
  background: none;
  border: none;
  color: var(--color-accent);
  cursor: pointer;
  padding: 2px 6px;
}
.aoa-calc__scenario-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  divide: var(--color-border);
}
.aoa-calc__scenario-col {
  padding: 12px 14px;
  border-right: 1px solid var(--color-border);
}
.aoa-calc__scenario-col:last-child { border-right: none; }
.aoa-calc__scenario-col-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.aoa-calc__scenario-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  padding: 4px 0;
  border-bottom: 1px solid var(--color-border);
  gap: 8px;
}
.aoa-calc__scenario-row:last-child { border-bottom: none; }
.aoa-calc__scenario-row-label { color: var(--color-text-muted); flex: 1; }
.aoa-calc__scenario-row-value { font-weight: 700; color: var(--color-text); white-space: nowrap; }

/* ── Progress bar ── */
.aoa-calc__progress {
  height: 10px;
  background: var(--color-border);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 6px;
}
.aoa-calc__progress-bar {
  height: 100%;
  border-radius: 99px;
  transition: width 0.6s cubic-bezier(.4,0,.2,1), background 0.3s;
}
.aoa-calc__progress-label {
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 12px;
}

/* ── Tools action bar (share link / print / embed) ── */
.aoa-calc__tools {
  display: flex;
  gap: 8px;
  padding: 10px 16px;
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
  flex-wrap: wrap;
}
.aoa-calc__tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text-muted);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}
.aoa-calc__tool-btn:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
  background: rgba(79,99,255,.05);
}

/* ── Save Scenario button ── */
.aoa-calc__save-scenario-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 16px 12px;
  padding: 8px 16px;
  border: 1px dashed var(--color-accent);
  border-radius: var(--radius-sm);
  background: rgba(79,99,255,.04);
  color: var(--color-accent);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  width: calc(100% - 32px);
  justify-content: center;
}
.aoa-calc__save-scenario-btn:hover { background: rgba(79,99,255,.10); }

/* ── Embed modal overlay ── */
.aoa-calc__embed-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.aoa-calc__embed-box {
  background: #fff;
  border-radius: 14px;
  padding: 24px;
  width: 100%;
  max-width: 520px;
  box-shadow: 0 20px 60px rgba(0,0,0,.25);
}
.aoa-calc__embed-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 15px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 10px;
}
.aoa-calc__embed-close {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: var(--color-text-muted);
  line-height: 1;
  padding: 0 4px;
}
.aoa-calc__embed-desc {
  font-size: 13px;
  color: var(--color-text-muted);
  margin: 0 0 12px;
}
.aoa-calc__embed-code {
  width: 100%;
  height: 90px;
  resize: none;
  font-family: 'Courier New', monospace;
  font-size: 11px;
  padding: 10px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-bg);
  color: var(--color-text);
  display: block;
}

/* ── Dark mode for new components ── */
@media (prefers-color-scheme: dark) {
  .aoa-calc__bench       { background: rgba(255,255,255,.04); }
  .aoa-calc__bench--good { background: rgba(34,201,122,.10); }
  .aoa-calc__bench--warn { background: rgba(249,115,22,.10); }
  .aoa-calc__advice      { background: rgba(255,255,255,.03); }
  .aoa-calc__scenario    { background: var(--color-surface); }
  .aoa-calc__embed-box   { background: #1e2030; }
  .aoa-calc__embed-code  { background: #13151f; color: #e2e8f0; }
}

/* ── Responsive — narrow containers ── */
@media (max-width: 480px) {
  .aoa-calc__scenario-grid { grid-template-columns: 1fr 1fr; }
  .aoa-calc__tools { gap: 6px; }
  .aoa-calc__tool-btn { font-size: 11px; padding: 6px 10px; }
  .aoa-calc__chart { max-height: 200px; }
}

/* ================================================================
   SUPPLEMENTAL — classes used across calculators, added in v3.1
   ================================================================ */

/* ── Single-column grid ── */
.aoa-calc__grid--1 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

/* ── Button variants ── */
.aoa-calc__btn--secondary {
  background: var(--color-bg);
  border-color: var(--color-border);
  color: var(--color-text-muted);
}
.aoa-calc__btn--secondary:hover {
  background: var(--color-border);
  border-color: var(--color-border);
  color: var(--color-text);
}
.aoa-calc__btn--danger {
  background: #fef2f2;
  border-color: #fecaca;
  color: #b91c1c;
}
.aoa-calc__btn--danger:hover {
  background: var(--color-danger);
  border-color: var(--color-danger);
  color: white;
}

/* ── Result card aliases (for backwards-compat querySelector targeting) ── */
/* These are applied alongside aoa-calc__result-card/value/label by renderCards */
.aoa-calc__card        { /* styled by aoa-calc__result-card */ }
.aoa-calc__card-value  { /* styled by aoa-calc__result-value */ }
.aoa-calc__card-label  { /* styled by aoa-calc__result-label */ }

/* ── Tab panel (JS-controlled show/hide via is-active — used by calculators
      that add/remove is-active instead of toggling inline style) ── */
.aoa-calc__tab-panel {
  display: none;
}
.aoa-calc__tab-panel.is-active {
  display: block;
}

/* ── Info callout box (tip / rule-check / guidance shown after calculation) ── */
.aoa-calc__info-box {
  padding: 10px 14px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 3px solid var(--color-accent);
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: #1e40af;
  line-height: 1.55;
  margin-top: 8px;
  grid-column: 1 / -1;
}
.aoa-calc__info-box strong { color: #1e3a8a; }

/* ── Collapsible / accordion section ── */
.aoa-calc__collapsible {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  margin-top: 12px;
  overflow: hidden;
}
.aoa-calc__collapsible-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: var(--color-bg);
  border: none;
  border-bottom: 1px solid transparent;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text);
  cursor: pointer;
  text-align: left;
  transition: background var(--transition);
}
.aoa-calc__collapsible-trigger:hover {
  background: #eef0ff;
}
.aoa-calc__collapsible-trigger[aria-expanded="true"],
.aoa-calc__collapsible.is-open .aoa-calc__collapsible-trigger {
  border-bottom-color: var(--color-border);
  background: #f0f4ff;
}
.aoa-calc__collapsible-body {
  padding: 12px 14px;
  background: var(--color-surface);
}

/* ============================================================
   SINGLE CALCULATOR PAGE — meta pill badges
   ============================================================ */
.aoa-single-calc__meta-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 11px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.aoa-single-calc__meta-pill--cat {
  background: rgba(255,255,255,.2);
  color: white;
}
.aoa-single-calc__meta-pill--free {
  background: rgba(34,201,122,.2);
  color: #86efac;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}

/* ============================================================
   SEO CONTENT SECTION — homepage
   ============================================================ */
.aoa-seo-section {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: 56px 0 52px;
}
.aoa-seo-section__title {
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 800;
  color: var(--color-text);
  margin-bottom: 32px;
  text-align: center;
  letter-spacing: -.02em;
}
.aoa-seo-grid {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 48px;
  align-items: start;
}
.aoa-seo-content h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--color-primary);
  margin: 24px 0 8px;
}
.aoa-seo-content p {
  font-size: 15px;
  line-height: 1.75;
  color: var(--color-text-muted);
  margin: 0;
}
.aoa-seo-content p + p { margin-top: 12px; }
.aoa-seo-content a {
  color: var(--color-accent);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgba(67,97,238,.3);
  text-underline-offset: 2px;
}
.aoa-seo-content a:hover { text-decoration-color: var(--color-accent); }
.aoa-seo-sidebar {
  background: var(--color-bg);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 24px 20px;
}
.aoa-seo-sidebar h3 {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--color-text-muted);
  margin-bottom: 14px;
}
.aoa-seo-links {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.aoa-seo-links li a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text);
  transition: background var(--transition), color var(--transition);
}
.aoa-seo-links li a:hover {
  background: rgba(67,97,238,.08);
  color: var(--color-accent);
}
.aoa-seo-trust {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--color-border);
}
.aoa-seo-trust__item {
  text-align: center;
}
.aoa-seo-trust__num {
  font-size: 28px;
  font-weight: 800;
  color: var(--color-accent);
  line-height: 1;
  display: block;
}
.aoa-seo-trust__label {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 4px;
}
@media (max-width: 768px) {
  .aoa-seo-grid { grid-template-columns: 1fr; gap: 24px; }
  .aoa-seo-trust { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .aoa-seo-trust__num { font-size: 22px; }
}
