/* ============================================================
   MAREGRAPH — almanac shell
   Bukan terminal ber-sidebar: ini lembar almanak pasang-surut.
   Header dek horizontal, hero serif di tengah, laut melintang
   selebar halaman di bawah, dan halaman men-scroll secara
   native — tidak ada shell yang dikunci.

   Satu tinta, kertas bergaris (bukan grid titik), aksen teal.
   Serif untuk judul, mono untuk data.
   ============================================================ */

:root {
  --paper:   #F2F4F1;
  --ink:     #0A0A0A;
  --line:    rgba(10, 10, 10, 0.16);
  --line-2:  rgba(10, 10, 10, 0.08);
  --dim:     rgba(10, 10, 10, 0.42);
  --dimmer:  rgba(10, 10, 10, 0.26);
  --accent:  #0E7C6B;
  --mono:    "Source Code Pro", ui-monospace, SFMono-Regular, Menlo, monospace;
  --serif:   "Fraunces", Georgia, "Times New Roman", serif;
  --deck-h:  85px;   /* dua baris header + border, dipakai menghitung tinggi stage */
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* `hidden` hanya di-set display:none oleh UA stylesheet; aturan penulis
   apa pun mengalahkannya. Naikkan kembali ke tingkat yang bisa diandalkan. */
[hidden] { display: none !important; }

/* Situs ini satu look, terang, sengaja — jangan biarkan form control
   dan scrollbar ikut dark-mode OS. */
html { height: 100%; color-scheme: light; }

/* Semua target anchor (#shoals, #s3, …) hidup di bawah dek yang sticky;
   tanpa ini lompatan anchor menyembunyikan judulnya di balik header. */
[id] { scroll-margin-top: calc(var(--deck-h) + 14px); }
body {
  min-height: 100%;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

:focus-visible {
  outline: 1px solid var(--accent);
  outline-offset: 2px;
  border-radius: 0;
}
:focus:not(:focus-visible) { outline: none; }

::selection { background: var(--ink); color: var(--paper); }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 99;
  background: var(--ink);
  color: var(--paper);
  padding: 9px 13px;
  font-size: 11px;
}
.skip:focus { left: 8px; top: 8px; text-decoration: none; }

/* ── deck: header dua baris ────────────────────────────────── */
.deck {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.deck-top {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 clamp(16px, 3vw, 32px);
  height: 47px;
  border-bottom: 1px solid var(--line-2);
}
.brand {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 500;
  letter-spacing: 0.20em;
}
.brand:hover { text-decoration: none; color: var(--accent); }
.ver { font-size: 10px; color: var(--dimmer); letter-spacing: 0.1em; }
.tagline { font-size: 11px; color: var(--dim); letter-spacing: 0.05em; }

.deck-top .spacer, .deck-nav .spacer { margin-left: auto; }

.ca {
  font: inherit;
  font-size: 10.5px;
  color: var(--dim);
  background: transparent;
  border: 1px solid var(--line);
  padding: 6px 10px;
  cursor: pointer;
  max-width: 300px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: border-color .14s, color .14s;
}
.ca::before { content: "CA "; color: var(--dimmer); letter-spacing: .08em; }
.ca:hover { border-color: var(--ink); color: var(--ink); }
.ca.copied { border-color: var(--accent); color: var(--accent); }
.ca.pending { cursor: default; }
.ca.pending:hover { border-color: var(--line); color: var(--dim); }

.connect {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid var(--ink);
  font-size: 11.5px;
  letter-spacing: .04em;
  white-space: nowrap;
  transition: background .14s, color .14s;
}
.connect:hover { background: var(--ink); color: var(--paper); text-decoration: none; }
.connect .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--accent); flex: none; }
.connect:hover .dot { background: var(--paper); }

.deck-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 0 clamp(16px, 3vw, 32px);
  height: 37px;
  font-size: 11px;
  color: var(--dim);
  letter-spacing: .06em;
  overflow-x: auto;
  scrollbar-width: none;
}
.deck-nav::-webkit-scrollbar { display: none; }

.nav { display: flex; align-items: stretch; height: 100%; }
.nav a {
  display: flex;
  align-items: center;
  padding: 0 11px;
  color: var(--dim);
  border-bottom: 2px solid transparent;
  transition: color .14s, border-color .14s;
}
.nav a:hover { color: var(--ink); border-bottom-color: var(--ink); text-decoration: none; }
.nav a .g { display: none; }   /* glyph hanya dipakai tema lain; di dek cukup teks */

.net { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.live {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent);
  animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: .25 } }
.clock { font-variant-numeric: tabular-nums; white-space: nowrap; margin-left: 16px; }

/* ── stage: laut selebar halaman ───────────────────────────── */
.stage {
  position: relative;
  overflow: hidden;
  min-height: calc(100dvh - var(--deck-h) - 39px);   /* 39px = keel */
  display: flex;
  flex-direction: column;
  /* kertas bergaris horizontal, ala kertas instrumen strip-chart —
     BUKAN grid titik. Garisnya berhenti terasa di bawah hero karena
     kanvas air menimpanya. */
  background-image: repeating-linear-gradient(
    to bottom, transparent 0 27px, var(--line-2) 27px 28px);
}
#tide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* hero di TENGAH — serif, bukan mono rata kiri */
.hero {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 780px;
  margin: 0 auto;
  padding: clamp(40px, 9vh, 96px) 20px 0;
  pointer-events: none;
}
.hero a, .hero button { pointer-events: auto; }

.greet {
  font-size: 11px;
  color: var(--dim);
  letter-spacing: .22em;
  text-transform: uppercase;
  margin-bottom: 24px;
}

h1 {
  font-family: var(--serif);
  font-size: clamp(34px, 5.4vw, 62px);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.01em;
}
.h-dim { color: rgba(10, 10, 10, 0.34); }
.h-lit { color: var(--ink); }
.cur { font-family: var(--mono); font-weight: 300; animation: blink 1.1s step-end infinite; }
@keyframes blink { 0%,100% { opacity: 1 } 50% { opacity: 0 } }

.role {
  margin-top: 20px;
  font-size: 12px;
  color: var(--dim);
  letter-spacing: .05em;
}
.lede {
  margin: 20px auto 0;
  font-size: 12.5px;
  line-height: 1.8;
  color: rgba(10, 10, 10, 0.66);
  max-width: 56ch;
}

.caps {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 26px;
}
.caps li {
  font-size: 10.5px;
  color: var(--dim);
  border: 1px solid var(--line);
  padding: 4px 8px;
  letter-spacing: .04em;
  background: var(--paper);   /* opak: tag UI harus selalu terbaca di atas air */
}

.cta-row {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 18px;
  margin-top: 30px;
  flex-wrap: wrap;
}
.cta {
  font-size: 12px;
  border-bottom: 1px solid var(--ink);
  padding-bottom: 2px;
  letter-spacing: .04em;
}
.cta:hover { text-decoration: none; color: var(--accent); border-color: var(--accent); }
.hint { font-size: 10px; color: var(--dimmer); }

/* ── papan pasang: countdown di TENGAH bawah ───────────────── */
.countdown {
  position: relative;
  z-index: 2;
  margin: auto auto clamp(30px, 7vh, 72px);
  text-align: center;
  background: var(--paper);
  border-top: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  padding: 12px clamp(22px, 4vw, 44px) 13px;
  width: max-content;
  max-width: calc(100% - 40px);
}
.cd-label {
  font-size: 10px;
  color: var(--dim);
  letter-spacing: .26em;
  text-transform: uppercase;
}
.cd-clock {
  font-size: clamp(19px, 3vw, 28px);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  letter-spacing: .03em;
  margin-top: 5px;
}
.cd-abs { font-size: 10px; color: var(--dimmer); margin-top: 4px; letter-spacing: .08em; }
.countdown.live .cd-clock { color: var(--accent); }

/* ── keel: footer satu baris ───────────────────────────────── */
.keel {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  height: 39px;
  padding: 0 16px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: .06em;
  background: var(--paper);
  position: relative;
  z-index: 2;
}
.connect-label { color: var(--dimmer); }
.sig { color: var(--dimmer); }
.keel .sep { color: var(--dimmer); }

/* ── responsive ────────────────────────────────────────────── */
@media (max-width: 720px) {
  :root { --deck-h: 123px; }   /* CA turun ke baris sendiri */
  .deck-top { flex-wrap: wrap; height: auto; padding-top: 10px; padding-bottom: 10px; row-gap: 8px; }
  .tagline { display: none; }
  .ca { order: 5; flex: 1 1 100%; max-width: none; }
  .hero { padding-top: 40px; }
  /* air di belakang teks panjang menyakitkan di layar kecil */
  #tide { opacity: .38; }
  .keel { flex-wrap: wrap; height: auto; padding: 10px 14px; gap: 10px; }
}

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

/* Viewport pendek (laptop kecil / landscape phone): hero dan laut mau tak
   mau bertumpuk — pudarkan airnya supaya teks tetap menang. */
@media (max-height: 640px) {
  #tide { opacity: .55; }
}
