/* How Cooked Is Your Lobster? — local draft styles. All presentation lives here. */
:root {
  --navy: #07183a;
  --navy-deep: #041028;
  --blue: #0a2a6e;
  --blue-mid: #12388a;
  --cream: #fff6ec;
  --cream-soft: #f7ead7;
  --ink: #1a1230;
  --ink-soft: #3a2a4a;
  --pink: #ff7eb6;
  --pink-hot: #ff4f9a;
  --pink-deep: #9b1458;
  --gold: #f3c15a;
  --white: #fffdf9;
  --link-on-navy: #ffd0e6;
  --focus: #ffe082;
  --draft: #3a2060;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  max-width: 100%;
  overflow-x: clip;
}

body {
  font-family: "Segoe UI", "Trebuchet MS", "Helvetica Neue", system-ui, sans-serif;
  font-size: 1.05rem;
  line-height: 1.55;
  color: var(--cream);
  background:
    radial-gradient(1200px 600px at 50% -80px, #163a8c 0%, var(--navy) 58%, var(--navy-deep) 100%);
  background-color: var(--navy-deep);
  min-height: 100vh;
}

img, svg, video { max-width: 100%; height: auto; }

a {
  color: var(--pink-deep);
}

.footer a,
.hero a,
.music-credit a,
.footer-bbb a {
  color: var(--link-on-navy);
}

a:hover { text-decoration-thickness: 2px; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -100px;
  background: var(--gold);
  color: var(--ink);
  padding: 0.5rem 0.8rem;
  z-index: 20;
  font-weight: 700;
  text-decoration: none;
  border-radius: 0 0 0.4rem 0.4rem;
}
.skip-link:focus { top: 0; }

.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;
}

.svg-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.page {
  width: min(44rem, calc(100% - 1.5rem));
  margin-left: auto;
  margin-right: auto;
}

.hero {
  position: relative;
  text-align: center;
  padding: 1.75rem 0 0.5rem;
}

.hero-marks {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  pointer-events: none;
  margin: 0 0 0.2rem;
}

.hero-lobster {
  width: 4.4rem;
  height: 5.5rem;
  overflow: visible;
}

.hero-lobster--right { transform: scaleX(-1); }

.kicker {
  margin: 0;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 700;
}

h1 {
  margin: 0.35rem 0 0.15rem;
  font-family: Georgia, "Palatino Linotype", Palatino, "Times New Roman", serif;
  font-size: clamp(1.6rem, 6vw, 2.4rem);
  line-height: 1.2;
  font-weight: 700;
  color: var(--white);
  text-wrap: balance;
}

.subtitle {
  margin: 0.15rem 0 0.9rem;
  font-family: Georgia, "Palatino Linotype", Palatino, serif;
  font-style: italic;
  font-size: 1.15rem;
  letter-spacing: 0.08em;
  color: var(--pink);
}

.intro {
  margin: 0 auto 1.25rem;
  max-width: 38rem;
  font-size: 1.12rem;
}

.clock-section, .milestones, .reading-section, .cook-section {
  padding: 0.5rem 0 1.25rem;
}

h2 {
  font-family: Georgia, "Palatino Linotype", Palatino, serif;
  font-size: 1.45rem;
  margin: 0 0 0.75rem;
  color: var(--white);
  text-align: center;
}

.clock-wrap {
  width: min(20rem, 80vw, 100%);
  margin: 0 auto;
}

.clock {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.clock-rim-outer {
  fill: #2a1450;
  stroke: var(--pink);
  stroke-width: 5;
  stroke-linejoin: round;
}

.clock-face {
  fill: var(--cream);
  stroke: #5a2a6e;
  stroke-width: 2.5;
}

.clock-nums text {
  font-family: Georgia, Palatino, serif;
  font-size: 11px;
  font-weight: 700;
  fill: var(--ink);
}

.clock-nums text:first-child {
  fill: var(--pink-deep);
  font-size: 13px;
}

.singularity-mark { color: var(--pink-hot); }

.clock-tick {
  stroke: #3a2a4a;
  stroke-width: 1.4;
  stroke-linecap: round;
}
.clock-tick--hour { stroke-width: 2.2; stroke: #1a1230; }

.hand line {
  stroke: #1a1230;
  stroke-linecap: round;
}
.hand--hour line { stroke-width: 5; }
.hand--minute line { stroke-width: 3.2; stroke: var(--pink-deep); }
.hand circle { fill: #1a1230; }
.clock-pin { fill: var(--pink-hot); stroke: #1a1230; stroke-width: 1.2; }

.clock-reading {
  margin: 0.9rem 0 0.7rem;
  text-align: center;
  font-family: Georgia, Palatino, serif;
  font-size: clamp(1.2rem, 4.5vw, 1.6rem);
  line-height: 1.3;
  color: var(--white);
  position: sticky;
  top: 0;
  z-index: 6;
  background: var(--navy);
  padding: 0.55rem 0.6rem;
  border-radius: 0 0 0.6rem 0.6rem;
  box-shadow: 0 8px 16px rgba(4, 16, 40, 0.4);
}

.clock-poles {
  display: grid;
  gap: 0.6rem;
}

@media (min-width: 640px) {
  .clock-poles { grid-template-columns: 1fr 1fr; }
}

.pole {
  margin: 0;
  padding: 0.7rem 0.8rem;
  background: rgba(4, 16, 40, 0.45);
  border: 1px solid rgba(255, 126, 182, 0.28);
  border-radius: 0.7rem;
  font-size: 0.95rem;
  color: var(--cream-soft);
}

.pole.is-active {
  border-color: var(--pink);
  background: rgba(80, 20, 60, 0.35);
  color: var(--white);
}

.clock-how {
  margin: 0.85rem 0 0;
  font-size: 0.95rem;
  color: #d9e2f7;
}

.milestones-lead {
  margin: 0 0 1rem;
  text-align: center;
}

.card {
  background: var(--cream);
  color: var(--ink);
  border-radius: 1rem;
  padding: 1rem 1rem 1.05rem;
  margin: 0 0 1rem;
  box-shadow: 0 8px 0 rgba(0, 0, 0, 0.18);
  border: 2px solid #f0cfe0;
}

.card--claim {
  border-color: #e8b86a;
}

.card-head h3 {
  margin: 0 0 0.2rem;
  font-size: 1.15rem;
  line-height: 1.3;
  color: var(--blue);
  font-family: Georgia, Palatino, serif;
}

.card-date {
  margin: 0 0 0.6rem;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.card h4 {
  margin: 0 0 0.35rem;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pink-deep);
}

.card p { margin: 0 0 0.7rem; }

.source { margin-bottom: 0.85rem; }
.source a { font-weight: 700; }

.slider-block label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--ink);
}

.slider-ends {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin-bottom: 0.15rem;
}

input[type="range"] {
  display: block;
  width: 100%;
  height: 2.75rem;
  margin: 0;
  accent-color: #c61d6e;
  cursor: pointer;
}

.slider-value {
  margin: 0.15rem 0 0;
  font-weight: 700;
  color: var(--pink-deep);
}

.thanks {
  margin: 0.45rem 0 0;
  font-style: italic;
  color: var(--ink-soft);
}

.reading-section {
  text-align: center;
}

.lot {
  font-weight: 700;
  color: var(--gold);
}

.reading-summary {
  font-family: Georgia, Palatino, serif;
  font-size: 1.25rem;
}

.share {
  text-align: left;
  background: rgba(4, 16, 40, 0.4);
  border: 1px solid rgba(255, 126, 182, 0.28);
  border-radius: 0.8rem;
  padding: 0.9rem;
}

.share label {
  display: block;
  font-weight: 700;
  margin-bottom: 0.35rem;
}

#share-line {
  display: block;
  width: 100%;
  resize: vertical;
  min-height: 4.5rem;
  font: inherit;
  color: var(--ink);
  background: var(--white);
  border: 2px solid #d7b7c8;
  border-radius: 0.5rem;
  padding: 0.55rem 0.7rem;
}

.share-btn, .cook-btn, .reset-btn, .sound-toggle {
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  border-radius: 999px;
  padding: 0.7rem 1.15rem;
}

.share-btn, .sound-toggle, .reset-btn {
  background: var(--cream);
  color: var(--blue);
  border: 2px solid var(--pink);
  margin-top: 0.65rem;
}

.share-btn:hover, .sound-toggle:hover, .reset-btn:hover {
  background: #ffe6f1;
}

.copy-status { min-height: 1.3em; margin: 0.4rem 0 0; }

.cook-section { text-align: center; padding-bottom: 2rem; position: relative; z-index: 12; }

.cook-btn {
  display: inline-block;
  width: min(28rem, 100%);
  background: linear-gradient(#ff7eb6, #e91e73);
  color: var(--white);
  border: 3px solid #fff3ea;
  box-shadow: 0 6px 0 #7a1048;
  font-size: 1.05rem;
  line-height: 1.3;
  padding: 0.9rem 1.1rem;
}

.cook-btn:hover { filter: brightness(1.05); }
.cook-btn:active { transform: translateY(2px); box-shadow: 0 4px 0 #7a1048; }

@media (prefers-reduced-motion: reduce) {
  .cook-btn:active { transform: none; }
}

.cook-warn, .cooked-msg, .inside-dance {
  margin: 0.7rem 0 0;
}

.cooked-msg {
  font-family: Georgia, Palatino, serif;
  font-size: 1.3rem;
  color: var(--gold);
}

.inside-dance { font-style: italic; color: var(--pink); }

.footer {
  padding: 1.5rem 0 3rem;
  color: #d9e2f7;
  font-size: 0.98rem;
}

.footer h2 {
  font-size: 1.1rem;
  text-align: left;
  margin: 1.2rem 0 0.5rem;
}

.footer-bbb {
  margin-top: 1.4rem;
  font-size: 0.92rem;
  color: #9eb0d6;
}

.footer-bbb a { color: #c9d4f0; }

.sound-toggle[aria-pressed="true"] {
  background: #ffe6f1;
  box-shadow: inset 0 0 0 2px var(--pink-deep);
}

.stage {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 8;
  overflow: hidden;
}

.dancers {
  width: 100%;
  height: 100%;
  display: block;
  color: var(--pink);
}

.dancer { color: var(--pink-hot); }

body.is-cooked .clock-rim-outer {
  stroke: var(--gold);
}

[hidden] { display: none !important; }


body.is-cooked .cook-section {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 12;
  margin: 0;
  padding: 0.7rem 1rem 1rem;
  background: rgba(4, 16, 40, 0.94);
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.35);
  pointer-events: auto;
}

body.is-cooked {
  padding-bottom: 7.5rem;
}

@media (min-width: 900px) and (orientation: landscape) {
  html, body {
    height: 100%;
  }

  body {
    display: flex;
    flex-direction: column;
    height: 100vh;
    overflow: hidden;
  }

  .page {
    width: min(86rem, calc(100% - 2rem));
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(20rem, 28rem) minmax(22rem, 1fr);
    column-gap: 2.25rem;
    align-items: stretch;
    overflow: hidden;
  }

  .clock-panel {
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    padding-top: 0.35rem;
    padding-bottom: 1rem;
  }

  .scroll-panel {
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
  }

  body.is-cooked {
    padding-bottom: 0;
  }

  body.is-cooked .scroll-panel {
    padding-bottom: 7.5rem;
  }

  .hero {
    padding-top: 0.85rem;
    padding-bottom: 0.2rem;
  }

  .hero-lobster {
    width: 3.2rem;
    height: 4rem;
  }

  h1 {
    font-size: clamp(1.35rem, 2.2vw, 1.95rem);
  }

  .intro {
    font-size: 1rem;
    margin-bottom: 0.7rem;
  }

  .clock-wrap {
    width: min(16.5rem, 100%);
  }

  .clock-reading {
    position: static;
    background: transparent;
    box-shadow: none;
    padding: 0.4rem 0;
    border-radius: 0;
  }

  .clock-how {
    font-size: 0.88rem;
  }

  .clock-section, .milestones, .reading-section, .cook-section {
    padding-top: 0.35rem;
  }
}

@media (max-width: 399px) {
  body { font-size: 1rem; }
  .page { width: calc(100% - 1rem); }
  .card { padding: 0.85rem 0.75rem 0.95rem; }
  .hero-lobster { width: 3.2rem; height: 4rem; }
}
