:root {
  --ink: #0c0707;
  --ink-2: #160d0c;
  --ink-3: #221312;
  --red: #e8291c;
  --red-deep: #9f1710;
  --gold: #f5b91e;
  --bone: #f4efe6;
  --muted: #b9aca6;

  --bs-body-bg: var(--ink);
  --bs-body-color: var(--bone);
  --bs-body-font-family: 'Barlow', system-ui, sans-serif;
  --bs-body-font-size: 1.0625rem;
  --bs-body-line-height: 1.65;
  --bs-link-color-rgb: 245, 185, 30;
  --bs-link-hover-color-rgb: 255, 214, 100;
}

html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body { background: var(--ink); }

h1, h2, h3, .display-face {
  font-family: 'Anton', 'Barlow Condensed', Impact, sans-serif;
  font-weight: 400;
  letter-spacing: .01em;
  line-height: .95;
  text-transform: uppercase;
}
.condensed { font-family: 'Barlow Condensed', 'Barlow', sans-serif; letter-spacing: .14em; text-transform: uppercase; font-weight: 600; }

:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* ---------- Buttons ---------- */
.btn-kane, .btn-ghost {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  border-radius: 0;
  padding: .85rem 1.75rem;
  border-width: 2px;
  transition: background-color .2s, color .2s, border-color .2s, transform .2s;
}
.btn-kane { background: var(--red); border-color: var(--red); color: #fff; }
.btn-kane:hover, .btn-kane:focus { background: #ff3d2e; border-color: #ff3d2e; color: #fff; transform: translateY(-2px); }
.btn-ghost { background: transparent; border-color: var(--gold); color: var(--gold); }
.btn-ghost:hover, .btn-ghost:focus { background: var(--gold); color: var(--ink); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.btn-gold:hover, .btn-gold:focus { background: #ffd056; border-color: #ffd056; color: var(--ink); transform: translateY(-2px); }

/* ---------- Nav ---------- */
.site-nav {
  background: rgba(12, 7, 7, .0);
  transition: background-color .3s, backdrop-filter .3s, box-shadow .3s;
  padding-block: .9rem;
}
.site-nav.scrolled {
  background: rgba(12, 7, 7, .88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 rgba(255,255,255,.07);
}
.navbar-brand { font-family: 'Anton', sans-serif; font-size: 1.35rem; letter-spacing: .04em; text-transform: uppercase; color: var(--bone) !important; }
.navbar-brand span { color: var(--red); }
.site-nav .nav-link {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--bone);
  opacity: .75;
  padding-inline: 1rem !important;
  position: relative;
}
.site-nav .nav-link:hover { opacity: 1; }
.site-nav .nav-link.active { opacity: 1; color: var(--gold); }
.site-nav .nav-link.active::after {
  content: ""; position: absolute; left: 1rem; right: 1rem; bottom: .15rem; height: 2px; background: var(--red);
}
.navbar-toggler { border-radius: 0; border-color: rgba(255,255,255,.3); }
@media (max-width: 991.98px) {
  .site-nav .navbar-collapse { background: var(--ink-2); margin: .75rem -.75rem -.9rem; padding: 1rem 1.5rem 1.5rem; }
  .site-nav .nav-link.active::after { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 8rem 0 5rem;
  overflow: hidden;
  background:
    radial-gradient(1200px 600px at 10% 100%, rgba(232,41,28,.35), transparent 60%),
    linear-gradient(180deg, #0c0707 0%, #1a0a08 100%);
}
/* diagonal gold slice — echoes the cover's split between port and airport */
.hero::before {
  content: "";
  position: absolute; inset: 0 0 0 auto;
  width: 46%;
  background: linear-gradient(200deg, #ffcf4d 0%, #f5b91e 35%, #b26a0d 100%);
  clip-path: polygon(38% 0, 100% 0, 100% 100%, 0 100%);
  opacity: .96;
}
.hero::after {
  content: "";
  position: absolute; inset: 0;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,.05) 0 1px, transparent 1px 3px);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 2; }

.hero-kicker { color: var(--gold); font-size: 1rem; margin-bottom: 1.25rem; display: flex; align-items: center; gap: .9rem; }
.hero-kicker::before { content: ""; width: 44px; height: 2px; background: var(--gold); }

.hero-title { font-size: clamp(4.25rem, 13vw, 9rem); margin: 0 0 1.5rem; letter-spacing: -1px; }
.hero-title .t1 { display: block; color: var(--bone); }
.hero-title .t2 { display: block; color: var(--red); margin-top: .02em; }

.hero-lede { font-size: 1.3rem; max-width: 45ch; color: #e7ddd3; margin-bottom: 2.25rem; }
.byline { font-size: 1.05rem; color: var(--gold); margin-top: 2.25rem; }

.cover-wrap { position: relative; max-width: 380px; margin-inline: auto; }
.cover-wrap img {
  display: block; width: 100%; height: auto;
  transform: rotate(3deg);
  box-shadow: -30px 30px 60px rgba(0,0,0,.6), 0 0 90px rgba(232,41,28,.35);
  border-radius: 3px;
}
/* crosshair from the cover */
.crosshair {
  position: absolute; z-index: -1;
  width: 120%; aspect-ratio: 1; left: -10%; top: -6%;
  border: 1px solid rgba(232,41,28,.55); border-radius: 50%;
}
.crosshair::before, .crosshair::after { content: ""; position: absolute; background: rgba(232,41,28,.55); }
.crosshair::before { left: 50%; top: -12%; bottom: -12%; width: 1px; }
.crosshair::after { top: 50%; left: -12%; right: -12%; height: 1px; }

@media (max-width: 991.98px) {
  .hero { padding-top: 7rem; min-height: auto; }
  .hero::before { width: 100%; height: 42%; inset: auto 0 0 0; clip-path: polygon(0 40%, 100% 0, 100% 100%, 0 100%); opacity: .9; }
  .cover-wrap { max-width: 300px; margin-top: 3rem; }
}

/* ---------- Sections ---------- */
section { position: relative; }
.section-pad { padding: 7rem 0; }
.section-title { font-size: clamp(2.6rem, 6vw, 4.5rem); margin-bottom: 1.5rem; }
.section-title .red { color: var(--red); }
.rule { width: 64px; height: 4px; background: var(--red); margin-bottom: 2rem; }
.prose p { max-width: 62ch; color: #e5dad0; }
.prose p.lead { font-size: 1.35rem; line-height: 1.5; color: var(--bone); }

/* ---------- Book ---------- */
#book { background: var(--bone); color: var(--ink); }
#book .section-title { color: var(--ink); }
#book .prose p { color: #2b2120; }
#book .prose p.lead { color: var(--ink); }

.panel-stack { position: relative; min-height: 520px; }
.panel {
  position: absolute;
  background-image: url("cover.png");
  background-repeat: no-repeat;
  background-color: var(--ink);
  box-shadow: 0 25px 50px rgba(12,7,7,.35);
}
/* bottom-left of the cover: the freighter */
.panel-port {
  width: 72%; height: 340px; left: 0; top: 0;
  background-size: 235% auto; background-position: 0% 88%;
  clip-path: polygon(0 0, 100% 0, 88% 100%, 0 100%);
}
/* bottom-right of the cover: the airport */
.panel-air {
  width: 62%; height: 330px; right: 0; bottom: 0;
  background-size: 330% auto; background-position: 100% 88%;
  clip-path: polygon(14% 0, 100% 0, 100% 100%, 0 100%);
}
@media (max-width: 991.98px) { .panel-stack { min-height: 460px; margin-bottom: 2rem; } }

.details { list-style: none; padding: 0; margin: 2rem 0; border-top: 2px solid var(--ink); }
.details li { display: flex; justify-content: space-between; gap: 1rem; padding: .8rem 0; border-bottom: 1px solid rgba(12,7,7,.18); }
.details .k { font-family: 'Barlow Condensed', sans-serif; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--red-deep); }
.details .v { text-align: right; font-weight: 500; }

#book .btn-ghost { color: var(--ink); border-color: var(--ink); }
#book .btn-ghost:hover, #book .btn-ghost:focus { background: var(--ink); color: var(--bone); }

/* ---------- Author ---------- */
#author {
  background:
    linear-gradient(180deg, var(--ink) 0%, var(--ink-2) 100%);
}
.author-photo {
  aspect-ratio: 4 / 5; width: 100%; max-width: 380px;
  background: linear-gradient(160deg, var(--red-deep), #2a0b09 70%);
  display: grid; place-items: center;
  position: relative;
  clip-path: polygon(0 0, 100% 0, 100% 88%, 88% 100%, 0 100%);
}
.author-photo span { font-family: 'Anton', sans-serif; font-size: 6rem; color: rgba(255,255,255,.9); letter-spacing: .04em; }
.author-photo img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }

/* ---------- Signup ---------- */
#signup {
  background:
    linear-gradient(115deg, var(--red-deep) 0%, var(--red) 55%, #ff5a2b 100%);
  color: #fff;
  overflow: hidden;
}
#signup::before {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 34%;
  background: var(--ink); opacity: .22;
  clip-path: polygon(0 0, 100% 0, 40% 100%, 0 100%);
}
#signup .container { position: relative; z-index: 1; }
#signup .section-title { color: #fff; }
.signup-form .form-control {
  border-radius: 0; border: 2px solid var(--ink); background: var(--ink); color: var(--bone);
  padding: .95rem 1.1rem;
}
.signup-form .form-control::placeholder { color: #8f827c; }
.signup-form .form-control:focus { border-color: var(--gold); box-shadow: none; background: var(--ink); color: var(--bone); }
.form-note { font-size: .9rem; opacity: .85; }

/* ---------- Contact ---------- */
#contact { background: var(--ink-2); }
#contact .form-control {
  border-radius: 0; background: var(--ink); border: 1px solid rgba(255,255,255,.18); color: var(--bone); padding: .85rem 1rem;
}
#contact .form-control:focus { border-color: var(--gold); box-shadow: none; background: var(--ink); color: var(--bone); }
#contact .form-label { font-family: 'Barlow Condensed', sans-serif; letter-spacing: .12em; text-transform: uppercase; font-weight: 600; color: var(--muted); }
.contact-list { list-style: none; padding: 0; margin: 2rem 0 0; }
.contact-list li { padding: 1rem 0; border-top: 1px solid rgba(255,255,255,.12); }
.contact-list li:last-child { border-bottom: 1px solid rgba(255,255,255,.12); }
.contact-list .k { display: block; font-family: 'Barlow Condensed', sans-serif; letter-spacing: .12em; text-transform: uppercase; font-weight: 600; color: var(--gold); font-size: .95rem; }
.contact-list a { color: var(--bone); text-decoration: none; }
.contact-list a:hover { color: var(--gold); }
#thanksModal .modal-content { border-radius: 0; background: var(--ink-2); border: 0; border-top: 4px solid var(--red); }
#thanksModal .modal-title { font-size: 2.25rem; }

/* ---------- Footer ---------- */
footer { background: #060303; padding: 3rem 0 2.5rem; border-top: 4px solid var(--red); color: var(--muted); font-size: .95rem; }
footer .brand { font-family: 'Anton', sans-serif; font-size: 1.6rem; text-transform: uppercase; color: var(--bone); letter-spacing: .03em; }
footer .brand span { color: var(--red); }
footer a { color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--gold); }
footer .foot-links a { margin-right: 1.4rem; font-family: 'Barlow Condensed', sans-serif; letter-spacing: .12em; text-transform: uppercase; font-weight: 600; }

/* One deliberate motion moment: hero load-in */
@media (prefers-reduced-motion: no-preference) {
  .hero .t1 { animation: cut .7s cubic-bezier(.2,.8,.2,1) both; }
  .hero .t2 { animation: cut .7s .12s cubic-bezier(.2,.8,.2,1) both; }
  @keyframes cut { from { clip-path: inset(0 100% 0 0); transform: translateX(-12px); } to { clip-path: inset(0 0 0 0); transform: none; } }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ---------- Sample chapter ---------- */
.chapter-head {
  padding: 9rem 0 4rem;
  background:
    radial-gradient(1000px 500px at 10% 100%, rgba(232,41,28,.3), transparent 60%),
    linear-gradient(180deg, #0c0707 0%, #1a0a08 100%);
}
.chapter-title { font-size: clamp(3.25rem, 10vw, 6.5rem); margin: 0; }
.chapter-title .t2 { display: block; color: var(--red); }
.chapter-body { background: var(--bone); color: var(--ink); padding: 5rem 0 6rem; }
.chapter-body .prose { max-width: 65ch; margin-inline: auto; }
.chapter-body .prose p { color: #2b2120; font-size: 1.15rem; line-height: 1.8; margin-bottom: 1.15rem; }
.chapter-end { background: var(--ink-2); padding: 6rem 0; text-align: center; }
.chapter-end .section-title { margin-bottom: 1rem; }
.chapter-end p { color: #e5dad0; max-width: 48ch; margin: 0 auto 2.25rem; }
@media (max-width: 991.98px) { .chapter-head { padding: 7rem 0 3rem; } .chapter-body { padding: 3rem 0 4rem; } }
