:root {
  --cream: #faf6f0;
  --paper: #f2eadf;
  --ink: #2b2724;
  --ink-soft: #5b514a;
  --red: #bf5253;
  --red-btn: #b54849;
  --red-dark: #9e3f40;
  --sand: #e4d8c8;
  --white: #ffffff;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --max: 1120px;
  --shadow-soft: 0 24px 50px -32px rgba(43, 39, 36, 0.45);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  background-color: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

::selection {
  background-color: var(--red);
  color: var(--white);
}

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
  border-radius: 4px;
}

.container {
  width: min(100% - 2.5rem, var(--max));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  border-radius: 8px;
  background-color: var(--ink);
  color: var(--cream);
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: rgba(250, 246, 240, 0.9);
  border-bottom: 1px solid var(--sand);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 78px;
}

.brand {
  flex: 0 0 auto;
}

.brand img {
  width: auto;
  height: 48px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.8rem;
}

.nav a {
  position: relative;
  padding-block: 0.25rem;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.nav a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background-color: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}

.nav a:not(.nav-cta):hover::after,
.nav a:not(.nav-cta):focus-visible::after {
  transform: scaleX(1);
}

.nav a.nav-cta {
  padding: 0.6rem 1.15rem;
  border-radius: 999px;
  background-color: var(--red-btn);
  color: var(--cream);
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.nav a.nav-cta:hover {
  background-color: var(--red-dark);
  color: var(--cream);
  transform: translateY(-1px);
}

.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(3rem, 6vw, 5.5rem) 0 clamp(4rem, 7vw, 6rem);
  background:
    radial-gradient(900px 520px at 88% -10%, #f3e6da 0%, rgba(243, 230, 218, 0) 65%),
    var(--cream);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.eyebrow,
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  margin: 0 0 1rem;
  color: var(--red-dark);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}

.eyebrow::before,
.section-label::before {
  content: "";
  width: 30px;
  height: 1px;
  background-color: currentColor;
}

.hero h1 {
  margin: 0 0 1.4rem;
  max-width: 20ch;
  font-family: var(--serif);
  font-size: clamp(2.4rem, 4.2vw, 3.8rem);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.04;
}

.lede {
  max-width: 45ch;
  margin: 0;
  color: var(--ink-soft);
  font-size: clamp(1.05rem, 1.3vw, 1.22rem);
  line-height: 1.7;
}

.hero-author {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 1.6rem 0 0;
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.hero-author::before {
  content: "";
  width: 26px;
  height: 1px;
  background-color: var(--red);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2.2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary {
  background-color: var(--red-btn);
  color: var(--cream);
  box-shadow: 0 14px 24px -14px rgba(191, 82, 83, 0.7);
}

.btn-primary:hover {
  background-color: var(--red-dark);
  transform: translateY(-2px);
}

.btn-ghost {
  border-color: var(--sand);
  background-color: transparent;
  color: var(--ink);
}

.btn-ghost:hover {
  border-color: var(--red);
  color: var(--red-dark);
  transform: translateY(-2px);
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  padding: 1rem 1rem 2rem;
}

.cover-frame {
  position: relative;
  width: min(100%, 390px);
  border-radius: 6px 10px 10px 6px;
  background-color: var(--white);
  box-shadow:
    0 40px 80px -30px rgba(43, 39, 36, 0.55),
    0 10px 25px -12px rgba(43, 39, 36, 0.3);
  transform: rotate(-1.2deg);
}

.cover-frame picture,
.cover-frame img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: inherit;
}

.cover-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(43, 39, 36, 0.16), rgba(43, 39, 36, 0) 5%, rgba(255, 255, 255, 0.08) 7%, rgba(43, 39, 36, 0) 11%);
  pointer-events: none;
}

.section {
  padding: clamp(4rem, 8vw, 7rem) 0;
}

.book {
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--sand);
  border-bottom: 1px solid var(--sand);
  background-color: var(--paper);
}

.book-inner {
  position: relative;
  max-width: 900px;
}

.book-watermark {
  position: absolute;
  top: -1.5rem;
  right: 0;
  width: 180px;
  height: auto;
  opacity: 0.12;
  pointer-events: none;
}

.book-copy h2,
.author-copy h2,
.buy-head h2 {
  margin: 0 0 1.4rem;
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.book-copy h2 {
  max-width: 26ch;
  font-size: clamp(2rem, 3.4vw, 3rem);
}

.book-copy p {
  max-width: 68ch;
  margin: 0 0 1.15rem;
  color: var(--ink-soft);
}

.book-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 3rem;
  margin: 2.5rem 0 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--sand);
}

.book-meta dt {
  color: var(--ink-soft);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.book-meta dd {
  margin: 0.3rem 0 0;
  font-weight: 600;
  font-size: 1rem;
}

.author {
  background-color: var(--cream);
}

.author-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.author-photo {
  position: relative;
  width: min(100%, 380px);
  margin-inline: auto;
}

.author-photo::before {
  content: "";
  position: absolute;
  inset: -14px;
  border: 1px solid var(--red);
  border-radius: 200px 200px 24px 24px;
  opacity: 0.35;
}

.author-photo picture {
  display: block;
  overflow: hidden;
  aspect-ratio: 900 / 978;
  border: 1px solid var(--sand);
  border-radius: 200px 200px 24px 24px;
  background-color: var(--paper);
  box-shadow: var(--shadow-soft);
}

.author-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.author-copy h2 {
  font-size: clamp(2.2rem, 3.6vw, 3.2rem);
}

.author-copy p {
  max-width: 58ch;
  margin: 0 0 1.15rem;
  color: var(--ink-soft);
}

.buy {
  border-top: 1px solid var(--sand);
  background-color: var(--paper);
}

.buy-head {
  max-width: 720px;
  margin: 0 auto 2.8rem;
  text-align: center;
}

.buy-head h2 {
  max-width: 24ch;
  margin-inline: auto;
  font-size: clamp(2rem, 3.4vw, 3rem);
}

.buy-head p:not(.section-label) {
  margin: 0;
  color: var(--ink-soft);
}

.retailers {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.retailer {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 124px;
  padding: 1.5rem 1.25rem;
  border: 1px solid var(--sand);
  border-radius: 16px;
  background-color: var(--white);
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.retailer img {
  width: auto;
  height: auto;
  max-width: 150px;
  max-height: 48px;
  object-fit: contain;
}

.retailer:hover {
  border-color: var(--red);
  box-shadow: 0 18px 30px -18px rgba(43, 39, 36, 0.35);
  transform: translateY(-4px);
}

.site-footer {
  padding: clamp(3rem, 6vw, 4.5rem) 0 2rem;
  background-color: #26221f;
  color: #efe6db;
}

.footer-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding-bottom: 2.2rem;
  border-bottom: 1px solid rgba(239, 230, 219, 0.14);
}

.footer-brand img {
  width: auto;
  height: 56px;
  filter: brightness(0) invert(1);
  opacity: 0.9;
}

.footer-site {
  margin: 0;
}

.footer-site a {
  color: #efe6db;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-decoration: none;
  border-bottom: 1px solid rgba(239, 230, 219, 0.35);
  transition: border-color 0.2s ease, color 0.2s ease;
}

.footer-site a:hover {
  border-color: #efe6db;
  color: var(--white);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin-top: 2.2rem;
}

.publishers {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.publishers img {
  width: auto;
  height: 38px;
  filter: brightness(0) invert(1);
  opacity: 0.75;
}

.publishers .erbulak-logo {
  width: 46px;
  height: 46px;
  padding: 5px;
  border-radius: 8px;
  background-color: var(--cream);
  object-fit: contain;
  filter: none;
  opacity: 0.9;
}

.copyright {
  margin: 0;
  color: rgba(239, 230, 219, 0.6);
  font-size: 0.82rem;
}

.to-top {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(239, 230, 219, 0.3);
  border-radius: 50%;
  color: #efe6db;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.to-top:hover {
  border-color: var(--red);
  background-color: var(--red);
  transform: translateY(-2px);
}

@media (max-width: 1024px) {
  .hero-grid {
    gap: 2.5rem;
  }

  .cover-frame {
    width: min(100%, 340px);
  }

  .retailers {
    grid-template-columns: repeat(2, 1fr);
  }

  .author-grid {
    gap: 2.5rem;
  }

  .book-watermark {
    width: 150px;
    opacity: 0.1;
  }
}

@media (max-width: 820px) {
  .hero-grid,
  .author-grid {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    max-width: 600px;
  }

  .hero h1 {
    max-width: 16ch;
  }

  .hero-visual {
    padding-top: 1.5rem;
  }

  .author-photo {
    width: min(100%, 300px);
  }

  .nav {
    gap: 1.2rem;
  }
}

@media (max-width: 600px) {
  .container {
    width: min(100% - 2rem, var(--max));
  }

  .header-inner {
    min-height: 68px;
  }

  .brand img {
    height: 40px;
  }

  .nav {
    gap: 0.9rem;
  }

  .nav a {
    font-size: 0.85rem;
  }

  .nav a.nav-cta {
    padding: 0.5rem 0.9rem;
  }

  .hero {
    padding-top: 2.5rem;
  }

  .hero-grid {
    gap: 2rem;
  }

  .cover-frame {
    width: min(100%, 320px);
  }

  .retailers {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }

  .retailer {
    min-height: 104px;
    padding: 1.1rem 0.75rem;
  }

  .retailer img {
    max-width: 120px;
    max-height: 38px;
  }

  .book-meta {
    gap: 1.25rem 2rem;
  }

  .footer-top,
  .footer-bottom {
    align-items: flex-start;
  }
}

@media (max-width: 420px) {
  .hero h1 {
    font-size: 2.35rem;
  }

  .actions .btn {
    flex: 1 1 auto;
  }

  .publishers {
    gap: 1.25rem;
  }

  .publishers img {
    height: 32px;
  }

  .publishers .erbulak-logo {
    width: 38px;
    height: 38px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
