/* Login e Cadastro */
.login-container,
.cadastro-container {
    min-height: calc(100vh - 400px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 16px;
    background: linear-gradient(135deg, #071C39 0%, #0D3B73 100%);
}

.login-box,
.cadastro-box {
    background: white;
    border-radius: 10px;
    padding: 40px;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    animation: fadeInUp 0.5s ease;
}

.cadastro-box {
    max-width: 700px;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-header,
.cadastro-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header i,
.cadastro-header i {
    font-size: 60px;
    color: #0D3B73;
    margin-bottom: 10px;
}

.login-header h2,
.cadastro-header h2 {
    color: #071C39;
    margin-bottom: 5px;
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #071C39;
    font-weight: 500;
}

.form-group label i {
    margin-right: 8px;
    color: #0D3B73;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 16px;
    transition: all 0.3s;
}

.form-group input:focus,
.form-group select:focus {
    border-color: #071C39;
    outline: none;
}

.toggle-password {
    position: absolute;
    right: 12px;
    top: 42px;
    cursor: pointer;
    color: #999;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.checkbox-label input {
    margin-right: 8px;
}

.forgot-password {
    color: #0D3B73;
    text-decoration: none;
    font-size: 14px;
}

.forgot-password:hover {
    text-decoration: underline;
}

.btn-login,
.btn-cadastrar,
.btn-salvar {
    width: 100%;
    padding: 14px;
    background: #071C39;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-login:hover,
.btn-cadastrar:hover,
.btn-salvar:hover {
    background: #0D3B73;
}

.btn-register {
    display: block;
    text-align: center;
    padding: 12px;
    background: #071C39;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s;
}

.btn-register:hover {
    background: #050f1f;
}

.login-divider {
    text-align: center;
    margin: 20px 0;
    position: relative;
}

.login-divider::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 45%;
    height: 1px;
    background: #ddd;
}

.login-divider::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    width: 45%;
    height: 1px;
    background: #ddd;
}

.login-divider span {
    background: white;
    padding: 0 10px;
    color: #999;
}

.login-link {
    text-align: center;
    margin-top: 20px;
}

.form-terms {
    margin: 20px 0;
}

/* Minha Conta (mobile-first: base = celular, @media min-width:769px = desktop) */
.minha-conta-container {
    padding: 24px 0 40px;
    background: #f8f9fa;
    min-height: calc(100vh - 400px);
    overflow-x: hidden;
    max-width: 100vw;
}

.conta-header {
    text-align: center;
    margin-bottom: 24px;
    padding: 0 16px;
}

.conta-header h1 {
    color: #071C39;
    margin-bottom: 10px;
}

.conta-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
    padding: 0 16px;
}

.conta-sidebar {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    height: fit-content;
    min-width: 0;
}

/* Mobile: avatar + nome/e-mail em linha, compacto (menos altura antes do conteúdo) */
.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    padding-bottom: 14px;
    border-bottom: 1px solid #ecf0f1;
    margin-bottom: 12px;
}

.user-avatar {
    color: #0D3B73;
    flex-shrink: 0;
}

.user-info h3 {
    margin: 0;
    font-size: 15px;
    color: #071C39;
}

.user-info p {
    color: #7f8c8d;
    font-size: 12.5px;
    word-break: break-all;
}

/* Mobile: abas horizontais roláveis - evita empilhar o menu inteiro antes do conteúdo */
.conta-menu ul {
    list-style: none;
    display: flex;
    gap: 8px;
    margin: 0 0 16px;
    padding-bottom: 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    width: 100%;
    min-width: 0;
}

.conta-menu li {
    flex: 0 0 auto;
    padding: 9px 14px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s;
    color: #6a7280;
    background: #f4f6f9;
    font-size: 13px;
    white-space: nowrap;
}

.conta-menu li i {
    margin-right: 6px;
}

.conta-menu li:hover {
    background: #ecf0f1;
}

.conta-menu li.active {
    background: #071C39;
    color: white;
}

.btn-logout {
    display: block;
    text-align: center;
    padding: 12px;
    background: #E3262E;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s;
    margin-top: 20px;
}

.btn-logout:hover {
    background: #B91F26;
}

.conta-main {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

.tab-content h2 {
    margin-bottom: 20px;
    color: #071C39;
    padding-bottom: 10px;
    border-bottom: 2px solid #ecf0f1;
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #7f8c8d;
}

.empty-state i {
    color: #bdc3c7;
    margin-bottom: 20px;
}

.empty-state p {
    margin-bottom: 20px;
}

.pedidos-list {
    display: grid;
    gap: 20px;
}

.pedido-card {
    border: 1px solid #ecf0f1;
    border-radius: 8px;
    overflow: hidden;
}

.pedido-header {
    background: #f8f9fa;
    padding: 15px 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 6px 12px;
    border-bottom: 1px solid #ecf0f1;
}

.pedido-number {
    font-weight: bold;
    color: #071C39;
}

.pedido-date {
    color: #7f8c8d;
}

.pedido-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
}

.pedido-total {
    font-size: 18px;
    font-weight: bold;
    color: #E3262E;
}

.pedido-status {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: bold;
}

.status-pendente {
    background: #f39c12;
    color: white;
}

.status-pago {
    background: #27ae60;
    color: white;
}

.status-enviado {
    background: #071C39;
    color: white;
}

.status-entregue {
    background: #2ecc71;
    color: white;
}

.status-cancelado {
    background: #E3262E;
    color: white;
}

.pedido-footer {
    padding: 15px 20px;
    background: #f8f9fa;
    border-top: 1px solid #ecf0f1;
}

.btn-detalhes {
    padding: 8px 20px;
    background: #071C39;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.endereco-card {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-top: 15px;
}

.btn-editar-endereco {
    margin-top: 15px;
    padding: 8px 20px;
    background: #071C39;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Desktop (mobile-first: aqui entram as colunas largas, sidebar fixa etc.) */
@media (min-width: 769px) {
    .minha-conta-container {
        padding: 60px 0;
    }

    .conta-header {
        margin-bottom: 40px;
        padding: 0;
    }

    .conta-content {
        grid-template-columns: 280px 1fr;
        gap: 30px;
        padding: 0;
    }

    .conta-sidebar {
        padding: 30px;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        position: sticky;
        top: 20px;
    }

    /* Desktop: avatar e dados centralizados, empilhados (como era antes) */
    .user-info {
        display: block;
        text-align: center;
        padding-bottom: 20px;
        margin-bottom: 20px;
    }
    .user-avatar { margin-bottom: 10px; }
    .user-info h3 { margin: 10px 0 5px; font-size: 16px; }
    .user-info p { font-size: 14px; word-break: normal; }

    /* Desktop: menu volta a ser uma lista vertical de bloco cheio */
    .conta-menu ul {
        display: block;
        overflow-x: visible;
        margin-bottom: 20px;
        padding-bottom: 0;
    }
    .conta-menu li {
        display: block;
        padding: 12px 15px;
        margin-bottom: 5px;
        border-radius: 5px;
        background: transparent;
        font-size: 14px;
        white-space: normal;
    }
    .conta-menu li i { width: 20px; margin-right: 10px; }

    .conta-main {
        padding: 30px;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }

    .form-row {
        grid-template-columns: 1fr 1fr;
        gap: 20px;
    }

    .login-box,
    .cadastro-box {
        padding: 40px;
    }

    .pedido-body {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        text-align: left;
    }
}