:root {
  --night: #070c12;
  --night-2: #0e1824;
  --deep: #132033;
  --gold: #c4a35a;
  --gold-bright: #e4c97a;
  --gold-dim: rgba(196, 163, 90, 0.28);
  --parchment: #efe6d4;
  --stone: #a7b0b8;
  --ink: #1a365d;
  --shell: 26.5rem;
  --font-display: "Cinzel", "Palatino Linotype", Palatino, "Times New Roman", serif;
  --font-serif: "Cormorant Garamond", "Palatino Linotype", Palatino, serif;
  --font-sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --shell-pad-top: 1.35rem;
  --seal-size: 6.35rem;
  --ray-origin-y: calc(var(--shell-pad-top) + var(--seal-size) / 2);
}

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

html {
  color-scheme: dark;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  min-height: 100vh;
  font-family: var(--font-sans);
  color: var(--parchment);
  background: var(--night);
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 20;
  padding: 0.55rem 0.9rem;
  background: var(--parchment);
  color: var(--night);
  font-size: 0.85rem;
  text-decoration: none;
  border-radius: 4px;
}

.skip:focus {
  top: 0.75rem;
}

/* Atmosphere — Pharos beams over a night sea */

.sky {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background:
    radial-gradient(ellipse 90% 55% at 50% -8%, rgba(196, 163, 90, 0.22), transparent 58%),
    radial-gradient(ellipse 70% 40% at 50% 108%, rgba(22, 58, 95, 0.35), transparent 60%),
    linear-gradient(180deg, #0a121c 0%, var(--night) 38%, #06090e 100%);
}

.rays {
  position: absolute;
  left: 50%;
  top: var(--ray-origin-y);
  width: 160vmax;
  height: 160vmax;
  transform: translate(-50%, -50%);
  transform-origin: 50% 50%;
  background: repeating-conic-gradient(
    from 0deg,
    rgba(196, 163, 90, 0.045) 0deg 4deg,
    transparent 4deg 12deg
  );
  mask-image: radial-gradient(circle at 50% 50%, #000 0 16%, transparent 52%);
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 0 16%, transparent 52%);
  animation: slow-turn 72s linear infinite;
  opacity: 0.85;
}

.grain {
  position: absolute;
  inset: 0;
  opacity: 0.16;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

@keyframes slow-turn {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

.shell {
  position: relative;
  z-index: 1;
  width: min(100%, var(--shell));
  margin: 0 auto;
  padding: var(--shell-pad-top) 1.15rem 2.4rem;
}

/* Header */

.mast {
  text-align: center;
}

.seal {
  width: var(--seal-size);
  height: var(--seal-size);
  margin: 0 auto 0.85rem;
  padding: 0.28rem;
  border-radius: 1.05rem;
  background: var(--parchment);
  border: 1px solid var(--gold);
  box-shadow:
    0 0 0 5px rgba(196, 163, 90, 0.1),
    0 16px 36px rgba(0, 0, 0, 0.45);
}

.seal img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 0.78rem;
}

.kicker {
  margin: 0;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
}

.ornament {
  display: block;
  width: 9.5rem;
  height: 1rem;
  margin: 0.55rem auto 0.45rem;
  stroke: var(--gold);
  stroke-width: 1.15;
  fill: var(--gold);
  opacity: 0.9;
}

.tagline {
  margin: 0 auto 1.15rem;
  max-width: 22rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 500;
  font-size: 1.18rem;
  line-height: 1.35;
  color: var(--parchment);
}

/* Destination buttons */

.links {
  display: grid;
  gap: 0.62rem;
}

.link {
  display: grid;
  grid-template-columns: 2.4rem 1fr 1rem;
  align-items: center;
  gap: 0.7rem;
  min-height: 3.35rem;
  padding: 0.55rem 0.8rem 0.55rem 0.7rem;
  text-decoration: none;
  color: var(--parchment);
  background: linear-gradient(180deg, rgba(19, 32, 51, 0.72), rgba(10, 16, 24, 0.78));
  border: 1px solid var(--gold-dim);
  border-radius: 0.7rem;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.22);
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.link:hover,
.link:focus-visible {
  border-color: var(--gold);
  background: linear-gradient(90deg, rgba(196, 163, 90, 0.16), rgba(19, 32, 51, 0.7));
  box-shadow:
    0 0 0 1px rgba(196, 163, 90, 0.18),
    0 10px 26px rgba(0, 0, 0, 0.3);
}

.link:hover {
  transform: translateY(-1px);
}

.link-icon {
  display: grid;
  place-items: center;
  width: 2.4rem;
  height: 2.4rem;
  color: var(--gold-bright);
  border: 1px solid var(--gold-dim);
  border-radius: 999px;
  background: rgba(7, 12, 18, 0.45);
}

.link-copy {
  display: flex;
  flex-direction: column;
  gap: 0.08rem;
  min-width: 0;
}

.link-title {
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.link-hint {
  font-size: 0.78rem;
  color: var(--stone);
}

.link-go {
  color: var(--gold);
  display: grid;
  place-items: center;
  opacity: 0.75;
}

.link:hover .link-go,
.link:focus-visible .link-go {
  opacity: 1;
}

.link:focus-visible,
.thumbs a:focus-visible {
  outline: 2px solid var(--gold-bright);
  outline-offset: 3px;
}

/* Gallery */

.cabinet {
  margin-top: 1.55rem;
}

.cabinet-title {
  margin: 0 0 0.7rem;
  text-align: center;
  font-family: var(--font-display);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
}

.thumbs {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
}

.thumbs a {
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 50%;
  border: 1px solid var(--gold-dim);
  background: #05080c;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 28%;
  transform: scale(1.42) translateY(8%);
}

.thumbs a:hover,
.thumbs a:focus-visible {
  border-color: var(--gold);
  transform: translateY(-2px);
  box-shadow:
    0 0 0 1px rgba(196, 163, 90, 0.28),
    0 12px 22px rgba(0, 0, 0, 0.4);
}

/* Footer */

.colophon {
  margin-top: 1.55rem;
  text-align: center;
}

.colophon-line {
  margin: 0 auto;
  max-width: 22rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.98rem;
  line-height: 1.4;
  color: var(--stone);
  text-wrap: balance;
}

.colophon-mark {
  margin: 0.7rem 0 0;
  font-family: var(--font-display);
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.85;
}

@media (min-width: 720px) {
  :root {
    --shell-pad-top: 2.4rem;
    --seal-size: 7rem;
  }

  .shell {
    padding-top: var(--shell-pad-top);
    padding-bottom: 3rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rays {
    animation: none;
  }

  .link,
  .thumbs a {
    transition: none;
  }

  .link:hover,
  .thumbs a:hover {
    transform: none;
  }
}
