/* Site público — Tutoriais VOWT. Tema escuro estilo Netflix (full-bleed), azul VOWT. */
:root {
    --bg: #18191b;
    --surface: #202125;
    --surface-2: #2a2c31;
    --text: #f5f5f7;
    --muted: #9aa0ad;
    --border: #32343a;
    --primary: #2f6bed;
    --primary-600: #4f86f5;
    --ring: rgba(47, 107, 237, .45);
    --shadow: 0 6px 20px rgba(0, 0, 0, .45);
    --shadow-lg: 0 22px 55px rgba(0, 0, 0, .65);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--text);
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased; }
img { display: block; }
a { color: inherit; text-decoration: none; }

.site-main { width: 100%; }

/* ================= HERO / BILLBOARD ================= */
/* Altura baseada na LARGURA (vw), não em vh — estável dentro de iframe com altura dinâmica. */
.hero { position: relative; width: 100%; height: clamp(340px, 42vw, 560px); display: flex; align-items: flex-end; overflow: hidden; }
.hero__bg { position: absolute; inset: 0; background-size: cover; background-position: center right; }
.hero::after { content: ""; position: absolute; inset: 0; pointer-events: none;
    background:
        linear-gradient(90deg, var(--bg) 0%, rgba(24,25,27,.85) 26%, rgba(24,25,27,.25) 56%, rgba(24,25,27,0) 78%),
        linear-gradient(0deg, var(--bg) 2%, rgba(24,25,27,0) 38%); }

/* Ferramentas (busca + filtro) sobre o hero, topo-direita (como a nav da Netflix) */
.hero__tools { position: absolute; top: 1rem; right: clamp(1rem, 3vw, 2.5rem); z-index: 4;
    display: flex; gap: .5rem; flex-wrap: wrap; justify-content: flex-end; }

/* Conteúdo do destaque, embaixo-esquerda */
.hero__inner { position: relative; z-index: 2; padding: 0 clamp(1.25rem, 4vw, 3.5rem) clamp(1.5rem, 4vw, 3rem);
    max-width: 640px; }
.hero__kicker { display: flex; align-items: center; gap: .55rem; margin-bottom: .8rem; }
.hero__kicker img { height: 18px; width: auto; }
.hero__kicker span { font-size: .75rem; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.hero__title { font-size: clamp(1.9rem, 4.5vw, 3.4rem); font-weight: 800; line-height: 1.05; margin: 0 0 .55rem;
    text-shadow: 0 2px 12px rgba(0,0,0,.5); }
.hero__meta { display: inline-block; font-size: .82rem; font-weight: 700; letter-spacing: .03em; color: #fff;
    background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.2); padding: .15rem .6rem; border-radius: 6px; margin-bottom: .9rem; }
.hero__desc { color: #e3e7ee; margin: 0 0 1.3rem; max-width: 560px; font-size: 1.02rem; line-height: 1.5;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; text-shadow: 0 1px 6px rgba(0,0,0,.5); }
.btn-play { display: inline-flex; align-items: center; gap: .5rem; background: var(--primary); color: #fff; border: none;
    padding: .8rem 1.9rem; border-radius: 8px; font-size: 1.05rem; font-weight: 700; cursor: pointer; text-decoration: none; }
.btn-play:hover { background: var(--primary-600); }

/* Logo VOWT no canto inferior-direito (como o "NETFLIX" da print) */
.corner-logo { position: absolute; right: clamp(1rem, 3vw, 2.5rem); bottom: clamp(1rem, 3vw, 2rem); z-index: 3;
    height: 30px; width: auto; opacity: .95; }

/* ================= BUSCA / FILTRO ================= */
.search { display: flex; gap: .4rem; }
.search input { width: min(260px, 40vw); padding: .55rem .85rem; border-radius: 10px; border: 1px solid var(--border);
    background: rgba(20,21,23,.7); color: var(--text); font-size: .92rem; backdrop-filter: blur(4px); }
.search input::placeholder { color: var(--muted); }
.search input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--ring); background: rgba(20,21,23,.9); }
.search__btn { display: inline-flex; align-items: center; gap: .4rem; padding: 0 .9rem; border: none; border-radius: 10px;
    background: var(--primary); color: #fff; font-size: .9rem; font-weight: 600; cursor: pointer; white-space: nowrap; }
.search__btn:hover { background: var(--primary-600); }
.filter { padding: .5rem 2.1rem .5rem .8rem; border-radius: 10px; border: 1px solid var(--border);
    background: rgba(20,21,23,.7) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%239aa0ad' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E") right .55rem center/18px no-repeat;
    color: var(--text); font-size: .9rem; appearance: none; cursor: pointer; backdrop-filter: blur(4px); }
.filter:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--ring); }

/* ================= FILEIRAS (carrossel) ================= */
.rows { padding: 1.5rem clamp(1.25rem, 3.5vw, 3.5rem) 3.5rem; }
.row { margin-bottom: 2rem; }
.row__head { display: flex; align-items: center; gap: .75rem; margin: 0 0 .7rem; }
.row__name { font-size: 1.25rem; font-weight: 700; margin: 0; line-height: 1.3; }
.row__nav { display: flex; gap: .4rem; margin-left: auto; }
.row__arrow { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--border); background: var(--surface-2);
    color: var(--text); cursor: pointer; font-size: 1.1rem; line-height: 1; display: flex; align-items: center; justify-content: center; }
.row__arrow:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.row__track { display: flex; gap: .9rem; overflow-x: auto; padding: .35rem .15rem 1rem; cursor: grab;
    scroll-behavior: smooth; scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
    scrollbar-width: none; -ms-overflow-style: none; }
.row__track.is-grabbing { cursor: grabbing; scroll-behavior: auto; scroll-snap-type: none; user-select: none; }
.row__track::-webkit-scrollbar { display: none; } /* esconde a barra (scroll por arraste/setas/touch) */

/* ================= CARD (Netflix: só a imagem + título sobreposto) ================= */
.card { flex: 0 0 auto; width: 280px; scroll-snap-align: start; position: relative; border: none; padding: 0; cursor: pointer;
    border-radius: 6px; overflow: hidden; background: #000; aspect-ratio: 16 / 9; text-align: left;
    box-shadow: var(--shadow); transition: transform .2s ease, box-shadow .2s ease; }
.card:hover, .card:focus-visible { transform: scale(1.08); box-shadow: var(--shadow-lg); outline: none; z-index: 5; }
.card:focus-visible { box-shadow: 0 0 0 3px var(--ring), var(--shadow-lg); }
.card__thumb { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.card::after { content: ""; position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(to top, rgba(0,0,0,.9) 0%, rgba(0,0,0,.15) 42%, rgba(0,0,0,0) 66%); }
.card__title { position: absolute; left: .7rem; right: .7rem; bottom: .55rem; z-index: 2; color: #fff;
    font-size: .9rem; font-weight: 600; line-height: 1.3; text-shadow: 0 1px 4px rgba(0,0,0,.7);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ================= BUSCA (grade) ================= */
.toolbar { display: flex; align-items: center; gap: .75rem; padding: 1.25rem clamp(1.25rem, 3.5vw, 3.5rem) 0; flex-wrap: wrap; }
.toolbar__spacer { flex: 1; }
.search-page { padding: 1.5rem clamp(1.25rem, 3.5vw, 3.5rem) 3.5rem; }
.search-page h1 { font-size: 1.5rem; margin: 1.25rem 0 1.25rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1rem; }
.grid .card { width: auto; }

/* ================= ESTADOS VAZIOS ================= */
.empty { text-align: center; padding: 5rem 1.5rem; color: var(--muted); }
.empty h2 { color: var(--text); margin-top: 0; }
.muted { color: var(--muted); }

/* ================= TEATRO (player + lista lateral) ================= */
.theater { position: fixed; inset: 0; z-index: 60; display: none; }
.theater.is-open { display: block; }
.theater__backdrop { position: absolute; inset: 0; background: #0a0a0c; }
.theater__dialog { position: absolute; inset: 0; display: flex; background: #0a0a0c; }
.theater__close { position: absolute; top: .8rem; right: 1rem; z-index: 5; width: 42px; height: 42px; border-radius: 50%;
    border: none; background: rgba(0,0,0,.55); color: #fff; font-size: 1.7rem; line-height: 1; cursor: pointer; }
.theater__close:hover { background: var(--primary); }
.theater__main { flex: 1; min-width: 0; overflow-y: auto; padding: clamp(1rem, 3vw, 2.5rem); display: flex; flex-direction: column; justify-content: center; }
.theater__video { width: 100%; max-width: 1100px; margin: 0 auto; aspect-ratio: 16 / 9; background: #000; border-radius: 10px; overflow: hidden; position: relative; }
.theater__video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.theater__title { width: 100%; max-width: 1100px; margin: 1rem auto .3rem; font-size: 1.3rem; }
.theater__desc { width: 100%; max-width: 1100px; margin: 0 auto; color: var(--muted); }
.theater__side { width: 360px; flex-shrink: 0; background: var(--surface); border-left: 1px solid var(--border); overflow-y: auto; padding: 1rem; }
.theater__side-title { font-weight: 700; margin: .25rem .25rem 1rem; }
.theater__list { display: flex; flex-direction: column; gap: .5rem; }
.theater__item { display: flex; gap: .65rem; padding: .4rem; border-radius: 8px; cursor: pointer; background: transparent;
    border: none; text-align: left; color: var(--text); width: 100%; align-items: flex-start; }
.theater__item:hover { background: var(--surface-2); }
.theater__item.is-active { background: rgba(47, 107, 237, .2); }
.theater__item img { width: 120px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; flex-shrink: 0; background: #000; }
.theater__item span { font-size: .85rem; font-weight: 600; line-height: 1.3;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

@media (max-width: 820px) {
    .theater__dialog { flex-direction: column; }
    .theater__main { flex: none; justify-content: flex-start; padding: 1rem; padding-top: 3.2rem; }
    .theater__side { width: 100%; border-left: none; border-top: 1px solid var(--border); }
}

/* ================= RESPONSIVO ================= */
@media (max-width: 720px) {
    .hero { height: clamp(300px, 64vw, 460px); }
    .hero__title { font-size: 1.8rem; }
    .hero__desc { -webkit-line-clamp: 2; font-size: .95rem; }
    .hero__tools { top: .75rem; right: .75rem; left: .75rem; }
    .search input { width: 100%; flex: 1; }
    .search { flex: 1; }
    .corner-logo { height: 22px; }
    .card { width: 66vw; max-width: 300px; }
    .grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
}
