/* ChowChow Labs theme: warm cream and forest green, used by every page. Loaded after styles.css. */
body {
  --bg: #f7f2e8;
  --surface: #fffdf8;
  --surface-2: #f3ede1;
  --tint: #edf1e4;
  --text: #1f2a22;
  --muted: #5d665c;
  --border: #e6dfd0;
  --shadow: 0 1px 2px rgb(60 50 30 / 0.05), 0 8px 24px rgb(60 50 30 / 0.06);
  --accent: #2f5a3a;
  --accent-strong: #244a2e;
  --accent-text: #2f5a3a;
  --leaf: #4f8a52;
  --gold: #f2c94c;
  --foot-bg: #1f3a28;
  --foot-text: #e8efe4;
  --focus: #2f7d46;
  --serif: Fraunces, "Iowan Old Style", Georgia, serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  body {
    --bg: #141a15;
    --surface: #1c241d;
    --surface-2: #232d24;
    --tint: #1f2a21;
    --text: #edf0e8;
    --muted: #aab4a6;
    --border: #2e3a2f;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 8px 24px rgb(0 0 0 / 0.25);
    --accent: #7cbf86;
    --accent-strong: #93cf9c;
    --accent-text: #98d3a0;
    --leaf: #7cbf86;
    --foot-bg: #0e1510;
    --foot-text: #d9e3d5;
    --focus: #98d3a0;
    color-scheme: dark;
  }
  body button { color: #10200f; }
  body .art-frame { filter: brightness(0.92); }
}

body { background: var(--bg); font-family: "Nunito Sans", Nunito, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
body h1, body h2, body .wordmark, body .tile h3 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.01em; }
body .wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* Header */
body .site-head { max-width: 1120px; margin: 0 auto; padding: 18px 20px; display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; }
body .brandline { display: flex; align-items: center; gap: 16px; text-decoration: none; color: var(--text); }
body .wordmark { font-size: 26px; color: var(--accent-text); line-height: 1; }
body .tagline { font-size: 14px; color: var(--muted); padding-left: 16px; border-left: 1px solid var(--border); }
body .site-head nav { display: flex; gap: 8px 28px; flex-wrap: wrap; }
body .site-head nav a { color: var(--text); font-weight: 700; text-decoration: none; font-size: 15px; }
body .site-head nav a:hover { color: var(--accent-text); text-decoration: underline; text-underline-offset: 4px; }

body main.company { max-width: 1120px; padding: 8px 20px 40px; gap: 28px; }

/* Hero */
body .hero { display: grid; grid-template-columns: 1fr 1.15fr; gap: 32px; align-items: center; }
body .hero h1 { font-size: clamp(40px, 6vw, 64px); line-height: 1.02; color: var(--text); }
body .hero h1 em { display: block; font-style: italic; font-weight: 400; color: var(--accent-text); }
body .hero p { margin-top: 18px; font-size: 18px; color: var(--muted); max-width: 34em; }
body .hero .hero-sub { margin-top: 10px; font-size: 16px; }
body .head-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
body .btn { display: inline-block; padding: 12px 26px; border-radius: 999px; font-weight: 800; text-decoration: none; border: 2px solid var(--accent); }
body .btn.solid { background: var(--accent); color: #fff; }
body .btn.solid:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
body .btn.ghost { color: var(--accent-text); }
body .btn.ghost:hover { background: var(--tint); }
@media (prefers-color-scheme: dark) { body .btn.solid { color: #10200f; } }
body .art-frame { border-radius: 24px; overflow: hidden; box-shadow: var(--shadow); line-height: 0; }
body .art-frame svg { width: 100%; height: auto; display: block; }

/* Cards and section titles */
body .card { border-radius: 20px; background: var(--surface); border-color: var(--border); }
body section > h2 { font-size: clamp(28px, 3.4vw, 38px); margin-bottom: 6px; }
body .sub { margin: 0 0 18px; font-size: 17px; }
body .arrow { font-weight: 800; color: var(--accent-text); text-decoration: none; display: inline-flex; align-items: center; gap: 6px; border-bottom: 2px solid currentColor; padding-bottom: 2px; }
body .arrow::after { content: "→"; }

/* Practise + guide picks */
body .practise-row { display: grid; grid-template-columns: 1.7fr 1fr; gap: 16px; }
body .practise { display: grid; grid-template-columns: 1.15fr 1fr; gap: 20px; align-items: center; padding: 28px 30px; background: linear-gradient(135deg, var(--surface) 55%, var(--tint)); }
body .practise h2 { font-size: clamp(26px, 3vw, 34px); margin-bottom: 12px; }
body .practise p { font-size: 18px; line-height: 1.5; }
body .practise .arrow { margin-top: 18px; }
body .notepad { position: relative; background: #fffef9; color: #2a3a2c; border-radius: 10px; padding: 22px 20px 22px 34px; box-shadow: 0 10px 24px rgb(60 50 30 / 0.16); transform: rotate(-3deg); font-family: "Patrick Hand", "Segoe Print", cursive; font-size: 19px; border-left: 10px dotted #a7a296; }
body .notepad strong { display: inline-block; font-size: 23px; font-weight: 400; margin-bottom: 8px; background: linear-gradient(transparent 60%, #cfe3b8 60%); }
body .notepad ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
body .notepad li { display: flex; gap: 10px; align-items: baseline; }
body .notepad li::before { content: "✓"; flex: none; width: 18px; height: 18px; border: 2px solid #3f7a4a; border-radius: 3px; color: #3f7a4a; font: 700 13px/14px system-ui, sans-serif; text-align: center; }
body .notepad .last { background: linear-gradient(transparent 70%, #f6d96b 70%); }
body .sticky { position: absolute; top: -18px; right: -12px; width: 62px; height: 62px; background: #fbe68a; transform: rotate(8deg); box-shadow: 0 4px 10px rgb(60 50 30 / 0.15); display: grid; place-items: center; font-size: 28px; }

body .picks { list-style: none; margin: 0; padding: 8px; display: flex; flex-direction: column; }
body .picks li + li { border-top: 1px solid var(--border); }
body .picks a { display: grid; grid-template-columns: 88px 1fr auto; gap: 14px; align-items: center; padding: 12px; border-radius: 14px; text-decoration: none; color: var(--text); }
body .picks a:hover { background: var(--surface-2); }
body .picks svg { width: 88px; height: 64px; border-radius: 10px; display: block; }
body .picks strong { display: block; font-size: 16px; }
body .picks span.d { display: block; font-size: 14px; color: var(--muted); line-height: 1.4; margin-top: 2px; }
body .picks .chev { color: var(--accent-text); font-size: 20px; }

/* Category tiles */
body .tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
body .tile { position: relative; display: flex; flex-direction: column; min-height: 200px; padding: 22px 24px 0; overflow: hidden; text-decoration: none; color: var(--text); background: var(--surface); transition: transform .2s ease; }
body .tile:hover { transform: translateY(-3px); }
body .tile h3 { font-size: 27px; color: var(--accent-text); }
body .tile p { margin-top: 8px; color: var(--muted); max-width: 22em; position: relative; z-index: 1; }
body .tile svg { display: block; width: calc(100% + 48px); margin: auto -24px 0; height: auto; }
body .tile.study { background: linear-gradient(#edf3ea, #f7f4ea); }
body .tile.money { background: linear-gradient(#fbf0e0, #f8f1e4); }
body .tile.well { background: linear-gradient(#e8f0ee, #f2f4ee); }
@media (prefers-color-scheme: dark) { body .tile.study, body .tile.money, body .tile.well { background: var(--surface); } }
@media (prefers-reduced-motion: reduce) { body .tile { transition: none; } }

/* Guides, grouped */
body .guide-group + .guide-group { margin-top: 22px; }
body .guide-group h3 { font-family: var(--serif); font-weight: 600; font-size: 21px; margin-bottom: 10px; scroll-margin-top: 16px; }
body .company .guide-list .card { border-top: 0; border-left: 4px solid var(--leaf); padding: 18px 20px; }
body .guide-list a { color: var(--text); text-decoration: none; }
body .guide-list a:hover { color: var(--accent-text); text-decoration: underline; }

/* Tools & apps */
body .tools { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
body .tools .card.has-shot { padding: 18px 20px 20px; background: var(--surface); }
body .shot-thumb { margin: 0 0 16px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface-2); padding: 10px 10px 0; box-shadow: inset 0 0 0 6px var(--surface-2); aspect-ratio: 16 / 10; }
body .shot-thumb img { border-radius: 8px 8px 0 0; box-shadow: 0 4px 14px rgb(60 50 30 / 0.12); }
body .tools h3 { font-family: var(--serif); font-weight: 600; font-size: 19px; line-height: 1.25; display: flex; align-items: center; gap: 10px; }
body .tools h3 svg.art { width: 28px; height: 28px; }
body .tools h3 a { color: var(--text); text-decoration: none; }
body .tools h3 a:hover { color: var(--accent-text); }
body .tools .card p { color: var(--muted); font-size: 15px; }
body .tools .card ul { color: var(--muted); font-size: 15px; }
body .tools .card p:last-child { margin-top: auto; padding-top: 12px; font-size: 15px; }
body .tools .card p:last-child a { font-weight: 800; color: var(--accent-text); }
body .more-link { margin-top: 16px; }

/* How we check our content */
body .check { display: grid; grid-template-columns: auto 1fr 1fr; gap: 20px 32px; align-items: start; padding: 24px 28px; background: var(--tint); }
body .check-title { display: flex; align-items: center; gap: 14px; }
body .check-title svg { width: 40px; height: 40px; color: var(--text); flex: none; }
body .check-title h2 { font-size: 24px; margin: 0; }
body .check h3 { font-size: 16px; font-weight: 800; margin-bottom: 4px; }
body .check p { color: var(--muted); font-size: 15px; }
body .check .rule { border-left: 1px solid var(--border); padding-left: 24px; }

/* Contact */
body .contact-form, body .contact-done { max-width: none; }
body input, body textarea { background: var(--bg); border-color: var(--border); }
body button { background: var(--accent); border-radius: 999px; padding: 12px 28px; }
body button:hover { background: var(--accent-strong); }
body button.secondary { background: var(--surface-2); color: var(--text); }

/* Footer */
body .site-foot { background: var(--foot-bg); color: var(--foot-text); margin-top: 16px; }
body .site-foot .wrap { padding-top: 28px; padding-bottom: 28px; display: flex; flex-direction: column; gap: 14px; }
body .site-foot .row { display: flex; align-items: center; justify-content: space-between; gap: 14px 24px; flex-wrap: wrap; }
body .site-foot .wordmark { color: #fff; }
body .site-foot .tagline { color: var(--foot-text); border-color: rgb(255 255 255 / 0.25); }
body .site-foot .foot-links { gap: 8px 26px; }
body .site-foot a { color: #fff; text-decoration: none; font-weight: 600; font-size: 15px; }
body .site-foot a:hover { text-decoration: underline; }
body .site-foot .small { font-size: 14px; color: var(--foot-text); opacity: 0.85; border-top: 1px solid rgb(255 255 255 / 0.15); padding-top: 14px; }
body .site-foot .small a { font-size: 14px; text-decoration: underline; font-weight: 400; }

/* Narrower screens */
@media (max-width: 960px) {
  body .practise-row { grid-template-columns: 1fr; }
  body .tools { grid-template-columns: repeat(2, 1fr); }
  body .check { grid-template-columns: 1fr 1fr; }
  body .check-title { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  body .hero { grid-template-columns: 1fr; }
  body .practise { grid-template-columns: 1fr; padding: 24px 22px; }
  body .notepad { max-width: 320px; margin: 12px auto 4px; }
  body .tiles, body .tools { grid-template-columns: 1fr; }
  body .tile { min-height: 0; }
  body .check { grid-template-columns: 1fr; padding: 22px; }
  body .check .rule { border-left: 0; padding-left: 0; }
  body .tagline { display: none; }
  body .site-head nav { gap: 6px 18px; }
}
@media (max-width: 420px) {
  body .picks a { grid-template-columns: 64px 1fr auto; gap: 12px; }
  body .picks svg { width: 64px; height: 48px; }
}
body .eyebrow { margin: 0 0 14px !important; font-size: 14px !important; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--leaf) !important; }



body .hero .head-actions { justify-content: flex-start; }
body .check-title svg { fill: none; stroke: currentColor; stroke-width: 2; }
body .art-frame svg, body .tile svg, body .picks svg { stroke: none; }

/* Round 2: logo, active tab, shorter hero, shared page styles. */
body .brandline .logo { display: block; height: 44px; width: auto; }
@media (prefers-color-scheme: dark) { body .brandline .logo { background: #fff; border-radius: 999px; } }
body .site-head nav a[aria-current="page"] { color: var(--accent-text); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; }
body .site-head { padding-top: 14px; padding-bottom: 14px; }

body .hero { grid-template-columns: 1.05fr 1fr; gap: 36px; }
body .hero h1 { font-size: clamp(36px, 4.6vw, 52px); }
body .eyebrow { margin-bottom: 8px !important; font-size: 13px !important; }
body .hero p { margin-top: 12px; font-size: 17px; }
body .hero .hero-sub { margin-top: 6px; font-size: 15px; }
body .head-actions { margin-top: 16px; }
body .btn { padding: 10px 24px; }
body .art-frame img { display: block; width: 100%; height: auto; aspect-ratio: 594 / 290; object-fit: cover; }

/* Long-form pages and the sites page */
body .page h1, body .company-head h1 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.01em; }
body .page article h2, body .page article h3, body section h2 { font-family: var(--serif); font-weight: 600; }
body .page .note { border-left-color: var(--leaf); background: var(--tint); }
body .page table { background: var(--surface); }
body .page th { background: var(--surface-2); }
body .page .guide-list .card { border-left: 4px solid var(--leaf); }
body .page .guide-list a { color: var(--text); }
body .page .guide-list a:hover { color: var(--accent-text); }
body main.page { padding-top: 16px; }
body .company-head p { color: var(--muted); }
body .btn-outline { border-color: var(--accent); color: var(--accent-text); }
body .btn-outline:hover { background: var(--accent); color: #fff; }
body .site:hover, body .apps li { color: inherit; }
@media (max-width: 760px) {
  body .brandline .logo { height: 38px; }
}
body .brandline .logo { height: 50px; }
body .page .guide-list { padding-left: 0; }
@media (max-width: 760px) {
  body .hero { grid-template-columns: 1fr; gap: 20px; }
  body .brandline .logo { height: 40px; }
}

/* Round 3: "A better way to practise" row about 20% shorter, same content and look. */
body .practise { padding: 20px 28px; gap: 16px; }
body .practise h2 { line-height: 1.15; margin-bottom: 10px; }
body .practise p { line-height: 1.45; }
body .practise .arrow { margin-top: 12px; }
body .notepad { padding: 14px 18px 14px 32px; }
body .notepad strong { margin-bottom: 4px; }
body .notepad ul { gap: 3px; }
body .picks { padding: 4px 8px; }
body .picks a { padding: 7px 10px; }
body .picks strong { line-height: 1.3; }
body .picks span.d { line-height: 1.35; }
body .practise-row { grid-template-columns: 1.5fr 1fr; }
body .picks a { grid-template-columns: 80px 1fr auto; }
body .picks svg { width: 80px; height: 58px; }
@media (max-width: 960px) { body .practise-row { grid-template-columns: 1fr; } }

/* ---------- Sign in / Sign up (header) ---------- */
/* One ChowChow Labs account for all the sites. Google, Apple and email marks
   show the ways in; a light sweep runs across it every few seconds. */
body .signin-btn {
  position: relative; overflow: hidden; isolation: isolate;
  display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
  padding: 9px 18px; border-radius: 999px; background: var(--accent); color: #fff; font-weight: 800; font-size: 15px; text-decoration: none;
  box-shadow: 0 8px 20px -10px var(--accent);
}
body .signin-btn:hover { background: var(--accent-strong); color: #fff; }
body .signin-btn::after {
  content: ""; position: absolute; top: -50%; bottom: -50%; left: -60%; width: 40%; z-index: 1; pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .55), transparent);
  transform: translateX(0) skewX(-18deg); animation: signin-shine 3.6s ease-in-out 1s infinite;
}
@keyframes signin-shine { 0%, 55% { transform: translateX(0) skewX(-18deg); } 100% { transform: translateX(420%) skewX(-18deg); } }
@media (prefers-reduced-motion: reduce) { body .signin-btn::after { animation: none; display: none; } }
body .signin-marks { display: inline-flex; gap: 3px; flex: none; }
body .signin-marks svg { width: 20px; height: 20px; padding: 3px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, .06); }
@media (max-width: 520px) { body .signin-btn .signin-marks { display: none; } }

/* ---------- Ads (ads.js) ---------- */
/* Hidden unless an ad is loading or showing, so an empty spot never leaves a gap. */
body .ccl-ad { display: none; position: relative; }
body .ccl-ad.is-loading, body .ccl-ad.is-filled { display: block; }
body .ccl-ad .ad-label { display: block; text-align: center; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
body .ccl-ad .ccl-ad-box { display: flex; justify-content: center; min-height: 50px; }
body .ccl-ad.ad-top { max-width: 1120px; margin: 0 auto 12px; padding: 0 20px; }
body .ccl-ad.ad-bottom { max-width: 1120px; margin: 24px auto 8px; padding: 0 20px; }
body .ccl-ad.ad-inline { margin: 4px 0; }
/* The ad beside the Study & pass guides: a card like its neighbours. */
body .company .guide-list .ad-card { display: flex; align-items: center; justify-content: center; }
body .company .guide-list .ad-card:not(:has(.ccl-ad.is-loading, .ccl-ad.is-filled)) { display: none; }
body .company .guide-list .ad-card:hover { transform: none; }

/* ---------- Sign-in page (login.html) ---------- */
body .login-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 20px; margin-top: 18px; align-items: start; }
@media (max-width: 760px) { body .login-grid { grid-template-columns: 1fr; } }
body .login-card h2, body .login-grid h2 { margin-top: 0; font-size: 1.3rem; }
body .social-signin { display: grid; gap: 10px; margin: 14px 0 4px; }
body .social-btn { width: 100%; display: flex; align-items: center; gap: 12px; padding: 11px 18px; border-radius: 12px; font-weight: 700; align-self: stretch; }
body .social-btn svg { width: 20px; height: 20px; flex: none; }
body .social-btn span { flex: 1; text-align: center; margin-right: 32px; }
body .social-google, body .social-google:hover { background: #fff; color: #1f1f1f; border: 1px solid #747775; }
body .social-apple, body .social-apple:hover { background: #000; color: #fff; border: 1px solid #000; }
body .social-btn:hover { filter: brightness(.94); }
body .social-or { display: flex; align-items: center; gap: 12px; margin: 12px 0; color: var(--muted); font-size: 14px; }
body .social-or::before, body .social-or::after { content: ""; flex: 1; height: 1px; background: var(--border); }
body .login-form { display: grid; gap: 8px; }
body .login-form label { font-weight: 700; }
body .login-form input { font: inherit; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--border); background: var(--bg); color: var(--text); }
body .login-form button[type="submit"] { justify-self: start; }
body .link-btn, body .link-btn:hover { background: none; color: var(--accent-text); padding: 6px 0; text-decoration: underline; font-weight: 700; }
body .login-error { color: #b3261e; font-weight: 700; }
body .login-sites { margin: 10px 0; padding-left: 20px; display: grid; gap: 6px; }
/* Wide screens: logo, menu and the sign-in button on one row. */
@media (min-width: 1040px) {
  body .site-head { flex-wrap: nowrap; gap: 12px 20px; }
  body .site-head .tagline { white-space: nowrap; }
  body .site-head nav { margin-left: auto; flex-wrap: nowrap; gap: 8px 20px; }
  body .site-head nav a { white-space: nowrap; }
}
