/* Affiliate Dogs — one stylesheet. Playful brand (navy + gold), serious content. Bump ASSET_V in site/config.mjs on change. */
:root {
  --bg: #fbf8f1; --card: #ffffff; --ink: #161b2b; --muted: #5a6275; --line: #e7e1d3;
  --navy: #0f1b3d; --gold: #f2a900; --gold-ink: #3a2700; --gold-soft: #fff3d1; --link: #1d4ed8;
  --ok: #0f7a3d; --bad: #b42318; --shadow: 0 1px 2px rgba(15,27,61,.06), 0 6px 24px rgba(15,27,61,.06);
  --radius: 14px; --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #0c1120; --card: #141b2e; --ink: #e8ebf3; --muted: #9ba3b6; --line: #243050;
    --navy: #0a1230; --gold: #f7c13a; --gold-ink: #241800; --gold-soft: #2a2410; --link: #8ab4ff; --ok: #4ade80; --bad: #f87171;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 6px 24px rgba(0,0,0,.25); }
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 17px/1.6 var(--font); }
img { max-width: 100%; height: auto; }
a { color: var(--link); text-underline-offset: 2px; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -.01em; }
h1 { font-size: clamp(1.45rem, 1.05rem + 2.4vw, 2.6rem); margin: .3em 0 .4em; overflow-wrap: break-word; }
h2, h3, summary, td, th { overflow-wrap: break-word; }
@media (max-width: 420px) { h1 { hyphens: auto; } }
h2 { font-size: clamp(1.25rem, 1.05rem + .9vw, 1.6rem); margin: 2em 0 .6em; }
p, ul, ol { margin: 0 0 1em; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.skip { position: absolute; left: -999px; top: 0; background: var(--gold); color: var(--gold-ink); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }

/* header */
.top { background: var(--navy); color: #fff; position: sticky; top: 0; z-index: 5; }
.top-in { display: flex; align-items: center; gap: 12px; min-height: 60px; flex-wrap: wrap; padding-top: 6px; padding-bottom: 6px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; font-size: 1.1rem; margin-right: auto; }
.brand img { display: block; }
.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a, .langs a { color: #e9edf8; text-decoration: none; padding: 6px 10px; border-radius: 999px; font-size: .95rem; }
.nav a:hover, .langs a:hover { background: rgba(255,255,255,.1); }
.nav .nav-cta { background: var(--gold); color: var(--gold-ink); font-weight: 700; }
.langs { display: flex; gap: 2px; }
.langs a { font-size: .8rem; padding: 4px 7px; opacity: .8; }
.langs a[aria-current] { opacity: 1; outline: 1px solid rgba(255,255,255,.5); }
@media (max-width: 720px) { .nav { order: 3; width: 100%; justify-content: flex-start; } .nav a { padding: 5px 9px; font-size: .9rem; } }

/* breadcrumbs */
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 14px 0 0; margin: 0; font-size: .85rem; color: var(--muted); }
.crumbs li + li::before { content: "›"; margin-right: 6px; }
.crumbs a { color: var(--muted); }

/* hero */
.hero { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; padding: 8px 0 8px; }
.hero-dog { width: 220px; filter: drop-shadow(0 8px 20px rgba(15,27,61,.18)); }
@media (max-width: 760px) { .hero { grid-template-columns: 1fr; } .hero-dog { width: 120px; order: -1; } }
.lead { font-size: 1.08rem; }
.updated { color: var(--muted); font-size: .88rem; }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 10px 18px; border-radius: 999px; border: 2px solid var(--navy);
  color: var(--navy); background: transparent; font: 700 1rem var(--font); text-decoration: none; cursor: pointer; }
@media (prefers-color-scheme: dark) { .btn { border-color: #c9d2ec; color: #e8ebf3; } }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--gold-ink); }
.btn:hover { filter: brightness(1.05); }

/* exchange cards */
.ex-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.ex-card { display: flex; flex-direction: column; gap: 4px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px;
  text-decoration: none; color: var(--ink); box-shadow: var(--shadow); transition: transform .12s ease; }
.ex-card:hover { transform: translateY(-2px); border-color: var(--gold); }
.ex-head { display: flex; align-items: center; gap: 10px; font-size: 1.05rem; }
.ex-head img { border-radius: 8px; }
.ex-rate { font-size: 1.5rem; font-weight: 800; color: var(--navy); }
@media (prefers-color-scheme: dark) { .ex-rate { color: var(--gold); } }
.ex-sub { color: var(--muted); font-size: .9rem; }
.ex-more { color: var(--link); font-size: .9rem; margin-top: auto; }
.ex-ban { display: block; color: var(--bad); font-size: .8rem; font-weight: 600; }
.ban { border-left: 4px solid var(--bad); background: var(--card); border-radius: 0 12px 12px 0; padding: 2px 16px 4px; margin: 1.5em 0; }
.ban h2 { margin-top: .6em; }
.ex-inline { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; white-space: nowrap; }
.ex-inline img { border-radius: 4px; }
.ex-title { display: flex; align-items: center; gap: 14px; }
.ex-title img { border-radius: 12px; flex: none; }
@media (max-width: 420px) { .ex-title { gap: 10px; } .ex-title img { width: 36px; height: 36px; } }
.ex-title h1 { margin: .3em 0; }

/* steps */
.howto { counter-reset: s; list-style: none; padding: 0; }
.howto li { counter-increment: s; position: relative; padding: 4px 0 12px 48px; }
.howto li::before { content: counter(s); position: absolute; left: 0; top: 2px; width: 34px; height: 34px; border-radius: 50%; background: var(--gold); color: var(--gold-ink);
  font-weight: 800; display: grid; place-items: center; }

/* tables */
.tbl { overflow-x: auto; margin: 0 0 1em; }
table { border-collapse: collapse; width: 100%; background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
th, td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: .95rem; }
thead th { background: var(--gold-soft); font-size: .85rem; }
.terms th { width: 30%; background: var(--gold-soft); font-size: .9rem; }
@media (max-width: 640px) {
  table.resp thead { display: none; }
  table.resp tr { display: block; border-bottom: 2px solid var(--line); padding: 6px 0; }
  table.resp td { display: grid; grid-template-columns: 42% 1fr; gap: 8px; border: 0; padding: 5px 12px; }
  table.resp td::before { content: attr(data-label); font-weight: 700; color: var(--muted); font-size: .82rem; }
  .terms th, .terms td { display: block; width: 100%; }
  .terms th { border-bottom: 0; padding-bottom: 2px; }
}

/* calculators */
.calc { background: var(--card); border: 2px solid var(--gold); border-radius: var(--radius); padding: 4px 18px 10px; margin: 2em 0; box-shadow: var(--shadow); }
.calc h2 { margin-top: .8em; }
.calc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin: 12px 0 16px; }
label { display: flex; flex-direction: column; gap: 4px; font-weight: 600; font-size: .92rem; }
label small { font-weight: 400; color: var(--muted); }
input, select { font: 400 1rem var(--font); padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--ink); min-height: 44px; width: 100%; }
input[type=radio], input[type=checkbox] { width: auto; min-height: 0; margin-right: 6px; }
fieldset.seg { border: 1px solid var(--line); border-radius: 10px; display: flex; gap: 14px; align-items: center; flex-wrap: wrap; padding: 6px 12px; margin: 0; }
fieldset.seg legend { font-weight: 600; font-size: .92rem; padding: 0 4px; }
fieldset.seg label { flex-direction: row; align-items: center; font-weight: 400; }
label[data-f="vip"] span { display: flex; align-items: center; font-weight: 400; padding-top: 28px; }
.calc-out td:last-child { font-weight: 800; }
.calc-out .note { display: block; font-weight: 400; color: var(--muted); font-size: .8rem; }
.sub-out { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin-bottom: 10px; }
.sub-out .cell { background: var(--gold-soft); border-radius: 10px; padding: 10px 12px; }
.sub-out .cell b { display: block; font-size: 1.3rem; }
.sub-out .wide { grid-column: 1 / -1; margin: 0; }
.sub-out .err { grid-column: 1 / -1; color: var(--bad); font-weight: 600; }

/* picks, faq, related, sources */
.picks li { margin-bottom: .6em; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 0 16px; margin-bottom: 8px; }
.faq summary { cursor: pointer; font-weight: 700; padding: 12px 0; list-style-position: outside; }
.faq .ans { padding-bottom: 6px; }
.related ul, .sources ul { padding-left: 1.2em; }
.clist { font-size: .95rem; }

/* tools */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.tool { display: flex; flex-direction: column; gap: 4px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; text-decoration: none; color: var(--ink); box-shadow: var(--shadow); }
.tool b { color: var(--link); }

/* form */
.apply { margin: 2.4em 0; }
.apply-card { background: var(--navy); color: #eef1f9; border-radius: 18px; padding: 6px 20px 18px; }
.apply-card h2 { color: #fff; margin-top: .8em; }
.apply-card a { color: #ffd36b; }
.lead-form, form.lead { display: grid; gap: 12px; max-width: 560px; }
form.lead label { color: #fff; }
form.lead label small { color: #b9c2da; }
form.lead input, form.lead select { background: #fff; color: #161b2b; border-color: #c9d2ec; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form-msg { min-height: 1.2em; font-weight: 700; margin: 0; }
.form-msg.ok { color: #7ee2a8; } .form-msg.bad { color: #ffb4ab; }
.form-note { font-size: .85rem; color: #b9c2da; margin: 0; }

/* footer */
.foot { background: var(--navy); color: #c9d0e3; margin-top: 3em; padding: 28px 0 20px; font-size: .9rem; }
.foot a { color: #e9edf8; }
.foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 24px; }
@media (max-width: 760px) { .foot-grid { grid-template-columns: 1fr; } }
.foot-brand { display: flex; align-items: center; gap: 8px; font-weight: 800; color: #fff; font-size: 1.05rem; }
.foot-links { display: flex; flex-direction: column; gap: 4px; }
.foot-note { border-top: 1px solid rgba(255,255,255,.12); padding-top: 12px; margin-top: 16px; color: #9aa4c0; font-size: .82rem; }

/* 404 */
.nf { text-align: center; padding: 40px 16px; }
.nf-links { list-style: none; padding: 0; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
