*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

html{
    scroll-behavior:smooth;
}

body{
    min-height:100vh;
    font-family:Arial,Helvetica,sans-serif;
    background:
        linear-gradient(
            180deg,
            #eef3ff 0%,
            #f7f9fc 34%,
            #ffffff 100%
        );
    color:#111827;
}

/* =========================
   TOPO
========================= */

.topbar{
    min-height:72px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:0 40px;
    background:#ffffff;
    border-bottom:1px solid #e5e7eb;
    box-shadow:0 1px 0 rgba(17,24,39,.03);
}

.brand{
    color:#e50914;
    text-decoration:none;
    font-size:28px;
    font-weight:900;
    letter-spacing:.2px;
}

.top-link{
    color:#111827;
    text-decoration:none;
    font-weight:700;
    padding:10px 16px;
    border:1px solid #d1d5db;
    border-radius:6px;
    background:#ffffff;
    transition:.2s;
}

.top-link:hover{
    border-color:#e50914;
    color:#e50914;
}

/* =========================
   ESTRUTURA
========================= */

.page{
    max-width:1120px;
    margin:auto;
    padding:64px 20px 90px;
}

.card{
    background:#ffffff;
    border:1px solid #e5e7eb;
    border-radius:18px;
    padding:42px;
    box-shadow:0 18px 50px rgba(17,24,39,.08);
}

.login-card{
    max-width:560px;
    margin:auto;
}

.eyebrow{
    color:#e50914;
    font-size:13px;
    font-weight:900;
    letter-spacing:1.5px;
    margin-bottom:14px;
}

h1{
    color:#111827;
    font-size:38px;
    line-height:1.15;
    margin-bottom:14px;
}

h2{
    color:#111827;
    font-size:24px;
    margin-bottom:18px;
}

p{
    color:#4b5563;
    line-height:1.6;
}

/* =========================
   FORMULÁRIOS
========================= */

.form{
    display:grid;
    gap:12px;
    margin-top:30px;
}

label{
    color:#111827;
    font-size:14px;
    font-weight:700;
}

input,
select,
textarea{
    width:100%;
    border:1px solid #d1d5db;
    border-radius:10px;
    background:#ffffff;
    color:#111827;
    padding:15px 16px;
    font-size:16px;
    outline:none;
    transition:.2s;
}

input::placeholder,
textarea::placeholder{
    color:#9ca3af;
}

input:focus,
select:focus,
textarea:focus{
    border:2px solid transparent;
    background:
        linear-gradient(#ffffff,#ffffff) padding-box,
        linear-gradient(
            90deg,
            #e50914,
            #db2777,
            #8b5cf6,
            #2563eb
        ) border-box;
    box-shadow:0 8px 24px rgba(37,99,235,.08);
}

textarea{
    min-height:130px;
    resize:vertical;
}

/* =========================
   BOTÕES
========================= */

.btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border:none;
    border-radius:8px;
    padding:14px 20px;
    text-decoration:none;
    font-weight:800;
    cursor:pointer;
    transition:.2s;
}

.primary{
    background:#e50914;
    color:#ffffff;
    box-shadow:0 10px 22px rgba(229,9,20,.18);
}

.primary:hover{
    background:#c40710;
    transform:translateY(-1px);
}

.dark{
    background:#ffffff;
    color:#111827;
    border:1px solid #d1d5db;
}

.dark:hover{
    border-color:#e50914;
    color:#e50914;
    background:#fff7f7;
}

/* =========================
   TRIAGEM
========================= */

.choice-grid{
    display:grid;
    grid-template-columns:repeat(2,1fr);
    gap:18px;
    margin-top:30px;
}

.choice{
    display:block;
    width:100%;
    min-height:175px;
    padding:26px;
    border:1px solid #e5e7eb;
    border-radius:16px;
    background:#ffffff;
    color:#111827;
    text-align:left;
    text-decoration:none;
    cursor:pointer;
    transition:.22s;
    box-shadow:0 8px 24px rgba(17,24,39,.05);
}

.choice:hover{
    border-color:#e50914;
    transform:translateY(-3px);
    box-shadow:0 16px 34px rgba(17,24,39,.10);
}

.choice span{
    display:block;
    font-size:32px;
    margin-bottom:16px;
}

.choice strong{
    display:block;
    color:#111827;
    font-size:20px;
    margin-bottom:8px;
}

.choice small{
    color:#6b7280;
    line-height:1.45;
}

.subpanel{
    display:none;
    margin-top:26px;
    padding:24px;
    border-radius:14px;
    background:#f8fafc;
    border:1px solid #e5e7eb;
}

.subpanel.active{
    display:block;
}

.actions{
    display:flex;
    flex-wrap:wrap;
    gap:12px;
}

/* =========================
   ALERTAS
========================= */

.alert{
    background:#fff1f2;
    border:1px solid #fecdd3;
    color:#9f1239;
    padding:14px 16px;
    border-radius:10px;
    margin-top:18px;
}

.placeholder{
    margin-top:24px;
    padding:20px;
    border-radius:12px;
    background:#f8fafc;
    border:1px dashed #cbd5e1;
    color:#475569;
}

/* =========================
   BUSCA
========================= */

.search-area,
.tmdb-search-area{
    margin-top:30px;
}

.search-area input,
.tmdb-search-area input{
    border:2px solid transparent;
    background:
        linear-gradient(#ffffff,#ffffff) padding-box,
        linear-gradient(
            90deg,
            #e50914 0%,
            #db2777 35%,
            #8b5cf6 68%,
            #2563eb 100%
        ) border-box;
    box-shadow:0 10px 28px rgba(17,24,39,.08);
}

.search-status{
    min-height:22px;
    margin:12px 0;
    color:#6b7280;
    font-size:14px;
}

/* =========================
   CARDS DE CONTEÚDO
========================= */

.catalog-results,
.tmdb-results{
    display:grid;
    grid-template-columns:repeat(auto-fill,minmax(190px,1fr));
    gap:20px;
    margin-top:20px;
}

.catalog-card,
.tmdb-card{
    width:100%;
    min-height:395px;
    display:flex;
    flex-direction:column;
    overflow:hidden;
    border:1px solid #e5e7eb;
    border-radius:14px;
    background:#ffffff;
    color:#111827;
    text-align:left;
    cursor:pointer;
    transition:.22s;
    box-shadow:0 10px 28px rgba(17,24,39,.06);
}

.catalog-card:hover,
.tmdb-card:hover{
    transform:translateY(-4px);
    border-color:#e50914;
    box-shadow:0 18px 38px rgba(17,24,39,.12);
}

.catalog-card:focus,
.tmdb-card:focus{
    outline:2px solid #e50914;
    outline-offset:3px;
}

.poster-wrap{
    width:100%;
    height:275px;
    min-height:275px;
    overflow:hidden;
    background:#eef2f7;
}

.poster-wrap img{
    width:100%;
    height:100%;
    display:block;
    object-fit:cover;
    object-position:center;
}

.poster-placeholder{
    width:100%;
    height:100%;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:18px;
    color:#94a3b8;
    font-size:14px;
    text-align:center;
    background:#f1f5f9;
}

.catalog-info{
    width:100%;
    min-width:0;
    padding:16px;
    display:flex;
    flex-direction:column;
    flex:1;
}

.catalog-info strong{
    color:#111827;
    font-size:17px;
    line-height:1.3;
    margin-bottom:7px;
    min-height:44px;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
}

.catalog-info small{
    color:#6b7280;
    font-size:13px;
    line-height:1.35;
    margin-bottom:12px;
    min-height:18px;
    overflow:hidden;
    white-space:nowrap;
    text-overflow:ellipsis;
}

.catalog-meta{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:8px;
    margin-top:auto;
    color:#4b5563;
    font-size:13px;
}

/* =========================
   SELOS
========================= */

.active-badge,
.catalog-active,
.catalog-inactive,
.catalog-missing{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    padding:5px 9px;
    border-radius:999px;
    font-size:11px;
    font-weight:800;
}

.active-badge,
.catalog-active{
    background:#dcfce7;
    color:#166534;
}

.catalog-inactive{
    background:#fef3c7;
    color:#92400e;
}

.catalog-missing{
    background:#dbeafe;
    color:#1d4ed8;
}

.request-status{
    margin-top:12px;
}

/* =========================
   SELEÇÃO E FORMULÁRIO
========================= */

.selected-content{
    margin-top:26px;
    padding:17px;
    border-left:4px solid #e50914;
    border-radius:10px;
    background:#fff7f7;
    color:#111827;
}

.report-form{
    display:grid;
    gap:14px;
    margin-top:26px;
}

.form-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:18px;
}

.scope-options{
    display:flex;
    flex-direction:column;
    gap:10px;
    padding:16px;
    border-radius:10px;
    background:#f8fafc;
    border:1px solid #e5e7eb;
}

.scope-options label{
    display:flex;
    align-items:center;
    gap:10px;
    font-weight:400;
}

.scope-options input{
    width:auto;
}

.disabled-field{
    opacity:.5;
}

.form-message{
    min-height:20px;
    color:#be123c;
}

.existing-notice{
    padding:15px;
    border-radius:10px;
    line-height:1.5;
}

.notice-error{
    background:#fff1f2;
    border:1px solid #fecdd3;
    color:#9f1239;
}

.notice-warning{
    background:#fffbeb;
    border:1px solid #fde68a;
    color:#92400e;
}

.notice-ok{
    background:#f0fdf4;
    border:1px solid #bbf7d0;
    color:#166534;
}

/* =========================
   SUCESSO
========================= */

.success-box{
    margin-top:28px;
    padding:38px;
    border-radius:16px;
    background:#ffffff;
    border:1px solid #e5e7eb;
    text-align:center;
    box-shadow:0 14px 34px rgba(17,24,39,.08);
}

.success-icon{
    width:80px;
    height:80px;
    margin:0 auto 18px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#e50914;
    color:#ffffff;
    font-size:42px;
    font-weight:900;
    box-shadow:0 12px 28px rgba(229,9,20,.20);
}

.success-box .btn{
    margin-top:20px;
}

/* =========================
   RESPONSIVO
========================= */

@media(max-width:700px){

    .topbar{
        padding:0 20px;
    }

    .brand{
        font-size:23px;
    }

    .page{
        padding-top:30px;
    }

    .card{
        padding:28px 20px;
        border-radius:14px;
    }

    h1{
        font-size:30px;
    }

    .choice-grid{
        grid-template-columns:1fr;
    }

    .choice{
        min-height:auto;
    }

    .actions{
        flex-direction:column;
    }

    .actions .btn{
        width:100%;
    }

    .catalog-results,
    .tmdb-results{
        grid-template-columns:repeat(2,minmax(0,1fr));
        gap:12px;
    }

    .poster-wrap{
        height:220px;
        min-height:220px;
    }

    .catalog-card,
    .tmdb-card{
        min-height:350px;
    }

    .catalog-info{
        padding:12px;
    }

    .catalog-info strong{
        font-size:15px;
        min-height:39px;
    }

    .form-grid{
        grid-template-columns:1fr;
    }
}

@media(max-width:430px){

    .topbar{
        min-height:64px;
    }

    .page{
        padding-left:14px;
        padding-right:14px;
    }

    .catalog-results,
    .tmdb-results{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

    .poster-wrap{
        height:205px;
        min-height:205px;
    }

    .catalog-card,
    .tmdb-card{
        min-height:330px;
        border-radius:12px;
    }

    .catalog-info{
        padding:10px;
    }

    .catalog-info strong{
        font-size:14px;
        min-height:37px;
    }

    .catalog-info small,
    .catalog-meta{
        font-size:12px;
    }
}
