/* Lockodo website. Paper and ink, like the layouts it shows; the app's
   purple accent only where you can act. Fonts are self-hosted (no
   third-party requests from this site). */

@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-italic.woff2") format("woff2");
  font-weight: 300 600;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Figtree";
  src: url("../fonts/figtree.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f5f0e6;
  --paper-deep: #ebe3d3;
  --card: #fbf8f2;
  --ink: #1a1820;
  --ink-2: #57525e;
  --ink-3: #8d8794;
  --rule: #d6cdbb;
  --rule-strong: #1a1820;
  --accent: #6c3ccb;
  --accent-ink: #ffffff;
  --accent-soft: rgba(108, 60, 203, 0.1);
  --night: #15121c;
  --night-ink: #f3eee6;
  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: "Figtree", -apple-system, "Helvetica Neue", sans-serif;
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1200px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #131117;
    --paper-deep: #1c1922;
    --card: #1f1c25;
    --ink: #f2ede4;
    --ink-2: #b4adb8;
    --ink-3: #7d7684;
    --rule: #38333f;
    --rule-strong: #f2ede4;
    --accent: #9b72f0;
    --accent-ink: #120d1c;
    --accent-soft: rgba(155, 114, 240, 0.16);
    --night: #0b0a0e;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* A faint paper grain. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 100;
  opacity: 0.35;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) body::before { mix-blend-mode: screen; opacity: 0.18; } }

img { max-width: 100%; display: block; }
a { color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Masthead ---------- */
.masthead {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid var(--rule);
}
.masthead .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font: 600 22px/1 var(--serif);
  letter-spacing: -0.01em;
}
.brand img { width: 32px; height: 32px; border-radius: 8px; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a:not(.pill) {
  text-decoration: none;
  font-size: 15px;
  color: var(--ink-2);
  transition: color 0.2s;
}
.nav a:not(.pill):hover { color: var(--ink); }
@media (max-width: 720px) { .nav a:not(.pill) { display: none; } }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font: 600 15px/1 var(--sans);
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s;
}
.pill:hover { transform: translateY(-1px); box-shadow: 0 6px 18px -6px var(--accent); }

/* App Store button: ink, not purple, so it reads like Apple's badge. */
.store {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 58px;
  padding: 0 24px 0 20px;
  border-radius: 16px;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.25s;
}
.store:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -14px rgba(0, 0, 0, 0.55); }
.store svg { width: 24px; height: 28px; fill: currentColor; flex: none; }
.store span { display: flex; flex-direction: column; line-height: 1.1; }
.store small { font-size: 11px; letter-spacing: 0.02em; opacity: 0.8; }
.store b { font: 600 20px/1.1 var(--sans); letter-spacing: -0.01em; }

/* ---------- Type ---------- */
.kicker {
  display: flex;
  align-items: center;
  gap: 12px;
  font: 600 12px/1 var(--sans);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.kicker::after { content: ""; flex: 1; height: 1px; background: var(--rule); max-width: 120px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; letter-spacing: -0.02em; margin: 0; }
h1 { font-size: clamp(40px, 4.4vw, 62px); line-height: 1.04; font-weight: 400; font-variation-settings: "opsz" 120; }
h2 { font-size: clamp(30px, 3.4vw, 44px); line-height: 1.1; font-weight: 400; font-variation-settings: "opsz" 96; }
section .wrap > h2 { margin-bottom: 32px; }
h3 { font-size: 24px; line-height: 1.2; font-weight: 500; }
em { font-style: italic; }
.lede { font-size: clamp(18px, 1.6vw, 21px); color: var(--ink-2); max-width: 34em; }

/* ---------- Hero ---------- */
.hero { padding: clamp(40px, 7vw, 88px) 0 clamp(56px, 8vw, 110px); }
.hero .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 7vw, 110px); align-items: center; }
.hero h1 { margin: 0 0 24px; }
.hero .lede { margin: 0 0 34px; }
.hero-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 22px; }
.hero-note { font-size: 14px; color: var(--ink-3); }
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; }
}

/* ---------- Phone mockup ----------
   A Lock Screen: the background photo, the iOS date and clock (drawn here),
   and the layout image exactly as the app renders it, on top. */
.phone {
  --w: 260px;
  width: var(--w);
  aspect-ratio: 786 / 1704;
  border-radius: calc(var(--w) * 0.155);
  padding: calc(var(--w) * 0.032);
  background: linear-gradient(145deg, #3a3740, #121116 40%, #2a2830);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.06) inset,
    0 40px 60px -30px rgba(20, 12, 30, 0.55),
    0 18px 30px -18px rgba(20, 12, 30, 0.4);
  flex: none;
}
.screen {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: calc(var(--w) * 0.125);
  overflow: hidden;
  background: var(--bg) center / cover no-repeat, #222;
  container-type: inline-size;
}
.screen > img { position: absolute; inset: 0; width: 100%; height: 100%; }
.island {
  position: absolute;
  top: 2.6%;
  left: 50%;
  width: 31%;
  height: 4.2%;
  transform: translateX(-50%);
  border-radius: 99px;
  background: #000;
  z-index: 2;
}
.lock-date, .lock-time {
  position: absolute;
  left: 0;
  right: 0;
  text-align: center;
  color: #fff;
  font-family: -apple-system, "SF Pro Display", system-ui, sans-serif;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.18);
}
.lock-date { top: 10%; font-size: 5.6cqw; font-weight: 600; opacity: 0.92; }
.lock-time { top: 12.4%; font-size: 27cqw; font-weight: 600; letter-spacing: -0.02em; line-height: 1; }
.screen.dark-clock .lock-date, .screen.dark-clock .lock-time { color: #2a2620; text-shadow: none; }
.lock-btn {
  position: absolute;
  bottom: 4.5%;
  width: 13%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: rgba(30, 30, 30, 0.38);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.lock-btn.l { left: 11%; }
.lock-btn.r { right: 11%; }

/* The hero fan of three. */
.fan {
  position: relative;
  height: clamp(460px, 52vw, 620px);
  display: flex;
  justify-content: center;
  align-items: center;
}
.fan .phone { position: absolute; transition: transform 0.6s cubic-bezier(.2,.8,.2,1); }
.fan .phone:nth-child(1) { --w: clamp(190px, 19vw, 240px); transform: translateX(-74%) rotate(-9deg) translateY(30px); animation: rise 1s 0.15s both; }
.fan .phone:nth-child(3) { --w: clamp(190px, 19vw, 240px); transform: translateX(74%) rotate(8deg) translateY(36px); animation: rise 1s 0.3s both; }
.fan .phone:nth-child(2) { --w: clamp(220px, 23vw, 280px); z-index: 2; animation: rise 1s 0.45s both; }
.fan:hover .phone:nth-child(1) { transform: translateX(-84%) rotate(-12deg) translateY(24px); }
.fan:hover .phone:nth-child(3) { transform: translateX(84%) rotate(11deg) translateY(30px); }
@keyframes rise { from { opacity: 0; translate: 0 60px; } to { opacity: 1; translate: 0 0; } }
@media (max-width: 560px) {
  .fan { height: 440px; }
  .fan .phone:nth-child(1), .fan .phone:nth-child(3) { --w: 150px; }
  .fan .phone:nth-child(2) { --w: 200px; }
}

@media (prefers-reduced-motion: reduce) {
  .fan .phone { animation: none !important; transition: none !important; }
}

/* ---------- Sections ---------- */
section { position: relative; }
.section { padding: clamp(72px, 10vw, 140px) 0; }
/* Who it's for: a phone beside each situation, alternating sides. */
.who-head { max-width: 34em; margin-bottom: clamp(40px, 6vw, 72px); }
.who-head h2 { margin-bottom: 14px; }
.who-head p { margin: 0; color: var(--ink-2); font-size: 19px; }
.who-carousel { border-top: 1px solid var(--rule); }
.who-track {
  display: grid; grid-auto-flow: column; grid-auto-columns: 100%;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain;
}
.who-track::-webkit-scrollbar { display: none; }
.who-track:focus-visible { outline: 2px solid var(--accent, currentColor); outline-offset: 4px; }
.who-row {
  scroll-snap-align: start; scroll-snap-stop: always;
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(32px, 7vw, 110px); align-items: center;
  padding: clamp(32px, 5vw, 56px) 0;
}
.who-row .phone { --w: clamp(200px, 20vw, 240px); transition: transform 0.6s cubic-bezier(.2,.8,.2,1), opacity 0.6s; }
.who-row:not(.on) .phone { transform: translateY(14px) scale(0.97); opacity: 0.5; }
.who-copy { max-width: 32em; }
.who-copy h3 { font-size: clamp(24px, 2.4vw, 30px); font-weight: 400; margin-bottom: 14px; }
.who-copy p { margin: 0 0 14px; color: var(--ink-2); }
.who-nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 8px; }
.who-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.who-tabs button {
  position: relative; overflow: hidden; font: inherit; font-size: 14px; color: var(--ink-2);
  background: none; border: 1px solid var(--rule); border-radius: 999px; padding: 8px 16px; cursor: pointer;
}
.who-tabs button:hover { color: var(--ink); }
.who-tabs button[aria-selected="true"] { color: var(--ink); border-color: var(--ink); }
/* The time left before the carousel turns, drawn under the current tab. */
.who-tabs button[aria-selected="true"]::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: currentColor;
  transform-origin: left; animation: who-timer var(--who-time, 7s) linear both;
}
.who-carousel.paused .who-tabs button::after { animation-play-state: paused; }
@keyframes who-timer { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) { .who-tabs button::after { display: none; } .who-row .phone { transition: none; } }
@media (max-width: 760px) {
  .who-row { grid-template-columns: 1fr; gap: 28px; }
  .who-row .phone { margin: 0 auto; }
  .who-tabs { display: none; }
  .who-nav { justify-content: center; }
}

/* Layouts: a horizontal shelf of Lock Screens. */
.looks-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 40px; }
.looks-head h2 { margin-bottom: 14px; }
.looks-head p { margin: 0; color: var(--ink-2); max-width: 36em; }

/* What's in the app: plain notes, two columns. */
.notes { display: grid; grid-template-columns: 1fr 1fr; gap: 0 56px; margin: 0; }
.notes div { padding: 22px 0 26px; border-top: 1px solid var(--rule); }
.notes dt { font: 500 21px/1.3 var(--serif); margin-bottom: 8px; }
.notes dd { margin: 0; color: var(--ink-2); }
@media (max-width: 720px) { .notes { grid-template-columns: 1fr; } }


.looks { background: var(--paper-deep); overflow: hidden; }
.shelf {
  display: flex;
  gap: clamp(20px, 3vw, 36px);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  --inset: var(--gutter);
  padding: 10px var(--inset) 40px;
  scroll-padding-inline: var(--inset);
  scrollbar-width: none;
}
.shelf::-webkit-scrollbar { display: none; }
@media (min-width: 1200px) { .shelf { --inset: calc((100vw - var(--max)) / 2 + var(--gutter)); } }
.shelf figure { margin: 0; scroll-snap-align: start; }
.shelf .phone { --w: clamp(200px, 22vw, 250px); transition: transform 0.4s cubic-bezier(.2,.8,.2,1); }
.shelf figure:hover .phone { transform: translateY(-10px) rotate(-1.5deg); }
.shelf figcaption { margin-top: 16px; padding: 0 6px; font-size: 15px; color: var(--ink-2); }
.shelf-controls { display: flex; gap: 10px; }
.round {
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--rule-strong); background: transparent; color: var(--ink);
  display: grid; place-items: center; cursor: pointer; transition: background 0.2s, color 0.2s;
}
.round:hover { background: var(--ink); color: var(--paper); }
.round svg { width: 18px; height: 18px; }

/* FAQ teaser and the support page share these. */
.faq { border-top: 1px solid var(--rule-strong); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 22px 0;
  font: 400 clamp(19px, 2vw, 23px)/1.3 var(--serif);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 300 30px/1 var(--sans); color: var(--accent); transition: transform 0.25s; flex: none; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .answer { padding: 0 0 24px; color: var(--ink-2); max-width: 46em; }
.faq .answer p { margin: 0 0 12px; }
.faq .answer ol, .faq .answer ul { margin: 0 0 12px; padding-left: 1.3em; }
.faq .answer li { margin-bottom: 6px; }

/* Closing call to action */
.closing { text-align: center; padding: clamp(80px, 12vw, 160px) 0; }
.closing img.icon { width: 96px; height: 96px; border-radius: 22px; margin: 0 auto 30px; box-shadow: 0 20px 40px -20px rgba(20, 20, 60, 0.6); }
.closing h2 { margin: 0 auto 12px; }
.closing p { color: var(--ink-2); margin: 0 auto 34px; max-width: 30em; }

/* ---------- Footer ---------- */
footer { border-top: 1px solid var(--rule-strong); padding: 40px 0 56px; font-size: 14px; color: var(--ink-2); }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 20px; }
footer nav { display: flex; flex-wrap: wrap; gap: 24px; }
footer a { text-decoration: none; }
footer a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Document pages (privacy, terms, support) ---------- */
.doc-head { padding: clamp(48px, 8vw, 96px) 0 clamp(32px, 4vw, 48px); border-bottom: 1px solid var(--rule-strong); }
.doc-head h1 { font-size: clamp(42px, 6vw, 76px); margin: 20px 0 16px; }
.doc-head .meta { color: var(--ink-3); font-size: 15px; }
.doc { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); padding: clamp(40px, 6vw, 72px) 0 clamp(72px, 10vw, 120px); }
.toc { position: sticky; top: 96px; align-self: start; font-size: 14px; }
.toc b { display: block; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 12px; }
.toc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a { display: block; padding: 6px 0; color: var(--ink-2); text-decoration: none; }
.toc a::before { content: counter(toc) "  "; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.toc a:hover { color: var(--accent); }
@media (max-width: 860px) { .doc { grid-template-columns: 1fr; } .toc { display: none; } }

.prose { max-width: 42em; }
.prose .summary {
  background: var(--card);
  border-radius: 20px;
  padding: 24px 28px;
  margin-bottom: 48px;
  font-size: 17px;
}
.prose .summary b { display: block; font: 500 20px/1.3 var(--serif); margin-bottom: 10px; }
.prose .summary ul { margin: 0; padding-left: 1.2em; }
.prose .summary li { margin: 6px 0; }
.prose h2 { font-size: clamp(26px, 3vw, 34px); font-weight: 400; margin: 56px 0 16px; padding-top: 18px; border-top: 1px solid var(--rule); scroll-margin-top: 90px; }
.prose h2:first-of-type { margin-top: 0; }
.prose h3 { font-size: 20px; margin: 28px 0 8px; }
.prose p, .prose li { color: var(--ink-2); }
.prose p { margin: 0 0 16px; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 16px; }
.prose li { margin-bottom: 6px; }
.prose strong { color: var(--ink); font-weight: 600; }
.prose a { color: var(--accent); text-underline-offset: 3px; }
.prose table { width: 100%; border-collapse: collapse; margin: 8px 0 24px; font-size: 15px; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 12px 12px 12px 0; border-bottom: 1px solid var(--rule); }
.prose th { color: var(--ink); font-weight: 600; border-bottom-color: var(--rule-strong); }
.prose td { color: var(--ink-2); }
.table-scroll { overflow-x: auto; }

/* Support contact block */
.contact {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
  background: var(--accent);
  color: var(--accent-ink);
  border-radius: 24px;
  padding: clamp(24px, 4vw, 36px);
  margin-bottom: 56px;
}
.contact h2 { color: inherit; border: 0; margin: 0 0 6px; padding: 0; font-size: clamp(26px, 3vw, 34px); }
.contact p { color: inherit; opacity: 0.85; margin: 0; }
.contact a.mail {
  display: inline-flex; align-items: center; height: 48px; padding: 0 22px; border-radius: 999px;
  background: var(--accent-ink); color: var(--accent); font-weight: 600; text-decoration: none; white-space: nowrap;
}
@media (max-width: 640px) { .contact { grid-template-columns: 1fr; } }
