:root {
  --ink: #142d31;
  --cream: #fff2cf;
  --paper: #f8d996;
  --rust: #b64f2d;
  --rust-dark: #80311f;
  --turquoise: #43aeb6;
  --sky: #99c6bb;
  --sage: #678747;
  --gold: #f4c345;
  --pink: #e97796;
  --blue: #63bad7;
  --shadow: 0 24px 70px rgba(20, 45, 49, .18);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: #f7e7bc;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { color: inherit; }

.skip-link {
  position: fixed;
  left: 1rem;
  top: -5rem;
  z-index: 1000;
  padding: .7rem 1rem;
  background: #fff;
  border-radius: .5rem;
}

.skip-link:focus { top: 1rem; }

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 2rem;
  min-height: 88px;
  padding: .65rem clamp(1rem, 4vw, 4.5rem);
  color: #fff8e6;
  transition: background .25s ease, box-shadow .25s ease, min-height .25s ease;
}

.site-header.is-scrolled {
  min-height: 70px;
  background: rgba(20, 45, 49, .96);
  box-shadow: 0 8px 30px rgba(0, 0, 0, .18);
  backdrop-filter: blur(10px);
}

.brand {
  display: inline-flex;
  width: fit-content;
  flex-direction: column;
  align-items: center;
  font-family: Rockwell, "Roboto Slab", Georgia, serif;
  font-weight: 900;
  line-height: .7;
  letter-spacing: .04em;
  text-decoration: none;
  text-transform: uppercase;
  filter: drop-shadow(0 3px 0 rgba(20, 45, 49, .55));
  transform: rotate(-2deg);
}

.brand-top { font-size: 1.85rem; color: var(--gold); }
.brand-bottom { font-size: 1.05rem; color: #fff8e6; letter-spacing: .18em; }

nav { display: flex; gap: clamp(1.25rem, 3vw, 3rem); }
nav a { font-size: .84rem; font-weight: 800; letter-spacing: .11em; text-decoration: none; text-transform: uppercase; }
nav a:hover, nav a:focus-visible { color: var(--gold); }

.header-cta {
  justify-self: end;
  padding: .55rem 1rem;
  border: 1px solid rgba(255, 248, 230, .65);
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-decoration: none;
  text-transform: uppercase;
}

.hero {
  position: relative;
  min-height: 780px;
  height: min(900px, 100svh);
  isolation: isolate;
  overflow: hidden;
  background: #7da58f;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(15, 42, 46, .88) 0%, rgba(15, 42, 46, .58) 39%, rgba(15, 42, 46, .05) 70%), linear-gradient(0deg, rgba(20, 45, 49, .62) 0%, transparent 38%);
}

.hero-scenery {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 58% center;
  transform: scale(1.03);
}

.hero-copy {
  position: relative;
  z-index: 3;
  width: min(620px, 48vw);
  padding-top: clamp(10rem, 21vh, 13rem);
  margin-left: clamp(1.4rem, 7vw, 7rem);
  color: #fff8e6;
}

.eyebrow {
  margin: 0 0 .8rem;
  color: var(--rust);
  font-size: .78rem;
  font-weight: 900;
  letter-spacing: .19em;
  text-transform: uppercase;
}

.hero .eyebrow { color: var(--gold); }

h1, h2, h3 { margin: 0; line-height: 1.03; }

h1, h2 {
  font-family: Rockwell, "Roboto Slab", Georgia, serif;
  font-weight: 900;
  letter-spacing: -.045em;
}

h1 { max-width: 680px; font-size: clamp(3rem, 5.3vw, 5rem); text-wrap: balance; }
h1 span { display: block; color: var(--gold); }

.hero-intro {
  max-width: 570px;
  margin: 1.4rem 0 2rem;
  color: rgba(255, 248, 230, .9);
  font-size: clamp(1rem, 1.45vw, 1.22rem);
}

.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  min-height: 50px;
  padding: .75rem 1.35rem;
  border: 2px solid transparent;
  border-radius: 999px;
  font-weight: 900;
  letter-spacing: .03em;
  text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

.button:hover, .button:focus-visible { transform: translateY(-3px); }
.button-primary { color: var(--ink); background: var(--gold); box-shadow: 0 10px 24px rgba(20, 45, 49, .25); }
.button-primary:hover, .button-primary:focus-visible { background: #ffda6f; box-shadow: 0 14px 30px rgba(20, 45, 49, .32); }
.button-quiet { color: #fff8e6; border-color: rgba(255, 248, 230, .55); background: rgba(20, 45, 49, .18); }

.hero-cast { position: absolute; inset: auto 0 0 43%; z-index: 2; height: 78%; pointer-events: none; }
.hero-character { position: absolute; bottom: -7%; object-fit: contain; filter: drop-shadow(0 22px 28px rgba(10, 28, 31, .45)); }
.hero-zoobi { left: 7%; z-index: 3; width: min(31vw, 430px); animation: friendly-bob 6s ease-in-out infinite; }
.hero-toobi { left: 41%; z-index: 4; width: min(18vw, 230px); bottom: -4%; animation: friendly-bob 5.2s .5s ease-in-out infinite; }
.hero-jilly { right: 3%; z-index: 1; width: min(23vw, 300px); bottom: -5%; animation: friendly-bob 5.7s 1s ease-in-out infinite; }

.hero-trail {
  position: absolute;
  left: -8%; right: -8%; bottom: -68px;
  z-index: 5;
  height: 140px;
  border-radius: 50% 50% 0 0;
  background: #f7e7bc;
}

.hero-sun {
  position: absolute;
  right: 10%; top: 16%;
  z-index: 1;
  width: 90px; height: 90px;
  border-radius: 50%;
  background: rgba(255, 220, 116, .72);
  box-shadow: 0 0 70px rgba(255, 227, 141, .9);
}

.dust { position: absolute; z-index: 1; width: 14px; height: 14px; border-radius: 50%; background: rgba(255, 232, 177, .55); box-shadow: 28px 10px rgba(255,232,177,.25), 53px -6px rgba(255,232,177,.35), 80px 14px rgba(255,232,177,.2); animation: dust 10s linear infinite; }
.dust-one { right: 13%; bottom: 18%; }
.dust-two { right: 30%; bottom: 12%; animation-delay: -4s; }

.section { padding: clamp(5rem, 9vw, 9rem) clamp(1.25rem, 6vw, 6.5rem); }

.section-heading { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 520px); gap: 3rem; align-items: end; max-width: 1220px; margin: 0 auto 2.5rem; }
.section-heading h2, .world-copy h2, .mischief-copy h2, .victoria-section h2 { font-size: clamp(2.4rem, 5vw, 5rem); }
.section-heading > p { margin: 0; font-size: 1.08rem; }
.section-heading.centered { display: block; max-width: 780px; text-align: center; }
.section-heading.centered > p:last-child { margin: 1rem auto 0; max-width: 620px; }

.watch-section { background: #f7e7bc; }
.screening-card { position: relative; max-width: 1220px; margin: 0 auto; padding: 1rem; border: 8px solid #5d2f20; border-radius: 24px; background: #2d1913; box-shadow: var(--shadow), inset 0 0 0 2px #ad6c3f; }
.screening-card::before, .screening-card::after { content: ""; position: absolute; bottom: -28px; width: 34%; height: 30px; background: #5d2f20; clip-path: polygon(5% 0, 95% 0, 100% 100%, 0 100%); }
.screening-card::before { left: 7%; transform: rotate(1deg); }
.screening-card::after { right: 7%; transform: rotate(-1deg); }
.screening-card video { display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: 10px; background: #0f2022; }
.screening-lights { display: flex; gap: 1.2rem; justify-content: center; padding: .1rem 0 .8rem; }
.screening-lights span { width: 9px; height: 9px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 13px var(--gold); }
.screening-meta { display: flex; justify-content: space-between; gap: 1rem; padding: .9rem .25rem .1rem; color: #fff2cf; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; }
.screening-meta div { display: flex; flex-wrap: wrap; gap: 1.1rem; }
.screening-meta a { color: var(--gold); font-weight: 900; }
.episode-credits { margin: 1rem .25rem .25rem; padding: .85rem 1rem; border: 1px solid rgba(255,242,207,.24); border-radius: 10px; color: rgba(255,242,207,.82); background: rgba(15,32,34,.45); font-size: .82rem; }
.episode-credits summary { color: var(--gold); cursor: pointer; font-weight: 900; letter-spacing: .04em; }
.episode-credits p { margin: .65rem 0 0; }
.episode-credits a { color: #fff2cf; }
.episode-archive { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; max-width: 1220px; margin: 3rem auto 0; padding: 1.15rem 1.35rem; border: 2px dashed rgba(93,47,32,.35); border-radius: 18px; }
.episode-archive div { display: grid; gap: .2rem; }
.episode-archive span { color: var(--rust); font-size: .72rem; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.episode-archive strong { font-family: Rockwell, Georgia, serif; font-size: 1.25rem; }

.friends-section { position: relative; background: #fff5dc; }
.character-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 2.2vw, 2rem); max-width: 1220px; margin: 0 auto; }
.character-card { overflow: hidden; border: 2px solid rgba(20, 45, 49, .14); border-radius: 26px; background: #fffaf0; box-shadow: 0 16px 40px rgba(20, 45, 49, .08); transition: transform .25s ease, box-shadow .25s ease; }
.character-card:hover { transform: translateY(-8px) rotate(-.3deg); box-shadow: 0 24px 55px rgba(20, 45, 49, .14); }
.character-art { position: relative; display: grid; place-items: end center; height: 370px; overflow: hidden; background: var(--blue); }
.jilly-card .character-art { background: var(--pink); }
.toobi-card .character-art { background: var(--gold); }
.character-art::after { content: ""; position: absolute; inset: auto -10% -40% -10%; height: 60%; border-radius: 50%; background: rgba(255,255,255,.3); }
.character-art img { position: relative; z-index: 2; height: 94%; width: auto; object-fit: contain; object-position: bottom; filter: drop-shadow(0 15px 18px rgba(20, 45, 49, .25)); }
.jilly-card .character-art img { height: 89%; }
.toobi-card .character-art img { height: 96%; }
.scribble { position: absolute; width: 210px; height: 210px; top: 16%; left: 50%; transform: translateX(-50%) rotate(-8deg); border: 4px dashed rgba(255,255,255,.35); border-radius: 46% 54% 43% 57%; }
.character-copy { padding: 1.6rem 1.6rem 1.8rem; }
.character-number { margin: 0 0 .15rem; color: var(--rust); font-family: Rockwell, Georgia, serif; font-weight: 900; }
.character-copy h3 { font-family: Rockwell, Georgia, serif; font-size: 2rem; }
.character-copy h3 span { display: block; margin-top: .25rem; color: #6c7773; font-family: "Trebuchet MS", sans-serif; font-size: .72rem; letter-spacing: .12em; }
.character-copy > p:not(.character-number) { min-height: 7.5em; }
.character-copy ul { display: flex; flex-wrap: wrap; gap: .4rem; margin: 0; padding: 0; list-style: none; }
.character-copy li { padding: .28rem .62rem; border-radius: 999px; background: #f1e2bd; font-size: .75rem; font-weight: 800; }

.world-section { display: grid; grid-template-columns: 1.18fr .82fr; min-height: 700px; background: var(--ink); color: #fff3d2; }
.world-image { position: relative; min-height: 650px; overflow: hidden; }
.world-image::after { content: ""; position: absolute; inset: 0; box-shadow: inset -70px 0 100px rgba(20, 45, 49, .75); pointer-events: none; }
.world-image img { width: 100%; height: 100%; object-fit: cover; object-position: 54% center; }
.world-copy { align-self: center; padding: clamp(3rem, 7vw, 7rem); }
.world-copy .eyebrow { color: var(--gold); }
.world-copy p { font-size: 1.08rem; color: rgba(255, 243, 210, .82); }
.world-copy blockquote { margin: 2.2rem 0 0; padding-left: 1.4rem; border-left: 4px solid var(--gold); color: var(--gold); font-family: Georgia, serif; font-size: 1.45rem; font-style: italic; }
.world-label { position: absolute; z-index: 3; padding: .55rem .8rem; border: 2px solid var(--ink); border-radius: 8px; color: var(--ink); background: var(--gold); box-shadow: 4px 5px 0 var(--ink); font-family: Rockwell, Georgia, serif; font-weight: 900; transform: rotate(-4deg); }
.world-label::after { content: ""; position: absolute; width: 2px; height: 55px; top: 100%; left: 50%; background: var(--ink); }
.saloon-label { left: 22%; top: 43%; }
.victoria-label { right: 16%; top: 18%; transform: rotate(4deg); }

.mischief-section { display: grid; grid-template-columns: 1fr minmax(280px, 420px); gap: 5rem; align-items: center; background: #e2b66d; }
.mischief-copy { max-width: 720px; justify-self: end; }
.mischief-copy p:last-child { max-width: 580px; font-size: 1.08rem; }
.mischief-peek { position: relative; min-height: 420px; display: grid; place-items: end center; }
.door-frame { position: relative; width: 260px; height: 360px; border: 22px solid #5f311e; border-bottom: 0; background: #1b2827; box-shadow: 15px 16px 0 rgba(92, 49, 30, .25); overflow: hidden; }
.door { position: absolute; inset: 0; z-index: 2; transform-origin: left; transform: perspective(600px) rotateY(-67deg); background: repeating-linear-gradient(90deg, #8c4d29 0 20px, #754020 20px 23px); border-right: 10px solid #3f2116; }
.door-frame img { position: absolute; bottom: -2%; right: -12%; width: 91%; filter: drop-shadow(0 8px 10px #000); animation: villain-peek 5s ease-in-out infinite; }
.mischief-peek > span { position: absolute; right: 1%; top: 8%; padding: .3rem .65rem; border: 2px solid var(--ink); border-radius: 50%; background: #fff5dc; font-family: Georgia, serif; font-weight: 900; transform: rotate(7deg); }

.victoria-section { position: relative; isolation: isolate; overflow: hidden; padding: clamp(7rem, 13vw, 12rem) 1.5rem; text-align: center; color: #fff8e6; background: linear-gradient(180deg, #487d7e, #24525b 64%, #153d45); }
.victoria-section::before { content: ""; position: absolute; left: 50%; bottom: -120px; z-index: -1; width: 62%; height: 410px; transform: translateX(-50%); background: #d99749; clip-path: polygon(45% 100%, 55% 100%, 72% 0, 56% 35%, 50% 0, 44% 35%, 28% 0); opacity: .65; filter: blur(2px); }
.victoria-section .eyebrow { color: var(--gold); }
.victoria-section h2 { text-shadow: 0 5px 0 rgba(20,45,49,.35); }
.victoria-section > p:not(.eyebrow) { max-width: 650px; margin: 1.2rem auto 2rem; font-size: 1.15rem; }
.victoria-rays { position: absolute; left: 50%; top: 43%; z-index: -2; width: 740px; height: 740px; transform: translate(-50%, -50%); border-radius: 50%; background: repeating-conic-gradient(from 0deg, rgba(255,222,126,.12) 0 6deg, transparent 6deg 18deg); animation: rotate 45s linear infinite; }

footer { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 2rem; padding: 2rem clamp(1.25rem, 6vw, 6rem); color: rgba(255, 248, 230, .72); background: #0f292e; font-size: .82rem; }
.footer-brand .brand-top { font-size: 1.4rem; }
.footer-brand .brand-bottom { font-size: .78rem; }
footer > p { margin: 0; }
.copyright { text-align: right; }

@keyframes friendly-bob { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-9px) rotate(.6deg); } }
@keyframes dust { from { transform: translateX(0) scale(.8); opacity: 0; } 20% { opacity: 1; } to { transform: translateX(210px) scale(1.25); opacity: 0; } }
@keyframes villain-peek { 0%, 16%, 86%, 100% { transform: translateX(38px) rotate(2deg); } 35%, 68% { transform: translateX(-8px) rotate(-2deg); } }
@keyframes rotate { to { transform: translate(-50%, -50%) rotate(360deg); } }

@media (max-width: 1000px) {
  .site-header { grid-template-columns: 1fr auto; }
  .site-header nav { display: none; }
  .hero { min-height: 830px; height: auto; }
  .hero-copy { width: min(680px, calc(100% - 2.5rem)); padding-top: 9.5rem; margin-left: 1.25rem; }
  .hero-cast { inset: auto 0 0 18%; height: 55%; }
  .hero-zoobi { left: 4%; width: min(42vw, 380px); }
  .hero-toobi { left: 43%; width: min(24vw, 220px); }
  .hero-jilly { right: 2%; width: min(30vw, 280px); }
  .section-heading { grid-template-columns: 1fr; gap: 1rem; align-items: start; }
  .character-grid { grid-template-columns: 1fr; max-width: 720px; }
  .character-card { display: grid; grid-template-columns: .85fr 1.15fr; }
  .character-art { height: 380px; }
  .character-copy { align-self: center; }
  .character-copy > p:not(.character-number) { min-height: auto; }
  .world-section { grid-template-columns: 1fr; }
  .world-image { min-height: 540px; }
  .world-image::after { box-shadow: inset 0 -70px 100px rgba(20,45,49,.65); }
  .mischief-section { gap: 2rem; }
  footer { grid-template-columns: 1fr; text-align: center; }
  .footer-brand { margin: auto; }
  .copyright { text-align: center; }
}

@media (max-width: 680px) {
  .site-header { min-height: 70px; padding-inline: 1rem; background: rgba(20,45,49,.82); backdrop-filter: blur(8px); }
  .brand-top { font-size: 1.45rem; }
  .brand-bottom { font-size: .82rem; }
  .header-cta { font-size: .68rem; }
  .hero { min-height: 920px; }
  .hero::after { background: linear-gradient(180deg, rgba(15,42,46,.9) 0%, rgba(15,42,46,.55) 56%, rgba(15,42,46,.28) 100%); }
  .hero-copy { width: calc(100% - 2rem); padding-top: 7.8rem; margin-left: 1rem; }
  h1 { font-size: clamp(2.65rem, 11.8vw, 3.35rem); }
  .hero-intro { max-width: 96%; font-size: .98rem; }
  .hero-cast { left: 0; height: 34%; }
  .hero-zoobi { left: 1%; width: min(47vw, 280px); }
  .hero-toobi { left: 41%; width: min(27vw, 155px); }
  .hero-jilly { right: -4%; width: min(34vw, 195px); }
  .hero-sun { display: none; }
  .section { padding: 4.5rem 1rem; }
  .screening-card { padding: .55rem; border-width: 5px; border-radius: 14px; }
  .screening-meta { flex-direction: column; }
  .episode-archive { align-items: stretch; flex-direction: column; }
  .character-card { display: block; }
  .character-art { height: 350px; }
  .world-image { min-height: 420px; }
  .world-copy { padding: 4rem 1.2rem; }
  .world-label { font-size: .7rem; }
  .saloon-label { left: 8%; top: 45%; }
  .victoria-label { right: 8%; top: 15%; }
  .mischief-section { grid-template-columns: 1fr; text-align: center; }
  .mischief-peek { min-height: 360px; }
  .door-frame { width: 220px; height: 320px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
