/* Skadson Puzzles — colors come from CSS vars set in _includes/head.html,
   which the generator fills from series-manager (author.metadata.website.colors). */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--ink);
  background: var(--card);
  line-height: 1.6;
  font-size: 18px;
}
h1, h2, h3 { font-family: "Fraunces", Georgia, "Times New Roman", serif; line-height: 1.1; font-weight: 600; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

.wrap { width: min(1080px, 100% - 3rem); margin-inline: auto; }
.measure { max-width: 42rem; }
main { display: block; }
section { padding-block: clamp(2.5rem, 6vw, 5rem); }

/* Header */
.site-header { background: var(--bg); color: var(--fg); }
.site-header .bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: 1rem; flex-wrap: wrap; }
.brand { color: var(--fg); font-family: "Fraunces", serif; font-weight: 600; font-size: 1.25rem; letter-spacing: .2px; }
.brand:hover { text-decoration: none; opacity: .9; }
.nav { display: flex; gap: 1.25rem; flex-wrap: wrap; }
.nav a { color: var(--muted); font-size: .95rem; }
.nav a:hover { color: var(--fg); text-decoration: none; }

/* Hero */
.hero { background: var(--bg); color: var(--fg); }
.hero h1 { font-size: clamp(2.4rem, 7vw, 4.2rem); margin: 0; }
.hero .tagline { color: var(--muted); font-size: 1.25rem; margin-top: 1rem; }
.home-hero h1 { letter-spacing: -.5px; }
.hero-tagline { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: clamp(1.4rem, 3.2vw, 2rem); line-height: 1.15; color: var(--fg); margin: .9rem 0 0; }
.hero-tagline .accent { color: var(--accent); }
.line-hero .subhead { color: var(--muted); font-size: 1.15rem; margin-top: 1rem; }

/* Intro / about prose */
.intro .lede { font-size: 1.3rem; }
.about p { font-size: 1.12rem; margin-block: 0 1.1rem; }
.about p:last-child { margin-bottom: 0; }
.about strong { color: var(--bg); }
/* about flows straight into the books section — collapse the doubled padding */
.about { padding-bottom: 0; }
.books { padding-top: 2.5rem; }

.section-title { font-size: clamp(1.6rem, 3.5vw, 2.2rem); margin: 0 0 1.5rem; }

/* Featured puzzle line (home) — one quiet full-width card with an image */
.line-feature { display: grid; grid-template-columns: 230px 1fr; gap: 2.5rem; align-items: center; padding: 2.5rem; border: 1px solid #e6e8ef; border-radius: 18px; background: #fff; color: var(--ink); transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.line-feature + .line-feature { margin-top: 1.5rem; }
.line-feature:hover { box-shadow: 0 16px 40px rgba(20,30,60,.10); }
.line-feature-img { display: block; }
.line-feature-img img { border-radius: 6px; box-shadow: 0 14px 36px rgba(20,30,60,.22); width: 100%; }
.line-feature-body h2 { font-size: clamp(1.7rem, 3.5vw, 2.3rem); margin: 0 0 .5rem; }
.line-feature-body h2 a { color: inherit; }
.line-feature-body h2 a:hover { text-decoration: none; color: var(--accent); }
.line-feature-body p { color: #4a5168; font-size: 1.15rem; margin: 0 0 1.4rem; }
.line-feature-cta { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.line-feature-cta .more { color: var(--accent); font-weight: 600; }
@media (max-width: 640px) {
  .line-feature { grid-template-columns: 1fr; gap: 1.5rem; text-align: center; }
  .line-feature-img { max-width: 190px; margin: 0 auto; }
}

/* Book card */
.book { display: grid; grid-template-columns: 230px 1fr; gap: 2rem; align-items: start; padding: 2rem; border: 1px solid #e6e8ef; border-radius: 16px; background: #fff; }
.book + .book { margin-top: 1.5rem; }
.cover-wrap { }
.cover { border-radius: 4px; box-shadow: 0 14px 36px rgba(20,30,60,.22); width: 100%; }
.book-title { font-size: 1.7rem; margin: 0 0 .35rem; }
.book-title .vol { color: var(--accent); font-weight: 600; }
.subtitle { color: #4a5168; font-size: 1.05rem; margin: 0 0 1rem; }
.facts { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; margin: 0 0 1.25rem; }
.facts li { background: #f1f3f9; color: #3a4060; border-radius: 999px; padding: .25rem .75rem; font-size: .85rem; font-weight: 500; }
.book-body p { margin: 0 0 .9rem; }
.cta { margin-top: 1.25rem; }
.btn, .btn-amazon { display: inline-block; background: var(--accent); color: #fff; padding: .8rem 1.5rem; border-radius: 10px; font-weight: 600; }
.btn:hover, .btn-amazon:hover { text-decoration: none; filter: brightness(1.05); }
/* "Coming Soon on Amazon" — button-shaped but clearly not live; borrows
   currentColor so it reads on both the navy hero and white cards. */
.btn-soon { display: inline-block; padding: calc(.8rem - 1.5px) 1.5rem; border-radius: 10px; border: 1.5px solid currentColor; font-weight: 600; opacity: .6; }
.hero-cta { margin: 1.4rem 0 0; }

/* Newsletter */
.newsletter { background: var(--bg); color: var(--fg); }
.newsletter h2 { color: var(--fg); font-size: clamp(1.6rem, 3.5vw, 2.2rem); margin: 0 0 .75rem; }
.newsletter p { color: var(--muted); }
.signup { display: flex; gap: .6rem; margin-top: 1.25rem; flex-wrap: wrap; }
.signup input { flex: 1 1 16rem; padding: .85rem 1rem; border-radius: 10px; border: 1px solid #3a466b; background: #11192e; color: var(--fg); font-size: 1rem; }
.signup input::placeholder { color: #8e9ab8; }
.signup button { padding: .85rem 1.5rem; background: var(--accent); color: #fff; border: 0; border-radius: 10px; font-weight: 600; font-size: 1rem; cursor: pointer; }
.signup button:hover { filter: brightness(1.05); }
.newsletter .note { margin-top: 1rem; }

/* Footer */
.site-footer { background: #11192e; color: var(--muted); padding-block: 2.5rem; }
.site-footer .brand-line { font-family: "Fraunces", serif; color: var(--fg); font-size: 1.1rem; margin: 0 0 .25rem; }
.site-footer p { margin: 0; }
.site-footer .fine { margin-top: 1rem; font-size: .85rem; color: #6b7690; }

.muted { color: var(--muted); }

/* Kit (ConvertKit) embed — fit it to the brand. The embed sets some colors via
   inline style attributes, so the button override needs !important. */
.hero-signup { margin-top: 1.4rem; }
.signup-kicker { color: var(--muted); margin: 0 0 .35rem; font-size: 1rem; }
.formkit-form[data-uid="f12f61303b"] { max-width: 30rem; margin: 0; }
/* the embed leaves top padding for an (unused) header image; trim it so the
   form sits right under the CTA line */
.formkit-form[data-uid="f12f61303b"] [data-style="clean"] { padding-top: 0 !important; }
.formkit-form[data-uid="f12f61303b"] .formkit-fields { margin-top: 0; }
.formkit-form[data-uid="f12f61303b"] .formkit-input { border-radius: 10px !important; border-color: transparent !important; }
.formkit-form[data-uid="f12f61303b"] .formkit-submit { background-color: var(--accent) !important; border-radius: 10px !important; font-weight: 600 !important; }
.formkit-form[data-uid="f12f61303b"] .formkit-submit:hover { filter: brightness(1.05); }
/* 'Built with Kit' badge: force the logo white so it reads on the navy band */
.formkit-form[data-uid="f12f61303b"] .formkit-powered-by-convertkit-container { margin: .35rem 0 0; justify-content: flex-start; }
.formkit-form[data-uid="f12f61303b"] .formkit-powered-by-convertkit[data-variant="dark"] { margin: 0; filter: brightness(0) invert(1); opacity: .5; }

@media (max-width: 640px) {
  .book { grid-template-columns: 1fr; gap: 1.25rem; }
  .cover-wrap { max-width: 200px; }
}
