/* PinSchedule landing page
   Palette follows the app (artifacts/pinschedule/constants/colors.ts). */

:root {
  --primary: #6c5ce7;
  --primary-deep: #4f3fd0;
  --primary-ink: #3b2fb0;
  --lavender: #f0eeff;
  --lavender-2: #e7e3ff;
  --bg: #fafafe;
  --card: #ffffff;
  --text: #1a1836;
  --muted: #5d5b76;
  --border: #e4e1ee;
  --green: #10b981;
  --gold: #f5b301;
  --coral: #ff6b6b;
  --teal: #14b8a6;
  --blue: #4a90d9;

  --radius: 20px;
  --shadow-sm: 0 1px 3px rgba(26, 24, 54, 0.06), 0 8px 20px rgba(26, 24, 54, 0.06);
  --shadow-lg: 0 2px 6px rgba(26, 24, 54, 0.08), 0 24px 48px rgba(79, 63, 208, 0.18);
  /* Fluid: content spans the full window; gutters, type and mockups grow with the viewport. */
  --max: none;
  --gutter: clamp(16px, 5vw, 120px);
  --header-h: clamp(72px, 4.2vw, 104px);
  --fs: clamp(16px, 0.35vw + 11px, 22px);   /* base type size */
  --u: clamp(10px, 0.78vw, 17px);          /* phone-mockup unit */
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: var(--fs);
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  overflow-x: clip;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
button { font: inherit; }

.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.center { text-align: center; }
.ico { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.ico-lg { width: calc(var(--fs) * 2.75); height: calc(var(--fs) * 2.75); stroke-width: 1.6; }
.c-primary { color: var(--primary); }
.c-green { color: var(--green); }
.c-gold { color: var(--gold); }

.sprite { position: absolute; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--primary-deep); color: #fff; padding: 10px 16px; border-radius: 10px; }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; border-radius: 6px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: calc(var(--fs) * 0.75) calc(var(--fs) * 1.5); border: 0; border-radius: 999px;
  font-weight: 600; font-size: calc(var(--fs) * 0.94); line-height: 1.2; cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 6px 16px rgba(108, 92, 231, 0.32); }
.btn-primary:hover { background: var(--primary-deep); transform: translateY(-1px); }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: rgba(250, 250, 254, 0.86);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  transition: box-shadow .2s ease;
}
.site-header.scrolled { box-shadow: 0 1px 0 var(--border), 0 8px 24px rgba(26, 24, 54, 0.05); }
.header-inner { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; flex: none; }
.brand-mark { width: calc(var(--fs) * 2.25); height: calc(var(--fs) * 2.25); border-radius: 10px; background: var(--primary); color: #fff; display: grid; place-items: center; }
.brand-mark .ico { width: calc(var(--fs) * 1.25); height: calc(var(--fs) * 1.25); }
.brand-name { font-size: calc(var(--fs) * 1.375); font-weight: 800; letter-spacing: -0.02em; color: var(--primary-ink); }
.brand-name span { color: var(--primary); }
.brand-logo { display: block; height: calc(var(--fs) * 2.6); width: auto; }

.nav { display: flex; align-items: center; gap: 28px; margin-left: auto; margin-right: 8px; font-size: calc(var(--fs) * 0.9); font-weight: 500; }
.nav a:not(.btn) { color: var(--text); padding: 6px 0; border-bottom: 2px solid transparent; transition: color .15s, border-color .15s; }
.nav a:not(.btn):hover, .nav a.active { color: var(--primary); border-color: var(--primary); }
.nav-cta { display: none; }
.nav-toggle { display: none; margin-left: auto; width: 44px; height: 44px; border: 0; border-radius: 12px; background: var(--lavender); color: var(--primary-ink); cursor: pointer; place-items: center; }
.nav-toggle .ico { width: 22px; height: 22px; }
.nav-toggle .ico-close { display: none; }
.nav-toggle[aria-expanded="true"] .ico-menu { display: none; }
.nav-toggle[aria-expanded="true"] .ico-close { display: block; }

/* ---------- Typography ---------- */
.eyebrow { font-size: calc(var(--fs) * 0.78); font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--primary); margin-bottom: 14px; }
h1 { font-size: clamp(38px, 4.3vw, 96px); line-height: 1.08; font-weight: 800; letter-spacing: -0.035em; }
h1 .accent { color: var(--primary); }
h1, h2 { text-wrap: balance; }
h2 { font-size: clamp(26px, 2.6vw, 56px); line-height: 1.2; font-weight: 700; letter-spacing: -0.025em; }
h3 { font-size: 1em; font-weight: 700; letter-spacing: -0.01em; }
.lede { margin-top: 24px; font-size: calc(var(--fs) * 1.06); max-width: 30em; color: var(--text); }

/* ---------- Store badges ---------- */
.store-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.store-row.center { justify-content: center; }
.store {
  display: inline-flex; align-items: center; gap: 10px;
  height: calc(var(--fs) * 3.25); padding: 0 calc(var(--fs) * 1.25) 0 calc(var(--fs) * 1); border-radius: 10px;
  background: #0b0b12; color: #fff; border: 1px solid #3a3a48;
  transition: transform .15s ease, box-shadow .15s ease;
}
.store:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(0, 0, 0, 0.25); }
.store-glyph { width: calc(var(--fs) * 1.75); height: calc(var(--fs) * 1.75); flex: none; }
.store-text { display: flex; flex-direction: column; line-height: 1.05; text-align: left; }
.store-text small { font-size: calc(var(--fs) * 0.6); font-weight: 500; letter-spacing: 0.02em; }
.store-text strong { font-size: calc(var(--fs) * 1.25); font-weight: 600; letter-spacing: -0.01em; }
.store-lg { height: calc(var(--fs) * 3.625); padding: 0 calc(var(--fs) * 1.5) 0 calc(var(--fs) * 1.125); }
.store-lg .store-glyph { width: calc(var(--fs) * 2); height: calc(var(--fs) * 2); }
.store-lg .store-text strong { font-size: calc(var(--fs) * 1.375); }

/* ---------- Hero ---------- */
.hero { padding: clamp(24px, 4vw, 48px) 0 clamp(32px, 5vw, 56px); position: relative; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 24px; align-items: center; }
.hero-copy { padding-block: 24px; }
.hero-note { margin-top: 30px; font-size: calc(var(--fs) * 0.875); color: var(--muted); }

.hero-art { position: relative; min-height: 60em; font-size: var(--u); }
.blob {
  position: absolute; inset: 4% -8% 4% 8%;
  background: radial-gradient(120% 100% at 30% 20%, #ddd8ff 0%, #ebe8ff 55%, rgba(240, 238, 255, 0) 100%);
  border-radius: 46% 54% 40% 60% / 52% 44% 56% 48%;
}
.sparkle { position: absolute; left: 2%; top: 4%; width: 3.4em; }
.hand {
  position: absolute; right: 0; top: 0; z-index: 3; text-align: right;
  font-family: "Caveat", "Segoe Script", cursive; font-weight: 600; font-size: 2.4em; line-height: 1.05;
  color: var(--primary-ink); transform: rotate(-6deg);
}
.hand .ico { width: 0.9em; height: 0.9em; vertical-align: -0.1em; }

/* Phone mockups — everything inside is sized in em so the whole device scales via font-size */
.phone { font-size: var(--u); position: absolute; width: 23em; background: #0d0d14; border-radius: 3.6em; padding: 0.7em; box-shadow: var(--shadow-lg); }
.phone-screen { position: relative; background: #fff; border-radius: 3em; overflow: hidden; padding: 1.2em 1.4em 0; height: 100%; }
.phone-front { left: 12%; top: 4em; z-index: 2; height: 51em; }
.phone-back { left: 46%; top: 10em; z-index: 1; height: 46em; transform: rotate(3deg); transform-origin: 30% 0; }
.status { display: flex; justify-content: space-between; align-items: center; font-size: 0.85em; margin-bottom: 1.6em; }
.status i { width: 3.8em; height: 0.9em; border-radius: 0.3em; background: linear-gradient(90deg, var(--text) 30%, transparent 30% 45%, var(--text) 45% 70%, transparent 70% 80%, var(--text) 80%); opacity: .85; }
.ph-title { font-size: 1.7em; font-weight: 700; letter-spacing: -0.02em; }
.ph-head { display: flex; justify-content: space-between; align-items: center; }
.ph-head .bell { width: 1.7em; height: 1.7em; }
.phone small { font-size: 0.8em; color: var(--muted); font-weight: 400; }
.phone b { font-weight: 600; font-size: 1em; display: block; line-height: 1.25; }
.phone .ico { width: 1.6em; height: 1.6em; }

.av { display: inline-grid; place-items: center; width: 2.4em; height: 2.4em; border-radius: 50%; color: #fff; font-weight: 700; font-size: 0.9em; flex: none; position: relative; }
.av-a { background: linear-gradient(135deg, #4a90d9, #6c5ce7); }
.av-b { background: linear-gradient(135deg, #ff8a7a, #f59e0b); }
.av-lg { width: 4.6em; height: 4.6em; font-size: 1.2em; }
.av.add { background: var(--lavender); color: var(--primary); }
.av em { position: absolute; right: 0.1em; bottom: 0.1em; width: 1em; height: 1em; background: var(--green); border: 0.2em solid #fff; border-radius: 50%; }
.kids { display: flex; gap: 1.6em; margin: 1.4em 0 1.8em; }
.kids > div { display: flex; flex-direction: column; align-items: center; gap: 0.5em; }
.kids small { color: var(--text); font-size: 0.8em; }
.ph-row { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 0.4em; }
.ph-row h4 { font-size: 1.15em; font-weight: 700; }
.link { color: var(--primary) !important; font-weight: 600 !important; }

.ph-list li { display: flex; align-items: center; gap: 0.9em; padding: 0.9em 0; border-bottom: 1px solid #f0eff6; }
.ph-list li:last-child { border-bottom: 0; }
.ph-list small { display: block; }
.sched time { width: 4.6em; font-size: 0.8em; color: var(--muted); flex: none; }
.dot { width: 2.2em; height: 2.2em; border-radius: 50%; flex: none; border: 0.35em solid; }
.d-blue { border-color: var(--blue); } .d-red { border-color: var(--coral); } .d-teal { border-color: var(--teal); } .d-dark { border-color: var(--text); }
.ph-banner { display: flex; align-items: center; gap: 1em; background: var(--lavender); border-radius: 1.2em; padding: 1.1em 1.2em; margin-top: 1em; }
.ph-banner .ico { color: var(--gold); width: 2.2em; height: 2.2em; }
.tabbar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: space-around; padding: 1em 0.6em 1.4em; border-top: 1px solid #f0eff6; background: #fff; font-size: 0.72em; color: var(--muted); }
.tabbar span { display: flex; flex-direction: column; align-items: center; gap: 0.35em; }
.tabbar .ico { width: 2em; height: 2em; }
.tabbar .on { color: var(--primary); font-weight: 600; }

.seg { display: flex; background: var(--lavender); border-radius: 1em; padding: 0.3em; margin: 1.2em 0 1.4em; font-size: 0.85em; }
.seg span { flex: 1; text-align: center; padding: 0.55em 0; border-radius: 0.8em; color: var(--muted); }
.seg .on { background: var(--primary); color: #fff; font-weight: 600; }
.ph-label { font-size: 0.85em; color: var(--muted); margin-top: 0.4em; }
.tasks li { padding: 0.8em 0; }
.cb { width: 1.5em; height: 1.5em; border: 0.18em solid #c9c6dc; border-radius: 0.35em; flex: none; }
.fab { position: absolute; right: 1.4em; bottom: 1.6em; width: 3.6em; height: 3.6em; border-radius: 50%; background: var(--primary); color: #fff; display: grid; place-items: center; box-shadow: 0 0.6em 1.2em rgba(108, 92, 231, .45); }
.fab .ico { width: 1.8em; height: 1.8em; }

@media (prefers-reduced-motion: no-preference) {
  .phone-front { animation: float 7s ease-in-out infinite; }
  .phone-back { animation: float-b 8s ease-in-out infinite; }
  @keyframes float { 50% { transform: translateY(-8px); } }
  @keyframes float-b { 50% { transform: rotate(3deg) translateY(8px); } }
}

/* ---------- Feature strip ---------- */
.feature-strip {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px;
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow-sm);
  padding: 28px 16px; text-align: center; margin-top: 8px;
}
.feature-strip li { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 4px 12px; }
.feature-strip .ico { margin-bottom: 8px; }
.feature-strip p, .why-grid p { font-size: calc(var(--fs) * 0.875); color: var(--muted); line-height: 1.5; }

/* ---------- Split sections ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; padding-block: clamp(36px, 6vw, 64px); }
.split-flip { grid-template-columns: 1fr 1fr; }
.split-copy h2 { margin-bottom: 16px; max-width: 14em; }
.split-copy p:not(.eyebrow) { color: var(--muted); max-width: 32em; }
.split-copy .btn { margin-top: 26px; }
.photo { border-radius: 26px; overflow: hidden; box-shadow: var(--shadow-sm); background: var(--lavender); aspect-ratio: 372 / 226; }
.photo img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Why ---------- */
.why { background: var(--lavender); border-radius: 28px; padding: clamp(40px, 6vw, 64px) 0; margin-top: 24px; }
.why .eyebrow { margin-bottom: 10px; }
.why-grid { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 40px; }
.why-grid li { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 8px 20px; }
.why-grid li + li { border-left: 1px solid #d9d4f5; }
.why-grid .ico { margin-bottom: 10px; }

/* ---------- Pricing ---------- */
.pricing { padding-block: clamp(48px, 7vw, 88px) 0; }
.sub { max-width: 38em; margin: 12px auto 0; color: var(--muted); }
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; align-items: stretch; }
.plan { position: relative; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px 28px 28px; box-shadow: var(--shadow-sm); }
.plan h3 { font-size: calc(var(--fs) * 1.125); }
.plan .price { margin: 8px 0 20px; font-size: calc(var(--fs) * 2.375); font-weight: 800; letter-spacing: -0.03em; color: var(--text); }
.plan .price span { font-size: calc(var(--fs) * 0.8125); font-weight: 500; color: var(--muted); letter-spacing: 0; }
.plan li { position: relative; padding: 6px 0 6px 28px; font-size: calc(var(--fs) * 0.9); }
.plan li::before { content: ""; position: absolute; left: 0; top: 10px; width: 16px; height: 16px; border-radius: 50%; background: var(--lavender-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236c5ce7' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 10px no-repeat; }
.plan-featured { border: 2px solid var(--primary); box-shadow: var(--shadow-lg); }
.plan-featured h3, .plan-featured .price { color: var(--primary-deep); }
.plan-badge { position: absolute; top: -13px; right: 24px; background: var(--primary); color: #fff; font-size: 12px; font-weight: 600; padding: 4px 12px; border-radius: 999px; }
.plan-badge-alt { background: #7c3aed; }

/* ---------- CTA ---------- */
.cta { position: relative; overflow: hidden; margin-top: clamp(48px, 7vw, 88px); background: linear-gradient(135deg, #5b4bdb 0%, #6c5ce7 55%, #5a49d6 100%); color: #fff; text-align: center; padding: clamp(48px, 7vw, 80px) 0; }
.cta-blob { position: absolute; right: -120px; top: -60px; width: 460px; height: 460px; border-radius: 50%; background: rgba(255, 255, 255, 0.07); }
.cta-blob::after { content: ""; position: absolute; left: -900px; bottom: -300px; width: 420px; height: 420px; border-radius: 50%; background: rgba(255, 255, 255, 0.05); }
.cta-inner { position: relative; }
.cta h2 { font-size: clamp(26px, 3vw, 64px); letter-spacing: -0.03em; }
.cta p { margin-top: 14px; opacity: 0.92; }
.cta .store-row { margin-top: 32px; }
.cta-status { display: inline-block; margin-top: 22px !important; padding: 8px 16px; border-radius: 999px; background: rgba(255, 255, 255, 0.16); font-size: 14px; }

/* ---------- Footer ---------- */
.site-footer { padding: 36px 0; background: var(--bg); }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: calc(var(--fs) * 0.875); color: var(--muted); }
.site-footer nav a:hover { color: var(--primary); }
.copy { font-size: 13px; color: var(--muted); width: 100%; text-align: center; padding-top: 16px; border-top: 1px solid var(--border); }

/* ---------- Early-access dialog ---------- */
.signup { width: min(440px, calc(100vw - 32px)); border: 0; border-radius: 24px; padding: 0; box-shadow: 0 30px 80px rgba(26, 24, 54, 0.35); color: var(--text); background: #fff; }
.signup::backdrop { background: rgba(26, 24, 54, 0.55); backdrop-filter: blur(3px); }
.signup form { padding: 32px 28px 24px; display: grid; gap: 16px; position: relative; }
.signup h2 { font-size: 26px; }
.signup-intro { color: var(--muted); font-size: 15px; margin-top: -6px; }
.signup label { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
.signup .opt { font-weight: 400; color: var(--muted); }
.signup input, .signup select { width: 100%; font: inherit; font-weight: 400; padding: 12px 14px; border: 1.5px solid var(--border); border-radius: 12px; background: #fff; color: var(--text); }
.signup input:focus, .signup select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.18); }
.signup input[aria-invalid="true"] { border-color: #ef4444; }
.signup-close { position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--lavender); color: var(--primary-ink); cursor: pointer; display: grid; place-items: center; }
.signup-msg { min-height: 1.4em; font-size: 14px; }
.signup-msg.error { color: #dc2626; }
.signup-msg.ok { color: #047857; font-weight: 600; }
.signup-fine { font-size: 12.5px; color: var(--muted); text-align: center; }
.signup .btn[disabled] { opacity: .65; cursor: progress; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Scroll reveal ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
  .js .reveal.in { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1020px) {
  .nav { gap: 20px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-copy { padding-bottom: 0; }
  .hero-art { max-width: 56em; margin-inline: auto; width: 100%; }
  .phone-front { left: 4%; }
  .phone-back { left: 44%; }
}

@media (max-width: 860px) {
  .header-cta { display: none; }
  .nav-toggle { display: grid; }
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0; margin: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; padding: 8px var(--gutter) 20px;
    box-shadow: 0 20px 40px rgba(26, 24, 54, 0.12);
    transform: translateY(-12px); opacity: 0; visibility: hidden; transition: opacity .18s, transform .18s, visibility .18s;
  }
  .nav.open { transform: none; opacity: 1; visibility: visible; }
  .nav a:not(.btn) { padding: 14px 4px; font-size: 16px; border-bottom: 1px solid var(--border); }
  .nav-cta { display: inline-flex; margin-top: 16px; }

  .feature-strip { grid-template-columns: repeat(2, 1fr); row-gap: 28px; }
  .split, .split-flip { grid-template-columns: 1fr; }
  .split-flip .photo { order: 2; }
  .why-grid { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
  .why-grid li:nth-child(3) { border-left: 0; }
  .plans { grid-template-columns: 1fr; max-width: 460px; margin-inline: auto; }
}

@media (max-width: 520px) {
  .hero-art { --u: 8px; }
  .phone-front { left: 0; top: 4em; }
  .phone-back { left: 40%; top: 9em; }
  .hand { font-size: 2.5em; }
  .feature-strip { padding: 20px 8px; }
  .why-grid li { padding-inline: 8px; }
  .store-row { gap: 10px; }
  .store, .store-lg { height: 48px; padding: 0 14px 0 12px; gap: 8px; }
  .store-glyph, .store-lg .store-glyph { width: 24px; height: 24px; }
  .store-text small { font-size: 8.5px; }
  .store-text strong, .store-lg .store-text strong { font-size: 17px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

/* ---------- 404 page ---------- */
.not-found { min-height: 100vh; display: grid; place-content: center; justify-items: center; text-align: center; gap: 16px; }
.not-found h1 { font-size: clamp(32px, 6vw, 52px); }
