/* ---------- Base ---------- */
:root {
  --bg: #1f201f;
  --bar: #4b4d4c;
  --panel: #262726;
  --panel-2: #2d2e2d;
  --line: rgba(98, 201, 133, 0.22);
  --text: #e9e9e9;
  --muted: rgba(233, 233, 233, 0.55);
  --muted-2: rgba(233, 233, 233, 0.35);
  --accent: #62c985;
  --warn: #f0ef00;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  --radius: 8px;
}

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

html,
body {
  height: 100%;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(1200px, calc(100% - 40px));
  margin: 0 auto;
}

/* ---------- Top bar ---------- */
.topbar {
  background: var(--bar);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.topbar__inner {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 14px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.8px;
}

.brand__mark {
  width: 28px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.18);
}

.brand__mark svg {
  fill: rgba(255, 255, 255, 0.85);
}

.brand__name {
  font-size: 22px;
  color: rgba(150, 215, 175, 0.95);
}

/* Nav */
.nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 16px;
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: 0.9px;
  color: rgba(255, 255, 255, 0.85);
}

.nav__link {
  opacity: 0.9;
  padding: 8px 10px;
  border-radius: 6px;
}

.nav__link:hover {
  background: rgba(0, 0, 0, 0.14);
}

.nav__group {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav__link--active {
  outline: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.12);
}

.nav__dots {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 30px;
  border: 0;
  background: rgba(0, 0, 0, 0.12);
  outline: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 6px;
  cursor: pointer;
}

.nav__dots span {
  width: 3px;
  height: 3px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 999px;
  display: inline-block;
  margin: 0 1px;
}

.mobileNav {
  display: none;
  background: var(--bar);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.mobileNav__inner {
  padding: 8px 0;
}

.mobileNav__nav {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.mobileNav__nav::-webkit-scrollbar {
  height: 4px;
}

.mobileNav__nav::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
}

.mobileNav__nav .nav__link {
  flex: 0 0 auto;
  white-space: nowrap;
}

.topbar__searchToggle {
  display: none;
  margin-left: auto;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  padding: 6px 12px;
  background: rgba(0, 0, 0, 0.2);
  color: rgba(255, 255, 255, 0.9);
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  cursor: pointer;
}

.topbar__searchToggle:hover {
  background: rgba(0, 0, 0, 0.35);
}

.topbar__searchToggleIcon svg {
  fill: currentColor;
}

/* ---------- Search row ---------- */
.searchRow {
  padding: 16px 0 4px;
}

.searchRow__inner {
  display: flex;
  justify-content: center;
}

.search {
  width: min(420px, 100%);
}

.search__input {
  width: 100%;
  height: 34px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  padding: 0 12px;
  outline: none;
}

.search__input::placeholder {
  color: rgba(255, 255, 255, 0.35);
  font-style: italic;
}

/* ---------- Main ---------- */
.main {
  padding: 14px 0 28px;
}

.notice {
  background: var(--warn);
  color: #111;
  border-radius: 4px;
  padding: 10px 12px;
  font-size: 14px;
  text-align: center;
  box-shadow: var(--shadow);
  margin: 10px auto 16px;
}

/* Layout */
.layout {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 18px;
  align-items: start;
}

.layout--single {
  grid-template-columns: minmax(0, 1fr);
}

/* Sticky sidebar (desktop) */
@media (min-width: 921px) {
  .panel--side {
    position: sticky;
    top: 14px;
    align-self: start;
    max-height: calc(100vh - 28px);
  }

  .panel--side .top {
    max-height: calc(100vh - 28px - 46px); /* viewport - margins - header */
    overflow: auto;
  }
}


/* Panels */
.panel {
  background: rgba(0, 0, 0, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel__header {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.05);
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.panel__header--side {
  justify-content: flex-start;
}

.panel__icon svg {
  fill: rgba(255, 255, 255, 0.55);
}

.panel__title {
  margin: 0;
  font-size: 14px;
  letter-spacing: 0.9px;
  font-style: italic;
  color: rgba(255, 255, 255, 0.55);
}

.panel__body {
  padding: 16px;
}

.panel__empty {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

/* Search posters */
.posterGrid {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 18px 14px;
  justify-items: center;
}

.posterGrid__item {
  width: 100%;
  max-width: 150px;
}

.posterGrid__link {
  display: grid;
  gap: 8px;
  text-align: center;
}

.posterGrid__media {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
}

.posterGrid__poster {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: var(--shadow);
}

.posterGrid__title {
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  word-break: break-word;
  line-height: 1.35;
}

.posterOverlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(8, 8, 12, 0.55);
  color: #fff;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.posterOverlay svg {
  fill: currentColor;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.35));
}

.carousel__link:hover .posterOverlay,
.carousel__link:focus-visible .posterOverlay,
.posterGrid__link:hover .posterOverlay,
.posterGrid__link:focus-visible .posterOverlay,
.detail__media:hover .posterOverlay,
.detail__media:focus-within .posterOverlay {
  opacity: 1;
}

.detail__media {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  max-width: 260px;
}

.detail__media img {
  display: block;
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: var(--shadow);
}

.posterBadge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: lowercase;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25);
}

/* Left list */
.list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.list__item {
  border-top: 1px solid var(--line);
}

.list__item:first-child {
  border-top: 0;
}

.list__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.10);
}

.list__link:hover {
  background: rgba(255, 255, 255, 0.04);
}

.list__name {
  font-size: 14px;
  font-weight: 650;
  color: rgba(255, 255, 255, 0.9);
}

.list__meta {
  font-size: 12px;
  font-style: italic;
  color: rgba(255, 255, 255, 0.35);
}

/* Right "Top" */
.top {
  margin: 0;
  padding: 0;
  list-style: none;
}

.top__item {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.top__item:first-child {
  border-top: 0;
}

.top__link {
  display: block;
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.10);
}

.top__link:hover {
  background: rgba(255, 255, 255, 0.04);
}

.top__kicker {
  display: flex;
  align-items: baseline;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
}

.top__num {
  min-width: 18px;
  color: rgba(255, 255, 255, 0.55);
}

.top__cat {
  color: rgba(255, 255, 255, 0.4);
}

.top__title {
  margin-top: 6px;
  font-weight: 750;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.9);
}

.top__badge {
  margin-top: 8px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 750;
  color: var(--accent);
}

.badge svg {
  fill: var(--accent);
}

/* ---------- Bottom text zone (full width in layout) ---------- */
.bottomText {
  padding: 18px 0 22px;
}

.bottomText__panel {
  background: rgba(0, 0, 0, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px;
}

.bottomText__header {
  margin-bottom: 10px;
}

.bottomText__title {
  margin: 0;
  font-size: 16px;
  letter-spacing: 0.3px;
}

.bottomText__subtitle {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.bottomText__content {
  margin: 12px 0 0;
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}

.bottomText__label {
  display: block;
  margin-top: 12px;
  margin-bottom: 8px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.9px;
  color: rgba(255, 255, 255, 0.7);
}

.bottomText__input {
  width: 100%;
  resize: vertical;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  padding: 12px;
  outline: none;
}

.bottomText__input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.bottomText__input:focus {
  outline: 2px solid rgba(98, 201, 133, 0.45);
  outline-offset: 2px;
}

.bottomText__hint {
  margin-top: 10px;
  color: var(--muted-2);
  font-size: 12px;
}

/* ---------- Footer ---------- */
.footer {
  color: var(--muted-2);
}

.footer__top {
  padding: 22px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.12);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 18px;
  align-items: start;
}

.footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.8px;
}

.footer__mark {
  width: 28px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.18);
}

.footer__mark svg {
  fill: rgba(255, 255, 255, 0.85);
}

.footer__name {
  color: rgba(150, 215, 175, 0.95);
}

.footer__text {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 13px;
  line-height: 1.5;
}

.footer__heading {
  margin: 0 0 10px;
  font-size: 12px;
  letter-spacing: 0.9px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}

.footer__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer__list li + li {
  margin-top: 8px;
}

.footer__link {
  display: inline-flex;
  color: rgba(255, 255, 255, 0.72);
  padding: 2px 0;
}

.footer__link:hover {
  color: rgba(98, 201, 133, 0.9);
}

.footer__bottom {
  padding: 14px 0 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.10);
}

.footer__bottomInner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.footer__bottomInner--centered {
  justify-content: center;
}

.footer__bottomInner--centered .footer__copyright {
  width: 100%;
  display: flex;
  justify-content: center;
}

.footer__copyright {
  color: rgba(255, 255, 255, 0.55);
}

.footer__protection {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.6rem;
  padding: 0.5rem 0 1rem;
}

.footer__protectionLogo {
  width: auto;
  max-height: 120px;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.35));
}

.footer__protectionText {
  margin: 0;
  max-width: 520px;
  color: #b6b6b6;
  line-height: 1.5;
}

.footer__protectionLink {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: #e8e8e8;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.01em;
  transition: background 0.2s ease, color 0.2s ease;
}

.footer__protectionLink:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
}

.footer__mini {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.footer__miniLink {
  color: rgba(255, 255, 255, 0.65);
}

.footer__miniLink:hover {
  color: rgba(98, 201, 133, 0.9);
}

.footer__dot {
  color: rgba(255, 255, 255, 0.25);
}

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

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  :root {
    --topbar-height: 64px;
  }
  body {
    padding-top: var(--topbar-height);
  }
  .nav {
    display: none;
  }
  .mobileNav {
    display: block;
  }
  .layout {
    grid-template-columns: 1fr;
  }
  .topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
  }
  .searchRow {
    scroll-margin-top: calc(var(--topbar-height) + 12px);
  }
  .topbar__searchToggle {
    display: none;
  }
  .is-scrolled .topbar__searchToggle {
    display: inline-flex;
  }
}


/* ---------- Hero / Carousel ---------- */
.hero {
  margin: 8px 0 16px;
}

.hero__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 10px;
}

.hero__title {
  margin: 0;
  font-size: 18px;
  letter-spacing: 0.4px;
}

.hero__subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.carousel {
  position: relative;
  background: rgba(0, 0, 0, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 10px 44px;
}

.carousel__viewport {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.carousel__viewport:focus {
  outline: 2px solid rgba(98, 201, 133, 0.45);
  outline-offset: 3px;
  border-radius: 10px;
}

.carousel__track {
  display: flex;
  gap: 12px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.carousel__slide {
  flex: 0 0 auto;
  width: 140px;
  scroll-snap-align: start;
}

.carousel__media {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
}

.carousel__poster {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  display: block;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.carousel__caption {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.carousel__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(0, 0, 0, 0.35);
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
}

.carousel__btn:hover {
  background: rgba(0, 0, 0, 0.55);
}

.carousel__btn--prev {
  left: 8px;
}

.carousel__btn--next {
  right: 8px;
}

/* ---------- Buttons / Footer panel ---------- */
.panel__footer {
  display: flex;
  justify-content: center;
  padding: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.10);
}

.btn {
  border: 0;
  border-radius: 8px;
  padding: 10px 14px;
  cursor: pointer;
  font-weight: 750;
  letter-spacing: 0.2px;
}

.btn--primary {
  background: rgba(98, 201, 133, 0.18);
  color: rgba(255, 255, 255, 0.9);
  outline: 1px solid rgba(98, 201, 133, 0.35);
}

.btn--primary:hover {
  background: rgba(98, 201, 133, 0.28);
}

.btn__meta {
  display: inline-block;
  margin-left: 10px;
  font-weight: 650;
  color: rgba(255, 255, 255, 0.7);
  font-size: 12px;
}

@media (max-width: 520px) {
  .carousel {
    padding: 10px 40px;
  }
  .carousel__slide {
    width: 128px;
  }
  .hero__header {
    flex-direction: column;
    align-items: flex-start;
  }
}
