/* The Mindset by Longevity Edition — shared styles
   Values taken from the design handoff README. Breakpoint: <820px mobile. */

:root {
  --white: #FFFFFF;
  --cream: #FBF6F1;
  --modal-surface: #F4EFEA;
  --tip-surface: #E8DFD7;
  --link-2: #E9E4DE;
  --ink: #111111;
  --ink-2: #222222;
  --body: #333333;
  --muted: rgba(255,255,255,0.6);
  --placeholder: rgba(255,255,255,0.55);
  --error: #F2B8A8;
  --overlay: rgba(6,8,8,0.62);
  --font-sans: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --font-serif: 'Newsreader', Georgia, 'Times New Roman', serif;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-sans);
  color: var(--white);
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.035em;
}
a { color: var(--white); text-decoration: none; }
a:hover { color: #D9D4CE; }
img { display: block; max-width: 100%; height: auto; }
button { font: inherit; letter-spacing: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--white); outline-offset: 4px; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* Extended caps used for buttons and labels */
.caps {
  font-stretch: 125%;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.arrow-btn {
  display: inline-flex; align-items: center;
  gap: clamp(10px, 0.9vw, 18px);
  white-space: nowrap;
  transition: opacity .15s ease;
}
.arrow-btn:hover { opacity: 0.75; }
.arrow-btn svg { width: clamp(26px, 1.6vw, 38px); height: auto; flex: 0 0 auto; }

/* Footer (shared) */
.site-footer {
  display: flex; flex-wrap: wrap; align-items: center;
  column-gap: clamp(20px, 1.75vw, 40px); row-gap: 6px;
  font-size: clamp(14px, 1.05vw, 22px);
  letter-spacing: -0.01em;
}

/* ───────────────────────── Landing ───────────────────────── */
.landing { background: #0A0C0C; }
.landing .page {
  position: relative; min-height: 100vh; min-height: 100svh; overflow: hidden;
  background: linear-gradient(180deg,#555150 0%,#6E6864 14%,#8F847D 26%,#7E8A85 62%,#3C5552 82%,#223836 100%);
}
/* Hero media */
.hero-media { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.hero-media video, .hero-media .hero-still {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center top;
}
.hero-media .hero-still { background-size: cover; background-position: center top; }
.hero-media::after {
  /* keeps the lede, form and footer legible over the brightest part of the water */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0) 45%, rgba(0,0,0,0.35) 100%);
}
.landing .content {
  position: relative; z-index: 1;
  display: flex; flex-direction: column;
  min-height: 100vh; min-height: 100svh;
  padding: 2.6vw 3.3vw 2.4vw;
}
.wordmark { margin: 0; }
.wordmark img { width: 100%; }
.spacer { flex: 1 0 auto; min-height: 28vh; }
.landing main {
  display: flex; flex-direction: column; gap: clamp(14px, 1.4vw, 30px);
  max-width: 48vw;
}
.mindset-mark { margin: 0; }
.mindset-mark img { width: clamp(240px, 23.6vw, 620px); }
.lede { margin: 0; font-size: clamp(18px, 1.72vw, 40px); line-height: 1.3; font-weight: 400; }

.signup { display: flex; flex-direction: column; gap: clamp(10px, 1vw, 20px); margin: 0; }
.signup input[type="email"] {
  width: 100%; background: transparent; color: var(--white);
  border: 0; border-bottom: 2px solid var(--white); border-radius: 0;
  font: inherit; font-size: clamp(22px, 2.2vw, 50px); letter-spacing: -0.035em;
  padding: 0 0 clamp(6px, 0.6vw, 12px); outline: none;
}
.signup input::placeholder { color: var(--placeholder); }
.signup input:-webkit-autofill { -webkit-text-fill-color: #fff; transition: background-color 9999s; }
.signup.has-error input[type="email"] { border-bottom-color: var(--error); }
.signup .error { display: none; color: var(--error); font-size: 14px; letter-spacing: -0.02em; }
.signup.has-error .error { display: block; }
.signup .row {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.signup .disclaimer {
  margin: 0; font-size: clamp(11px, 0.8vw, 17px); line-height: 1.4; letter-spacing: -0.04em; color: var(--muted);
}
.signup .submit { font-size: clamp(12px, 1vw, 20px); flex: 0 0 auto; }
.signup .submit:disabled { opacity: 0.5; cursor: default; }
.signup .honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.signup .done {
  display: none; justify-content: space-between; align-items: center;
  border-bottom: 2px solid var(--white);
  font-size: clamp(22px, 2.2vw, 50px); padding-bottom: clamp(6px, 0.6vw, 12px);
}
.signup.is-done .done { display: flex; }
.signup.is-done .field, .signup.is-done .row, .signup.is-done .error { display: none; }

.landing main .site-footer { margin-top: clamp(24px, 3vw, 60px); }
.landing .footer-mobile { display: none; }

.phone {
  position: absolute; right: 8vw; bottom: 0; width: 24vw; max-width: 620px;
  z-index: 1; pointer-events: none;
}

/* Modal */
.modal {
  position: fixed; inset: 0; z-index: 50;
  background: var(--overlay); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  overflow-y: auto; padding: 32px;
  display: none; justify-content: center; align-items: flex-start;
}
.modal.is-open { display: flex; }
.dialog {
  display: flex; flex-direction: row; margin: auto;
  max-width: 980px; width: 100%;
  background: var(--modal-surface); color: var(--ink);
  box-shadow: 0 40px 120px rgba(0,0,0,0.45);
  letter-spacing: -0.025em;
}
.dialog .image {
  flex: 0 0 40%; position: relative; min-height: min(560px, calc(100vh - 64px));
  background: #1D2A22 url("assets/modal-waterfall.jpg") center 40% / cover no-repeat;
}
.dialog .image .mark {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 24px 28px;
  background: linear-gradient(180deg, rgba(0,0,0,0), rgba(0,0,0,0.55));
}
.dialog .image .mark img { width: 200px; }
.dialog .body { flex: 1 1 auto; display: flex; flex-direction: column; gap: 20px; padding: 36px 40px 40px; }
.dialog .head { display: flex; justify-content: space-between; align-items: center; }
.dialog .label { font-size: 12px; letter-spacing: 0.14em; }
.dialog .close {
  width: 44px; height: 44px; margin: -14px -14px -14px 0;
  display: inline-flex; align-items: center; justify-content: center;
  transition: opacity .15s ease;
}
.dialog .close:hover { opacity: 0.6; }
.dialog .rule { height: 1px; background: var(--ink); }
.dialog h2 { margin: 0; font-size: 44px; font-weight: 500; line-height: 1.02; letter-spacing: -0.045em; }
.dialog p { margin: 0; font-size: 17px; line-height: 1.4; color: var(--body); }
.dialog p strong { font-weight: 600; color: var(--ink); word-break: break-all; }
.dialog .tip { display: flex; flex-direction: column; gap: 6px; background: var(--tip-surface); padding: 16px 18px; }
.dialog .tip .label { font-size: 11px; }
.dialog .tip span:last-child { font-size: 15px; line-height: 1.4; color: var(--ink-2); }
.dialog .tip strong { font-weight: 600; color: var(--ink); }
.dialog .grow { flex: 1 0 auto; }
.dialog .cta { display: flex; flex-wrap: wrap; align-items: center; }
.share {
  display: inline-flex; align-items: center; gap: 14px;
  background: var(--ink); color: var(--modal-surface);
  min-height: 52px; padding: 0 26px; font-size: 13px; white-space: nowrap;
  transition: background .15s ease;
}
.share:hover { background: var(--body); }
.share svg { width: 30px; height: auto; }

@media (max-width: 999px) {
  .dialog { flex-direction: column; max-width: 560px; }
  .dialog .image { flex: 0 0 auto; min-height: 0; height: 240px; }
  .dialog .image .mark { padding: 16px 20px; }
  .dialog .image .mark img { width: 150px; }
  .dialog .body { gap: 16px; padding: 28px 32px 32px; }
  .dialog h2 { font-size: 36px; }
  .dialog p { font-size: 16px; }
}

/* ───────────────────────── Unsubscribed ───────────────────────── */
.unsub { background: #030303; }
.unsub .page {
  position: relative; min-height: 100vh; min-height: 100svh; overflow: hidden;
  background: linear-gradient(180deg,#A3A8AD 0%,#B3B2B1 18%,#B9B7B5 27%,#3A3C40 46%,#1C1E21 58%,#0A0B0C 76%,#020202 100%);
}
.unsub .photo {
  position: absolute; left: 0; right: 0; top: 24%; height: 15vw; z-index: 0; pointer-events: none;
  background: url("assets/unsub-bg-desktop.jpg") center / cover no-repeat;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 22%, #000 68%, transparent 100%);
          mask-image: linear-gradient(180deg, transparent 0%, #000 22%, #000 68%, transparent 100%);
}
.unsub .content {
  position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center;
  min-height: 100vh; min-height: 100svh; padding: 2.6vw 3.3vw 2.2vw;
}
.unsub .wordmark { width: 100%; }
.unsub .spacer-top { height: max(4vh, calc(48vh - 13vw - 2.6vw)); flex: 0 0 auto; }
.unsub main {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  max-width: 52vw; gap: clamp(12px, 1.3vw, 30px);
}
.unsub h1 {
  margin: 0; font-family: var(--font-serif); font-weight: 400;
  font-size: clamp(44px, 5.1vw, 124px); line-height: 0.98; letter-spacing: -0.035em;
  color: var(--cream); text-wrap: balance;
}
.unsub main p { margin: 0; font-size: clamp(17px, 1.6vw, 38px); line-height: 1.35; }
.unsub .ctas {
  display: flex; flex-direction: column; align-items: center;
  gap: clamp(10px, 1vw, 22px); margin-top: clamp(16px, 2.4vw, 56px);
}
.unsub .resub { font-size: clamp(12px, 0.85vw, 20px); }
.unsub .resub svg { width: clamp(24px, 1.5vw, 36px); }
.unsub .resub:disabled { opacity: 0.5; cursor: default; }
.unsub .back { font-size: clamp(14px, 1.05vw, 24px); color: var(--link-2); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.unsub .back:hover { color: var(--white); }
.unsub .error { display: none; color: var(--error); font-size: 14px; letter-spacing: -0.02em; }
.unsub.has-error .error { display: block; }
.unsub.is-resubbed .resub { display: none; }
.unsub .spacer-bottom { flex: 1 0 auto; min-height: 48px; }
.unsub .site-footer { justify-content: center; }

/* ───────────────────────── Mobile (<820px) ───────────────────────── */
@media (max-width: 819px) {
  /* Landing */
  .landing .page { background: linear-gradient(180deg,#565152 0%,#6A6362 12%,#000000 72%); }
  .hero-media { inset: auto 0 auto 0; top: calc(20px + 15vw); height: 120vw; }
  .hero-media video { display: none; }
  .hero-media .hero-still { background-image: url("assets/bg-mobile.jpg") !important; }
  .hero-media {
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 8%, #000 60%, transparent 100%);
            mask-image: linear-gradient(180deg, transparent 0%, #000 8%, #000 60%, transparent 100%);
  }
  .hero-media::after { display: none; }
  .landing .content { padding: 28px 20px 32px; }
  .spacer { min-height: 0; height: 112vw; flex: 0 0 auto; }
  .landing main { max-width: 100%; gap: 16px; }
  .mindset-mark img { width: 66%; }
  .lede { font-size: 17px; }
  .signup { gap: 16px; }
  .signup input[type="email"], .signup .done { font-size: 24px; padding-bottom: 8px; }
  .signup .row { flex-direction: column; align-items: flex-start; gap: 18px; }
  .signup .submit { order: 0; font-size: 13px; gap: 12px; }
  .signup .submit svg { width: 28px; }
  .signup .disclaimer { order: 1; font-size: 11px; }
  .landing main .site-footer { display: none; }
  .phone { position: relative; right: auto; width: 69%; max-width: 360px; margin: 56px auto 0; }
  .landing .footer-mobile { display: flex; padding-top: 28px; font-size: 16px; column-gap: 22px; row-gap: 6px; }

  /* Modal → bottom sheet */
  .modal { padding: 0; }
  .dialog { max-width: 100%; margin: auto 0 0; }
  .dialog .image { height: 200px; }
  .dialog .body { padding: 22px 20px 28px; }
  .dialog h2 { font-size: 30px; }
  .dialog .cta { flex-direction: column; align-items: stretch; }
  .share { justify-content: center; width: 100%; }

  /* Unsubscribed */
  .unsub .page { background: linear-gradient(180deg,#A9A6A5 0%,#BAB4B0 8%,#2E2925 52%,#0A0A0A 72%,#000000 100%); }
  .unsub .photo {
    top: calc(18px + 12vw); height: 125vw;
    background-image: url("assets/unsub-bg-mobile.jpg");
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 10%, #000 70%, transparent 100%);
            mask-image: linear-gradient(180deg, transparent 0%, #000 10%, #000 70%, transparent 100%);
  }
  .unsub .content { padding: 30px 20px 40px; }
  .unsub .spacer-top { height: 118vw; }
  .unsub main { max-width: 100%; }
  .unsub h1 { font-size: 46px; }
  .unsub main p { font-size: 17px; }
  .unsub .resub { font-size: 14px; }
  .unsub .resub svg { width: 28px; }
  .unsub .back { font-size: 15px; }
  .unsub .spacer-bottom { min-height: 72px; }
  .unsub .site-footer { font-size: 16px; max-width: 320px; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-media video { display: none; }
  .arrow-btn, .share, .dialog .close { transition: none; }
}
