/* Reset e Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8fafc;
    color: #1a202c;
    line-height: 1.6;
}

/* Utilities */
.mb-0 { margin-bottom: 0 !important; }
.mb-1 { margin-bottom: 0.5rem !important; }
.mb-2 { margin-bottom: 1rem !important; }
.mb-3 { margin-bottom: 1.5rem !important; }
.mt-1 { margin-top: 0.5rem !important; }
.mt-2 { margin-top: 1rem !important; }
.mt-3 { margin-top: 1.5rem !important; }
.ml-auto { margin-left: auto !important; }
.pt-1 { padding-top: 0.5rem !important; }
.pt-2 { padding-top: 1rem !important; }
.pt-3 { padding-top: 1.5rem !important; }
.pb-1 { padding-bottom: 0.5rem !important; }
.pb-2 { padding-bottom: 1rem !important; }
.pb-3 { padding-bottom: 1.5rem !important; }
.text-center { text-align: center !important; }
.flex-col { display: flex !important; flex-direction: column !important; }
.items-stretch { align-items: stretch !important; }
.no-pointer { cursor: default !important; }
.d-inline { display: inline !important; }

/* Hero simples (dashboard) */
.hero {
    text-align: center;
    padding: 0.75rem 1rem;
}
.hero h1 { margin: 0; font-weight: 800; letter-spacing: 2px; color: #1a202c; }
.coach-greeting { color: #2d3748; font-weight: 600; }

/* Linhas auxiliares */
.chip-row { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: 0.25rem; }
.btn-row { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.btn-row .btn { flex: 1; justify-content: center; }
.full-cta { display: block; text-decoration: none; }
.full-cta .stat-card { justify-content: space-between; }

/* Portal do Aluno: usar conteúdo em largura total */
body.portal .sidebar { display: none; }
body.portal .main-content { margin-left: 0; }

/* Layout Principal */
.dashboard-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.logo {
    padding: 2rem 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.logo h2 {
    font-size: 1.5rem;
    font-weight: 600;
    text-align: center;
}

.logo i {
    margin-right: 0.5rem;
    color: #ffd700;
}

.sidebar nav {
    padding: 1rem 0;
}

.sidebar nav ul {
    list-style: none;
}

.sidebar nav li {
    margin: 0.25rem 1rem;
}

.sidebar nav a {
    display: flex;
    align-items: center;
    padding: 0.875rem 1rem;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.sidebar nav a i {
    margin-right: 0.75rem;
    width: 20px;
    text-align: center;
}

.sidebar nav li.active a,
.sidebar nav a:hover {
    background-color: rgba(255,255,255,0.15);
    color: white;
    transform: translateX(4px);
}

/* Mobile Navigation */
.mobile-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: white;
    border-top: 1px solid #e2e8f0;
    display: none;
    justify-content: space-around;
    padding: 0.35rem 0;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.08);
}

.mobile-nav-link {
    flex: 1;
    text-align: center;
    color: #718096;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.75rem;
    font-weight: 600;
    gap: 0.15rem;
}

.mobile-nav-link i {
    font-size: 1.1rem;
}

.mobile-nav-link.active,
.mobile-nav-link:hover {
    color: #667eea;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 260px;
    background-color: #f8fafc;
}

.content-header {
    background: white;
    padding: 2rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.header-buttons {
    display: flex;
    gap: 1rem;
    align-items: center;
}

/* Back Button */
.back-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: none;
    background: #edf2f7; /* cinza claro */
    color: #4a5568; /* cinza escuro */
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.back-button i {
    margin: 0;
    font-size: 1rem;
}

.back-button:hover {
    background: #e2e8f0;
}

.back-button:active {
    transform: translateY(1px);
}


/* Content Areas */

.content-header h1 {
    font-size: 2rem;
    font-weight: 600;
    color: #2d3748;
}

/* Botões */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
}

.btn i {
    margin-right: 0.5rem;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-success {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    color: white;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(72, 187, 120, 0.4);
}

.btn-secondary {
    background-color: #e2e8f0;
    color: #4a5568;
}

.btn-warning {
    background: linear-gradient(135deg, #f6ad55 0%, #ed8936 100%);
    color: white;
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(246, 173, 85, 0.4);
}

.btn-danger {
    background: linear-gradient(135deg, #f56565 0%, #e53e3e 100%);
    color: white;
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(229, 62, 62, 0.4);
}

.btn-outline {
    background: transparent;
    color: #4a5568;
    border: 2px solid #e2e8f0;
}

.btn-outline:hover {
    background: #f7fafc;
}

.btn-sm {
    padding: 0.4rem 0.75rem;
    font-size: 0.8rem;
    border-radius: 6px;
}

.user-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #eef2ff;
    color: #3730a3;
    padding: 0.35rem 0.6rem;
    border-radius: 999px;
    margin-right: 0.5rem;
}

.edit-info {
    background-color: #f7fafc;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    color: #2d3748;
}

/* Content Area */
.content-area {
    padding: 2rem;
}

/* Flash Messages */
.flash-messages {
    margin: 1rem 2rem;
}

.alert {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    position: relative;
    transition: all 0.3s ease;
}

.alert i {
    margin-right: 0.75rem;
}

.alert-success {
    background-color: #f0fff4;
    color: #38a169;
    border-left: 4px solid #48bb78;
}

.close-btn {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: inherit;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    min-height: 110px; /* uniformiza altura dos cards de estatística */
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.stat-card-link:hover .stat-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.stat-card-link:hover .stat-icon {
    background: rgba(255,255,255,0.2);
    color: white;
}

.stat-card-link:hover .stat-arrow {
    opacity: 1;
    transform: translateX(5px);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 1.5rem;
}

.stat-content h3 {
    font-size: 2rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 0.25rem;
}
.table-container {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.data-table th, .data-table td {
    padding: 0.85rem 1rem;
    text-align: left;
    border-bottom: 1px solid #edf2f7;
    font-size: 0.95rem;
}

.data-table thead {
    background: #f7fafc;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* (removido duplicado: lista genérica) */

/* Responsividade específica para Leads (tabela -> cartões) */
@media (max-width: 768px) {
    .content-header { padding: 1rem; }
    .content-area { padding: 1rem; }

    .data-table, .data-table thead, .data-table tbody, .data-table th, .data-table td, .data-table tr {
        display: block;
    }
    .data-table thead { 
        position: absolute; 
        width: 1px; height: 1px; 
        overflow: hidden; 
        clip: rect(0 0 0 0);
    }
    .data-table tr {
        background: white;
        margin-bottom: 0.75rem;
        border-radius: 12px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
        padding: 0.25rem 0.5rem;
    }
    .data-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        border-bottom: 1px solid #edf2f7;
    }
    .data-table td:last-child { border-bottom: none; }
    .data-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #4a5568;
        margin-right: 1rem;
    }
}

.stat-content p {
    color: #718096;
    font-weight: 500;
}

.stat-arrow {
    margin-left: auto;
    opacity: 0;
    transform: translateX(-5px);
    transition: all 0.3s ease;
    font-size: 1.2rem;
    color: #cbd5e0;
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.dashboard-section {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.dashboard-section h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
}

.dashboard-section h2 i {
    margin-right: 0.5rem;
    color: #667eea;
}

/* Semana em colunas (calendário) */
.week-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 0.75rem; }
.week-col { background: #fff; border: 1px solid #e2e8f0; border-radius: 8px; padding: 0.5rem; min-height: 120px; }
.week-col-header { display: flex; justify-content: space-between; align-items: center; font-weight: 600; color: #2d3748; margin-bottom: 0.5rem; }
.week-item { background: #f9fafb; border: 1px dashed #e2e8f0; border-radius: 8px; padding: 0.5rem 0.6rem; margin-bottom: 0.5rem; }
.week-item .meta { color: #718096; font-size: 0.85rem; }

@media (max-width: 1024px) {
    .week-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
    .week-grid { grid-template-columns: repeat(2, 1fr); }
}
/* Ajuste de inputs dentro das colunas do planner */
.week-col .form-group { margin-bottom: 0.6rem; }
.week-col .form-group .form-label { font-size: 0.85rem; }
.week-col .form-control { padding: 0.5rem 0.6rem; }

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2d3748;
    display: flex;
    align-items: center;
}

.section-header h3 i {
    margin-right: 0.5rem;
    color: #667eea;
}

/* List Items */
.list-items {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 0.75rem;
    transition: all 0.3s ease;
}

.list-item:hover {
    border-color: #cbd5e0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* Notificações (borda colorida à esquerda) */
.list-item.notif { border-left: 4px solid #cbd5e0; }
.list-item.notif.notif-warning { border-left-color: #f6e05e; }
.list-item.notif.notif-info { border-left-color: #63b3ed; }
.list-item.notif.notif-default { border-left-color: #cbd5e0; }

.item-info {
    flex: 1;
}

.item-info strong {
    display: block;
    color: #2d3748;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.item-meta {
    color: #718096;
    font-size: 0.875rem;
}

.item-info small {
    display: block;
    color: #a0aec0;
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.no-data {
    text-align: center;
    color: #718096;
    font-style: italic;
    padding: 2rem;
}

/* Turmas */
.turmas-resumo {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.turmas-resumo h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
}

.turmas-resumo h2 i {
    margin-right: 0.5rem;
    color: #667eea;
}

.turmas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.turma-card {
    padding: 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    text-align: center;
    transition: all 0.3s ease;
}

.turma-card:hover {
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.turma-card h4 {
    color: #2d3748;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.turma-card p {
    color: #718096;
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
}

.turma-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    background-color: #48bb78;
    color: white;
}

.turma-badge.online {
    background-color: #667eea;
}

/* Tabela de Dados */
.table-container {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    background-color: #f7fafc;
    padding: 1rem 1.5rem;
    text-align: left;
    font-weight: 600;
    color: #2d3748;
    border-bottom: 1px solid #e2e8f0;
}

.data-table th:nth-child(2) {
    text-align: center;
    width: 80px;
}

.data-table td:nth-child(2) {
    text-align: center;
    width: 80px;
}

.data-table th i {
    margin-right: 0.5rem;
    color: #667eea;
}

.data-table td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.data-table tr:hover {
    background-color: #f8fafc;
}

.user-info {
    display: flex;
    align-items: center;
}

.user-avatar {
    margin-right: 0.75rem;
    color: #667eea;
    font-size: 1.5rem;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
}

/* Contact Icons */
.contact-icons {
    display: flex;
    gap: 0.3rem;
    align-items: center;
    justify-content: center;
}

.contact-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    width: 32px;
    height: 32px;
    border-radius: 4px;
}

.contact-icon i {
    font-size: 18px;
    line-height: 1;
    text-align: center;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.email-icon {
    color: #4299e1;
}

.email-icon:hover {
    transform: translateY(-1px);
    color: #3182ce;
}

.whatsapp-icon {
    color: #48bb78;
}

.whatsapp-icon:hover {
    transform: translateY(-1px);
    color: #38a169;
}

.contact-row {
    align-items: center;
    margin-bottom: 1.5rem;
    justify-content: space-between;
}

.contact-label {
    color: #4a5568;
    font-weight: 500;
    font-size: 0.9rem;
}

.contact-row .contact-icons {
    gap: 0.4rem;
}

/* Mobile Card View */
.alunos-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.aluno-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.aluno-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

.aluno-header {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f1f5f9;
}

.aluno-header .user-info {
    display: flex;
    align-items: center;
}

.user-details h4 {
    margin: 0 0 0.25rem 0;
    color: #2d3748;
    font-weight: 600;
    font-size: 1.1rem;
}

.aluno-info {
    margin-bottom: 1.5rem;
}

.info-row {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    color: #4a5568;
}

.info-row i {
    margin-right: 0.75rem;
    width: 20px;
    color: #667eea;
    font-size: 0.9rem;
}

.info-row span {
    font-size: 0.9rem;
}

.aluno-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* Responsive Display Controls */
.desktop-only {
    display: block;
}

.mobile-only {
    display: none;
}

/* Forms */
.form-container {
    max-width: 600px;
    margin: 0 auto;
}

.form-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #2d3748;
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: white;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-help {
    display: block;
    margin-top: 0.25rem;
    color: #718096;
    font-size: 0.875rem;
}

.error-message {
    margin-top: 0.5rem;
    color: #e53e3e;
    font-size: 0.875rem;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.aluno-info {
    background-color: #f7fafc;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    color: #2d3748;
}

.aluno-info i {
    margin-right: 0.5rem;
    color: #667eea;
}

/* Profile */
.profile-header {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    display: flex;
    align-items: center;
}

.profile-avatar {
    margin-right: 2rem;
    color: #667eea;
    font-size: 4rem;
}

.profile-info h2 {
    font-size: 2rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 1rem;
}

.profile-details p {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    color: #718096;
}

.profile-details i {
    margin-right: 0.75rem;
    width: 20px;
    color: #667eea;
}

.profile-section {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.profile-section h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

/* Perfil (novo header e tabs) */
.profile-hero {
    background: #1E2A47; /* azul escuro */
    color: #fff;
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}
.profile-hero .back-button { background: rgba(255,255,255,0.15); color: #fff; }
.profile-hero .back-button:hover { background: rgba(255,255,255,0.25); }
.profile-hero .hero-info h2 { margin: 0; font-size: 1.4rem; font-weight: 700; }
.status-pill {
    display: inline-block;
    margin-left: 0.5rem;
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    font-size: 0.8rem;
}

/* Header escuro apenas no perfil */
.profile-view .content-header {
    background: #1E2A47;
    color: #fff;
    border-bottom-color: transparent;
}
.profile-view .content-header h1 { color: #fff; }
.profile-view .content-header .back-button { background: rgba(255,255,255,0.15); color:#fff; }
.profile-view .content-header .back-button:hover { background: rgba(255,255,255,0.25); }

.tabs.two-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; margin-bottom: 1rem; }
.tab {
    background: #e6efff;
    color: #1E2A47;
    border: 1px solid #cfd9ff;
    border-radius: 8px;
    padding: 0.6rem 0.75rem;
    font-weight: 600;
    cursor: pointer;
}
.tab.active {
    background: #ffffff;
    border-color: #e2e8f0;
}
.tab-content { margin-bottom: 1rem; }

/* Frequência de treinos (círculos) */
.week-circles { display: flex; gap: 0.5rem; align-items: center; }
.day-circle {
    width: 36px; height: 36px; border-radius: 50%;
    border: 2px solid #667eea; background: #ffffff; color: #1E2A47;
    display: inline-flex; align-items: center; justify-content: center;
    position: relative; font-weight: 700;
}
.day-circle .badge {
    position: absolute; top: -6px; right: -6px;
    width: 16px; height: 16px; border-radius: 50%;
    background: #e53e3e; color: #fff; font-size: 0.7rem;
    display: inline-flex; align-items: center; justify-content: center;
}

/* Lista de opções (cards) - grid, tamanhos uniformes */
.list-cards { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); 
    gap: 0.75rem; 
}
.list-card {
    display: flex; 
    flex-direction: column;
    align-items: center; 
    justify-content: center;
    gap: 0.4rem;
    padding: 0.9rem 0.75rem; 
    text-decoration: none;
    background: #ffffff; 
    color: #2d3748;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    min-height: 92px; /* altura mínima para padronizar */
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.list-card .icon { color: #667eea; width: auto; text-align: center; font-size: 1.1rem; }
.list-card span { font-weight: 600; }
.list-card:hover { background: #f8fafc; border-color: #cbd5e0; }

.actions-stack { display: flex; flex-direction: column; gap: 0.75rem; }
.btn-outline-blue { background: #fff; color: #667eea; border: 2px solid #667eea; }
.btn-outline-blue:hover { background: #eef2ff; }
.btn-outline-red { background: #fff; color: #e53e3e; border: 2px solid #e53e3e; }
.btn-outline-red:hover { background: #ffeef0; }

.profile-section h3 i {
    margin-right: 0.5rem;
    color: #667eea;
}

.objetivo-text {
    color: #4a5568;
    line-height: 1.6;
    font-size: 1rem;
}

/* Treinos */
.treinos-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.treino-card {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.treino-card:hover {
    border-color: #cbd5e0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.treino-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.treino-tipo {
    display: flex;
    align-items: center;
    color: #2d3748;
    font-weight: 600;
}

.treino-tipo i {
    margin-right: 0.5rem;
    color: #667eea;
}

.treino-data {
    color: #718096;
    font-size: 0.875rem;
}

.treino-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 1rem;
}

.stat-item {
    display: flex;
    align-items: center;
    color: #4a5568;
    font-size: 0.875rem;
}

.stat-item i {
    margin-right: 0.5rem;
    color: #667eea;
}

.treino-observacoes {
    background-color: #f7fafc;
    padding: 1rem;
    border-radius: 6px;
    border-left: 4px solid #667eea;
}

.treino-observacoes p {
    color: #4a5568;
    margin: 0;
}

/* Calculadora de Ritmo */
.pace-calculator {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.calc-result {
    display: flex;
    align-items: center;
    font-weight: 500;
}

.calc-result i {
    margin-right: 0.75rem;
    color: #ffd700;
}

/* Turmas Detalhadas */
.turma-card-detailed {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.turma-card-detailed:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.turma-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.turma-header h3 {
    color: #2d3748;
    font-weight: 600;
    display: flex;
    align-items: center;
}

.turma-header h3 i {
    margin-right: 0.5rem;
    color: #667eea;
}

.turma-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
}

.turma-status.active {
    background-color: #48bb78;
    color: white;
}

.turma-info {
    margin-bottom: 1.5rem;
}

.info-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    color: #4a5568;
}

.info-item i {
    margin-right: 0.75rem;
    width: 20px;
    color: #667eea;
}

.turma-actions {
    display: flex;
    gap: 0.75rem;
}

/* Progresso da Turma */
.turma-progress {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}
.progress-bar {
    flex: 1;
    height: 10px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
}
.progress-fill {
    height: 100%;
    width: var(--progress, 0%);
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    transition: width 0.3s ease;
}
.progress-text { color: #4a5568; font-size: 0.9rem; font-weight: 600; }

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: #718096;
}

.empty-icon {
    font-size: 4rem;
    color: #cbd5e0;
    margin-bottom: 1rem;
}

.empty-state h3,
.empty-state h4 {
    color: #4a5568;
    margin-bottom: 0.5rem;
}

.empty-state p {
    margin-bottom: 2rem;
}

/* Lista de Treinos */
.treinos-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.treino-item {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.treino-item:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

.treino-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f1f5f9;
}

.treino-aluno {
    display: flex;
    align-items: center;
}

.aluno-avatar {
    margin-right: 1rem;
    color: #667eea;
    font-size: 2rem;
}

.aluno-info h4 {
    margin: 0 0 0.25rem 0;
    color: #2d3748;
    font-weight: 600;
}

.treino-data {
    color: #718096;
    font-size: 0.875rem;
    font-weight: 500;
}

.treino-content {
    margin-bottom: 1rem;
}

.treino-tipo {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    color: #2d3748;
    font-size: 1.1rem;
}

.treino-tipo i {
    margin-right: 0.5rem;
    color: #667eea;
}

.treino-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.stat-item.pace {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
}

.treino-actions {
    display: flex;
    gap: 0.75rem;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
}

.treinos-stats {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.treinos-stats h3 {
    margin-bottom: 1rem;
    color: #2d3748;
    font-weight: 600;
    display: flex;
    align-items: center;
}

.treinos-stats h3 i {
    margin-right: 0.5rem;
    color: #667eea;
}

.stats-summary {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.summary-item {
    color: #4a5568;
    padding: 0.5rem 0;
}

.summary-item strong {
    color: #2d3748;
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .main-content {
        margin-left: 0;
        padding-bottom: 5.5rem;
    }

    /* Switch to mobile view */
    .desktop-only {
        display: none !important;
    }

    .mobile-only {
        display: flex !important;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .mobile-nav {
        display: flex;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .turmas-grid {
        grid-template-columns: 1fr;
    }

    .treino-stats {
        flex-direction: column;
        gap: 0.5rem;
    }

    .content-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        padding: 1.25rem;
    }

    .header-left {
        width: 100%;
        flex-wrap: wrap;
        gap: 0.75rem;
    }

    .nav-buttons {
        order: -1;
        margin-bottom: 0.5rem;
    }

    .header-left h1 {
        font-size: 1.5rem;
        flex: 1;
    }

    .header-buttons {
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
    }

    .profile-avatar {
        margin-right: 0;
        margin-bottom: 1rem;
    }

    .form-actions {
        flex-direction: column;
    }

    .treino-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .treino-stats {
        flex-direction: column;
        gap: 0.75rem;
    }

    .treino-actions {
        flex-direction: column;
    }

    .stats-summary {
        gap: 1rem;
    }

    /* Mobile specific improvements */
    .aluno-actions .btn {
        flex: 1;
        justify-content: center;
    }

    .contact-icons {
        justify-content: flex-start;
    }

    .contact-row {
        padding: 0.5rem 0;
        border-bottom: 1px solid #f1f5f9;
        margin-bottom: 0.5rem;
    }

    .turma-header {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .turma-icon {
        margin-right: 0;
        margin-bottom: 1rem;
    }

    .turma-details h2 {
        font-size: 1.5rem;
        text-align: center;
    }

    .turma-info-card {
        padding: 1.5rem;
    }

    /* Empilhar título/ações nas seções internas */
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
    .section-header .actions-grid {
        width: 100%;
    }
    .section-header .actions-grid .btn,
    .section-header .actions-grid .dropdown > .btn {
        width: 100%;
        justify-content: center;
    }

    /* Botões de ação em listas/tabelas mais acessíveis no mobile */
    .action-buttons {
        width: 100%;
        gap: 0.5rem;
        flex-wrap: wrap;
    }
    .action-buttons .btn {
        flex: 1 1 48%;
        min-width: 140px;
        justify-content: center;
    }

    /* Cartões com menos padding em telas pequenas */
    .dashboard-section,
    .profile-section,
    .form-card {
        padding: 1rem;
    }
}

/* Modelos de Treino */
.modelos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.modelo-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.modelo-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.modelo-card.preview {
    margin-bottom: 2rem;
    border: 2px solid #667eea;
}

.modelo-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.modelo-header h3 {
    color: #2d3748;
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
}

.modelo-header h4 {
    color: #2d3748;
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.tipo-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
}

.modelo-info {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.modelo-info .info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #4a5568;
    font-size: 0.9rem;
}

.modelo-info .info-item i {
    color: #667eea;
    width: 16px;
}

.modelo-descricao {
    margin-bottom: 1.5rem;
    color: #4a5568;
    line-height: 1.6;
}

.modelo-descricao p {
    margin: 0.5rem 0;
}

.modelo-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.modelo-preview {
    margin-bottom: 2rem;
}

.modelo-preview h3 {
    color: #2d3748;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Formulário de aplicar modelo */
.alunos-checklist {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem;
    background: #f8fafc;
}

.checkbox-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.checkbox-item:hover {
    background: white;
}

.checkbox-item input[type="checkbox"] {
    margin-right: 0.75rem;
    width: 18px;
    height: 18px;
    accent-color: #667eea;
}

.checkbox-item label {
    flex: 1;
    cursor: pointer;
    margin: 0;
}

.aluno-info-checkbox {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.aluno-info-checkbox strong {
    color: #2d3748;
    font-size: 0.95rem;
}

.aluno-info-checkbox span {
    color: #4a5568;
    font-size: 0.85rem;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.status-badge.active {
    background: #c6f6d5;
    color: #22543d;
}

.status-badge.inactive {
    background: #fed7d7;
    color: #742a2a;
}

/* Ações (grid) */
.actions-grid {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}
.actions-grid .dropdown { display: inline-block; }

/* Dropdown simples */
.dropdown { position: relative; display: inline-block; }
.dropdown .dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    min-width: 220px;
    box-shadow: 0 8px 18px rgba(0,0,0,0.08);
    padding: 0.5rem;
    display: none;
    z-index: 1000;
}
.dropdown .dropdown-menu.open { display: block; }
.dropdown .dropdown-menu a,
.dropdown .dropdown-menu .as-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    text-decoration: none;
    color: #2d3748;
    border-radius: 6px;
}
.dropdown .dropdown-menu a + a,
.dropdown .dropdown-menu .as-link + .as-link,
.dropdown .dropdown-menu a + .as-link,
.dropdown .dropdown-menu .as-link + a {
    margin-top: 0.25rem;
}
.dropdown .dropdown-menu a:hover,
.dropdown .dropdown-menu .as-link:hover { background: #f7fafc; }
.dropdown .dropdown-menu .as-link {
    background: none; border: none; cursor: pointer; width: 100%; text-align: left; font: inherit;
}

.help-card, .info-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 2rem;
}

.help-card h3, .info-card h3 {
    color: #2d3748;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.help-card ul {
    margin: 0;
    padding-left: 1.5rem;
    color: #4a5568;
    line-height: 1.6;
}

.help-card li {
    margin-bottom: 0.5rem;
}

/* Desktop: dropdowns marcados com .desktop-inline viram menus inline (sem botão) */
@media (min-width: 769px) {
    .dropdown.desktop-inline > .btn { display: none; }
    .dropdown.desktop-inline > .dropdown-menu {
        display: flex !important;
        position: static;
        background: transparent;
        border: 0;
        box-shadow: none;
        padding: 0;
        min-width: 0;
        gap: 0.5rem;
    }
    .dropdown.desktop-inline > .dropdown-menu a,
    .dropdown.desktop-inline > .dropdown-menu .as-link {
        padding: 0.5rem 0.75rem;
    }
}

/* Responsividade para modelos */
@media (max-width: 768px) {
    /* Botões de ações em largura total no mobile */
    .actions-grid { gap: 0.5rem; }
    .actions-grid .btn,
    .actions-grid .dropdown > .btn { width: 100%; justify-content: center; }

    /* Dropdown mais amigável no mobile (alinhado à esquerda e com áreas de toque maiores) */
    .dropdown .dropdown-menu {
        left: 0;
        right: auto;
        min-width: min(260px, 90vw);
        padding: 0.5rem;
    }
    .dropdown .dropdown-menu a,
    .dropdown .dropdown-menu .as-link { padding: 0.75rem 1rem; }
    .dropdown .dropdown-menu a i,
    .dropdown .dropdown-menu .as-link i { width: 18px; }

    .modelos-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .modelo-card {
        padding: 1rem;
    }
    
    .modelo-header {
        flex-direction: column;
        gap: 0.5rem;
        align-items: flex-start;
    }
    
    .modelo-info {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .modelo-actions {
        justify-content: center;
    }
    
    .alunos-checklist {
        max-height: 200px;
    }
}

/* Ajustes adicionais para telas muito pequenas */
@media (max-width: 420px) {
    .content-area { padding: 1rem; }
    .stat-card { padding: 1rem; }
    .stat-icon { width: 48px; height: 48px; font-size: 1.2rem; }
    .stat-content h3 { font-size: 1.5rem; }
    .btn { padding: 0.5rem 0.75rem; font-size: 0.8rem; }
}