/* GenAlpha Tools — US-fintech palette: ivory, deep navy, crimson accent. */
:root[data-ga-theme="light"], :root {
  --ga-bg:        #fbfaf7;
  --ga-surface:   #ffffff;
  --ga-surface-2: #f3f1ec;
  --ga-text:      #0b1437;
  --ga-muted:     #5a6478;
  --ga-border:    #e3e1da;
  --ga-primary:   #0b1437;        /* deep navy */
  --ga-primary-2: #1e3a8a;        /* indigo */
  --ga-accent:    #c1121f;        /* crimson */
  --ga-accent-2:  #f59e0b;        /* gold */
  --ga-good:      #15803d;
  --ga-bad:       #b91c1c;
  --ga-shadow:    0 1px 2px rgba(15,23,42,.06), 0 8px 24px -12px rgba(15,23,42,.12);
}
:root[data-ga-theme="dark"] {
  --ga-bg:        #07091a;
  --ga-surface:   #0f1428;
  --ga-surface-2: #161c34;
  --ga-text:      #eef2ff;
  --ga-muted:     #9aa3bf;
  --ga-border:    #232a47;
  --ga-primary:   #eef2ff;
  --ga-primary-2: #93c5fd;
  --ga-accent:    #ef4444;
  --ga-accent-2:  #fbbf24;
  --ga-good:      #4ade80;
  --ga-bad:       #f87171;
  --ga-shadow:    0 1px 2px rgba(0,0,0,.3), 0 12px 32px -16px rgba(0,0,0,.6);
}
body.ga-child {
  background: var(--ga-bg) !important;
  color: var(--ga-text) !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
.ga-container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ---- Header ---- */
.ga-header { background: var(--ga-surface); border-bottom: 1px solid var(--ga-border); position: sticky; top: 0; z-index: 50; }
.ga-header__inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 24px; gap: 16px; }
.ga-logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ga-text); font-weight: 800; font-size: 17px; }
.ga-logo__mark { background: var(--ga-primary); color: #fff; padding: 6px 9px; border-radius: 6px; font-weight: 800; letter-spacing: .5px; font-size: 13px; }
.ga-nav { display: flex; gap: 26px; }
.ga-nav a { color: var(--ga-text); text-decoration: none; font-weight: 600; font-size: 14.5px; opacity: .85; }
.ga-nav a:hover { opacity: 1; color: var(--ga-accent); }
.ga-header__actions { display: flex; gap: 8px; }
.ga-theme-toggle, .ga-menu-btn { background: transparent; border: 1px solid var(--ga-border); color: var(--ga-text); width: 38px; height: 38px; border-radius: 8px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.ga-menu-btn { display: none; }
.ga-mobile-nav { display: none; flex-direction: column; padding: 12px 24px; border-bottom: 1px solid var(--ga-border); background: var(--ga-surface); }
.ga-mobile-nav a { color: var(--ga-text); text-decoration: none; padding: 10px 0; border-bottom: 1px solid var(--ga-border); }
@media (max-width: 880px) {
  .ga-nav { display: none; }
  .ga-menu-btn { display: inline-flex; }
  .ga-mobile-nav.open { display: flex; }
}

/* ---- Hero ---- */
.ga-hero { background: var(--ga-bg); padding: 64px 0 24px; }
.ga-hero__inner { max-width: 880px; }
.ga-hero__eyebrow { color: var(--ga-muted); text-transform: uppercase; letter-spacing: .14em; font-weight: 600; font-size: 12.5px; margin: 0 0 18px; }
.ga-hero__title { font-family: 'Archivo', 'Inter', sans-serif; font-weight: 900; font-size: clamp(2.4rem, 5.4vw, 4.6rem); line-height: 1.04; letter-spacing: -.025em; margin: 0 0 22px; }
.ga-hero__title .hl { background: var(--ga-primary); color: #fff; padding: 0 .25em; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.ga-hero__sub { color: var(--ga-muted); font-size: 17px; line-height: 1.6; max-width: 640px; margin: 0 0 28px; }
.ga-search { display: flex; gap: 8px; max-width: 560px; }
.ga-search input { flex: 1; padding: 13px 16px 13px 42px; border-radius: 10px; border: 1px solid var(--ga-border); background: var(--ga-surface); color: var(--ga-text); font-size: 15px; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%235a6478' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='11' cy='11' r='8'/><path d='M21 21l-4.3-4.3'/></svg>"); background-repeat: no-repeat; background-position: 14px center; }
.ga-search button { display: none; }

/* ---- Sections ---- */
.ga-section { margin: 56px 0; }
.ga-section__title { font-family: 'Archivo', sans-serif; font-weight: 900; font-size: 1.8rem; margin: 0 0 22px; letter-spacing: -.01em; }
.ga-section__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 22px; }
.ga-link { color: var(--ga-accent); text-decoration: none; font-weight: 700; }

/* ---- Category cards ---- */
.ga-cats { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.ga-cat-card { background: var(--ga-surface); border: 1px solid var(--ga-border); border-radius: 14px; padding: 20px; text-decoration: none; color: var(--ga-text); transition: transform .15s, border-color .15s, box-shadow .15s; }
.ga-cat-card:hover { transform: translateY(-2px); border-color: var(--ga-primary-2); box-shadow: var(--ga-shadow); }
.ga-cat-card__emoji { display: block; font-size: 28px; margin-bottom: 10px; }
.ga-cat-card h3 { margin: 0 0 4px; font-size: 16px; font-weight: 700; }
.ga-cat-card p { margin: 0; color: var(--ga-muted); font-size: 13px; }

/* ---- Tool grid ---- */
.ga-filter { width: 100%; padding: 13px 16px 13px 42px; border-radius: 10px; border: 1px solid var(--ga-border); background: var(--ga-surface); color: var(--ga-text); font-size: 15px; margin-bottom: 22px; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%235a6478' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='11' cy='11' r='8'/><path d='M21 21l-4.3-4.3'/></svg>"); background-repeat: no-repeat; background-position: 14px center; }
.ga-tools-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.ga-tool-card { background: var(--ga-surface); border: 1px solid var(--ga-border); border-radius: 14px; padding: 22px; text-decoration: none; color: var(--ga-text); display: flex; flex-direction: column; gap: 10px; transition: transform .15s, border-color .15s, box-shadow .15s; }
.ga-tool-card:hover { transform: translateY(-2px); border-color: var(--ga-primary-2); box-shadow: var(--ga-shadow); }
.ga-tool-card__icon { font-size: 24px; }
.ga-tool-card h3 { margin: 0; font-size: 16px; font-weight: 700; line-height: 1.3; }
.ga-tool-card p { margin: 0; color: var(--ga-muted); font-size: 13.5px; line-height: 1.5; flex: 1; }
.ga-tool-card__cta { background: rgba(193,18,31,.08); color: var(--ga-accent); padding: 10px; text-align: center; border-radius: 8px; font-weight: 700; font-size: 13.5px; margin-top: 6px; }

/* ---- Article / tool page ---- */
.ga-crumbs { color: var(--ga-muted); font-size: 13.5px; margin: 24px 0 18px; }
.ga-crumbs a { color: var(--ga-accent); text-decoration: none; }
.ga-crumbs .sep::before { content: " › "; color: var(--ga-muted); margin: 0 6px; }
.ga-article__cat { color: var(--ga-muted); font-size: 13.5px; margin: 0 0 6px; text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.ga-article__title { font-family: 'Archivo', sans-serif; font-weight: 900; font-size: clamp(2rem, 4.6vw, 3.4rem); letter-spacing: -.02em; margin: 0 0 14px; line-height: 1.08; }
.ga-article__intro { color: var(--ga-muted); font-size: 17px; line-height: 1.6; max-width: 780px; margin: 0 0 28px; }
main#main-container > article, main#main-container > .ga-container, .ga-page-wrap { max-width: 880px; margin: 0 auto; padding: 0 24px 64px; }

/* ---- Calculator card ---- */
.ga-calc-card { background: var(--ga-surface); border: 1px solid var(--ga-border); border-radius: 16px; padding: 26px; box-shadow: var(--ga-shadow); margin: 18px 0 32px; }
.ga-calc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.ga-field { display: flex; flex-direction: column; gap: 6px; }
.ga-field__label { font-size: 13px; font-weight: 600; color: var(--ga-text); }
.ga-field__input { padding: 11px 13px; border-radius: 8px; border: 1px solid var(--ga-border); background: var(--ga-bg); color: var(--ga-text); font-size: 14.5px; font-family: inherit; }
.ga-field__input:focus { outline: 2px solid var(--ga-primary-2); outline-offset: -1px; border-color: var(--ga-primary-2); }
textarea.ga-field__input { font-family: 'SF Mono', Menlo, monospace; font-size: 13px; resize: vertical; }
.ga-calc-btn { margin-top: 16px; background: var(--ga-primary); color: #fff; border: 0; padding: 13px 22px; border-radius: 8px; font-weight: 700; font-size: 15px; cursor: pointer; transition: background .15s; }
.ga-calc-btn:hover { background: var(--ga-primary-2); }
.ga-calc-out { margin-top: 18px; }
.ga-calc-out__empty { color: var(--ga-muted); font-size: 14px; }
.ga-result { padding: 20px; border-radius: 10px; background: var(--ga-surface-2); border-left: 4px solid var(--ga-primary-2); }
.ga-result--good { border-left-color: var(--ga-good); }
.ga-result--bad  { border-left-color: var(--ga-bad); }
.ga-result__label { font-size: 13px; color: var(--ga-muted); text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.ga-result__value { font-family: 'Archivo', sans-serif; font-weight: 900; font-size: 2rem; margin-top: 4px; letter-spacing: -.01em; }
.ga-result__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin-top: 14px; }
.ga-result__stat { background: var(--ga-bg); border: 1px solid var(--ga-border); border-radius: 8px; padding: 12px; }
.ga-result__sub-label { font-size: 12px; color: var(--ga-muted); font-weight: 600; }
.ga-result__sub-value { font-size: 16px; font-weight: 700; margin-top: 3px; }
.ga-result__pre-wrap { grid-column: 1/-1; }
.ga-result__pre { background: var(--ga-bg); border: 1px solid var(--ga-border); border-radius: 8px; padding: 14px; overflow-x: auto; font-size: 12.5px; font-family: 'SF Mono', Menlo, monospace; white-space: pre; max-height: 320px; margin-top: 4px; }
.ga-calc-empty { color: var(--ga-muted); font-size: 14.5px; }
.ga-calc-empty__hint { font-size: 13px; margin-top: 8px; }
.tone-good { color: var(--ga-good); } .tone-bad { color: var(--ga-bad); }

/* ---- Share, How-to, FAQ ---- */
.ga-share { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 18px 0 28px; color: var(--ga-muted); font-size: 14px; }
.ga-share a, .ga-share button { padding: 7px 14px; border-radius: 6px; text-decoration: none; font-weight: 600; font-size: 13px; border: 1px solid var(--ga-border); background: var(--ga-surface); color: var(--ga-text); cursor: pointer; }
.ga-share a:hover, .ga-share button:hover { border-color: var(--ga-primary-2); }
.ga-howto { list-style: none; padding: 0; margin: 0 0 28px; }
.ga-howto li { display: flex; gap: 14px; padding: 10px 0; align-items: flex-start; }
.ga-howto__num { background: var(--ga-primary); color: #fff; width: 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; flex-shrink: 0; }
.ga-box { background: var(--ga-surface-2); border: 1px solid var(--ga-border); border-radius: 10px; padding: 16px 18px; font-size: 14.5px; line-height: 1.6; margin: 6px 0 20px; }
.ga-benefits { list-style: none; padding: 0; margin: 0 0 28px; }
.ga-benefits li { padding: 8px 0 8px 28px; position: relative; font-size: 14.5px; }
.ga-benefits li::before { content: "✓"; position: absolute; left: 0; color: var(--ga-good); font-weight: 800; }
.ga-faq details { border: 1px solid var(--ga-border); border-radius: 8px; padding: 14px 16px; margin-bottom: 8px; background: var(--ga-surface); }
.ga-faq summary { font-weight: 600; cursor: pointer; font-size: 14.5px; }
.ga-faq details[open] summary { color: var(--ga-accent); }
.ga-faq p { color: var(--ga-muted); font-size: 14px; margin: 8px 0 0; line-height: 1.6; }
h2 { font-family: 'Archivo', sans-serif; font-weight: 800; font-size: 1.45rem; margin: 36px 0 14px; letter-spacing: -.01em; }

/* ---- Blog ---- */
.ga-blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.ga-blog-card { background: var(--ga-surface); border: 1px solid var(--ga-border); border-radius: 14px; padding: 22px; text-decoration: none; color: var(--ga-text); transition: transform .15s, border-color .15s; display: block; }
.ga-blog-card:hover { transform: translateY(-2px); border-color: var(--ga-primary-2); }
.ga-blog-card__meta { font-size: 11.5px; color: var(--ga-muted); text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.ga-blog-card h3 { margin: 8px 0; font-size: 17px; line-height: 1.3; }
.ga-blog-card p { margin: 0; color: var(--ga-muted); font-size: 13.5px; line-height: 1.5; }

/* ---- Footer ---- */
.ga-footer { background: var(--ga-surface-2); border-top: 1px solid var(--ga-border); margin-top: 80px; padding: 56px 0 24px; }
.ga-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 48px; }
@media (max-width: 720px) { .ga-footer__grid { grid-template-columns: 1fr; gap: 28px; } }
.ga-footer__brand p { color: var(--ga-muted); font-size: 14px; line-height: 1.6; max-width: 320px; }
.ga-footer__brand .contact { margin-top: 14px; font-size: 14px; color: var(--ga-muted); }
.ga-footer__col h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; font-weight: 700; color: var(--ga-text); margin: 0 0 14px; }
.ga-footer__col ul { list-style: none; padding: 0; margin: 0; }
.ga-footer__col li { margin-bottom: 8px; }
.ga-footer__col a { color: var(--ga-muted); text-decoration: none; font-size: 14px; }
.ga-footer__col a:hover { color: var(--ga-accent); }
.ga-footer__bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 24px; margin-top: 32px; border-top: 1px solid var(--ga-border); color: var(--ga-muted); font-size: 13px; }
@media (max-width: 720px) { .ga-footer__bottom { flex-direction: column; gap: 8px; text-align: center; } }
