/* ==========================================================
   Dor+
   v0.1.0-alpha.4
   Primeiro Respiro
   ========================================================== */

/* ---------- RESET ---------- */

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

html{

    font-size:16px;

    -webkit-text-size-adjust:100%;
    scroll-behavior:smooth;

}

body{

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        sans-serif;

    background:#EEF3F8;

    color:#263238;

    min-height:100vh;

    line-height:1.5;

}


/* ---------- CORES ---------- */

:root{

    --primary:#2D6CDF;
    --primary-dark:#174DA8;

    --success:#32A852;
    --warning:#F4B400;
    --danger:#D93025;

    --text:#263238;
    --text-light:#6B7280;

    --background:#EEF3F8;
    --surface:#FFFFFF;

    --border:#D8DEE7;

    --shadow:

        0 8px 24px rgba(0,0,0,.08);

    --radius:18px;

}


/* ---------- APP ---------- */

#app{

    max-width:650px;

    margin:auto;

    min-height:100vh;

    display:flex;

    flex-direction:column;

}


/* ---------- HEADER ---------- */

.topbar{

    background:white;

    padding:28px;

    box-shadow:var(--shadow);

}

.brand{

    display:flex;

    align-items:center;

    gap:18px;

}

.brand-icon{

    width:68px;

    height:68px;

    border-radius:20px;

    display:flex;

    align-items:center;

    justify-content:center;

    font-size:34px;

    background:#FFE5EA;

}

.brand-text h1{

    font-size:2rem;

    color:var(--primary);

}

.brand-text p{

    margin-top:6px;

    color:var(--text-light);

    line-height:1.4;

}/* ==========================================================
   CONTEÚDO
   ========================================================== */

.screen{

    flex:1;

    padding:24px 18px 40px;

}


/* ==========================================================
   CARTÕES
   ========================================================== */

.card{

    background:var(--surface);

    border-radius:var(--radius);

    padding:22px;

    margin-bottom:18px;

    box-shadow:var(--shadow);

    border:1px solid var(--border);

}

.card h2{

    color:var(--primary);

    font-size:1.35rem;

    margin-bottom:10px;

}

.card p{

    color:var(--text-light);

}


/* ==========================================================
   TÍTULOS
   ========================================================== */

.section-title{

    font-size:1.55rem;

    color:var(--primary);

    font-weight:700;

    margin-bottom:10px;

}

.subtitle{

    color:var(--text-light);

    margin-bottom:24px;

    line-height:1.5;

}


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

.btn{

    border:none;

    cursor:pointer;

    border-radius:14px;

    padding:16px 20px;

    font-size:1rem;

    font-weight:600;

    transition:.25s;

}

.btn:disabled{

    opacity:.55;

    cursor:not-allowed;

}

.btn-primary{

    width:100%;

    background:var(--primary);

    color:white;

}

.btn-primary:hover{

    background:var(--primary-dark);

    transform:translateY(-2px);

}

.btn-secondary{

    width:100%;

    background:#F2F5F9;

    color:var(--text);

}

.btn-secondary:hover{

    background:#E6ECF4;

}


/* ==========================================================
   GRUPOS DE BOTÕES
   ========================================================== */

.button-group{

    display:flex;

    flex-direction:column;

    gap:14px;

    margin-top:28px;

}


/* ==========================================================
   ESPAÇAMENTO
   ========================================================== */

.mt-1{ margin-top:8px; }

.mt-2{ margin-top:16px; }

.mt-3{ margin-top:24px; }

.mt-4{ margin-top:32px; }

.mb-1{ margin-bottom:8px; }

.mb-2{ margin-bottom:16px; }

.mb-3{ margin-bottom:24px; }

.mb-4{ margin-bottom:32px; }

/* ==========================================================
   CAMPOS E FORMULÁRIOS
   ========================================================== */

.field{

    margin-bottom:20px;

}

.field label{

    display:block;

    margin-bottom:8px;

    font-weight:600;

    color:var(--text);

}

.input,
.select,
.textarea{

    width:100%;

    padding:14px 16px;

    border:1px solid var(--border);

    border-radius:14px;

    background:#fff;

    font-size:1rem;

    color:var(--text);

    transition:border-color .2s, box-shadow .2s;

}

.input:focus,
.select:focus,
.textarea:focus{

    outline:none;

    border-color:var(--primary);

    box-shadow:0 0 0 4px rgba(45,108,223,.12);

}

.textarea{

    resize:vertical;

    min-height:110px;

}


/* ==========================================================
   GRADE DE OPÇÕES
   ========================================================== */

.option-grid{

    display:grid;

    grid-template-columns:repeat(auto-fit,minmax(140px,1fr));

    gap:14px;

    margin-top:18px;

}


/* ==========================================================
   CARTÕES SELECIONÁVEIS
   ========================================================== */

.option-card{

    background:white;

    border:2px solid var(--border);

    border-radius:18px;

    padding:18px;

    cursor:pointer;

    transition:.25s;

    text-align:center;

}

.option-card:hover{

    transform:translateY(-3px);

    border-color:var(--primary);

}

.option-card.selected{

    border-color:var(--primary);

    background:#EDF4FF;

    box-shadow:0 8px 20px rgba(45,108,223,.15);

}

.option-card h3{

    color:var(--primary);

    font-size:1.1rem;

    margin-bottom:8px;

}

.option-card p{

    color:var(--text-light);

    font-size:.92rem;

}


/* ==========================================================
   CHIPS
   ========================================================== */

.chips{

    display:flex;

    flex-wrap:wrap;

    gap:10px;

    margin-top:18px;

}

.chip{

    padding:10px 16px;

    border-radius:999px;

    background:#F2F5F9;

    border:1px solid var(--border);

    cursor:pointer;

    transition:.2s;

    user-select:none;

}

.chip:hover{

    border-color:var(--primary);

}

.chip.selected{

    background:var(--primary);

    color:white;

    border-color:var(--primary);

}


/* ==========================================================
   LISTAS
   ========================================================== */

.list{

    display:flex;

    flex-direction:column;

    gap:12px;

}

.list-item{

    background:white;

    border-radius:14px;

    padding:16px;

    border:1px solid var(--border);

}/* ==========================================================
   MODAL
   ========================================================== */

.modal{

    position:fixed;

    inset:0;

    background:rgba(0,0,0,.45);

    display:flex;

    align-items:center;

    justify-content:center;

    padding:24px;

    z-index:999;

}

.modal.hidden{

    display:none;

}

.modal-content{

    width:100%;

    max-width:460px;

    background:white;

    border-radius:22px;

    padding:24px;

    box-shadow:0 20px 40px rgba(0,0,0,.20);

}

.modal-actions{

    display:flex;

    gap:12px;

    margin-top:24px;

}


/* ==========================================================
   TOAST
   ========================================================== */

.toast{

    position:fixed;

    left:50%;

    bottom:24px;

    transform:translateX(-50%);

    background:#263238;

    color:white;

    padding:14px 20px;

    border-radius:14px;

    box-shadow:0 10px 30px rgba(0,0,0,.25);

    z-index:1000;

    animation:fadeUp .25s ease;

}

.toast.hidden{

    display:none;

}


/* ==========================================================
   LOADING
   ========================================================== */

.loading{

    position:fixed;

    inset:0;

    background:rgba(255,255,255,.82);

    display:flex;

    flex-direction:column;

    align-items:center;

    justify-content:center;

    gap:20px;

    z-index:1001;

}

.loading.hidden{

    display:none;

}

.spinner{

    width:56px;

    height:56px;

    border:5px solid #DCE5F5;

    border-top-color:var(--primary);

    border-radius:50%;

    animation:spin 1s linear infinite;

}


/* ==========================================================
   ANIMAÇÕES
   ========================================================== */

@keyframes spin{

    to{

        transform:rotate(360deg);

    }

}

@keyframes fadeUp{

    from{

        opacity:0;

        transform:translate(-50%,20px);

    }

    to{

        opacity:1;

        transform:translate(-50%,0);

    }

}

@keyframes fadeIn{

    from{

        opacity:0;

    }

    to{

        opacity:1;

    }

}

.fade-in{

    animation:fadeIn .25s ease;

}


/* ==========================================================
   UTILITÁRIOS
   ========================================================== */

.hidden{

    display:none !important;

}

.center{

    text-align:center;

}

.text-primary{

    color:var(--primary);

}

.text-muted{

    color:var(--text-light);

}

.full-width{

    width:100%;

}


/* ==========================================================
   RESPONSIVIDADE
   ========================================================== */

@media (max-width:640px){

    .topbar{

        padding:22px 18px;

    }

    .brand{

        gap:14px;

    }

    .brand-icon{

        width:58px;

        height:58px;

        font-size:28px;

    }

    .brand-text h1{

        font-size:1.7rem;

    }

    .screen{

        padding:18px 14px 32px;

    }

    .card{

        padding:18px;

    }

    .modal-actions{

        flex-direction:column;

    }

}


/* ==========================================================
   RODAPÉ
   ========================================================== */

.footer{

    padding:24px;

    text-align:center;

    color:var(--text-light);

    font-size:.85rem;

}