/* Songway Studios — landing.
   Palette sampled from the key art: deep blue-black rain, one warm amber light.
   One accent doing all the work is what makes the site and the artwork read as
   the same world rather than two separate designs. */

:root {
  --ink:        #080A11;
  --ink-2:      #0E1119;
  --ink-3:      #161A26;
  --amber:      #D9A441;
  --amber-lit:  #F2C877;
  --cream:      #F1EEE6;
  --dim:        #98A0B4;
  --rule:       rgba(217, 164, 65, 0.28);

  --serif: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
  --sans: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--ink);
  color: var(--cream);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--amber-lit); }

/* ---------------------------------------------------------------- hero */

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
}

/* Stack, back to front: plate (-4), Leah (-3), scrims (-2), dust (-1), copy. */
.hero__art {
  position: absolute;
  inset: 0;
  z-index: -4;
  /* Filename is versioned, not query-strung: the old lr-*.webp still sits in
     caches with Leah baked into it, and layering the figure over that stale
     plate renders her twice. A new name is the only reliable bust. */
  background-image: image-set(url("img/plate-1920.webp") 1x);
  background-size: cover;
  /* Lower percentage pushes the figure right: cover reveals more of the image's
     left edge, so Leah clears the copy column instead of sitting behind it. */
  background-position: 38% center;
  /* Slow drift. Purely atmospheric, and disabled for reduced-motion below. */
  animation: drift 44s ease-in-out infinite alternate;
}

@keyframes drift {
  from { transform: scale(1.04) translate3d(0, 0, 0); }
  to   { transform: scale(1.11) translate3d(-1.6%, -1%, 0); }
}

/* Leah rides above the plate on her own layer. Same cover geometry and the same
   object-position as the background, so the two stay registered at every width.
   The wrapper carries the drift; the image carries the sway, because a single
   element can only own one transform. */
.hero__figure {
  position: absolute;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  animation: drift 44s ease-in-out infinite alternate;
}

.hero__figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 38% center;
  display: block;
  transform-origin: 62% 100%;   /* pivot at her seat, so she sways, not slides */
  animation: breeze 11s ease-in-out infinite alternate;
}

@keyframes breeze {
  from { transform: rotate(-0.32deg) translate3d(0, 0, 0); }
  to   { transform: rotate(0.34deg) translate3d(0.35%, -0.25%, 0); }
}

/* Dust and leaves on the wind. Drawn, not stacked as DOM nodes, so the count
   can scale with the viewport without costing layout. */
.hero__dust {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* Two scrims: one darkens the left so type has ground, one lifts the whole
   frame off pure black so the art keeps its depth. */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    linear-gradient(100deg, var(--ink) 4%, rgba(8, 10, 17, 0.86) 34%, rgba(8, 10, 17, 0.18) 68%, rgba(8, 10, 17, 0.55) 100%),
    linear-gradient(to top, var(--ink) 1%, transparent 32%);
}

.hero__inner {
  width: min(1180px, 92vw);
  margin: 0 auto;
  padding: 4rem 0;
}

.hero__copy { max-width: 34rem; }

.eyebrow {
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--amber);
  margin: 0 0 1.6rem;
}

.wordmark {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.6rem, 7.4vw, 5.1rem);
  letter-spacing: 0.1em;
  line-height: 0.98;
  margin: 0;
  text-wrap: balance;
}

.wordmark span {
  display: block;
  font-size: 0.365em;
  letter-spacing: 0.42em;
  color: var(--amber);
  margin-top: 1.1rem;
  padding-left: 0.3em;
}

.rule {
  width: 5.5rem;
  height: 2px;
  background: var(--amber);
  margin: 2.2rem 0;
  border: 0;
}

.promise {
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2.3vw, 1.5rem);
  line-height: 1.55;
  color: var(--cream);
  margin: 0 0 1.1rem;
  text-wrap: pretty;
}

.flagship {
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--dim);
  margin: 0 0 2.6rem;
  max-width: 30rem;
}

.flagship em {
  color: var(--amber-lit);
  font-style: normal;
  font-family: var(--serif);
  font-size: 1.08em;
}

/* ---------------------------------------------------------------- cta */

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.1rem 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font: inherit;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 0.95rem 1.9rem;
  border-radius: 2px;
  border: 1px solid var(--amber);
  background: var(--amber);
  color: #17120A;
  text-decoration: none;
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.btn:hover,
.btn:focus-visible {
  background: var(--amber-lit);
  border-color: var(--amber-lit);
  transform: translateY(-1px);
  box-shadow: 0 10px 30px -12px rgba(217, 164, 65, 0.75);
}

.btn--ghost {
  background: transparent;
  color: var(--cream);
  border-color: rgba(241, 238, 230, 0.32);
  box-shadow: none;
}

.btn--ghost:hover,
.btn--ghost:focus-visible {
  background: rgba(241, 238, 230, 0.06);
  border-color: var(--cream);
  box-shadow: none;
}

:focus-visible { outline: 2px solid var(--amber-lit); outline-offset: 3px; }

.note {
  font-size: 0.82rem;
  color: var(--dim);
  margin: 1.9rem 0 0;
}

/* ---------------------------------------------------------------- below the fold

   The hero sells; everything under it answers. Same palette, quieter voice —
   one amber accent, generous rules, no cards. Borders separate rows because a
   card around every block would flatten the hierarchy the hero just built. */

.meta-strip {
  border-top: 1px solid var(--ink-3);
  border-bottom: 1px solid var(--ink-3);
  background: var(--ink-2);
}

.meta-strip__inner,
.detail__inner,
.episodes__inner,
.gallery__inner {
  width: min(1180px, 92vw);
  margin: 0 auto;
}

.meta-strip__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1.1rem;
  padding: 1rem 0;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--dim);
}

.chip {
  border: 1px solid var(--ink-3);
  color: var(--cream);
  padding: 0.15rem 0.55rem;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
}

.meta-dot { color: #4E566A; }

/* ---- synopsis + specs ---- */

.detail__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 3.5rem;
  padding: 3.6rem 0 3.4rem;
}

.synopsis p {
  color: var(--dim);
  font-size: 0.97rem;
  line-height: 1.72;
  margin: 0 0 1.15rem;
  max-width: 60ch;
}

.synopsis p:last-child { margin-bottom: 0; }

/* The opening paragraph carries the premise, so it gets the serif and the
   cream — it should read like the book, not like a product description. */
.synopsis__lead {
  font-family: var(--serif);
  font-size: 1.22rem !important;
  line-height: 1.55 !important;
  color: var(--cream) !important;
}

.specs { margin: 0; display: flex; flex-direction: column; }

.spec {
  display: grid;
  grid-template-columns: 7rem minmax(0, 1fr);
  gap: 1.2rem;
  padding: 0.72rem 0;
  border-top: 1px solid var(--ink-3);
  font-size: 0.9rem;
}

.spec:first-child { border-top: 0; padding-top: 0; }

.spec dt {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--amber);
  padding-top: 0.2rem;
}

.spec dd { margin: 0; color: var(--cream); }

/* ---- section heads ---- */

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.6rem 1.5rem;
  padding-top: 2.6rem;
  border-top: 1px solid var(--ink-3);
}

.section-head h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.5rem, 3vw, 2.05rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0;
}

.section-head__tag {
  font-size: 0.76rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--dim);
}

/* ---- episodes ---- */

.episodes__inner { padding-bottom: 3.4rem; }

.ep-list {
  list-style: none;
  margin: 1.6rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.ep {
  display: grid;
  grid-template-columns: 3.2rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.4rem;
  padding: 0.8rem 0.7rem 0.8rem 0.25rem;
  border-top: 1px solid var(--ink-3);
  transition: background 160ms ease;
}

.ep:hover { background: var(--ink-2); }

.ep__no {
  font-size: 1.1rem;
  color: #5C6478;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

.ep__title { font-size: 0.98rem; color: var(--cream); }

.ep__part {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #5C6478;
  margin-top: 0.12rem;
}

.ep__run {
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  color: var(--dim);
  font-variant-numeric: tabular-nums;
}

/* ---- key art ---- */

.gallery__inner { padding-bottom: 4.2rem; }

.shots {
  margin-top: 1.6rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 1.4rem;
}

.shot { margin: 0; overflow: hidden; }

.shot img {
  width: 100%;
  height: auto;
  aspect-ratio: 21 / 9;
  object-fit: cover;
  display: block;
  transition: transform 420ms ease;
}

.shot:hover img { transform: scale(1.035); }

.shot figcaption { padding: 0.85rem 0.15rem 0; }

.shot h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.06rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin: 0 0 0.15rem;
  color: var(--cream);
}

.shot p {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.6;
  color: var(--dim);
}

/* ---------------------------------------------------------------- studio */

/* Deliberately small. The studio signs the work; it does not introduce it. */
footer.studio {
  border-top: 1px solid var(--ink-3);
  background: var(--ink);
  padding: 2.2rem 0;
}

footer.studio div {
  width: min(1180px, 92vw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.4rem 1.4rem;
}

.studio__mark {
  font-family: var(--sans);
  font-size: 0.74rem;
  letter-spacing: 0.3em;
  color: var(--amber);
}

.studio__line {
  font-size: 0.86rem;
  color: var(--dim);
}

/* ---------------------------------------------------------------- join */

.panel {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 3rem 1.5rem;
  background:
    radial-gradient(1100px 620px at 50% -8%, rgba(217, 164, 65, 0.13), transparent 62%),
    var(--ink);
}

.card {
  width: min(29rem, 100%);
  background: var(--ink-2);
  border: 1px solid var(--ink-3);
  border-radius: 4px;
  padding: 2.7rem 2.4rem;
  text-align: center;
}

.card h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.95rem;
  letter-spacing: 0.02em;
  margin: 0 0 0.7rem;
}

.card p {
  color: var(--dim);
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 0 0 1.9rem;
}

.card .btn { width: 100%; justify-content: center; margin-bottom: 0.75rem; }

.back {
  display: inline-block;
  margin-top: 1.4rem;
  font-size: 0.85rem;
  color: var(--dim);
  text-decoration: none;
}

.back:hover { color: var(--cream); }

footer.site {
  border-top: 1px solid var(--ink-3);
  background: var(--ink);
  padding: 2rem 0;
  font-size: 0.78rem;
  color: var(--dim);
}

footer.site div {
  width: min(1180px, 92vw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.6rem;
  letter-spacing: 0.04em;
}

/* ---------------------------------------------------------------- small */

@media (max-width: 46rem) {
  .hero__art { background-position: 42% center; }
  .hero__figure img { object-position: 42% center; }   /* keep the layers registered */
  .hero::after {
    background:
      linear-gradient(to top, var(--ink) 26%, rgba(8, 10, 17, 0.62) 62%, rgba(8, 10, 17, 0.42) 100%);
  }
  .hero__inner { padding: 6rem 0 3.5rem; }
  .hero { align-items: end; }

  .detail__inner { grid-template-columns: 1fr; gap: 2.4rem; }
  .spec { grid-template-columns: 6.5rem minmax(0, 1fr); }
  .ep { grid-template-columns: 2.4rem minmax(0, 1fr); gap: 0.9rem; }
  .ep__run { grid-column: 2; margin-top: -0.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hero__art { animation: none; transform: scale(1.04); }
  .hero__figure { animation: none; transform: scale(1.04); }
  .hero__figure img { animation: none; transform: none; }
  .hero__dust { display: none; }
  .btn { transition: none; }
  .btn:hover { transform: none; }
}

/* ---------------------------------------------------------------- admin */

.admin {
  width: min(1180px, 94vw);
  margin: 0 auto;
  padding: 3rem 0 5rem;
}

.admin__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.2rem;
  padding-bottom: 1.4rem;
  margin-bottom: 1.8rem;
  border-bottom: 1px solid var(--rule);
}

.admin__head h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 2rem;
  margin: 0 0 0.3rem;
}

.admin__head p { margin: 0; color: var(--dim); font-size: 0.9rem; }

.admin__actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.admin__actions .btn { padding: 0.62rem 1.2rem; font-size: 0.9rem; }

.admin__empty {
  color: var(--dim);
  background: var(--ink-2);
  border: 1px solid var(--ink-3);
  padding: 2.4rem;
  text-align: center;
  border-radius: 3px;
}

/* Radzen ships a light theme; these pull the grid onto the dark ground. */
.admin__grid { background: var(--ink-2); border: 1px solid var(--ink-3); }
.admin__grid .rz-grid-table { color: var(--cream); }
.admin__grid .rz-grid-table thead th { background: var(--ink-3); color: var(--dim); }
.admin__grid .rz-grid-table tbody td { border-color: var(--ink-3); }
.admin__grid .rz-grid-table tbody tr:hover td { background: rgba(217, 164, 65, 0.06); }
