:root {
  --paper: #f3eee4;
  --sheet: #fffdf8;
  --ink: #292820;
  --muted: #777468;
  --line: #e7e0d4;
  --accent: #53634f;
  --accent-dark: #3f4d3b;
  --soft: #e9eee5;
  --danger: #9a493d;
  --shadow: 0 24px 70px rgba(54, 47, 35, .09);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "DM Sans", sans-serif;
  min-height: 100vh;
}

[hidden] {
  display: none !important;
}

.paper-grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: .19;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.16'/%3E%3C/svg%3E");
}

.shell {
  max-width: 1160px;
  margin: auto;
  padding: 30px 42px 24px;
  position: relative;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(83, 99, 79, .2);
  padding-bottom: 20px;
}

.wordmark {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .14em;
}

.wordmark i {
  font-style: normal;
  color: var(--accent);
  font-weight: 500;
}

.mark {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-family: "Playfair Display", serif;
  font-size: 19px;
}

.top-note,
.eyebrow,
.side-meta,
.note-number,
.panel-kicker,
label,
.fine-print,
.card-footer,
.page-footer,
.verified-detail span {
  font-family: "DM Mono", monospace;
  letter-spacing: .12em;
  font-size: 9px;
}

.top-note {
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 9px;
}

.live-dot {
  width: 6px;
  height: 6px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 0 4px #53634f18;
}

.layout {
  display: grid;
  grid-template-columns: 1fr 480px;
  gap: clamp(50px, 9vw, 130px);
  align-items: center;
  max-width: 1000px;
  margin: 78px auto 66px;
}

.intro {
  padding: 12px 0;
}

.eyebrow {
  color: var(--accent);
  margin: 0 0 20px;
}

.intro h1 {
  font-family: "Playfair Display", serif;
  font-weight: 500;
  font-size: clamp(42px, 5vw, 62px);
  line-height: 1.08;
  letter-spacing: -.04em;
  margin: 0 0 24px;
}

.intro h1 em {
  color: var(--accent);
  font-weight: 500;
}

.intro-copy {
  font-size: 14px;
  line-height: 1.9;
  color: var(--muted);
  max-width: 390px;
}

.note-card {
  margin-top: 60px;
  border-left: 1px solid #aab3a2;
  padding: 3px 0 3px 18px;
  max-width: 340px;
}

.note-number {
  color: var(--accent);
}

.note-card p {
  font-family: "Playfair Display", serif;
  font-size: 17px;
  line-height: 1.55;
  margin: 12px 0;
  color: #555448;
}

.note-line {
  display: block;
  width: 38px;
  height: 1px;
  background: #aab3a2;
  margin-top: 16px;
}

.side-meta {
  display: flex;
  gap: 28px;
  color: #9a9588;
  margin-top: 76px;
}

.book-card {
  background: var(--sheet);
  box-shadow: var(--shadow);
  border: 1px solid #e9e3d8;
  padding: 34px 38px 22px;
  position: relative;
  animation: rise .7s ease both;
}

.book-card:before {
  content: "";
  position: absolute;
  left: 12px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: #f1ece3;
}

.book-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.book-top .eyebrow {
  margin-bottom: 8px;
}

.book-top h2 {
  font-family: "Playfair Display", serif;
  font-weight: 500;
  font-size: 27px;
  margin: 0;
  letter-spacing: -.03em;
}

.seal {
  width: 42px;
  height: 42px;
  border: 1px solid #d8dfd2;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--accent);
  font-family: "Playfair Display", serif;
  font-size: 16px;
  position: relative;
}

.seal span {
  font-size: 8px;
  position: absolute;
  right: 4px;
  top: 4px;
}

.progress {
  display: flex;
  align-items: center;
  margin: 32px 0 38px;
  gap: 10px;
}

.progress-step {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #aaa597;
  white-space: nowrap;
}

.progress-step span {
  width: 23px;
  height: 23px;
  border: 1px solid #ddd7ca;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font: 10px "DM Mono", monospace;
}

.progress-step small {
  font: 8px "DM Mono", monospace;
  letter-spacing: .1em;
}

.progress-step.active,
.progress-step.done {
  color: var(--accent);
}

.progress-step.active span,
.progress-step.done span {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
}

.progress-rule {
  height: 1px;
  background: var(--line);
  flex: 1;
}

.panel {
  display: none;
  animation: fade .35s ease;
}

.panel.active {
  display: block;
}

.panel-kicker {
  color: var(--accent);
  margin: 0 0 14px;
}

.panel h3 {
  font-family: "Playfair Display", serif;
  font-size: 34px;
  line-height: 1.12;
  letter-spacing: -.035em;
  font-weight: 500;
  margin: 0 0 12px;
}

.muted {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.75;
  margin: 0 0 26px;
}

.muted strong {
  color: var(--ink);
  font-weight: 600;
  overflow-wrap: anywhere;
}

label {
  display: block;
  color: #6d6a5e;
  margin: 0 0 9px;
}

input {
  width: 100%;
  height: 49px;
  border: 1px solid #e2dccf;
  background: #fffefa;
  padding: 0 14px;
  font: 12px "DM Sans", sans-serif;
  color: var(--ink);
  outline: none;
  transition: border .2s, box-shadow .2s;
}

input::placeholder {
  color: #b0aa9e;
}

input:focus {
  border-color: #8b9a83;
  box-shadow: 0 0 0 3px #53634f13;
}

.primary,
.secondary {
  width: 100%;
  height: 49px;
  margin-top: 13px;
  border: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  cursor: pointer;
  font: 600 11px "DM Sans", sans-serif;
  letter-spacing: .02em;
  transition: background .2s, transform .2s;
}

.primary {
  background: var(--accent);
  color: #fff;
}

.primary:hover {
  background: var(--accent-dark);
  transform: translateY(-1px);
}

.primary:disabled,
.secondary:disabled {
  opacity: .6;
  cursor: wait;
  transform: none;
}

.primary b {
  font-size: 17px;
  font-weight: 400;
}

.fine-print {
  color: #a29d91;
  line-height: 1.7;
  margin: 18px 0 0;
  font-size: 8px;
  letter-spacing: .04em;
}

.message {
  padding: 11px 12px;
  margin-top: 15px;
  font-size: 11px;
  line-height: 1.6;
  border: 1px solid var(--line);
  background: #faf8f2;
  color: var(--muted);
}

.message.error {
  border-color: #ead4ce;
  background: #fbf3f0;
  color: var(--danger);
}

.message.success {
  border-color: #d8e2d3;
  background: #f3f7f0;
  color: var(--accent-dark);
}

.text-button {
  border: 0;
  background: none;
  color: var(--muted);
  padding: 16px 0 0;
  font: 11px "DM Sans", sans-serif;
  cursor: pointer;
}

.text-button:hover {
  color: var(--accent);
}

.success-panel {
  text-align: left;
}

.success-symbol {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-size: 23px;
  margin-bottom: 24px;
}

.verified-detail {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 15px 0;
  margin: 24px 0;
}

.verified-detail span {
  display: block;
  color: #999487;
  margin-bottom: 7px;
}

.verified-detail strong {
  font-size: 13px;
  overflow-wrap: anywhere;
}

.secondary {
  background: #f0eee7;
  color: var(--ink);
  justify-content: center;
}

.secondary:hover {
  background: #e7e4da;
}

.card-footer {
  border-top: 1px solid var(--line);
  margin-top: 38px;
  padding-top: 17px;
  display: flex;
  justify-content: space-between;
  color: #aaa497;
  font-size: 8px;
}

.page-footer {
  display: flex;
  justify-content: space-between;
  color: #a39d90;
  font-size: 8px;
  padding-top: 18px;
  border-top: 1px solid rgba(83, 99, 79, .17);
}

/* WELCOME & SUCCESS POPUP */

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(27, 29, 24, .48);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  opacity: 1;
  visibility: visible;
  transition: opacity .25s, visibility .25s;
}

.modal-backdrop.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.modal-card {
  width: min(100%, 410px);
  max-height: min(90vh, 760px);
  overflow-y: auto;
  background: var(--sheet);
  border: 1px solid #e9e3d8;
  box-shadow: 0 28px 90px rgba(20, 22, 18, .22);
  padding: 30px;
  position: relative;
  animation: modalRise .35s ease both;
}

.welcome-card {
  text-align: left;
  width: min(100%, 370px);
}

.modal-mark {
  width: 42px;
  height: 42px;
  border: 1px solid var(--accent);
  display: grid;
  place-items: center;
  color: var(--accent);
  font: 24px "Playfair Display", serif;
  margin-bottom: 22px;
  position: relative;
}

.modal-mark span {
  position: absolute;
  font: 9px "DM Sans", sans-serif;
  right: 3px;
  top: 3px;
}

.modal-card .eyebrow {
  margin-bottom: 10px;
}

.modal-card h2 {
  font: 500 30px/1.1 "Playfair Display", serif;
  letter-spacing: -.035em;
  margin: 0 0 13px;
}

.modal-copy {
  font-size: 12px;
  line-height: 1.8;
  color: var(--muted);
  margin: 0;
}

.creator-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  margin-top: 22px;
}

.creator-line span,
.premium-summary span,
.benefit-heading {
  font: 9px "DM Mono", monospace;
  letter-spacing: .12em;
  color: #999487;
}

.creator-line strong {
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--accent);
}

.modal-primary {
  margin-top: 19px;
}

.success-modal-card {
  width: min(100%, 440px);
  padding: 29px 30px 22px;
}

.modal-success-symbol {
  margin-bottom: 17px;
}

.premium-summary {
  border: 1px solid var(--line);
  background: #fcfaf5;
  margin-top: 20px;
  padding: 16px;
}

.premium-email,
.premium-expiry {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
}

.premium-expiry {
  padding-top: 13px;
}

.premium-email strong,
.premium-expiry strong {
  font-size: 13px;
  overflow-wrap: anywhere;
}

.benefit-list {
  padding-top: 14px;
  display: grid;
  gap: 9px;
}

.benefit-heading {
  margin-bottom: 2px;
}

.benefit-list div {
  font-size: 12px;
  color: #555448;
  display: flex;
  align-items: center;
  gap: 9px;
}

.benefit-list i {
  font-style: normal;
  color: var(--accent);
  font-size: 14px;
}

.modal-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  margin-top: 17px;
  align-items: center;
}

.modal-actions .primary {
  margin: 0;
  min-width: 0;
}

.close-button {
  height: 49px;
  padding: 0 17px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font: 11px "DM Sans", sans-serif;
  cursor: pointer;
  transition: background .2s, color .2s;
}

.close-button:hover {
  background: #f0eee7;
  color: var(--ink);
}

.modal-disclaimer {
  font-size: 9px;
  line-height: 1.6;
  color: #9a9588;
  margin: 13px 0 0;
}

/* QUICK GUIDE */

.guide-section {
  max-width: 1000px;
  margin: 0 auto 58px;
  padding: 28px 0 0;
  border-top: 1px solid rgba(83, 99, 79, .2);
}

.guide-heading {
  max-width: 540px;
  margin-bottom: 25px;
}

.guide-heading .eyebrow {
  margin-bottom: 10px;
}

.guide-heading h2 {
  font: 500 clamp(27px, 3vw, 36px)/1.15 "Playfair Display", serif;
  letter-spacing: -.03em;
  margin: 0 0 10px;
}

.guide-heading > p:last-child {
  font-size: 12px;
  line-height: 1.8;
  color: var(--muted);
  margin: 0;
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.guide-item {
  display: flex;
  gap: 14px;
  padding: 18px 16px;
  background: rgba(255, 253, 248, .58);
  border: 1px solid #e8e1d5;
  min-height: 135px;
}

.guide-number {
  font: 11px "DM Mono", monospace;
  color: var(--accent);
  padding-top: 3px;
}

.guide-item h3 {
  font: 500 18px "Playfair Display", serif;
  margin: 0 0 8px;
}

.guide-item p {
  font-size: 11px;
  line-height: 1.75;
  color: var(--muted);
  margin: 0;
}

.guide-item p strong {
  color: var(--ink);
  font-weight: 600;
}

.guide-reminder {
  font-size: 10px;
  line-height: 1.7;
  color: #898476;
  margin: 15px 0 0;
}

/* ANIMATIONS */

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

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

@keyframes modalRise {
  from {
    opacity: 0;
    transform: translateY(10px) scale(.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* RESPONSIVE */

@media (max-width: 800px) {
  .shell {
    padding: 20px 20px;
  }

  .layout {
    grid-template-columns: 1fr;
    gap: 30px;
    margin: 48px auto 42px;
    max-width: 500px;
  }

  .intro h1 {
    font-size: 46px;
  }

  .intro-copy {
    max-width: 440px;
  }

  .note-card {
    display: none;
  }

  .side-meta {
    margin-top: 25px;
  }

  .book-card {
    padding: 29px 25px 20px;
  }

  .book-card:before {
    left: 8px;
  }

  .page-footer {
    gap: 12px;
    flex-wrap: wrap;
  }

  .top-note {
    font-size: 8px;
    letter-spacing: .06em;
  }

  .guide-section {
    margin: 0 auto 38px;
    padding-top: 24px;
  }

  .guide-grid {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .guide-item {
    min-height: 0;
    padding: 15px;
  }

  .modal-card {
    padding: 25px 22px;
  }

  .success-modal-card {
    padding: 24px 21px 19px;
  }
}

@media (max-width: 390px) {
  .shell {
    padding: 16px 13px;
  }

  .book-card {
    padding: 25px 20px 18px;
  }

  .progress {
    gap: 6px;
  }

  .progress-step {
    gap: 4px;
  }

  .progress-step small {
    font-size: 7px;
  }

  .book-top h2 {
    font-size: 24px;
  }

  .panel h3 {
    font-size: 31px;
  }

  .top-note {
    font-size: 7px;
  }

  .modal-actions {
    grid-template-columns: 1fr;
  }

  .close-button {
    width: 100%;
  }

  .modal-card h2 {
    font-size: 27px;
  }
}
