/* Tarnwick Press site. Brand colors from the covers (maths_cover_engine skins). */
:root {
  --navy: #0F52A8;
  --blue: #1470E0;
  --yellow: #FFD23F;
  --ink: #1a1a1a;
  --muted: #5b6270;
  --paper: #ffffff;
  --soft: #f3f6fb;
  --rule: #dfe5ee;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 17px/1.6 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
a { color: var(--navy); }
img { max-width: 100%; height: auto; display: block; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }

header.site { background: var(--navy); color: #fff; }
header.site .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; letter-spacing: .06em; }
.brand img { width: 34px; height: 34px; border-radius: 4px; }
nav a { color: #fff; text-decoration: none; margin-left: 18px; font-weight: 600; font-size: 15px; }
nav a:hover { text-decoration: underline; }

.hero { background: var(--navy); color: #fff; padding: 40px 0 56px; }
.hero h1 { font-size: clamp(34px, 6vw, 56px); line-height: 1.05; margin: 0 0 14px; color: var(--yellow); font-weight: 900; letter-spacing: -.01em; }
.hero p { font-size: 19px; max-width: 640px; margin: 0 0 22px; }
.btn { display: inline-block; background: var(--yellow); color: #13213d; font-weight: 800; text-decoration: none; padding: 13px 22px; border-radius: 8px; border: 0; font-size: 17px; cursor: pointer; }
.btn:hover { filter: brightness(.95); }
.btn.ghost { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.7); margin-left: 10px; }

section { padding: 52px 0; }
section.soft { background: var(--soft); }
h2 { font-size: 28px; line-height: 1.2; margin: 0 0 18px; }
.lead { color: var(--muted); max-width: 680px; margin: 0 0 28px; }

.books { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.book { background: #fff; border: 1px solid var(--rule); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; }
.book img { aspect-ratio: 8.5 / 11; object-fit: cover; width: 100%; }
.book .body { padding: 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.book h3 { margin: 0; font-size: 19px; }
.book .meta { color: var(--muted); font-size: 15px; margin: 0; }
.book .actions { margin-top: auto; padding-top: 10px; display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.book .actions a { font-weight: 700; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px; counter-reset: s; }
.step { background: #fff; border: 1px solid var(--rule); border-radius: 10px; padding: 18px; }
.step::before { counter-increment: s; content: counter(s); display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--yellow); font-weight: 800; margin-bottom: 8px; }
.step h3 { margin: 0 0 4px; font-size: 17px; }
.step p { margin: 0; color: var(--muted); font-size: 15px; }

.story { max-width: 680px; }
.signup { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: start; }
.formbox { background: #fff; border: 1px solid var(--rule); border-radius: 12px; padding: 22px; }
.formbox .placeholder { border: 2px dashed var(--rule); border-radius: 8px; padding: 18px; color: var(--muted); font-size: 15px; }
.small { font-size: 14px; color: var(--muted); }
ul.packs { padding-left: 20px; }

footer.site { border-top: 1px solid var(--rule); padding: 26px 0 40px; color: var(--muted); font-size: 14px; }
footer.site a { color: var(--muted); }

@media (max-width: 720px) {
  .signup { grid-template-columns: 1fr; }
  nav a { margin-left: 12px; font-size: 14px; }
  .btn.ghost { margin: 10px 0 0; }
}
