/* ======================================================
   COMERCIAL INTENCIONAL
   ESTILOS GERAIS
====================================================== */

:root {
    --bordo: #8F2929;
    --bordo-escuro: #701F1F;
    --dourado: #B89A5A;

    --fundo: #F7F5F2;
    --branco: #FFFFFF;

    --texto: #1F2937;
    --texto-secundario: #64748B;

    --barra-fundo: #E8E8E8;
    --borda-suave: #ECE8E3;
}


/* ======================================================
   RESET
====================================================== */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}


/* ======================================================
   PÁGINA
====================================================== */

body {
    font-family: Arial, sans-serif;

    background-color: var(--fundo);
    color: var(--texto);

    min-height: 100vh;
}


/* ======================================================
   CABEÇALHO PRINCIPAL
====================================================== */

.header {
    text-align: center;

    padding:
        34px
        20px
        22px;
}


.header h1 {
    margin-bottom: 8px;

    color: var(--bordo);

    font-size: 30px;
    font-weight: 800;

    letter-spacing: -0.5px;
}


.header p {
    color: var(--texto-secundario);

    font-size: 15px;

    line-height: 1.5;
}


/* ======================================================
   CONTAINER PRINCIPAL
====================================================== */

.container {
    width: 100%;
    max-width: 700px;

    margin: 0 auto;

    padding:
        0
        20px
        40px;
}


/* ======================================================
   STATUS DA MISSÃO
====================================================== */

.progress-section {
    position: relative;

    overflow: hidden;

    background-color: var(--branco);

    border:
        1px
        solid
        var(--borda-suave);

    border-radius: 18px;

    padding:
        24px
        24px
        22px;

    margin-bottom: 26px;

    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.05);
}


.progress-section::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 3px;

    background-color: var(--dourado);
}


.progress-heading {
    display: flex;

    align-items: center;
    justify-content: center;

    gap: 8px;

    margin-bottom: 12px;
}


.progress-accent {
    width: 7px;
    height: 7px;

    flex-shrink: 0;

    border-radius: 50%;

    background-color: var(--dourado);
}


.progress-label {
    margin: 0;

    color: var(--texto);

    font-size: 12px;
    font-weight: 800;

    letter-spacing: 1.4px;
}


.progress-percentage {
    margin-bottom: 16px;

    text-align: center;

    color: var(--bordo);

    font-size: 44px;
    font-weight: 800;

    line-height: 1;
}


.progress-bar {
    width: 100%;
    height: 10px;

    overflow: hidden;

    background-color: var(--barra-fundo);

    border-radius: 999px;
}


.progress-fill {
    width: 0%;
    height: 100%;

    background-color: var(--bordo);

    border-radius: 999px;

    transition:
        width
        0.4s
        ease;
}


.progress-phases {
    margin-top: 12px;

    text-align: center;

    color: var(--texto-secundario);

    font-size: 12px;
    font-weight: 700;
}


/* ======================================================
   LISTA DAS FASES
====================================================== */

.phases-section {
    display: flex;
    flex-direction: column;

    gap: 14px;
}


/* ======================================================
   CARD DA FASE
====================================================== */

.phase-card {
    overflow: hidden;

    background-color: var(--branco);

    border:
        1px
        solid
        var(--borda-suave);

    border-radius: 16px;

    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.05);

    transition:
        box-shadow 0.2s ease,
        transform 0.2s ease;
}


.phase-card:hover {
    box-shadow:
        0 6px 20px rgba(0, 0, 0, 0.07);
}


/* ======================================================
   CABEÇALHO CLICÁVEL DA FASE
====================================================== */

.phase-header {
    width: 100%;

    display: flex;
    align-items: center;

    gap: 16px;

    padding:
        20px
        22px;

    border: none;

    background: transparent;

    color: var(--texto);

    text-align: left;

    cursor: pointer;
}


.phase-header:hover {
    background-color: #FCFBFA;
}


/* ======================================================
   ÍCONE / IDENTIFICAÇÃO VISUAL
====================================================== */

.phase-icon {
    width: 44px;
    height: 44px;

    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background-color: rgba(143, 41, 41, 0.08);

    color: var(--bordo);
}


.phase-icon svg {
    width: 22px;
    height: 22px;

    fill: none;

    stroke: currentColor;
    stroke-width: 1.8;

    stroke-linecap: round;
    stroke-linejoin: round;
}


/* ======================================================
   TEXTO DO CABEÇALHO DA FASE
====================================================== */

.phase-header-text {
    flex: 1;

    min-width: 0;
}


.phase-label-row {
    display: flex;
    align-items: center;

    gap: 8px;

    margin-bottom: 5px;
}


.phase-label {
    display: block;

    color: var(--dourado);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: 1.4px;
}


.phase-label-row .phase-label {
    margin-bottom: 0;
}


.phase-header h3 {
    margin: 0;

    color: var(--texto);

    font-size: 18px;
    font-weight: 700;

    line-height: 1.25;
}


/* ======================================================
   SELO CONCLUÍDA
====================================================== */

.phase-completed-badge {
    display: none;

    padding:
        3px
        7px;

    border-radius: 999px;

    background-color: rgba(143, 41, 41, 0.10);

    color: var(--bordo);

    font-size: 9px;
    font-weight: 800;

    letter-spacing: 0.7px;

    line-height: 1;
}


.phase-card.concluida .phase-completed-badge {
    display: inline-flex;
    align-items: center;
}


/* ======================================================
   ESTADO VISUAL — FASE CONCLUÍDA
====================================================== */

.phase-card.concluida {
    border-color: rgba(143, 41, 41, 0.25);
}


.phase-card.concluida .phase-icon {
    background-color: var(--bordo);

    color: var(--branco);
}


/* ======================================================
   CHEVRONS DAS FASES
====================================================== */

.phase-arrow {
    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-left: 8px;

    color: var(--texto-secundario);

    line-height: 1;
}


.phase-arrow svg {
    width: 20px;
    height: 20px;

    fill: none;

    stroke: currentColor;
    stroke-width: 1.8;

    stroke-linecap: round;
    stroke-linejoin: round;
}


/* ======================================================
   ÁREA EXPANDIDA
====================================================== */

.phase-details {
    display: none;

    margin:
        0
        22px;

    padding:
        0
        0
        22px;

    border-top:
        1px
        solid
        var(--borda-suave);
}


.phase-details.aberto {
    display: block;
}


/* ======================================================
   CONTEÚDO INTERNO DAS FASES
====================================================== */

.phase-content-block {
    padding:
        18px
        0;
}


.phase-content-block + .phase-content-block {
    border-top:
        1px
        solid
        var(--borda-suave);
}


.phase-content-block h4 {
    margin-bottom: 10px;

    color: var(--bordo);

    font-size: 12px;
    font-weight: 800;

    letter-spacing: 1.3px;
}


.phase-content-block p {
    margin: 0;

    color: var(--texto-secundario);

    font-size: 14px;

    line-height: 1.65;
}


/* ======================================================
   LISTA DE AULAS
====================================================== */

.lesson-list {
    display: flex;
    flex-direction: column;

    gap: 10px;
}


.lesson-item {
    padding:
        14px
        14px;

    background-color: #FBFAF8;

    border:
        1px
        solid
        var(--borda-suave);

    border-radius: 12px;
}


.lesson-title {
    display: flex;

    align-items: flex-start;

    gap: 10px;
}


.lesson-id {
    min-width: 34px;

    flex-shrink: 0;

    color: var(--bordo);

    font-size: 13px;
    font-weight: 800;
}


.lesson-name {
    color: var(--texto);

    font-size: 14px;
    font-weight: 600;

    line-height: 1.45;
}


/* ======================================================
   MATERIAIS COMPLEMENTARES
====================================================== */

.lesson-materials {
    display: flex;
    flex-direction: column;

    gap: 6px;

    margin-top: 10px;
    margin-left: 44px;
}


.material-link {
    width: fit-content;

    color: var(--bordo);

    font-size: 13px;
    font-weight: 700;

    text-decoration: none;

    line-height: 1.4;
}


.material-link:hover {
    text-decoration: underline;
}


.material-indisponivel {
    opacity: 0.65;

    cursor: default;
}


/* ======================================================
   BOTÃO CONCLUIR FASE
====================================================== */

.btn-concluir {
    width: 100%;

    margin-top: 20px;

    padding:
        13px
        16px;

    border: none;
    border-radius: 10px;

    background-color: var(--bordo);

    color: var(--branco);

    font-size: 14px;
    font-weight: 700;

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        opacity 0.2s ease;
}


.btn-concluir:hover:not(:disabled) {
    background-color: var(--bordo-escuro);
}


.btn-concluir:disabled {
    opacity: 0.65;

    cursor: default;
}


/* ======================================================
   RESPONSIVIDADE
====================================================== */

@media (max-width: 600px) {

    .header {
        padding:
            28px
            18px
            18px;
    }


    .header h1 {
        font-size: 27px;
    }


    .container {
        padding:
            0
            14px
            32px;
    }


    .progress-section {
        padding:
            22px
            20px
            20px;
    }


    .progress-percentage {
        font-size: 40px;
    }


    .progress-phases {
        font-size: 12px;
    }


    .phase-header {
        gap: 13px;

        padding:
            18px
            16px;
    }


    .phase-icon {
        width: 40px;
        height: 40px;
    }


    .phase-header h3 {
        font-size: 16px;
    }


    .phase-arrow {
        margin-left: 4px;
    }


    .phase-details {
        margin:
            0
            16px;

        padding:
            0
            0
            20px;
    }


    .phase-content-block {
        padding:
            16px
            0;
    }


    .phase-content-block h4 {
        font-size: 11px;
    }


    .phase-content-block p {
        font-size: 13px;

        line-height: 1.6;
    }


    .lesson-item {
        padding:
            13px
            12px;
    }


    .lesson-title {
        gap: 8px;
    }


    .lesson-id {
        min-width: 32px;

        font-size: 12px;
    }


    .lesson-name {
        font-size: 13px;
    }


    .lesson-materials {
        margin-left: 40px;
    }


    .material-link {
        font-size: 12px;
    }

}

/* ======================================================
   RODAPÉ / INSTAGRAM
====================================================== */

.app-footer {
    width: 100%;
    max-width: 700px;

    margin:
        0
        auto;

    padding:
        4px
        20px
        34px;

    text-align: center;
}


.app-footer p {
    margin-bottom: 6px;

    color: var(--texto-secundario);

    font-size: 12px;

    line-height: 1.5;
}


.app-footer a {
    color: var(--bordo);

    font-size: 13px;
    font-weight: 700;

    text-decoration: none;
}


.app-footer a:hover {
    text-decoration: underline;
}


@media (max-width: 600px) {

    .app-footer {
        padding:
            4px
            14px
            28px;
    }

}

.app-footer a {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 6px;
}


.instagram-icon {
    width: 15px;
    height: 15px;

    fill: none;

    stroke: currentColor;
    stroke-width: 1.8;

    stroke-linecap: round;
    stroke-linejoin: round;
}


.instagram-dot {
    fill: currentColor;
    stroke: none;
}