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

:root {
  --paper: #fff5ec;
  --ink: #1f130f;
  --muted: #5c4a42;
  --accent: #e85d4c;
  --accent-dark: #c73f31;
  --accent-soft: #ffccc2;
  --card: #ffffff;
  --shadow: rgba(31, 19, 15, 0.12);
  --radius: 1.25rem;
  font-family: "Nunito", system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
}

body {
  margin: 0;
  min-height: 100dvh;
  position: relative;
  overflow-x: hidden;
}

.bg-blobs {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 80% 50% at 10% -10%, #ffd8cf 0%, transparent 55%),
    radial-gradient(ellipse 60% 40% at 100% 20%, #ffe8b8 0%, transparent 50%),
    radial-gradient(ellipse 50% 50% at 50% 100%, #c8e8ff 0%, transparent 45%);
  opacity: 0.9;
}

.site-header {
  text-align: center;
  padding: 2rem 1.25rem 1rem;
  max-width: 36rem;
  margin: 0 auto;
}

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

.logo {
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(2rem, 6vw, 2.75rem);
  font-weight: 600;
  font-variation-settings: "SOFT" 100;
  margin: 0 0 0.75rem;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.tagline {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.layout {
  max-width: 42rem;
  margin: 0 auto;
  padding: 0 1rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.panel {
  background: var(--card);
  border-radius: var(--radius);
  padding: 1.35rem 1.25rem 1.5rem;
  box-shadow:
    0 4px 24px var(--shadow),
    0 0 0 1px rgba(255, 255, 255, 0.8) inset;
}

.step {
  position: relative;
}

.step.hidden,
.step[hidden] {
  display: none !important;
}

.step-badge {
  position: absolute;
  top: -0.6rem;
  left: 1rem;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--accent), var(--accent-dark));
  color: #fff;
  font-weight: 800;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(232, 93, 76, 0.45);
}

.step-title {
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.35rem;
  margin: 0.25rem 0 1rem;
  padding-left: 0.25rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--muted);
}

input[type="search"],
select {
  font: inherit;
  padding: 0.65rem 0.85rem;
  border-radius: 0.85rem;
  border: 2px solid #ead5c8;
  background: #fffefb;
  width: 100%;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}

input[type="search"]:focus,
select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.hint {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0.5rem 0 0;
  min-height: 1.35em;
}

.show-list {
  list-style: none;
  margin: 0.75rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 18rem;
  overflow-y: auto;
}

.show-item {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  width: 100%;
  text-align: left;
  padding: 0.6rem 0.75rem;
  border-radius: 0.85rem;
  border: 2px solid transparent;
  background: #fff;
  cursor: pointer;
  font: inherit;
  color: inherit;
  transition:
    border-color 0.15s,
    transform 0.12s;
}

.show-item:hover,
.show-item:focus-visible {
  border-color: var(--accent-soft);
  transform: translateY(-1px);
}

.show-item:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.show-item__thumb {
  width: 2.5rem;
  height: 3.5rem;
  border-radius: 0.35rem;
  object-fit: cover;
  background: #eee;
  flex-shrink: 0;
}

.show-item__body {
  flex: 1;
  min-width: 0;
}

.show-item__title {
  font-weight: 700;
  margin: 0;
  font-size: 1rem;
}

.show-item__sub {
  margin: 0.15rem 0 0;
  font-size: 0.8rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.show-card {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding: 0.75rem;
  background: linear-gradient(135deg, #fffefb, #fff5ef);
  border-radius: 1rem;
  border: 1px solid #f0e0d4;
}

.show-card__media {
  width: 5rem;
  flex-shrink: 0;
  border-radius: 0.65rem;
  overflow: hidden;
  aspect-ratio: 2 / 3;
  background: linear-gradient(145deg, var(--accent-soft), #ffd4c9);
}

.show-card__poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.show-card__fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Fraunces", serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--accent-dark);
}

.show-card__title {
  margin: 0;
  font-size: 1.2rem;
  font-family: "Fraunces", serif;
}

.show-card__meta {
  margin: 0.35rem 0 0.5rem;
  font-size: 0.85rem;
  color: var(--muted);
}

.linkish {
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--accent-dark);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.linkish:hover,
.linkish:focus-visible {
  color: var(--accent);
}

.pick-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

@media (max-width: 520px) {
  .pick-grid {
    grid-template-columns: 1fr;
  }
}

.toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  margin-bottom: 1rem;
  cursor: pointer;
  user-select: none;
}

.toggle input {
  width: 1.15rem;
  height: 1.15rem;
  accent-color: var(--accent);
}

.btn {
  font: inherit;
  font-weight: 800;
  border: none;
  border-radius: 999px;
  padding: 0.85rem 1.5rem;
  cursor: pointer;
  width: 100%;
  transition:
    transform 0.1s,
    box-shadow 0.15s;
}

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.btn-primary {
  background: linear-gradient(180deg, var(--accent), var(--accent-dark));
  color: #fff;
  box-shadow: 0 4px 14px rgba(232, 93, 76, 0.45);
}

.btn-primary:not(:disabled):hover,
.btn-primary:not(:disabled):focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(232, 93, 76, 0.5);
}

.btn-primary:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px var(--accent-soft),
    0 6px 20px rgba(232, 93, 76, 0.5);
}

.recap-lede {
  margin-top: -0.35rem;
  margin-bottom: 0.75rem;
}

.recap-box {
  background: #1f130f;
  color: #fff5ec;
  border-radius: 1rem;
  padding: 1rem 1.15rem;
  min-height: 8rem;
  max-height: min(50vh, 24rem);
  overflow: auto;
  border: 3px solid #3d2e28;
}

.recap-text {
  margin: 0;
  font-family: "Nunito", ui-monospace, monospace;
  font-size: 0.95rem;
  white-space: pre-wrap;
  word-break: break-word;
}

.site-footer {
  max-width: 42rem;
  margin: 0 auto;
  padding: 0 1.25rem 2.5rem;
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
}

.site-footer strong {
  color: var(--ink);
}

.footer-meta {
  margin-top: 0.75rem;
  margin-bottom: 0;
}

.site-footer a {
  color: var(--accent-dark);
  font-weight: 700;
}

@keyframes pop-in {
  from {
    opacity: 0;
    transform: scale(0.98);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.panel:not(.hidden) {
  animation: pop-in 0.35s ease-out;
}
