/* ==========================================
   OLYMPO ADMIN V2
   CATEGORIAS
========================================== */


/* ==========================================
   CABEÇALHO
========================================== */

/* ==========================================
   CABEÇALHO / BANNER
========================================== */

.topo-admin {
    position: relative;

    width: 100%;
    min-height: 180px;

    overflow: hidden;

    border-bottom:
        1px solid
        rgba(212, 175, 55, 0.20);

    box-shadow:
        0 8px 25px
        rgba(0, 0, 0, 0.25);
}


/* Banner */

.topo-admin__banner {
    position: absolute;

    inset: 0;

    z-index: 1;

    display: block;

    width: 100%;
    height: 100%;
}

.topo-admin__banner img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;
}


/* Camada escura sobre o banner */

.topo-admin__overlay {
    position: absolute;

    inset: 0;

    z-index: 2;

    background:
        linear-gradient(
            90deg,
            rgba(5, 9, 16, 0.88) 0%,
            rgba(5, 9, 16, 0.55) 45%,
            rgba(5, 9, 16, 0.30) 100%
        );
}


/* Conteúdo do cabeçalho */

.topo-admin__conteudo {
    position: relative;

    z-index: 3;

    display: flex;

    align-items: center;

    gap: 18px;

    width: min(1150px, calc(100% - 50px));

    min-height: 180px;

    margin: 0 auto;
}


/* ==========================================
   LOGO
========================================== */

.logo-admin {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 72px;
    height: 72px;

    padding: 7px;

    background: rgba(8, 15, 28, 0.78);

    border:
        1px solid
        rgba(212, 175, 55, 0.35);

    border-radius: 12px;

    flex-shrink: 0;

    backdrop-filter: blur(4px);
}

.logo-admin img {
    width: 100%;
    height: 100%;

    object-fit: contain;
}


/* ==========================================
   TÍTULO DO CABEÇALHO
========================================== */

.titulo-admin {
    min-width: 0;
}

.titulo-admin span {
    display: block;

    margin-bottom: 5px;

    color: #d4af37;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 2px;
}

.titulo-admin h1 {
    margin: 0;

    color: #ffffff;

    font-size: 26px;
    font-weight: 700;
}

.titulo-admin p {
    margin-top: 4px;

    color: #717b87;

    font-size: 12px;
}


/* ==========================================
   CONTEÚDO
========================================== */

.conteudo-admin {
    width: min(1150px, calc(100% - 50px));

    margin: 0 auto;

    padding: 40px 0 60px;
}


/* ==========================================
   TÍTULO DA PÁGINA
========================================== */

.pagina-titulo {
    margin-bottom: 25px;
}

.pagina-titulo__mini {
    display: block;

    margin-bottom: 6px;

    color: #d4af37;

    font-size: 10px;
    font-weight: 800;

    text-transform: uppercase;

    letter-spacing: 1.8px;
}

.pagina-titulo h1 {
    margin: 0;

    color: #ffffff;

    font-size: 30px;
    font-weight: 700;
}

.pagina-titulo p {
    max-width: 650px;

    margin-top: 6px;

    color: #7f8996;

    font-size: 12px;
}


/* ==========================================
   CARDS
========================================== */

.card-admin {
    position: relative;

    overflow: hidden;

    padding: 25px;

    margin-bottom: 22px;

    background:
        linear-gradient(
            145deg,
            #151d2e 0%,
            #0e1625 55%,
            #0a101c 100%
        );

    border:
        1px solid
        rgba(212, 175, 55, 0.20);

    border-radius: 18px;

    box-shadow:
        0 12px 35px
        rgba(0, 0, 0, 0.22);
}


/* Linha dourada superior */

.card-admin::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;
    right: 0;

    height: 2px;

    background:
        linear-gradient(
            90deg,
            transparent,
            rgba(212, 175, 55, 0.65),
            transparent
        );
}


/* ==========================================
   CABEÇALHO DOS CARDS
========================================== */

.cabecalho-card {
    padding-bottom: 18px;

    margin-bottom: 20px;

    border-bottom:
        1px solid
        rgba(255, 255, 255, 0.06);
}

.cabecalho-card h2 {
    margin: 0;

    color: #ffffff;

    font-size: 18px;
    font-weight: 700;
}

.cabecalho-card p {
    margin-top: 6px;

    color: #7f8996;

    font-size: 12px;
}


/* ==========================================
   FORMULÁRIO
========================================== */

#form-categoria {
    display: flex;

    flex-direction: column;

    gap: 18px;
}

.campo-formulario {
    display: flex;

    flex-direction: column;

    gap: 7px;

    min-width: 0;
}

.campo-formulario > label {
    color: #e5e7eb;

    font-size: 11px;
    font-weight: 700;

    text-transform: uppercase;

    letter-spacing: 0.7px;
}


/* ==========================================
   INPUT E SELECT
========================================== */

.campo-formulario input[type="text"],
.campo-formulario select {
    width: 100%;

    min-height: 46px;

    padding: 0 14px;

    box-sizing: border-box;

    background: #080f1c;

    border:
        1px solid
        #293548;

    border-radius: 10px;

    color: #f9fafb;

    font-size: 14px;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}

.campo-formulario input[type="text"]:hover,
.campo-formulario select:hover {
    border-color:
        rgba(212, 175, 55, 0.40);
}

.campo-formulario input[type="text"]:focus,
.campo-formulario select:focus {
    background: #0b1423;

    border-color: #d4af37;

    box-shadow:
        0 0 0 3px
        rgba(212, 175, 55, 0.08);
}

.campo-formulario input::placeholder {
    color: #68727e;
}


/* ==========================================
   OPÇÕES DE CATEGORIA
========================================== */

.opcoes-categoria {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 12px;

    margin-top: 2px;
}

.opcoes-categoria label {
    display: flex;

    align-items: center;

    gap: 9px;

    min-height: 46px;

    padding: 0 14px;

    background: #080f1c;

    border:
        1px solid
        #293548;

    border-radius: 10px;

    color: #c6cbd2;

    font-size: 12px;
    font-weight: 600;

    cursor: pointer;

    transition:
        border-color 0.2s ease,
        background 0.2s ease,
        color 0.2s ease;
}

.opcoes-categoria label:hover {
    background: #0b1423;

    border-color:
        rgba(212, 175, 55, 0.40);

    color: #ffffff;
}

.opcoes-categoria input {
    width: 15px;
    height: 15px;

    margin: 0;

    accent-color: #d4af37;
}


/* ==========================================
   AÇÕES DO FORMULÁRIO
========================================== */

.acoes-formulario {
    display: flex;

    justify-content: flex-end;

    margin-top: 5px;

    padding-top: 20px;

    border-top:
        1px solid
        rgba(255, 255, 255, 0.06);
}


/* ==========================================
   BOTÃO SALVAR
========================================== */

#btn-salvar-categoria {
    min-height: 48px;

    padding: 0 27px;

    border-radius: 11px;

    background:
        linear-gradient(
            135deg,
            #d4af37,
            #a88420
        );

    color: #080c11;

    border:
        1px solid
        rgba(255, 220, 100, 0.45);

    font-size: 13px;
    font-weight: 800;

    box-shadow:
        0 6px 18px
        rgba(212, 175, 55, 0.20);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        filter 0.2s ease;
}

#btn-salvar-categoria:hover {
    background:
        linear-gradient(
            135deg,
            #e5c354,
            #c49d2e
        );

    transform: translateY(-2px);

    box-shadow:
        0 9px 24px
        rgba(212, 175, 55, 0.30);
}

#btn-salvar-categoria:active {
    transform: translateY(0);
}


/* ==========================================
   LISTA DE CATEGORIAS
========================================== */

#lista-categorias {
    display: flex;

    flex-direction: column;

    width: 100%;
}


/* ==========================================
   ESTADO VAZIO
========================================== */

#lista-categorias .estado-vazio {
    margin-top: 2px;

    padding: 35px 20px;

    background:
        rgba(8, 15, 28, 0.65);

    border:
        1px dashed
        rgba(212, 175, 55, 0.18);

    border-radius: 12px;

    text-align: center;
}

#lista-categorias .estado-vazio strong {
    color: #cbd2da;

    font-size: 14px;
}

#lista-categorias .estado-vazio p {
    margin-top: 7px;

    color: #737e8b;

    font-size: 12px;
}


/* ==========================================
   RESPONSIVO
========================================== */

@media (max-width: 900px) {

    .conteudo-admin {
        width: calc(100% - 35px);
    }

}


@media (max-width: 700px) {

    .topo-admin {
        min-height: 100px;

        padding: 18px 20px;

        gap: 14px;
    }

    .logo-admin {
        width: 58px;
        height: 58px;

        padding: 6px;
    }

    .titulo-admin span {
        font-size: 8px;

        letter-spacing: 1.5px;
    }

    .titulo-admin h1 {
        font-size: 21px;
    }

    .titulo-admin p {
        font-size: 10px;
    }


    .conteudo-admin {
        width: calc(100% - 30px);

        padding: 30px 0 50px;
    }


    .pagina-titulo {
        margin-bottom: 20px;
    }

    .pagina-titulo h1 {
        font-size: 25px;
    }

    .pagina-titulo p {
        font-size: 12px;
    }


    .card-admin {
        padding: 20px;

        border-radius: 15px;
    }


    .cabecalho-card {
        padding-bottom: 16px;

        margin-bottom: 18px;
    }

    .cabecalho-card h2 {
        font-size: 17px;
    }


    .opcoes-categoria {
        grid-template-columns: 1fr;
    }


    .acoes-formulario {
        justify-content: stretch;
    }

    #btn-salvar-categoria {
        width: 100%;
    }

}


@media (max-width: 420px) {

    .topo-admin {
        padding: 16px;
    }

    .logo-admin {
        width: 52px;
        height: 52px;
    }

    .titulo-admin h1 {
        font-size: 19px;
    }

    .conteudo-admin {
        width: calc(100% - 24px);

        padding-top: 25px;
    }

    .pagina-titulo h1 {
        font-size: 23px;
    }

    .card-admin {
        padding: 17px;
    }

    .campo-formulario input[type="text"],
    .campo-formulario select {
        min-height: 44px;

        font-size: 13px;
    }

}
/* ==========================================
   BANNER RESPONSIVO
========================================== */

@media (max-width: 700px) {

    .topo-admin {
        min-height: 150px;
    }

    .topo-admin__conteudo {
        width: calc(100% - 30px);

        min-height: 150px;

        gap: 14px;
    }

    .logo-admin {
        width: 58px;
        height: 58px;
    }

    .titulo-admin span {
        font-size: 8px;
        letter-spacing: 1.5px;
    }

    .titulo-admin h1 {
        font-size: 21px;
    }

    .titulo-admin p {
        font-size: 10px;
    }
}


@media (max-width: 420px) {

    .topo-admin {
        min-height: 135px;
    }

    .topo-admin__conteudo {
        width: calc(100% - 24px);

        min-height: 135px;

        gap: 10px;
    }

    .logo-admin {
        width: 52px;
        height: 52px;
    }

    .titulo-admin h1 {
        font-size: 19px;
    }
}
/* ==========================================
   LISTAGEM DE CATEGORIAS
========================================== */

.grupo-categoria {
    margin-bottom: 16px;

    overflow: hidden;

    background:
        linear-gradient(
            145deg,
            #111a29 0%,
            #0c1421 100%
        );

    border:
        1px solid
        rgba(212, 175, 55, 0.16);

    border-radius: 13px;
}


/* ==========================================
   CATEGORIA MÃE
========================================== */

.categoria-mae {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 15px;

    min-height: 58px;

    padding: 0 16px;

    background:
        rgba(212, 175, 55, 0.035);

    border-bottom:
        1px solid
        rgba(255, 255, 255, 0.06);
}

.categoria-mae strong {
    display: flex;

    align-items: center;

    gap: 10px;

    color: #ffffff;

    font-size: 14px;
    font-weight: 700;

    letter-spacing: 0.2px;
}

.categoria-mae strong::before {
    content: "";

    display: block;

    width: 7px;
    height: 7px;

    background: #d4af37;

    border-radius: 50%;

    box-shadow:
        0 0 8px
        rgba(212, 175, 55, 0.35);
}


/* ==========================================
   RAMIFICAÇÕES
========================================== */

.ramificacoes {
    display: flex;

    flex-direction: column;
}

.categoria-filho {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 15px;

    min-height: 52px;

    padding: 0 16px 0 28px;

    border-bottom:
        1px solid
        rgba(255, 255, 255, 0.04);

    transition:
        background 0.2s ease;
}

.categoria-filho:last-child {
    border-bottom: none;
}

.categoria-filho:hover {
    background:
        rgba(255, 255, 255, 0.025);
}

.categoria-filho > span {
    color: #aeb6c0;

    font-size: 13px;
}

.categoria-filho:hover > span {
    color: #ffffff;
}


/* ==========================================
   BOTÕES DE AÇÃO
========================================== */

.acoes-categoria {
    display: flex;

    align-items: center;

    gap: 7px;

    flex-shrink: 0;
}

.acoes-categoria button {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    min-height: 34px;

    padding: 0 11px;

    border-radius: 7px;

    font-size: 11px;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


/* ==========================================
   EDITAR
========================================== */

.acoes-categoria button:first-child {
    background:
        rgba(212, 175, 55, 0.08);

    border:
        1px solid
        rgba(212, 175, 55, 0.30);

    color: #d4af37;
}

.acoes-categoria button:first-child:hover {
    background:
        rgba(212, 175, 55, 0.16);

    border-color:
        rgba(212, 175, 55, 0.65);

    color: #e5c354;

    transform: translateY(-1px);

    box-shadow:
        0 4px 12px
        rgba(212, 175, 55, 0.10);
}


/* ==========================================
   EXCLUIR
========================================== */

.acoes-categoria button:last-child {
    background:
        rgba(199, 107, 107, 0.07);

    border:
        1px solid
        rgba(199, 107, 107, 0.28);

    color: #c76b6b;
}

.acoes-categoria button:last-child:hover {
    background:
        rgba(199, 107, 107, 0.14);

    border-color:
        rgba(199, 107, 107, 0.55);

    color: #e08383;

    transform: translateY(-1px);

    box-shadow:
        0 4px 12px
        rgba(199, 107, 107, 0.10);
}


/* ==========================================
   CATEGORIA SEM RAMIFICAÇÕES
========================================== */

.categoria-sem-filhos {
    padding: 16px 28px;

    color: #626d7a;

    font-size: 11px;

    font-style: italic;
}


/* ==========================================
   RESPONSIVO
========================================== */

@media (max-width: 700px) {

    .categoria-mae {
        min-height: 54px;

        padding: 0 13px;
    }

    .categoria-filho {
        min-height: 50px;

        padding-left: 20px;
        padding-right: 13px;
    }

    .categoria-mae strong {
        font-size: 13px;
    }

    .categoria-filho > span {
        font-size: 12px;
    }

    .acoes-categoria {
        gap: 5px;
    }

    .acoes-categoria button {
        min-width: 34px;
        min-height: 32px;

        padding: 0 9px;
    }
}


@media (max-width: 480px) {

    .categoria-mae {
        align-items: flex-start;

        flex-direction: column;

        gap: 10px;

        padding-top: 13px;
        padding-bottom: 13px;
    }

    .categoria-mae .acoes-categoria {
        width: 100%;
    }

    .categoria-mae .acoes-categoria button {
        flex: 1;
    }

    .categoria-filho {
        align-items: flex-start;

        flex-direction: column;

        gap: 8px;

        padding-top: 12px;
        padding-bottom: 12px;
    }

    .categoria-filho .acoes-categoria {
        width: 100%;
    }

    .categoria-filho .acoes-categoria button {
        flex: 1;
    }

}