/* ============================================================================
   Foxtrot — share page + landing (web/dist)
   Tokens copied from design-system/colors_and_type.css (only the ones used).
   No dark variant: the design system defines no dark tokens.
   ============================================================================ */

:root {
  --paper:          #F5F0E8;
  --ink:            #1C1916;
  --persimmon:      #D4541E;
  --persimmon-deep: #B23E0F;
  --moss-tint:      #DDE2D5;

  --ink-04: rgba(28, 25, 22, 0.04);
  --ink-08: rgba(28, 25, 22, 0.08);
  --ink-12: rgba(28, 25, 22, 0.12);
  --ink-16: rgba(28, 25, 22, 0.16);
  --ink-24: rgba(28, 25, 22, 0.24);
  --ink-40: rgba(28, 25, 22, 0.40);
  --ink-64: rgba(28, 25, 22, 0.64);
  --ink-80: rgba(28, 25, 22, 0.80);

  --map-paper:  #E9E2D6;

  --font-serif: 'Instrument Serif', 'Cormorant Garamond', Georgia, serif;
  --font-sans:  'Geist', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', system-ui, sans-serif;
  --font-mono:  'Geist Mono', ui-monospace, 'SF Mono', monospace;

  --r-btn: 12px;
  --ease:  cubic-bezier(0.2, 0, 0, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: 'ss01', 'cv11';
}

[hidden] { display: none !important; }

a { color: inherit; text-decoration: none; }

/* ── Page frame ─────────────────────────────────────────────────────────── */

.page {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 64px 20px 34px;
  padding-bottom: max(34px, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
}

/* ── Wordmark ───────────────────────────────────────────────────────────── */

.wordmark {
  position: relative;
  align-self: flex-start;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 22px;
  line-height: 1;
  color: var(--ink);
}

.wordmark-dot {
  position: absolute;
  right: 8px;
  top: -3px;
  width: 4px;
  height: 4px;
  border-radius: 2px;
  background: var(--persimmon);
}

/* ── State sections ─────────────────────────────────────────────────────── */

.state {
  display: none;
  flex-direction: column;
  flex-grow: 1;
}

main[data-state="loading"] .state-loading,
main[data-state="place"]   .state-place,
main[data-state="expired"] .state-expired { display: flex; }

.spacer { flex-grow: 1; min-height: 28px; }

/* ── Header ─────────────────────────────────────────────────────────────── */

.header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 32px;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.3;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--ink-64);
}

.eyebrow-faint { color: var(--ink-40); }

.eyebrow:empty { display: none; }

.place-name {
  margin: 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 32px;
  line-height: 1.08;
  letter-spacing: -0.64px;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.meta {
  font-size: 14px;
  line-height: 1.4;
  color: var(--ink-64);
}

.meta:empty { display: none; }

/* ── Map strip ──────────────────────────────────────────────────────────── */

.map {
  position: relative;
  margin-top: 18px;
  height: 132px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--map-paper);
}

.map[data-has-map="false"] { display: none; }

.map-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.map-pin {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 24px;
  height: 24px;
  border-radius: 12px;
  transform: translate(-50%, -50%);
  background: var(--persimmon);
  border: 3px solid var(--paper);
  box-shadow: 0 2px 6px rgba(28, 25, 22, 0.3); /* the one shadow: lifts the pin off the map (approved mockup) */
}

/* ── Note ───────────────────────────────────────────────────────────────── */

.note {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 22px;
}

.note-text {
  margin: 0;
  font-size: 16px;
  line-height: 1.45;
  color: var(--ink-80);
  white-space: pre-line;
  overflow-wrap: anywhere;
}

/* ── Provenance ─────────────────────────────────────────────────────────── */

.provenance {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 16px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--ink-08);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  transition: background-color 160ms var(--ease);
}

.pill:hover { background: var(--ink-12); }

.via {
  font-size: 13px;
  color: var(--ink-64);
  overflow-wrap: anywhere;
}

/* ── Actions ────────────────────────────────────────────────────────────── */

.actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 28px;
}

.cta {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--r-btn);
  font-weight: 500;
  line-height: 1;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 160ms var(--ease), transform 80ms var(--ease);
}

.btn:active { transform: scale(0.98); }

.btn-primary {
  height: 48px;
  background: var(--persimmon);
  color: var(--paper);
  font-size: 15px;
}

.btn-primary:hover { background: var(--persimmon-deep); }

.cta-subtext {
  margin: 0;
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
  color: var(--ink-64);
}

.maps-row {
  display: flex;
  gap: 10px;
}

.btn-outline {
  flex: 1 1 0;
  height: 44px;
  border: 1px solid var(--ink-16);
  color: var(--ink);
  font-size: 14px;
  background: transparent;
}

.btn-outline:hover { background: var(--ink-04); }
.btn-outline:active { background: var(--ink-08); }

/* ── Loading skeleton ───────────────────────────────────────────────────── */

.skel {
  background: var(--ink-08);
  border-radius: 6px;
}

.skel-eyebrow    { width: 112px; height: 11px; }
.skel-name       { width: 72%;   height: 32px; margin-top: 2px; }
.skel-line       { width: 46%;   height: 14px; }
.skel-line-long  { width: 84%; }
.skel-map        { height: 132px; margin-top: 18px; border-radius: 12px; }

/* ── Expired / error ────────────────────────────────────────────────────── */

.state-expired { padding-top: 32px; gap: 12px; }

.expired-title {
  margin: 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 32px;
  line-height: 1.08;
  letter-spacing: -0.64px;
  color: var(--ink);
}

.expired-body {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-80);
}

/* ── Landing page (dist/index.html) ─────────────────────────────────────── */

.landing { gap: 0; }

.voice {
  margin: 0;
  padding-top: 40px;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink-80);
}

.landing .actions { padding-top: 40px; }

/* ── Motion ─────────────────────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
  .btn:active { transform: none; }
}
