/* =========================================================
   RESET
   ========================================================= */

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


/* =========================================================
   BODY
   ========================================================= */

body {
    background-image: url('dragao fundo mobile.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: #e8eaf0;
    font-family: 'Poppins', sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    position: relative;
}

body::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(8, 14, 26, 0.78);
    z-index: -1;
}

@media (min-width: 768px) {
    body {
        background-image: url('dragao fundo desktop.webp');
    }
}


/* =========================================================
   UTILITÁRIO
   ========================================================= */

.hidden {
    display: none !important;
}


/* =========================================================
   CONTAINER PRINCIPAL
   ========================================================= */

.app-container {
    width: 100%;
    max-width: 440px;
    background:
        radial-gradient(
            circle at 0% 0%,
            rgba(251, 5, 50, 0.20) 0%,
            rgba(251, 5, 50, 0.08) 20%,
            transparent 42%
        ),
        radial-gradient(
            circle at 100% 100%,
            rgba(251, 5, 50, 0.16) 0%,
            rgba(251, 5, 50, 0.05) 22%,
            transparent 45%
        ),
        linear-gradient(
            145deg,
            #10141c 0%,
            #080b11 100%
        );
    border-radius: 20px;
    border: 1px solid #252d3a;
    padding: 30px 24px;
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.75),
        0 0 0 1px rgba(255,255,255,0.015);
    height: fit-content;
    position: relative;
    overflow: hidden;
}

.app-container::before {
    content: '';
    position: absolute;
    top: -120px;
    left: -120px;
    width: 280px;
    height: 280px;
    background: rgba(251, 5, 50, 0.10);
    border-radius: 50%;
    filter: blur(70px);
    pointer-events: none;
    z-index: 0;
}

.app-container::after {
    content: '';
    position: absolute;
    right: -140px;
    bottom: -140px;
    width: 300px;
    height: 300px;
    background: rgba(251, 5, 50, 0.08);
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}

.app-container > * {
    position: relative;
    z-index: 1;
}


/* =========================================================
   HEADER
   ========================================================= */

.header {
    text-align: center;
    margin-bottom: 25px;
    position: relative;
    padding-top: 5px;
}

.header-logo {
    max-width: 130px;
    height: auto;
    display: block;
    margin: 0 auto 8px auto;
    filter: brightness(0) invert(1);
}

.header p {
    color: #9aa2b2;
    font-size: 11px;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    font-weight: 600;
}


/* =========================================================
   BOTÃO CONFIGURAÇÕES
   ========================================================= */

.btn-admin-toggle {
    position: absolute;
    right: -4px;
    top: -2px;
    background: #171c25;
    border: 1px solid #303948;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: #9da5b5;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-admin-toggle:hover {
    color: #fff;
    border-color: #fb0532;
    background: #1d2029;
    box-shadow: 0 0 12px rgba(251, 5, 50, 0.15);
}


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

.card-box {
    background: #11151b;
    border-radius: 14px;
    padding: 22px;
    margin-bottom: 20px;
    border: 1px solid #28313f;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.015);
}

.input-group {
    margin-bottom: 16px;
    text-align: left;
}

.input-group label {
    display: block;
    font-size: 11px;
    color: #8c95a5;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.input-group input {
    width: 100%;
    padding: 12px 14px;
    background: #090c11;
    border: 1px solid #303947;
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.input-group input:focus {
    outline: none;
    border-color: #fb0532;
    box-shadow: 0 0 0 2px rgba(251, 5, 50, 0.08);
}


/* =========================================================
   BOTÃO PRINCIPAL
   ========================================================= */

.btn-gold {
    width: 100%;
    padding: 14px;
    background: linear-gradient(
        135deg,
        #ff1744 0%,
        #e5002d 100%
    );
    border: none;
    border-radius: 10px;
    color: #fff;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 18px rgba(251, 5, 50, 0.22);
    transition: opacity 0.2s, transform 0.1s, box-shadow 0.2s;
}

.btn-gold:hover {
    opacity: 0.97;
    box-shadow: 0 6px 22px rgba(251, 5, 50, 0.3);
}

.btn-gold:active {
    transform: scale(0.98);
}

.btn-gold:disabled {
    opacity: 0.6;
    cursor: wait;
}


/* =========================================================
   LINKS
   ========================================================= */

.btn-link {
    width: 100%;
    margin-top: 14px;
    background: none;
    border: none;
    color: #78808e;
    font-size: 12px;
    cursor: pointer;
    transition: color 0.2s;
}

.btn-link:hover {
    color: #c0c5ce;
}


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

.btn-sm {
    padding: 8px 12px;
    background: #171c23;
    color: #c7ccd5;
    border: 1px solid #303846;
    border-radius: 8px;
    font-size: 12px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.btn-sm:hover {
    background: #1d232c;
    border-color: #454f60;
    color: #fff;
}

.btn-full {
    width: 100%;
    margin-top: 12px;
}


/* =========================================================
   CARTÃO DE CARIMBOS
   ========================================================= */

.greeting-text {
    text-align: center;
    font-size: 13px;
    color: #aeb5c1;
    margin-bottom: 20px;
}

.greeting-text strong {
    color: #fff;
    font-weight: 600;
}

.stamps-grid {
    display: flex;
    justify-content: space-between;
    margin: 20px 0;
    gap: 10px;
    position: relative;
    z-index: 1;
}


/* =========================================================
   CARIMBO NORMAL
   ========================================================= */

.stamp-slot {
    flex: 1;
    background: linear-gradient(
        145deg,
        #151a22,
        #10141b
    );
    border: 1px solid #28313f;
    border-radius: 12px;
    height: 105px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 8px;
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

.stamp-slot:hover {
    border-color: #455268;
    transform: translateY(-1px);
}


/* =========================================================
   CARIMBO ATIVO
   ========================================================= */

.stamp-slot.active {
    border: 2px solid #ff1744;
    background: linear-gradient(
        145deg,
        #ff1744 0%,
        #cc0029 100%
    );
    box-shadow:
        inset 0 0 15px rgba(255, 255, 255, 0.35),
        0 0 25px rgba(255, 23, 68, 0.8),
        0 8px 30px rgba(255, 23, 68, 0.5);
    z-index: 3;
}


/* =========================================================
   ÍCONES DOS CARIMBOS
   ========================================================= */

.icon {
    font-size: 26px;
    margin-bottom: 6px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #F3F3F3;
    filter: grayscale(100%) opacity(0.3);
    transition: all 0.3s ease;
}

.icon svg {
    display: block;
    width: 28px;
    height: 28px;
}

.stamp-slot.active .icon {
    filter: grayscale(0%) opacity(1);
    transform: scale(1.1);
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}


/* =========================================================
   TEXTO DOS CARIMBOS
   ========================================================= */

.stamp-slot .label {
    font-size: 10px;
    color: #858e9d;
    line-height: 1.2;
}

.stamp-slot.active .label {
    color: #ffffff;
    font-weight: 600;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}


/* =========================================================
   BANNER DE BENEFÍCIO
   ========================================================= */

.discount-banner {
    background:
        radial-gradient(
            circle at 0% 0%,
            rgba(251, 5, 50, 0.18) 0%,
            rgba(251, 5, 50, 0.06) 25%,
            transparent 50%
        ),
        radial-gradient(
            circle at 100% 100%,
            rgba(251, 5, 50, 0.12) 0%,
            transparent 40%
        ),
        linear-gradient(
            145deg,
            #11161e 0%,
            #090d13 100%
        );
    border: 1px solid #303a48;
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    margin-bottom: 20px;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.03),
        0 4px 15px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.discount-label {
    font-size: 10px;
    color: #8992a1;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

.discount-banner h3 {
    color: #ffffff;
    font-size: 15px;
    font-family: 'Oswald', sans-serif;
    margin-top: 4px;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    line-height: 1.35;
}

.discount-banner h3::before {
    content: '★';
    color: #fb0532;
    font-family: Arial, sans-serif;
    font-size: 18px;
    line-height: 1;
    flex-shrink: 0;
    text-shadow: 0 0 10px rgba(251, 5, 50, 0.35);
}


/* =========================================================
   BOTÃO DO CÓDIGO DO ESTÚDIO
   ========================================================= */

.btn-code-client {
    margin-top: 2px;
    margin-bottom: 0;
    background: linear-gradient(
        135deg,
        #ff1744 0%,
        #e5002d 100%
    );
    border: 1px solid #ff1744;
    box-shadow: 0 5px 18px rgba(251, 5, 50, 0.22);
}

.btn-code-client:hover {
    background: linear-gradient(
        135deg,
        #ff3158 0%,
        #ec0030 100%
    );
    border-color: #ff3158;
    box-shadow: 0 6px 22px rgba(251, 5, 50, 0.30);
}


/* =========================================================
   BOTÃO DE INSTALAÇÃO DO APP
   ========================================================= */

#btn-instalar-app {
    background: linear-gradient(
        135deg,
        #1d232d 0%,
        #121720 100%
    );
    border: 1px solid #394455;
    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.20);
}

#btn-instalar-app:hover {
    background: linear-gradient(
        135deg,
        #252d39 0%,
        #171d27 100%
    );
    border-color: #fb0532;
    box-shadow: 0 6px 22px rgba(251, 5, 50, 0.16);
}


/* =========================================================
   MODAL DO CÓDIGO TEMPORÁRIO
   ========================================================= */

.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(3, 6, 11, 0.82);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.resgate-modal {
    width: 100%;
    max-width: 350px;
    background:
        radial-gradient(
            circle at 0% 0%,
            rgba(251, 5, 50, 0.16) 0%,
            transparent 45%
        ),
        linear-gradient(
            145deg,
            #151a22 0%,
            #0b0f15 100%
        );
    border: 1px solid #303a48;
    border-radius: 16px;
    padding: 28px 22px 22px;
    box-shadow:
        0 25px 70px rgba(0, 0, 0, 0.75),
        0 0 35px rgba(251, 5, 50, 0.08);
    position: relative;
    text-align: center;
    animation: modalEntrada 0.18s ease-out;
}

@keyframes modalEntrada {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-close {
    position: absolute;
    top: 9px;
    right: 11px;
    width: 30px;
    height: 30px;
    border: 1px solid #303846;
    border-radius: 50%;
    background: #171c23;
    color: #9da5b5;
    font-size: 21px;
    line-height: 25px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-close:hover {
    color: #fff;
    border-color: #fb0532;
    background: #21151a;
}

.modal-icon {
    font-size: 28px;
    line-height: 1;
    margin-bottom: 10px;
}

.resgate-modal h3 {
    color: #fff;
    font-family: 'Oswald', sans-serif;
    font-size: 20px;
    letter-spacing: 0.5px;
    margin-bottom: 7px;
}

.modal-description {
    color: #929baa;
    font-size: 12px;
    line-height: 1.5;
    max-width: 280px;
    margin: 0 auto;
}

.code-input-wrap {
    margin: 20px auto 8px;
}

#input-codigo-resgate {
    width: 100%;
    height: 58px;
    padding: 8px 14px;
    background: #080b10;
    border: 1px solid #3a4556;
    border-radius: 11px;
    color: #fff;
    text-align: center;
    font-family: 'Oswald', sans-serif;
    font-size: 30px;
    font-weight: 700;
    letter-spacing: 9px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

#input-codigo-resgate::placeholder {
    color: #414957;
    letter-spacing: 9px;
}

#input-codigo-resgate:focus {
    border-color: #fb0532;
    box-shadow: 0 0 0 3px rgba(251, 5, 50, 0.10);
}

.modal-expire {
    color: #697281;
    font-size: 10px;
    line-height: 1.4;
    margin-bottom: 18px;
}

.modal-actions {
    display: flex;
    gap: 8px;
}

.modal-actions .modal-cancel {
    flex: 0 0 34%;
    margin: 0;
}

.modal-actions .modal-confirm {
    flex: 1;
    padding: 11px 10px;
    font-size: 12px;
}


/* =========================================================
   PAINEL ADMIN
   ========================================================= */

.admin-panel {
    background: linear-gradient(
        145deg,
        #15191f,
        #11151b
    );
    border: 1px solid #303a48;
    border-radius: 14px;
    padding: 18px;
    margin-top: 15px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.015);
}

.admin-title {
    color: #fff;
    margin-bottom: 14px;
    font-family: 'Oswald', sans-serif;
    font-size: 16px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.admin-client-list {
    max-height: 250px;
    overflow-y: auto;
    padding-right: 2px;
}

.client-item {
    background: #0d1015;
    border: 1px solid #252d38;
    padding: 12px;
    border-radius: 10px;
    margin-bottom: 8px;
    font-size: 13px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.client-info {
    min-width: 0;
    flex: 1;
}

.client-info strong {
    color: #fff;
    display: block;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.client-info span {
    color: #7e8795;
    font-size: 11px;
}

.btn-code-admin {
    border-color: #465267;
    color: #e1e5eb;
    white-space: nowrap;
}

.btn-code-admin:hover {
    border-color: #fb0532;
    color: #fff;
    background: #21151a;
}

.btn-add-admin {
    white-space: nowrap;
}

.btn-delete-admin {
    background: #2a1114;
    border-color: #fb0532;
    color: #ff6b81;
    cursor: pointer;
    white-space: nowrap;
}

.btn-delete-admin:hover {
    background: #351419;
    border-color: #ff3154;
    color: #ff9aaa;
}


/* =========================================================
   SCROLLBAR — PAINEL
   ========================================================= */

.admin-client-list::-webkit-scrollbar {
    width: 5px;
}

.admin-client-list::-webkit-scrollbar-track {
    background: transparent;
}

.admin-client-list::-webkit-scrollbar-thumb {
    background: #303846;
    border-radius: 10px;
}

.admin-client-list::-webkit-scrollbar-thumb:hover {
    background: #485364;
}


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

@media (max-width: 480px) {

    body {
        padding: 14px;
    }

    .app-container {
        padding: 26px 18px;
        border-radius: 18px;
    }

    .stamp-slot {
        height: 100px;
    }

    .stamp-slot .label {
        font-size: 9px;
    }

    .discount-banner h3 {
        font-size: 14px;
    }

    .client-item {
        align-items: flex-start;
    }

    .client-item > div:last-child {
        flex-wrap: wrap;
        justify-content: flex-end;
    }

    .btn-code-admin,
    .btn-add-admin,
    .btn-delete-admin {
        font-size: 11px;
        padding: 7px 8px;
    }

    #input-codigo-resgate {
        height: 54px;
        font-size: 28px;
    }
}
