:root {
    color-scheme: dark;
    --background: #0b0e14;
    --panel: #151a23;
    --border: rgba(255, 255, 255, .08);
    --muted: #9ca3af;
    --accent: #22d3ee;
}
*, *::before, *::after { box-sizing: border-box; }
html { line-height: 1.5; -webkit-text-size-adjust: 100%; }
h1, h2, h3, p { margin: 0; }
img { display: block; max-width: 100%; }
button, input, select, textarea { margin: 0; }
button, select { text-transform: none; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--background); color: #e2e8f0; font-family: 'Inter', sans-serif; min-height: 100vh; -webkit-font-smoothing: antialiased; }
::selection { background: #06b6d4; color: #000; }
a { text-decoration: none; }
button, input, select, textarea { font: inherit; }
a, button, input, select, textarea { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.glass-panel { background: rgba(21, 26, 35, .7); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid var(--border); }
.site-header { position: sticky; top: 0; z-index: 50; border-width: 0 0 1px; }
.header-inner { max-width: 1280px; margin: auto; padding: 0 32px; min-height: 80px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 12px; color: #fff; font-size: 21px; font-weight: 800; letter-spacing: -.6px; flex-shrink: 0; white-space: nowrap; }
.brand img { width: auto; height: 40px; object-fit: contain; }
.brand-accent { color: var(--accent); }
.brand:hover { opacity: .85; }
.site-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.nav-link { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 14px; border: 1px solid transparent; border-radius: 8px; font-size: 14px; font-weight: 500; color: var(--muted); white-space: nowrap; transition: background .2s, color .2s; }
.nav-link i { font-size: 12px; }
.nav-link:hover { background: rgba(255,255,255,.05); color: #fff; }
.nav-link.is-active { color: var(--accent); background: rgba(6,182,212,.1); border-color: rgba(6,182,212,.2); }
.nav-account { display: flex; align-items: center; gap: 12px; margin-left: 8px; padding-left: 16px; border-left: 1px solid var(--border); }
.user-name { color: var(--muted); font-size: 12px; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.logout:hover { color: #f87171; background: rgba(248,113,113,.1); }
.page-content { width: 100%; min-width: 0; max-width: 1280px; margin: 0 auto; padding: 48px 32px; }
.page-content h1 { color: #fff; font-size: clamp(28px, 4vw, 36px); font-weight: 800; letter-spacing: -.8px; line-height: 1.2; margin: 0 0 12px; }
.page-content h2 { color: #fff; font-size: 24px; font-weight: 700; line-height: 1.3; margin: 0 0 12px; }
.page-subtitle { color: var(--muted); font-size: 14px; line-height: 1.7; margin: 0 0 32px; }
.page-content a:not(.btn):not(.filtro-link) { color: var(--accent); }
.page-content a:hover { color: #67e8f9; }
.page-content input:not([type=hidden]), .page-content select, .page-content textarea {
    background: rgba(255,255,255,.04); border: 1px solid var(--border); color: #e2e8f0;
    padding: 12px 14px; border-radius: 12px; font-size: 14px; max-width: 100%; transition: border-color .2s;
}
.page-content input:focus, .page-content select:focus, .page-content textarea:focus { border-color: #06b6d4; outline: 2px solid rgba(6,182,212,.15); outline-offset: 1px; }
.page-content input::placeholder, .page-content textarea::placeholder { color: #6b7280; }
.page-content option { background: #151a23; color: #e2e8f0; }
.page-content label { display: block; font-size: 13px; font-weight: 500; color: #d1d5db; }
.page-content button, .btn { display: inline-flex; justify-content: center; align-items: center; gap: 8px; background: #06b6d4; color: #000; border: 1px solid transparent; padding: 12px 20px; border-radius: 12px; font-size: 14px; font-weight: 600; cursor: pointer; transition: background .2s, transform .2s; }
.page-content button:hover, .page-content .btn:hover { background: #22d3ee; color: #000; }
.page-content button:active, .btn:active { transform: scale(.98); }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 16px; background: var(--panel); }
.tabela { width: 100%; border-collapse: collapse; font-size: 14px; }
.tabela th, .tabela td { padding: 16px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
.tabela th { background: rgba(255,255,255,.025); color: var(--muted); font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .7px; white-space: nowrap; }
.tabela td { line-height: 1.6; overflow-wrap: anywhere; min-width: 90px; }
.tabela tbody tr:last-child td { border-bottom: 0; }
.tabela tbody tr:hover { background: rgba(255,255,255,.025); }
.tabela small { color: var(--muted); font-size: 12px; }
.mini { width: 45px; height: 68px; max-width: none; object-fit: cover; border-radius: 6px; }
.status { display: inline-block; padding: 4px 10px; border-radius: 6px; font-size: 11px; font-weight: 600; text-transform: capitalize; border: 1px solid currentColor; white-space: nowrap; }
.status.pendente { background: #f59e0b15; color: #fbbf24; }
.status.aprovado { background: #10b98115; color: #34d399; }
.status.rejeitado { background: #ef444415; color: #f87171; }
.status.concluido { background: #06b6d415; color: #22d3ee; }
.filtros { display: flex; gap: 8px; margin: 0 0 24px; flex-wrap: wrap; }
.filtros .filtro-link { padding: 9px 16px; background: rgba(255,255,255,.03); border-radius: 10px; border: 1px solid var(--border); color: var(--muted); font-size: 13px; }
.filtros .filtro-link:hover, .filtros .ativo { background: rgba(6,182,212,.1); border-color: rgba(6,182,212,.25); color: var(--accent); }
.inline { display: flex; gap: 8px; }
.page-content .inline select, .page-content .inline button { padding: 8px 10px; font-size: 12px; border-radius: 8px; }
.inline select { min-width: 115px; }
.empty-state { text-align: center; padding: 48px 24px; background: var(--panel); border: 1px solid var(--border); border-radius: 16px; color: var(--muted); line-height: 1.8; }
.empty-state > i { display: block; font-size: 28px; color: var(--accent); margin-bottom: 16px; }
.empty-state p { margin: 0 0 20px; }
.ok, .erro { padding: 14px 16px; border-radius: 12px; margin: 0 0 24px; border: 1px solid; font-size: 14px; line-height: 1.6; }
.ok { color: #6ee7b7; background: #10b98115; border-color: #10b98133; }
.erro { color: #fca5a5; background: #ef444415; border-color: #ef444433; }
.detalhe { display: flex; align-items: flex-start; gap: 32px; margin-bottom: 24px; background: var(--panel); padding: 28px; border: 1px solid var(--border); border-radius: 16px; }
.detalhe > img, .poster-placeholder { width: 200px; aspect-ratio: 2 / 3; border-radius: 12px; object-fit: cover; flex-shrink: 0; }
.poster-placeholder { display: flex; align-items: center; justify-content: center; background: #111827; color: #6b7280; font-size: 36px; }
.detalhe p { color: var(--muted); font-size: 14px; line-height: 1.8; margin: 0 0 16px; white-space: pre-line; }
.detalhe .media-meta { color: var(--accent); }
.detalhe > div:not(.poster-placeholder) { min-width: 0; overflow-wrap: anywhere; }
.form-pedido { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; padding: 28px; border-radius: 16px; border: 1px solid var(--border); background: var(--panel); }
.form-pedido textarea { width: 100%; min-height: 120px; resize: vertical; }
.auth-shell { min-height: calc(100vh - 81px); display: grid; place-items: center; padding: 40px 16px; }
.auth { width: 100%; max-width: 440px; padding: 32px; border-radius: 20px; box-shadow: 0 24px 64px rgba(0,0,0,.25); }
.auth h1 { font-size: 28px; text-align: center; }
.auth .page-subtitle { text-align: center; margin-bottom: 24px; }
.auth-icon { width: 48px; height: 48px; display: grid; place-items: center; margin: 0 auto 20px; color: var(--accent); background: rgba(6,182,212,.1); border: 1px solid rgba(6,182,212,.2); border-radius: 14px; }
.auth form { display: flex; flex-direction: column; gap: 12px; }
.auth label:not(:first-child) { margin-top: 4px; }
.auth button { margin-top: 8px; }
.auth-footer { text-align: center; color: var(--muted); font-size: 13px; margin: 24px 0 0; }
.catalog-page { display: flex; flex-direction: column; }
.catalog-main { width: 100%; max-width: 1280px; margin: 0 auto; padding: 48px 32px; flex: 1; }
.search-hero { max-width: 672px; margin: 0 auto 48px; text-align: center; }
.search-title { margin: 0 0 12px; font-size: 36px; font-weight: 800; line-height: 1.2; letter-spacing: -.8px; color: #fff; }
.search-description { color: var(--muted); font-size: 16px; }
.search-form { display: flex; align-items: stretch; gap: 8px; padding: 8px; margin-top: 32px; border-radius: 16px; box-shadow: 0 24px 48px rgba(0,0,0,.25); }
.search-field { position: relative; flex: 1; min-width: 0; }
.search-icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: #6b7280; font-size: 14px; pointer-events: none; }
.search-input { width: 100%; min-width: 0; height: 100%; padding: 12px 16px 12px 44px; background: transparent; color: #fff; border: 1px solid transparent; border-radius: 12px; font-size: 14px; }
.search-input::placeholder { color: #6b7280; }
.search-filter { max-width: 100%; padding: 12px 16px; border: 1px solid var(--border); border-radius: 12px; background: rgba(255,255,255,.05); color: #d1d5db; font-size: 14px; cursor: pointer; }
.search-option { background: #111827; color: #e2e8f0; }
.search-button { padding: 12px 24px; background: #06b6d4; color: #000; font-size: 14px; font-weight: 600; border: 1px solid transparent; border-radius: 12px; cursor: pointer; box-shadow: 0 8px 16px rgba(6,182,212,.15); }
.search-button:hover { background: #22d3ee; }
.search-status { text-align: center; font-size: 14px; color: var(--muted); margin: 0 0 24px; }
.search-status:empty { display: none; }
.search-empty { max-width: 448px; margin: 48px auto; padding: 16px; border: 1px solid var(--border); border-radius: 12px; background: rgba(255,255,255,.05); color: var(--muted); font-size: 14px; text-align: center; }
.info-icon { color: var(--accent); margin-right: 6px; }
.catalog-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 24px; }
.media-card { min-width: 0; display: flex; flex-direction: column; overflow: hidden; background: var(--panel); border: 1px solid var(--border); border-radius: 12px; transition: border-color .2s; }
.media-card:hover { border-color: rgba(6,182,212,.3); }
.media-cover { position: relative; width: 100%; aspect-ratio: 2 / 3; overflow: hidden; background: #111827; }
.media-poster { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.media-card:hover .media-poster { transform: scale(1.05); }
.media-no-poster { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; width: 100%; height: 100%; color: #6b7280; }
.media-no-poster i { font-size: 24px; }
.poster-caption { font-size: 12px; }
.media-gradient { position: absolute; inset: 0; background: linear-gradient(to top, #151a23, transparent 50%, rgba(0,0,0,.4)); pointer-events: none; }
.media-type, .media-rating { position: absolute; top: 10px; padding: 2px 8px; border-radius: 4px; background: rgba(0,0,0,.6); border: 1px solid rgba(255,255,255,.1); backdrop-filter: blur(12px); }
.media-type { left: 10px; color: #fff; font-size: 10px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; }
.media-rating { right: 10px; display: flex; align-items: center; gap: 4px; color: #fbbf24; font-size: 11px; font-weight: 600; }
.media-rating i { font-size: 9px; }
.media-body { display: flex; flex-direction: column; justify-content: space-between; flex: 1; padding: 16px; }
.media-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 600; color: #fff; }
.media-card:hover .media-title { color: var(--accent); }
.media-year { margin-top: 2px; font-size: 12px; color: var(--muted); }
.media-synopsis { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; margin-top: 8px; font-size: 12px; line-height: 1.6; color: var(--muted); }
.media-request { display: block; width: 100%; margin-top: 16px; padding: 8px 12px; border: 1px solid rgba(255,255,255,.1); border-radius: 8px; background: rgba(255,255,255,.05); color: #fff; text-align: center; font-size: 12px; font-weight: 600; transition: background .2s, color .2s; }
.media-request:hover { background: #06b6d4; border-color: #06b6d4; color: #000; }
@media (max-width: 1023px) { .catalog-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 767px) { .catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px) { .user-name { display: none; } }
@media (max-width: 640px) {
    .header-inner { padding: 16px; flex-direction: column; gap: 14px; }
    .site-nav { width: 100%; justify-content: center; gap: 4px; }
    .nav-link { padding: 9px 8px; font-size: 12px; gap: 6px; }
    .nav-account { padding-left: 5px; margin-left: 0; }
    .page-content { padding: 32px 16px; }
    .detalhe { flex-direction: column; padding: 20px; gap: 24px; }
    .detalhe > img, .poster-placeholder { align-self: center; width: 180px; }
    .form-pedido { padding: 20px; }
    .form-pedido button { width: 100%; }
    .auth { padding: 28px 24px; }
    .auth-shell { min-height: calc(100vh - 132px); }
    .tabela th, .tabela td { padding: 12px; }
    .catalog-main { padding: 32px 16px; }
    .search-title { font-size: 30px; }
    .search-description { font-size: 14px; }
    .search-form { flex-direction: column; }
    .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
    .media-body { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; animation: none !important; }
}
