/* links.max-ship.com
 * Tokens come from the MaxShip Skyport system (maxship-site src/styles/tokens.css).
 * Night is the default; day follows the visitor's light-mode setting.
 */

@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("/fonts/fraunces-roman-latin.woff2") format("woff2");
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("/fonts/inter-roman-latin.woff2") format("woff2");
}

:root {
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --radius-pill: 999px;
  --radius-paper: 20px;
  --radius-input: 14px;
  --ease-ui: cubic-bezier(0.2, 0.7, 0.2, 1);
  --dur-ui: 180ms;

  /* Night (default) */
  color-scheme: dark;
  --color-bg: #0B1230;
  --color-bg-deep: #080D22;
  --accent-primary: #7FA8FF;
  --accent-highlight: #FD6C01;
  --accent-highlight-hover: #FF8A2A;
  --accent-highlight-text: #FD6C01;
  --accent-highlight-ink: #0B1230;
  --text-primary: #F6EEE3;
  --text-muted: #DCCFC0;
  --text-placeholder: #C9B9A6;
  --ember-text: #FF6B5E;
  --border-input: rgba(255, 235, 215, 0.35);
  --surface-glass: rgba(255, 150, 90, 0.1);
  --surface-glass-hover: rgba(255, 150, 90, 0.16);
  --surface-input: rgba(255, 255, 255, 0.06);
  --glass-edge: rgba(255, 200, 160, 0.3);
  --glass-ring: rgba(255, 255, 255, 0.1);
  --glass-sheen: linear-gradient(135deg, rgba(255, 225, 195, 0.18) 0%, rgba(255, 255, 255, 0) 26%, rgba(255, 255, 255, 0) 74%, rgba(253, 108, 1, 0.1) 100%);
  --shadow-card: 0 30px 60px -30px rgba(0, 0, 0, 0.7);
  --focus-ring: 0 0 0 3px var(--color-bg), 0 0 0 5px var(--accent-highlight-text);
  --tile-bg: rgba(253, 108, 1, 0.14);
  --tile-fg: #FD6C01;
  --page: radial-gradient(120% 55% at 50% -12%, rgba(253, 108, 1, 0.2), rgba(253, 108, 1, 0) 62%),
    linear-gradient(180deg, var(--color-bg) 0%, var(--color-bg) 55%, var(--color-bg-deep) 100%);
  --stars-opacity: 1;
}

@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;
    --color-bg: #EEF4FB;
    --color-bg-deep: #DCE8F5;
    --accent-primary: #0047AB;
    --accent-highlight: #FD6C01;
    --accent-highlight-hover: #F25A00;
    --accent-highlight-text: #B83A00;
    --accent-highlight-ink: #0B1230;
    --text-primary: #0B1230;
    --text-muted: #3D4C6B;
    --text-placeholder: #6A7894;
    --ember-text: #B3261E;
    --border-input: rgba(11, 18, 48, 0.3);
    --surface-glass: rgba(255, 255, 255, 0.72);
    --surface-glass-hover: rgba(255, 255, 255, 0.95);
    --surface-input: #FFFFFF;
    --glass-edge: rgba(255, 255, 255, 0.9);
    --glass-ring: rgba(11, 18, 48, 0.06);
    --glass-sheen: linear-gradient(135deg, rgba(255, 255, 255, 0.35) 0%, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, 0) 100%);
    --shadow-card: 0 30px 60px -34px rgba(20, 50, 110, 0.24);
    --focus-ring: 0 0 0 3px var(--color-bg), 0 0 0 5px var(--accent-primary);
    --tile-bg: rgba(0, 71, 171, 0.08);
    --tile-fg: #0047AB;
    --page: linear-gradient(180deg, #CFE2F6 0%, var(--color-bg) 42%, var(--color-bg-deep) 100%);
    --stars-opacity: 0;
  }
}

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

html { background: var(--color-bg-deep); -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--page);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

/* A faint star field at night. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: calc(var(--stars-opacity) * 0.55);
  background-image:
    radial-gradient(1px 1px at 24px 38px, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 142px 96px, #fff 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 210px 22px, #ffd9b8 50%, transparent 51%),
    radial-gradient(1px 1px at 76px 168px, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 188px 212px, #fff 50%, transparent 51%);
  background-size: 240px 240px;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.4) 50%, transparent 85%);
  mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.4) 50%, transparent 85%);
}

.wrap {
  position: relative;
  max-width: 520px;
  margin: 0 auto;
  padding:
    max(44px, env(safe-area-inset-top))
    max(16px, env(safe-area-inset-right))
    max(32px, env(safe-area-inset-bottom))
    max(16px, env(safe-area-inset-left));
}

/* —— Header —— */
.intro { text-align: center; margin: 0 0 28px; }
.mark {
  display: block;
  width: 72px;
  height: 72px;
  margin: 0 auto;
  border-radius: 17px;
  box-shadow: 0 18px 40px -18px rgba(253, 108, 1, 0.55);
}
h1 {
  margin: 18px 0 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(34px, 9.5vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.bio {
  margin: 0 auto;
  max-width: 30ch;
  color: var(--text-muted);
  text-wrap: balance;
}

/* —— Link cards —— */
.links { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }

.shell {
  display: block;
  border-radius: var(--radius-paper);
  background-color: var(--surface-glass);
  background-image: var(--glass-sheen);
  box-shadow: var(--shadow-card), inset 0 1px 0 var(--glass-edge), inset 0 0 0 1px var(--glass-ring);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  backdrop-filter: blur(12px) saturate(150%);
  transition: background-color var(--dur-ui) var(--ease-ui), transform var(--dur-ui) var(--ease-ui);
}

.row {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 76px;
  padding: 14px 16px;
  border-radius: var(--radius-paper);
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
a.shell:hover, .wa > summary:hover { background-color: var(--surface-glass-hover); }
a.shell:active { transform: scale(0.985); }
.wa:not([open]):has(> summary:active) { transform: scale(0.985); }
.row:focus-visible { outline: none; box-shadow: var(--focus-ring); }

.tile {
  flex: none;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: var(--tile-bg);
  color: var(--tile-fg);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 23px;
  line-height: 1;
}
.tile svg, .go, .done svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.tile svg { width: 24px; height: 24px; }

.text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
  line-height: 1.25;
  letter-spacing: -0.005em;
}
.desc { font-size: 15px; line-height: 1.45; color: var(--text-muted); }
.go { flex: none; width: 20px; height: 20px; color: var(--text-muted); }

/* —— WhatsApp: the card opens into the form —— */
.wa > summary { list-style: none; }
.wa > summary::-webkit-details-marker { display: none; }
.chev { transition: transform var(--dur-ui) var(--ease-ui); }
.wa[open] .chev { transform: rotate(180deg); }
.wa[open] > summary { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }

.panel { padding: 0 16px 18px; }
.field { display: grid; gap: 6px; margin-top: 14px; }
.field:first-child { margin-top: 2px; }
label { font-size: 15px; font-weight: 600; line-height: 1.4; }
.optional { font-weight: 400; color: var(--text-muted); }
.hint { margin: -2px 0 2px; font-size: 14px; line-height: 1.45; color: var(--text-muted); }

input, textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border: 1.5px solid var(--border-input);
  border-radius: var(--radius-input);
  background: var(--surface-input);
  color: var(--text-primary);
  font: inherit;
  font-size: 16px; /* 16px keeps iOS from zooming in on focus */
  line-height: 1.4;
  transition: border-color var(--dur-ui) var(--ease-ui), box-shadow var(--dur-ui) var(--ease-ui);
}
textarea { min-height: 96px; resize: vertical; }
::placeholder { color: var(--text-placeholder); opacity: 1; }
input:focus-visible, textarea:focus-visible { outline: none; border-color: transparent; box-shadow: var(--focus-ring); }
[aria-invalid="true"] { border-color: var(--ember-text); }

.error { margin: 0; font-size: 14px; line-height: 1.45; color: var(--ember-text); }
.form-error { margin-top: 14px; }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.turnstile:not(:empty) { margin-top: 14px; }

.submit {
  display: block;
  width: 100%;
  min-height: 54px;
  margin-top: 18px;
  padding: 0 20px;
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--accent-highlight);
  color: var(--accent-highlight-ink);
  font: 600 17px/1 var(--font-body);
  cursor: pointer;
  transition: background-color var(--dur-ui) var(--ease-ui), transform var(--dur-ui) var(--ease-ui);
}
.submit:hover { background: var(--accent-highlight-hover); }
.submit:active { transform: scale(0.985); }
.submit:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.submit[disabled] { opacity: 0.7; cursor: progress; }

.privacy { margin: 12px 0 0; font-size: 14px; line-height: 1.45; color: var(--text-muted); text-align: center; }

.done { display: grid; justify-items: center; gap: 10px; padding: 8px 4px 6px; text-align: center; }
.done[hidden] { display: none; }
.done:focus { outline: none; }
.done svg { width: 36px; height: 36px; color: var(--accent-highlight-text); stroke-width: 1.6; }
.done p { margin: 0; font-family: var(--font-display); font-weight: 600; font-size: 20px; line-height: 1.35; }

/* —— Footer —— */
.foot { margin-top: 32px; text-align: center; font-size: 14px; }
.foot a { color: var(--text-muted); text-decoration: none; padding: 10px 12px; border-radius: var(--radius-pill); }
.foot a:hover { color: var(--text-primary); }
.foot a:focus-visible { outline: none; box-shadow: var(--focus-ring); }

@media (min-width: 720px) {
  .wrap { padding-top: 72px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; }
}
