:root {
    --primary: #0066CC;
    --primary-light: #3388DD;
    --primary-dark: #004C99;
    --accent: #00AAFF;
    --bg-primary: #FFFFFF;
    --bg-secondary: #F0F4F8;
    --bg-card: #EBF5FF;
    --text-primary: #1A1A2E;
    --text-secondary: #4A5568;
    --text-muted: #94A3B8;
    --border-color: #E2E8F0;
    --success: #10B981;
    --error: #EF4444;
    --warning: #F59E0B;
    --shadow: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-lg: 0 4px 20px rgba(0,0,0,0.1);
    --radius: 14px;
    --radius-sm: 10px;
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
}

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

html {
    font-size: 16px;
    -webkit-tap-highlight-color: transparent;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-secondary);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100dvh;
}

a { text-decoration: none; color: inherit; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
input, select, textarea { font-family: inherit; font-size: 1rem; }
img { max-width: 100%; display: block; }

/* ── APP CONTAINER ─────────────────────────────── */
.app {
    max-width: 480px;
    margin: 0 auto;
    min-height: 100dvh;
    background: var(--bg-primary);
    position: relative;
    padding-bottom: calc(72px + var(--safe-bottom));
}

/* ── HEADER ────────────────────────────────────── */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    padding-top: calc(16px + var(--safe-top));
    background: var(--bg-primary);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border-color);
}
.header-title {
    font-size: 1.15rem;
    font-weight: 600;
}
.header-back {
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 10px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    transition: background .2s;
}
.header-back:active { background: var(--border-color); }
.header-back svg { width: 20px; height: 20px; }
.header-actions { display: flex; gap: 8px; }
.header-btn {
    width: 36px; height: 36px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 10px;
    background: var(--bg-secondary);
    color: var(--text-secondary);
    transition: background .2s;
}
.header-btn:active { background: var(--border-color); }
.header-btn svg { width: 20px; height: 20px; }

/* ── LOGIN PAGE ────────────────────────────────── */
.login-container {
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 28px;
    background: linear-gradient(160deg, #f0f7ff 0%, #ffffff 50%, #e8f4fd 100%);
}
.login-logo {
    width: 140px;
    margin-bottom: 32px;
}
.login-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}
.login-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 32px;
}
.login-form {
    width: 100%;
    max-width: 380px;
}
.input-group {
    margin-bottom: 18px;
}
.input-label {
    display: block;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 6px;
}
.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}
.input-icon {
    position: absolute;
    left: 14px;
    width: 18px; height: 18px;
    color: var(--text-muted);
    pointer-events: none;
}
.input-field {
    width: 100%;
    padding: 13px 14px 13px 42px;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: border-color .2s, box-shadow .2s;
    outline: none;
}
.input-field:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0,102,204,0.12);
}
.input-field::placeholder { color: var(--text-muted); }
.toggle-password {
    position: absolute;
    right: 12px;
    padding: 4px;
    color: var(--text-muted);
    background: none;
    border: none;
}
.toggle-password .eye-icon { width: 20px; height: 20px; }

/* ── BUTTONS ───────────────────────────────────── */
.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 14px;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    font-weight: 600;
    transition: transform .15s, opacity .15s;
    gap: 8px;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    box-shadow: 0 4px 14px rgba(0,102,204,0.3);
}
.btn-primary:hover { opacity: 0.92; }
.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary);
}
.btn-sm {
    padding: 8px 16px;
    font-size: 0.82rem;
    width: auto;
    border-radius: 8px;
}
.login-links {
    text-align: center;
    margin-top: 16px;
}
.login-link {
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 500;
}
.login-divider {
    display: flex;
    align-items: center;
    margin: 24px 0;
    color: var(--text-muted);
    font-size: 0.82rem;
    gap: 12px;
}
.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
}
.login-footer {
    margin-top: 32px;
    text-align: center;
}
.login-version {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* ── LOADING ───────────────────────────────────── */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}
.loading-overlay.hidden { display: none; }
.loading-spinner {
    width: 40px; height: 40px;
    border: 3px solid var(--border-color);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── HOME HEADER ───────────────────────────────── */
.home-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 24px 20px;
    padding-top: calc(24px + var(--safe-top));
    border-radius: 0 0 24px 24px;
    color: #fff;
}
.home-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}
.home-header-logo {
    height: 36px;
    width: auto;
}
.home-header-icons { display: flex; gap: 10px; }
.home-header-icon {
    width: 38px; height: 38px;
    border-radius: 10px;
    background: rgba(255,255,255,0.18);
    display: flex; align-items: center; justify-content: center;
    border: none;
    color: #fff;
    transition: background .2s;
}
.home-header-icon:active { background: rgba(255,255,255,0.3); }
.home-header-icon svg { width: 20px; height: 20px; }
.home-greeting {
    font-size: 0.88rem;
    opacity: 0.85;
    margin-bottom: 2px;
}
.home-user-name {
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.2;
}
.home-user-row {
    display: flex;
    align-items: center;
    gap: 14px;
}
.home-avatar {
    width: 50px; height: 50px;
    border-radius: 50%;
    border: 2.5px solid rgba(255,255,255,0.5);
    object-fit: cover;
    background: rgba(255,255,255,0.2);
}

/* ── QUICK ACTIONS ─────────────────────────────── */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 16px 20px;
    margin-top: -18px;
    position: relative;
    z-index: 1;
}
.quick-action {
    background: var(--bg-primary);
    border-radius: var(--radius);
    padding: 14px 10px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: transform .2s, box-shadow .2s;
}
.quick-action:active { transform: scale(0.96); }
.quick-action-icon {
    width: 42px; height: 42px;
    border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 8px;
}
.quick-action-icon svg { width: 20px; height: 20px; }
.quick-action-icon.blue   { background: #EBF5FF; color: var(--primary); }
.quick-action-icon.cyan   { background: #E0F7FA; color: #0097A7; }
.quick-action-icon.green  { background: #ECFDF5; color: var(--success); }
.quick-action-icon.purple { background: #F3E8FF; color: #8B5CF6; }
.quick-action-icon.yellow { background: #FFF8E1; color: var(--warning); }
.quick-action-icon.red    { background: #FEE2E2; color: var(--error); }
.quick-action-label {
    font-size: 0.76rem;
    font-weight: 500;
    color: var(--text-secondary);
}

/* ── SECTION ───────────────────────────────────── */
.section-title {
    font-size: 1rem;
    font-weight: 600;
    padding: 0 20px;
    margin: 8px 0 12px;
}

/* ── CARDS ──────────────────────────────────────── */
.card {
    margin: 0 20px 16px;
    background: var(--bg-primary);
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: var(--shadow);
}
.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}
.card-icon {
    width: 40px; height: 40px;
    border-radius: var(--radius-sm);
    background: var(--bg-card);
    display: flex; align-items: center; justify-content: center;
    color: var(--primary);
    flex-shrink: 0;
}
.card-icon svg { width: 20px; height: 20px; }
.card-title {
    font-size: 0.92rem;
    font-weight: 600;
}
.card-subtitle {
    font-size: 0.78rem;
    color: var(--text-muted);
}
.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}
.card-value {
    font-size: 1.1rem;
    font-weight: 700;
}
.card-link {
    font-size: 0.8rem;
    color: var(--primary);
    font-weight: 500;
}

/* ── STATUS BADGE ──────────────────────────────── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    padding: 3px 10px;
    border-radius: 20px;
}
.badge-success { background: #ECFDF5; color: var(--success); }
.badge-error   { background: #FEE2E2; color: var(--error); }
.badge-warning { background: #FFF8E1; color: var(--warning); }
.badge-info    { background: var(--bg-card); color: var(--primary); }
.badge::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    background: currentColor;
}

/* ── INFO BANNER ───────────────────────────────── */
.info-banner {
    margin: 0 20px 20px;
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.info-banner-icon {
    width: 40px; height: 40px;
    border-radius: var(--radius-sm);
    background: rgba(0,102,204,0.12);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    color: var(--primary);
}
.info-banner-icon svg { width: 20px; height: 20px; }
.info-banner-text {
    font-size: 0.84rem;
    color: var(--text-secondary);
    line-height: 1.4;
}
.info-banner-text strong { color: var(--text-primary); }

/* ── PROMO PIX ─────────────────────────────────── */
.promo-banner {
    margin: 12px 20px 14px;
    background: linear-gradient(135deg, #EBF5FF 0%, #DDF0FF 100%);
    border: 1px solid rgba(0, 102, 204, 0.15);
    border-radius: 16px;
    padding: 14px;
    box-shadow: var(--shadow);
}
.promo-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}
.promo-pix-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(0, 102, 204, 0.12);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.promo-pix-icon svg { width: 20px; height: 20px; }
.promo-header-title {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--primary-dark);
    letter-spacing: 0.04em;
}
.promo-header-subtitle {
    font-size: 0.86rem;
    color: var(--text-secondary);
}
.promo-plano-label {
    font-size: 0.76rem;
    color: var(--text-muted);
}
.promo-plano-nome {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 2px;
}
.promo-valores {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    flex-wrap: wrap;
}
.promo-valor-original {
    font-size: 0.82rem;
    color: var(--text-muted);
    text-decoration: line-through;
}
.promo-valor-desconto {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary);
}
.promo-badge {
    font-size: 0.68rem;
    font-weight: 700;
    background: var(--primary);
    color: #fff;
    padding: 3px 8px;
    border-radius: 999px;
}
.promo-footer {
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.promo-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--primary);
    color: #fff;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 0.82rem;
    font-weight: 600;
    transition: transform 0.15s, opacity 0.15s;
}
.promo-btn:active { transform: scale(0.98); }
.promo-btn svg { width: 16px; height: 16px; }
.promo-timer {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--text-secondary);
    font-size: 0.82rem;
    font-weight: 600;
}
.promo-timer-icon { width: 14px; height: 14px; }

.modal-pix {
    position: fixed;
    inset: 0;
    z-index: 1300;
    display: none;
}
.modal-pix.active { display: block; }
.modal-pix-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
}
.modal-pix-content {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: min(92vw, 420px);
    background: #fff;
    border-radius: 14px;
    box-shadow: var(--shadow-lg);
    padding: 16px;
}
.modal-pix-content h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}
.modal-pix-fechar {
    position: absolute;
    right: 10px;
    top: 8px;
    font-size: 24px;
    color: var(--text-muted);
    line-height: 1;
}
.pix-valor {
    margin: 10px 0 12px;
    font-size: 0.92rem;
    color: var(--text-secondary);
}
.pix-valor strong {
    color: var(--primary);
    font-size: 1.12rem;
}
.pix-qrcode {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 8px 0 12px;
}
.pix-qrcode img,
.pix-qrcode canvas {
    width: 180px;
    height: 180px;
    max-width: 100%;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: #fff;
    padding: 6px;
}
.pix-instrucao {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}
.pix-codigo-container {
    display: flex;
    align-items: center;
    gap: 8px;
}
.pix-codigo-container input {
    flex: 1;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px;
    font-size: 0.82rem;
}
.btn-copiar {
    background: var(--primary);
    color: #fff;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 0.78rem;
    font-weight: 600;
}
.btn-copiar.copiado { background: var(--success); }
.pix-status {
    margin-top: 12px;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 0.82rem;
    font-weight: 500;
}
.pix-status span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.pix-status svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}
.pix-status.aguardando {
    background: #EFF6FF;
    color: #1D4ED8;
}
.pix-status.aprovado {
    background: #ECFDF5;
    color: #047857;
}
.pix-status.expirado {
    background: #FEF2F2;
    color: #B91C1C;
}
.pix-loading {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(0, 102, 204, 0.2);
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin .8s linear infinite;
}
.pix-tentar-novamente {
    margin-top: 10px;
    width: 100%;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 0.82rem;
    font-weight: 600;
    background: #fff;
    color: #B91C1C;
    border: 1px solid rgba(185, 28, 28, 0.25);
}

/* ── TABS ──────────────────────────────────────── */
.tabs {
    display: flex;
    padding: 0 20px;
    gap: 0;
    margin-bottom: 16px;
    border-bottom: 1.5px solid var(--border-color);
}
.tab {
    flex: 1;
    padding: 10px 0;
    text-align: center;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-muted);
    border-bottom: 2.5px solid transparent;
    margin-bottom: -1.5px;
    cursor: pointer;
    transition: color .2s;
}
.tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

/* ── CALENDARIO ────────────────────────────────── */
.calendario {
    display: flex;
    gap: 6px;
    padding: 0 20px;
    margin-bottom: 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.calendario::-webkit-scrollbar { display: none; }
.calendario-dia {
    min-width: 50px;
    padding: 10px 6px;
    border-radius: var(--radius-sm);
    text-align: center;
    cursor: pointer;
    background: var(--bg-primary);
    border: 1.5px solid var(--border-color);
    transition: all .2s;
    flex-shrink: 0;
}
.calendario-dia.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}
.calendario-dia .dia-semana {
    font-size: 0.68rem;
    font-weight: 500;
    text-transform: uppercase;
    opacity: 0.7;
}
.calendario-dia .dia-numero {
    font-size: 1.05rem;
    font-weight: 700;
    margin-top: 2px;
}

/* ── AULA CARD ─────────────────────────────────── */
.aula-card {
    margin: 0 20px 10px;
    background: var(--bg-primary);
    border-radius: var(--radius);
    padding: 14px 16px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: transform .2s;
}
.aula-card:active { transform: scale(0.98); }
.aula-horario {
    text-align: center;
    min-width: 50px;
}
.aula-hora {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary);
}
.aula-duracao {
    font-size: 0.68rem;
    color: var(--text-muted);
}
.aula-info { flex: 1; }
.aula-nome {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 2px;
}
.aula-professor {
    font-size: 0.78rem;
    color: var(--text-secondary);
}
.aula-vagas {
    font-size: 0.72rem;
    padding: 3px 8px;
    border-radius: 20px;
    background: #ECFDF5;
    color: var(--success);
    font-weight: 500;
    white-space: nowrap;
}
.aula-vagas.lotada {
    background: #FEE2E2;
    color: var(--error);
}

/* ── TIMELINE POST ─────────────────────────────── */
.post {
    margin: 0 20px 14px;
    background: var(--bg-primary);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}
.post-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px 10px;
}
.post-avatar {
    width: 38px; height: 38px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--bg-secondary);
}
.post-author {
    font-size: 0.88rem;
    font-weight: 600;
}
.post-date {
    font-size: 0.72rem;
    color: var(--text-muted);
}
.post-image {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
}
.post-body {
    padding: 12px 16px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.5;
}
.post-actions {
    display: flex;
    gap: 20px;
    padding: 8px 16px 14px;
}
.post-action {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    color: var(--text-muted);
    cursor: pointer;
}
.post-action svg { width: 18px; height: 18px; }

/* ── PERFIL ────────────────────────────────────── */
.perfil-header {
    text-align: center;
    padding: 30px 20px 20px;
}
.perfil-avatar {
    width: 90px; height: 90px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 14px;
    border: 3px solid var(--primary);
    background: var(--bg-secondary);
}
.perfil-nome {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 4px;
}
.perfil-academia {
    font-size: 0.82rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.perfil-id {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 4px;
}
.perfil-stats {
    display: flex;
    justify-content: center;
    gap: 28px;
    margin-top: 18px;
    padding: 14px;
    background: var(--bg-secondary);
    border-radius: var(--radius);
    margin: 18px 20px 0;
}
.perfil-stat { text-align: center; }
.perfil-stat-value {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary);
}
.perfil-stat-label {
    font-size: 0.72rem;
    color: var(--text-muted);
}

/* ── PERFIL MENU ───────────────────────────────── */
.perfil-menu {
    padding: 16px 20px;
}
.perfil-menu-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    transition: opacity .2s;
}
.perfil-menu-item:last-child { border-bottom: none; }
.perfil-menu-item:active { opacity: 0.6; }
.perfil-menu-item svg {
    width: 20px; height: 20px;
    color: var(--text-muted);
    flex-shrink: 0;
}
.perfil-menu-item span {
    flex: 1;
    font-size: 0.9rem;
    font-weight: 500;
}
.perfil-menu-item .chevron {
    width: 16px; height: 16px;
    color: var(--text-muted);
}

/* ── DATA LIST ─────────────────────────────────── */
.data-list {
    padding: 0 20px;
}
.data-item {
    padding: 14px 0;
    border-bottom: 1px solid var(--border-color);
}
.data-item:last-child { border-bottom: none; }
.data-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}
.data-value {
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--text-primary);
}

/* ── CONTRATO CARD ─────────────────────────────── */
.contrato-card {
    margin: 0 20px 12px;
    background: var(--bg-primary);
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--primary);
}
.contrato-card.inativo { border-left-color: var(--text-muted); }
.contrato-nome {
    font-size: 0.92rem;
    font-weight: 600;
    margin-bottom: 8px;
}
.contrato-info {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px;
}
.contrato-info-item {
    font-size: 0.78rem;
    color: var(--text-secondary);
}
.contrato-info-item strong {
    display: block;
    font-size: 0.92rem;
    color: var(--text-primary);
}

/* ── PAGAMENTO ITEM ────────────────────────────── */
.pagamento-item {
    margin: 0 20px 10px;
    background: var(--bg-primary);
    border-radius: var(--radius);
    padding: 14px 16px;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.pagamento-info { flex: 1; }
.pagamento-desc {
    font-size: 0.88rem;
    font-weight: 500;
    margin-bottom: 2px;
}
.pagamento-data {
    font-size: 0.75rem;
    color: var(--text-muted);
}
.pagamento-valor {
    font-size: 1rem;
    font-weight: 700;
    text-align: right;
}
.pagamento-status {
    font-size: 0.72rem;
    margin-top: 2px;
    text-align: right;
}
.pagamento-status.pago { color: var(--success); }
.pagamento-status.pendente { color: var(--warning); }
.pagamento-status.atrasado { color: var(--error); }

/* ── CARTEIRA ──────────────────────────────────── */
.carteira-card {
    margin: 20px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 20px;
    padding: 24px;
    color: #fff;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}
.carteira-card::after {
    content: '';
    position: absolute;
    top: -40px; right: -40px;
    width: 120px; height: 120px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
}
.carteira-marca {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 20px;
}
.carteira-nome {
    font-size: 0.92rem;
    font-weight: 500;
    opacity: 0.9;
    margin-bottom: 4px;
}
.carteira-id {
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 2px;
}
.carteira-qr {
    margin: 20px auto;
    width: 180px; height: 180px;
    background: #fff;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
}
.carteira-qr canvas, .carteira-qr img {
    width: 100%; height: 100%;
}

/* ── BOTTOM NAV ────────────────────────────────── */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 480px;
    background: var(--bg-primary);
    display: flex;
    justify-content: space-around;
    padding: 8px 0;
    padding-bottom: calc(8px + var(--safe-bottom));
    border-top: 1px solid var(--border-color);
    z-index: 200;
}
.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 4px 8px;
    font-size: 0.68rem;
    color: var(--text-muted);
    font-weight: 500;
    transition: color .2s;
}
.nav-item.active { color: var(--primary); }
.nav-item svg { width: 22px; height: 22px; }

/* ── MENU LATERAL ──────────────────────────────── */
.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .3s, visibility .3s;
}
.menu-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.menu-lateral {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100vh;
    height: 100dvh;
    background: var(--bg-primary);
    z-index: 9999;
    overflow-y: auto;
    transition: right .3s ease;
    box-shadow: -4px 0 20px rgba(0,0,0,0.1);
}
.menu-lateral.active { right: 0; }
.menu-lateral-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 24px 20px;
    padding-top: calc(24px + var(--safe-top));
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
}
.menu-lateral-avatar {
    width: 48px; height: 48px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.5);
    object-fit: cover;
    background: rgba(255,255,255,0.2);
}
.menu-lateral-user { flex: 1; min-width: 0; }
.menu-lateral-nome {
    font-size: 0.95rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.menu-lateral-email {
    font-size: 0.75rem;
    opacity: 0.8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.menu-lateral-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    font-size: 0.88rem;
    color: var(--text-primary);
    transition: background .2s;
}
.menu-lateral-item:active { background: var(--bg-secondary); }
.menu-lateral-item svg {
    width: 20px; height: 20px;
    color: var(--text-muted);
    flex-shrink: 0;
}
.menu-lateral-divider {
    height: 1px;
    background: var(--border-color);
    margin: 4px 20px;
}
.menu-lateral-sair { color: var(--error); }
.menu-lateral-sair svg { color: var(--error); }

/* ── TOAST ─────────────────────────────────────── */
.toast {
    position: fixed;
    bottom: 90px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--text-primary);
    color: #fff;
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 0.85rem;
    z-index: 10000;
    opacity: 0;
    transition: all .3s ease;
    pointer-events: none;
    white-space: nowrap;
    max-width: 90%;
    text-align: center;
}
.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ── EMPTY STATE ───────────────────────────────── */
.empty-state {
    text-align: center;
    padding: 40px 20px;
}
.empty-state svg {
    width: 64px; height: 64px;
    color: var(--text-muted);
    margin-bottom: 16px;
    opacity: 0.4;
}
.empty-state p {
    font-size: 0.88rem;
    color: var(--text-muted);
}

/* ── SKELETON LOADING ──────────────────────────── */
.skeleton {
    background: linear-gradient(90deg, var(--bg-secondary) 25%, #e8edf2 50%, var(--bg-secondary) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 6px;
}
.skeleton-text { height: 14px; margin-bottom: 8px; }
.skeleton-text.short { width: 60%; }
.skeleton-avatar { width: 48px; height: 48px; border-radius: 50%; }
.skeleton-card { height: 80px; margin: 0 20px 10px; border-radius: var(--radius); }
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* ── CARTEIRA ───────────────────────────────────── */
.carteira-section {
    padding: 20px;
}
.carteira-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: var(--radius);
    padding: 24px;
    color: #fff;
    box-shadow: var(--shadow-lg);
    margin-bottom: 24px;
}
.carteira-marca {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    opacity: 0.9;
    margin-bottom: 8px;
}
.carteira-nome {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 4px;
}
.carteira-id {
    font-size: 0.9rem;
    font-family: monospace;
    letter-spacing: 0.15em;
    opacity: 0.95;
}
.carteira-qr-wrap {
    text-align: center;
    margin-bottom: 24px;
}
.carteira-qr {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    padding: 12px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
    margin-bottom: 12px;
}
.carteira-qr canvas {
    display: block;
}
.carteira-qr-hint {
    font-size: 0.82rem;
    color: var(--text-muted);
}
.carteira-info {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 16px;
}
.carteira-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
}
.carteira-info-row:last-child { border-bottom: none; }
.carteira-info-label {
    font-size: 0.88rem;
    color: var(--text-secondary);
}
.carteira-info-value {
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* ── WOD ───────────────────────────────────────── */
.wod-date {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 12px;
}
.wod-empty-msg {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin: 0;
}
.wod-card {
    margin: 0 20px 14px;
    background: var(--bg-primary);
    border-radius: var(--radius);
    padding: 16px;
    box-shadow: var(--shadow);
}
.wod-title {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--primary);
}
.wod-exercises {
    list-style: none;
}
.wod-exercise {
    padding: 8px 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 8px;
}
.wod-exercise:last-child { border-bottom: none; }
.wod-exercise::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--primary);
    flex-shrink: 0;
}
.historico-item {
    margin: 0 20px 12px;
    background: var(--bg-primary);
    border-radius: var(--radius);
    padding: 14px;
    box-shadow: var(--shadow);
}
.historico-data {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-bottom: 6px;
}
.historico-exercicio {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
}
.historico-resultado {
    font-size: 0.82rem;
    color: var(--primary);
}

/* ── UTILITIES ─────────────────────────────────── */
.hidden { display: none !important; }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-16 { margin-top: 16px; }
.mb-16 { margin-bottom: 16px; }
.px-20 { padding-left: 20px; padding-right: 20px; }
.py-20 { padding-top: 20px; padding-bottom: 20px; }
