/* Variáveis de cores */
:root {
    --color-primary-green: #2e8b57; /* Verde dos botões */
    --color-red-danger: #dc3545; /* Vermelho do botão "Excluir conta" */
    --color-text-dark: #333;
    --color-text-light: #666;
    --color-background-white: #ffffff;
    --color-red-message: #dc3545; /* Vermelho do texto do e-mail */
}

/* Reset básico e tipografia */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif;
}

.close-icon a {
    text-decoration: none;
    color: var(--color-text-light);
}

body {
    background-color: var(--color-background-white);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
}

.app-container {
    width: 100%;
    max-width: 400px; /* Largura típica para layout de app/móvel */
    background-color: var(--color-background-white);
    padding: 20px 25px; /* Preenchimento interno */
    position: relative;
    min-height: 100vh;
}

/* Ícone de fechar */
.close-icon {
    position: absolute;
    top: 30px;
    right: 15px;
    font-size: 30px;
    color: var(--color-text-light);
    cursor: pointer;
    font-weight: 300;
}

/* Conteúdo principal do perfil */
.profile-content {
    padding-top: 40px; /* Espaço para o ícone de fechar */
    text-align: center; /* Centraliza o texto e botões */
}

/* Botões de ação (Logout, Excluir conta) */
.action-button {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 5px;
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    margin-bottom: 5px; /* Espaço entre os botões */
    transition: background-color 0.2s;
}

.logout-button {
    background-color: var(--color-primary-green);
    color: var(--color-background-white);
}

.logout-button:hover {
    background-color: #247547; /* Verde um pouco mais escuro */
}

.delete-account-button {
    background-color: var(--color-primary-green); /* Conforme a imagem, o vermelho está no texto */
    color: var(--color-background-white);
}
/* Se quisesse o botão excluir na cor vermelha do fundo
.delete-account-button {
    background-color: var(--color-red-danger);
    color: var(--color-background-white);
}
*/
.delete-account-button:hover {
    background-color: #247547; /* Verde um pouco mais escuro */
}


/* Mensagem de usuário logado */
.logged-in-message {
    font-size: 16px;
    color: var(--color-red-message); /* Cor vermelha do texto "Você está logado como:" */
    margin-top: 30px;
    margin-bottom: 5px;
}

.user-email {
    font-size: 18px;
    font-weight: 500;
    color: var(--color-red-message); /* Cor vermelha do e-mail */
    margin-bottom: 40px;
}

/* Título da seção "Arquivos" */
.section-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-text-dark);
    margin-top: 30px;
    margin-bottom: 20px;
}

/* Estilos para a seção de arquivos (exemplo) */
.files-section {
    width: 100%;
    text-align: left;
    /* Adicione estilos para a lista de arquivos aqui se necessário */
}

.section-title {
    margin-top: 20px;
    font-size: 1.4rem;
    color: #333;
    font-weight: 600;
}

.coupons-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 10px;
    margin-bottom: 120px;
}

/* Loader de Carregamento */
.loader-container {
    position: fixed;
    inset: 0;
    background: #f9f9f9;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.4s ease;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 6px solid #cce5cc;
    border-top-color: #2ecc71;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loader-container p {
    margin-top: 12px;
    font-size: 15px;
    color: #333;
}


.cupom-card {
    display: flex;
    justify-content: space-between;
    background: #f6f7fb;
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 12px 16px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
    transition: transform 0.2s;
}

.cupom-card h3 {
    margin: 0;
    font-size: 1.1em;
    color: #2e8b57;
}

.cupom-card:hover {
    transform: translateY(-2px);
}

.no-coupons {
    color: #777;
    font-style: italic;
    margin-top: 10px;
}

.final{
    position: fixed;
    bottom: 0;
    width: 85%;
}

/* Estilos para a seção de arquivos */
.files-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 10px;
    margin-bottom: 140px; /* Garante que a lista não fique escondida atrás dos botões da div .final */
}

.arquivo-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f6f7fb;
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 12px 16px;
    text-decoration: none;
    color: #333;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
    transition: transform 0.2s, background 0.2s;
}

.arquivo-item:hover {
    transform: translateY(-2px);
    background: #eef2f5;
}

.arquivo-item span {
    font-weight: 500;
    word-break: break-all;
}

.arquivo-icon {
    font-size: 1.2rem;
}

.no-files {
    color: #777;
    font-style: italic;
    margin-top: 10px;
}

/* Reduzi a margem dos cupons para dividir melhor o espaço com os arquivos */
.coupons-section {
    margin-bottom: 20px; 
}

/* ==================== SWITCH E ABAS ==================== */
.switch-container {
    display: flex;
    background-color: #f1f5f9;
    border-radius: 30px;
    padding: 6px;
    margin: 20px 0;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.switch-tab {
    flex: 1;
    padding: 12px 0;
    border: none;
    background: transparent;
    border-radius: 25px;
    font-size: 15px;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.switch-tab.active {
    background-color: var(--color-primary-green);
    color: white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* Ocultar seção inativa */
.content-section {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
}

/* Seção ativa assume o layout flex em coluna */
.content-section.active {
    display: flex; 
    flex-direction: column;
    gap: 12px;
    margin-bottom: 120px; /* Espaço para os botões fixos embaixo */
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

#tituloApenasCupons {
    text-align: center;
    margin-bottom: 20px;
}