:root {
  color-scheme: light dark;
  --font: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Helvetica Neue", system-ui, sans-serif;
  --ink: #11213a;
  --muted: #607089;
  --surface: #f3f6fb;
  --card: rgba(255, 255, 255, .9);
  --line: rgba(18, 47, 83, .1);
  --blue: #087cff;
  --blue-soft: #e7f2ff;
  --navy: #0a2348;
  font-family: var(--font);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
html { min-height: 100%; }
body { margin: 0; background: var(--surface); color: var(--ink); font-family: var(--font); line-height: 1.6; }
button, input { font: inherit; }
.legal-shell { width: min(760px, calc(100% - 40px)); margin: 0 auto; padding: 32px 0 80px; }
.legal-brand { display: inline-flex; align-items: center; gap: 11px; color: inherit; text-decoration: none; font-weight: 750; letter-spacing: -.025em; }
.legal-brand img { border-radius: 11px; box-shadow: 0 7px 18px rgba(5, 40, 91, .18); }
.legal-card { margin-top: 56px; padding: clamp(24px, 5vw, 48px); border: 1px solid var(--line); border-radius: 28px; background: var(--card); box-shadow: 0 18px 60px rgba(44, 73, 111, .08); }
h1, h2 { font-family: var(--font); text-wrap: balance; }
h1 { margin: 0 0 12px; font-size: clamp(2rem, 6vw, 3.5rem); letter-spacing: -.045em; line-height: 1.05; }
h2 { margin-top: 34px; font-size: 1.15rem; }
p, li { color: var(--muted); }
a { color: #0969da; }
.legal-kicker { margin: 0 0 12px; color: #0068cc; font-size: 11px; font-weight: 800; letter-spacing: .15em; }
.legal-meta { margin: 0 0 34px; font-size: .82rem; }
.legal-card strong { color: var(--ink); }
.legal-card ul { padding-left: 1.35rem; }
.legal-card li + li { margin-top: .7rem; }
.legal-card address { padding: 18px 20px; border: 1px solid var(--line); border-radius: 17px; background: rgba(229, 240, 252, .42); color: var(--muted); font-style: normal; }
.legal-card address + address, .legal-card p + address { margin-top: 15px; }
.legal-note { margin: 18px 0; padding: 18px 20px; border-left: 4px solid #d86c19; border-radius: 14px; background: #fff4e5; color: #68401f; }
.legal-note strong, .legal-note p { color: inherit; }
.legal-note p { margin-bottom: 0; }
.legal-nav { display: flex; flex-wrap: wrap; gap: 10px 18px; margin-top: 44px; padding-top: 24px; border-top: 1px solid var(--line); }
.legal-nav a { font-size: .9rem; font-weight: 700; text-underline-offset: .2em; }
.legal-nav a:hover { text-decoration-thickness: 2px; }
.legal-nav a:focus-visible { border-radius: 4px; outline: 3px solid rgba(8, 124, 255, .45); outline-offset: 4px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.action { padding: 12px 18px; border-radius: 999px; background: #0b1d34; color: white; text-decoration: none; font-weight: 700; }
.action.secondary { background: #e4ebf4; color: #14243a; }

.share-page {
  min-height: 100dvh;
  background:
    radial-gradient(circle at 84% 12%, rgba(97, 195, 255, .2), transparent 27rem),
    linear-gradient(155deg, #f8fbff 0, #eef4fb 62%, #e9f1f9 100%);
}
.share-shell { width: min(900px, calc(100% - 40px)); padding-top: clamp(24px, 5vw, 44px); }
.share-card {
  position: relative;
  overflow: hidden;
  margin-top: clamp(42px, 8vw, 74px);
  padding: clamp(28px, 6vw, 58px);
  border: 1px solid rgba(25, 70, 122, .1);
  border-radius: clamp(28px, 5vw, 42px);
  background: rgba(255, 255, 255, .84);
  box-shadow: 0 28px 80px rgba(28, 65, 110, .13), inset 0 1px 0 rgba(255, 255, 255, .9);
  -webkit-backdrop-filter: blur(22px) saturate(130%);
  backdrop-filter: blur(22px) saturate(130%);
}
.share-card::before {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  right: -180px;
  top: -190px;
  border: 1px solid rgba(8, 124, 255, .12);
  border-radius: 50%;
  box-shadow: 0 0 0 54px rgba(8, 124, 255, .035), 0 0 0 108px rgba(8, 124, 255, .02);
  pointer-events: none;
}
.share-heading { position: relative; max-width: 690px; }
.share-kicker { display: block; margin-bottom: 18px; color: var(--blue); font-size: 11px; font-weight: 800; letter-spacing: .15em; }
.share-heading h1 { max-width: 650px; margin: 0; font-size: clamp(30px, 4.4vw, 42px); font-weight: 800; line-height: 1.08; letter-spacing: -.038em; }
.share-heading > p { max-width: 600px; margin: 19px 0 0; font-size: clamp(15px, 2.2vw, 18px); line-height: 1.55; text-wrap: pretty; }
.sighting-preview {
  position: relative;
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr);
  gap: 24px;
  margin-top: 36px;
  padding: 22px;
  border: 1px solid rgba(33, 89, 151, .1);
  border-radius: 25px;
  background: #f2f7fd;
}
.preview-visual {
  position: relative;
  min-height: 112px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 19px;
  border: 1px solid rgba(20, 57, 99, .08);
  background: #fff;
  box-shadow: 0 9px 24px rgba(19, 56, 99, .09);
}
.preview-visual img { width: 100%; height: 100%; padding: 7px; object-fit: contain; }
.preview-copy { min-width: 0; align-self: center; }
.preview-label { color: #3971aa; font-size: 10px; font-weight: 800; letter-spacing: .13em; }
.preview-copy h2 { margin: 5px 0 0; color: var(--ink); font-size: clamp(24px, 4vw, 32px); font-weight: 800; line-height: 1.12; letter-spacing: -.04em; }
.preview-copy p { margin: 7px 0 0; color: #657995; font-size: 13px; font-weight: 600; }
.preview-facts { grid-column: 1 / -1; display: grid; grid-template-columns: .8fr .9fr 1.5fr; gap: 0; margin: 0; padding-top: 20px; border-top: 1px solid rgba(33, 89, 151, .1); }
.preview-facts div { min-width: 0; padding: 0 18px; border-left: 1px solid rgba(33, 89, 151, .1); }
.preview-facts div:first-child { padding-left: 0; border-left: 0; }
.preview-facts div:last-child { padding-right: 0; }
.preview-facts dt { color: #8191a6; font-size: 9px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.preview-facts dd { margin: 5px 0 0; color: #263b57; font-size: 12px; font-weight: 700; line-height: 1.4; text-wrap: pretty; }
.privacy-note { max-width: 680px; margin: 17px 2px 0; color: #718198; font-size: 11px; line-height: 1.55; }
.share-actions { align-items: center; margin-top: 30px; }
.share-actions .action { min-height: 52px; display: inline-flex; align-items: center; justify-content: center; gap: 17px; padding: 13px 19px; border-radius: 16px; background: var(--navy); box-shadow: 0 12px 28px rgba(10, 35, 72, .17); transition: transform .18s ease, box-shadow .18s ease, background .18s ease; }
.share-actions .action:hover { transform: translateY(-2px); box-shadow: 0 17px 34px rgba(10, 35, 72, .23); }
.share-actions .action:active { transform: scale(.98); }
.share-actions .action:focus-visible { outline: 3px solid rgba(8, 124, 255, .4); outline-offset: 3px; }
.share-actions .source-action { border: 1px solid rgba(8, 124, 255, .2); background: var(--blue-soft); box-shadow: none; color: #145b9e; }
.share-actions .source-action[hidden] { display: none; }
.share-actions .source-action:hover { background: #d9ebff; box-shadow: none; }
.share-actions .action.secondary { background: transparent; box-shadow: none; color: #4b627e; }
.share-footer { margin: 22px 0 0; text-align: center; color: #5f7086; font-size: 13px; font-weight: 600; line-height: 1.5; }
.skeleton { display: inline-block; height: 1em; max-width: 100%; border-radius: 6px; background: linear-gradient(90deg, #dfe8f2 25%, #edf3f8 50%, #dfe8f2 75%); background-size: 200% 100%; animation: shimmer 1.25s ease-in-out infinite; }
.skeleton-title { width: 240px; height: 27px; }
.skeleton-copy { width: 185px; height: 13px; }
.skeleton-short { width: 68px; }.skeleton-medium { width: 92px; }.skeleton-long { width: 180px; }
.share-card[data-state="error"] .preview-visual { background: linear-gradient(145deg, #38516d, #667a92); }

@keyframes shimmer { to { background-position: -200% 0; } }

@media (max-width: 620px) {
  .share-shell { width: min(900px, calc(100% - 28px)); padding-bottom: 42px; }
  .share-card { margin-top: 34px; padding: 25px 20px 24px; border-radius: 28px; }
  .share-kicker { margin-bottom: 13px; }
  .sighting-preview { grid-template-columns: 88px minmax(0, 1fr); gap: 16px; margin-top: 27px; padding: 15px; border-radius: 21px; }
  .preview-visual { min-height: 94px; border-radius: 16px; }
  .preview-visual img { padding: 6px; }
  .preview-facts { grid-template-columns: 1fr 1fr; row-gap: 18px; }
  .preview-facts div { padding: 0 12px; }
  .preview-facts div:nth-child(3) { grid-column: 1 / -1; padding: 16px 0 0; border-top: 1px solid rgba(33, 89, 151, .1); border-left: 0; }
  .share-actions { align-items: stretch; flex-direction: column; }
  .share-actions .action { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media (prefers-color-scheme: dark) {
  :root { --ink: #f0f5fc; --muted: #b2c0d1; --surface: #091526; --card: rgba(16, 35, 60, .88); --line: rgba(146, 184, 226, .14); }
  .share-page { background: radial-gradient(circle at 84% 12%, rgba(25, 121, 214, .22), transparent 28rem), linear-gradient(155deg, #0a1728, #081321 70%); }
  .share-card { border-color: rgba(137, 183, 230, .15); background: rgba(15, 36, 63, .86); box-shadow: 0 28px 80px rgba(0, 6, 18, .3), inset 0 1px 0 rgba(255,255,255,.05); }
  .sighting-preview { border-color: rgba(131, 180, 229, .14); background: #102c4d; }
  .preview-copy h2 { color: #f0f5fc; }
  .preview-copy p { color: #9db0c8; }
  .preview-label { color: #75bfff; }
  .preview-facts, .preview-facts div, .preview-facts div:nth-child(3) { border-color: rgba(131, 180, 229, .14); }
  .preview-facts dt { color: #8399b3; }
  .preview-facts dd { color: #d7e2f0; }
  .privacy-note { color: #8395aa; }
  .share-footer { color: #aab9cb; }
  .share-actions .action { background: #dcecff; color: #0a2348; }
  .share-actions .source-action { border-color: rgba(117, 191, 255, .22); background: rgba(39, 106, 172, .2); color: #a9d7ff; }
  .share-actions .source-action:hover { background: rgba(47, 122, 197, .28); }
  .share-actions .action.secondary { color: #b8c9dc; }
  .action { background: #f1f5fa; color: #0b1d34; }
  .action.secondary { background: #24344a; color: #eef4fc; }
  .legal-card address { background: rgba(29, 59, 91, .45); }
  .legal-note { border-left-color: #ff9f4a; background: #382b1d; color: #ffd2aa; }
  .legal-nav a { color: #fff; }
  .skeleton { background: linear-gradient(90deg, #274564 25%, #355675 50%, #274564 75%); background-size: 200% 100%; }
}
