﻿/*==================================
   Create by Alison Lima 27/07/2026
   =================================*/

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Degradê Azul Céu */
body.bg-portal {
    background: linear-gradient(180deg, #3b7ddd 0%, #76a8f5 50%, #cce0fc 100%) !important;
    background-attachment: fixed;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    padding: 20px;
}

.container-cadastro {
    display: flex;
    justify-content: center;
    width: 100%;
}

.card-step {
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    padding: 40px 35px;
    max-width: 420px;
    width: 100%;
}

.card-step-wide {
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    padding: 35px;
    max-width: 820px;
    width: 100%;
}

.style-hidden {
    display: none !important;
}

.logo-portal {
    max-width: 130px !important;
    height: auto;
    display: block;
    margin: 0 auto 12px auto;
}

.logo-portal-sm {
    max-width: 100px !important;
    height: auto;
    display: block;
    margin: 0 auto 10px auto;
}

.portal-heading {
    font-size: 19px;
    font-weight: 700;
    color: #1a4273;
    margin-bottom: 4px;
    text-align: center;
    text-transform: uppercase;
}

.portal-subheading {
    font-size: 13px;
    color: #6b7280;
    text-align: center;
    margin-bottom: 25px;
}

.form-grid-layout {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

/* SEÇÃO DE AVATAR FOTO CIRCULAR */
.photo-section {
    flex: 0 0 220px;
    text-align: center;
}

.photo-label {
    font-size: 12px;
    font-weight: 700;
    color: #1a4273;
    margin-bottom: 12px;
    display: block;
    text-transform: uppercase;
}

.avatar-upload-box {
    position: relative;
    width: 150px;
    height: 150px;
    margin: 0 auto 12px auto;
    cursor: pointer;
}

.avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3.5px solid #3b7ddd;
    box-shadow: 0 8px 20px rgba(59, 125, 221, 0.25);
    background-color: #f1f5f9;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.avatar-upload-box:hover .avatar-img {
    transform: scale(1.02);
    border-color: #1a4273;
}

.avatar-badge {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 40px;
    height: 40px;
    background: #0f2b4d;
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    border: 3px solid #ffffff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: background 0.2s ease, transform 0.2s ease;
}

.avatar-upload-box:hover .avatar-badge {
    background: #2563eb;
    transform: scale(1.08);
}

.photo-hint {
    font-size: 12px;
    color: #475569;
    line-height: 1.4;
}

    .photo-hint span {
        font-size: 10.5px;
        color: #94a3b8;
    }

/* FORMULÁRIO */
.fields-section {
    flex: 1;
}

.form-group {
    margin-bottom: 16px;
}

.form-row {
    display: flex;
    gap: 12px;
}

.col-half {
    flex: 1;
}

.form_input {
    width: 100%;
    height: 46px;
    padding: 10px 14px;
    font-size: 13px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background-color: #f9fafb;
    color: #1f2937;
    transition: all 0.2s ease;
}

    .form_input:focus {
        background-color: #ffffff;
        border-color: #1a4273;
        outline: none;
        box-shadow: 0 0 0 3px rgba(26, 66, 115, 0.15);
    }

.password-field {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #6b7280;
}

.box-buttons-step {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.btn-step {
    flex: 1;
    height: 46px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-voltar {
    background-color: #ffffff;
    color: #1a4273;
    border: 2px solid #1a4273;
}

    .btn-voltar:hover {
        background-color: #f0f4f8;
    }

.btn-avancar, .btn-salvar {
    background: linear-gradient(135deg, #1a4273 0%, #0d2b52 100%);
    color: #ffffff;
}

    .btn-avancar:hover, .btn-salvar:hover {
        background: linear-gradient(135deg, #0250a3 0%, #1a4273 100%);
    }

.text-align-center {
    text-align: center;
}

.success-badge {
    font-size: 58px;
    color: #10b981;
    margin-bottom: 15px;
}

.highlight-text {
    font-size: 15px !important;
    color: #1a4273 !important;
    margin-top: 6px;
}

.success-description {
    font-size: 13px;
    color: #4b5563;
    line-height: 1.6;
    margin-top: 12px;
}

.btn-full {
    width: 100%;
}

/* ===================================================
   MODAIS DE FOTO DA CÂMERA E OPÇÕES
   =================================================== */
.modal-overlay-custom {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    animation: fadeInOverlay 0.2s ease-out;
}

.modal-card-custom {
    background: #ffffff;
    border-radius: 16px;
    padding: 28px 24px;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
    animation: popInModal 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
}

.modal-photo-dialog {
    max-width: 450px;
}

.modal-camera-wide {
    max-width: 480px;
}

.modal-header-custom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 12px;
}

.modal-subtitulo-custom {
    font-size: 13px;
    color: #64748b;
    margin-bottom: 16px;
    text-align: left;
}

/* CARDS DE OPÇÃO (CÂMERA x ARQUIVO) */
.photo-options-grid {
    display: flex;
    gap: 14px;
}

.photo-option-card {
    flex: 1;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #f8fafc;
}

    .photo-option-card:hover {
        border-color: #0f2b4d;
        background: #eff6ff;
        transform: translateY(-2px);
        box-shadow: 0 6px 16px rgba(15, 43, 77, 0.08);
    }

.photo-option-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: #dbeafe;
    color: #1d4ed8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin: 0 auto 10px auto;
}

.photo-option-card h4 {
    font-size: 14px;
    font-weight: 700;
    color: #0f2b4d;
    margin-bottom: 4px;
}

.photo-option-card p {
    font-size: 11px;
    color: #64748b;
    line-height: 1.3;
}

/* WEBCAM STREAM COM GUIA CIRCULAR */
.camera-stream-wrapper {
    position: relative;
    width: 100%;
    height: 310px;
    background: #0f172a;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
}

.video-stream-modal {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.camera-face-guide {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 210px;
    height: 210px;
    border: 2px dashed rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    box-shadow: 0 0 0 9999px rgba(15, 23, 42, 0.45);
    pointer-events: none;
}

.modal-actions-custom {
    display: flex;
    justify-content: center;
}

.btn-capturar-modal {
    width: 100%;
    height: 46px;
    background: #0f2b4d;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s ease;
}

    .btn-capturar-modal:hover {
        background: #1a4273;
    }

/* ===================================================
   MODAL DE ALERTA PERSONALIZADO (ALINHAMENTO CENTRALIZADO)
   =================================================== */
.modal-icon-custom {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px auto;
    font-size: 28px;
}

    .modal-icon-custom.warning {
        background-color: #fef3c7;
        color: #d97706;
    }

    .modal-icon-custom.error {
        background-color: #fee2e2;
        color: #dc2626;
    }

    .modal-icon-custom.success {
        background-color: #d1fae5;
        color: #059669;
    }

.modal-titulo-custom {
    font-size: 18px;
    font-weight: 700;
    color: #0f2b4d;
    margin-bottom: 10px;
    text-align: center !important;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-close-modal {
    background: transparent;
    border: none;
    font-size: 22px;
    color: #64748b;
    cursor: pointer;
    line-height: 1;
    padding: 0 4px;
}

    .btn-close-modal:hover {
        color: #0f2b4d;
    }

.modal-texto-custom {
    font-size: 14px;
    color: #475569;
    line-height: 1.5;
    margin-bottom: 22px;
    text-align: center !important;
    word-break: break-word;
    padding: 0 8px;
}

.btn-modal-custom {
    width: 100%;
    height: 44px;
    background: #0f2b4d;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
}

    .btn-modal-custom:hover {
        background: #1a4273;
    }

@keyframes fadeInOverlay {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes popInModal {
    from {
        transform: scale(0.88);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .form-grid-layout {
        flex-direction: column;
    }

    .photo-section {
        width: 100%;
        margin-bottom: 20px;
    }

    .form-row {
        flex-direction: column;
        gap: 0;
    }

    .photo-options-grid {
        flex-direction: column;
    }
}
