:root {
  --primary-1: #1f4e5f;
  --primary-2: #5b3a57;
  --primary-3: #2f4a3c;
  --accent: #b08a4a;
  --text-light: #f4efe6;
  --text-dark: #2e2e2e;
  --panel-border: rgba(244, 239, 230, 0.47);
  --panel-shadow: 0 22px 48px rgba(31, 78, 95, 0.45);
  --radius: 1.1rem;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  color: var(--text-light);
  font-family: "Work Sans", "Segoe UI", sans-serif;
  background: var(--text-dark);
  line-height: 1.55;
}

a {
  color: var(--text-light);
  text-decoration-color: var(--accent);
}

a:visited {
  color: var(--text-light);
}

.site-shell {
  position: relative;
  z-index: 1;
  width: min(72rem, 100% - 2.2rem);
  margin: 2.2rem auto 2.8rem;
  display: grid;
  gap: 1.25rem;
}

.site-footer {
  width: min(72rem, 100% - 2.2rem);
  margin: 0 auto 1.8rem;
  text-align: center;
}

.site-footer p {
  margin: 0;
  color: rgba(244, 239, 230, 0.82);
  font-size: 0.85rem;
}

.panel {
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  box-shadow: var(--panel-shadow);
  padding: clamp(1.15rem, 2vw, 2rem);
  backdrop-filter: blur(7px);
}

.panel.hero,
.panel.book,
.panel.newsletter,
.panel.manage {
  background: var(--primary-1);
}

.panel.wordmark-panel {
  background: var(--text-light);
  border-color: rgba(46, 46, 46, 0.18);
  color: var(--text-dark);
}

.hero,
.book {
  display: grid;
  gap: 1.2rem;
  align-items: center;
}

.hero {
  grid-template-columns: 1.2fr 0.8fr;
}

.book {
  grid-template-columns: 0.7fr 1.3fr;
}

h1,
h2 {
  font-family: "Fraunces", Georgia, serif;
  line-height: 1.08;
  letter-spacing: 0.01em;
  margin: 0;
  color: var(--text-light);
}

h1 {
  font-size: clamp(2.1rem, 3.5vw, 3.3rem);
}

h2 {
  font-size: clamp(1.7rem, 2.8vw, 2.4rem);
}

p {
  margin: 0.75rem 0;
  color: var(--text-light);
}

.lede {
  font-size: clamp(1rem, 1.8vw, 1.12rem);
}

.lede-name {
  font-size: clamp(1.45rem, 2.6vw, 1.95rem);
  font-weight: 600;
  line-height: 1;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.wordmark {
  display: block;
  width: min(29rem, 100%);
  height: auto;
  margin: 0;
  margin-inline: auto;
  border-radius: 0.45rem;
  object-fit: contain;
}

.wordmark-panel {
  padding-block: clamp(1rem, 2.4vw, 1.7rem);
  display: grid;
  place-items: center;
}

.eyebrow {
  margin: 0 0 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  font-size: 0.77rem;
  font-weight: 600;
  color: var(--text-light);
}

.photo-frame,
.book-cover {
  border-radius: 0.95rem;
  overflow: hidden;
  border: 1px solid rgba(244, 239, 230, 0.2);
  background: rgba(244, 239, 230, 0.06);
  box-shadow: 0 16px 30px rgba(31, 78, 95, 0.42);
}

.photo-frame img,
.book-cover img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.photo-frame picture,
.book-cover picture {
  display: block;
}

.book-cover {
  max-width: 24rem;
  justify-self: center;
}

.pills,
.buy-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1rem;
}

.pills a {
  text-decoration: none;
  color: var(--text-light);
  border: 1px solid rgba(244, 239, 230, 0.9);
  border-radius: 0.75rem;
  background: var(--primary-2);
  padding: 0.54rem 0.9rem;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.3rem;
  box-shadow:
    0 0 0.4rem rgba(176, 138, 74, 0.28),
    0 10px 22px rgba(31, 78, 95, 0.32);
  transition: transform 180ms ease, background-color 180ms ease, box-shadow 180ms ease;
}

.pills a:hover,
.pills a:focus-visible {
  background: var(--primary-3);
  color: var(--text-light);
  transform: translateY(-1px);
  box-shadow:
    0 0 0.5rem rgba(176, 138, 74, 0.35),
    0 14px 24px rgba(31, 78, 95, 0.38);
}

.pills a:active {
  transform: translateY(0);
  box-shadow: 0 8px 18px rgba(31, 78, 95, 0.4);
}

.btn,
.btn-alt {
  appearance: none;
  border: 1px solid rgba(244, 239, 230, 0.9);
  border-radius: 0.75rem;
  padding: 0.64rem 0.94rem;
  font: inherit;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 2.3rem;
  color: var(--text-light);
  background: var(--primary-2);
  font-size: 1rem;
  box-shadow:
    0 0 0.4rem rgba(176, 138, 74, 0.28),
    0 10px 22px rgba(31, 78, 95, 0.32);
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.btn-alt {
  opacity: 0.95;
}

.btn:hover,
.btn-alt:hover {
  background: var(--primary-3);
  transform: translateY(-1px);
  box-shadow:
    0 0 0.5rem rgba(176, 138, 74, 0.35),
    0 14px 24px rgba(31, 78, 95, 0.38);
}

.btn:active,
.btn-alt:active {
  transform: translateY(0);
  box-shadow: 0 8px 18px rgba(31, 78, 95, 0.4);
}

.btn:disabled,
.btn-alt:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.section-head p {
  margin-top: 0.5rem;
}

.stack {
  display: grid;
  gap: 0.72rem;
}

.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

label {
  font-size: 0.89rem;
  font-weight: 500;
  color: var(--text-light);
}

input[type="text"],
input[type="email"] {
  width: 100%;
  border: 1px solid rgba(244, 239, 230, 0.7);
  border-radius: 0.62rem;
  padding: 0.67rem 0.76rem;
  background: rgba(244, 239, 230, 0.08);
  color: var(--text-light);
  font: inherit;
}

input::placeholder {
  color: rgba(244, 239, 230, 0.84);
}

input:focus,
input:focus-visible {
  outline: 2px solid var(--text-light);
  outline-offset: 1px;
  border-color: rgba(244, 239, 230, 0.9);
}

input[aria-invalid="true"] {
  border-color: rgba(244, 239, 230, 0.9);
}

.checkbox {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.88rem;
}

.checkbox input {
  margin-top: 0.2rem;
  accent-color: var(--accent);
}

.form-message {
  min-height: 1.4rem;
  margin-top: 0.5rem;
  font-size: 0.92rem;
  color: var(--text-light);
}

.form-message.ok {
  border-left: 3px solid var(--text-light);
  background: rgba(176, 138, 74, 0.18);
  padding-left: 0.55rem;
}

.form-message.error {
  border-left: 3px solid var(--text-light);
  padding-left: 0.55rem;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--text-light);
  outline-offset: 2px;
}

.reveal {
  animation: riseIn 560ms ease both;
}

.delay-1 {
  animation-delay: 90ms;
}

.delay-2 {
  animation-delay: 180ms;
}

.delay-3 {
  animation-delay: 260ms;
}

.delay-4 {
  animation-delay: 340ms;
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

  .photo-frame {
    max-width: 28rem;
    width: 100%;
    justify-self: center;
  }

  .book-cover {
    max-width: 18rem;
  }
}
