/* ========================================
   FUTSAL MANAGER - STYLESHEET
   ======================================== */

:root {
    --primary: #10b981;
    --primary-dark: #059669;
    --secondary: #3b82f6;
    --danger: #ef4444;
    --warning: #f59e0b;
    --success: #10b981;
    --dark: #1f2937;
    --dark-light: #374151;
    --gray: #6b7280;
    --gray-light: #e5e7eb;
    --white: #ffffff;
    --background: #f9fafb;
    --sidebar-width: 280px;
    --header-height: 64px;
    --border-radius: 12px;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--background);
    color: var(--dark);
    line-height: 1.6;
}

/* ========================================
   LOADING SCREEN
   ======================================== */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--white);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--gray-light);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ========================================
   AUTH PAGE
   ======================================== */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    padding: 20px;
}

.auth-container {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 40px;
    max-width: 450px;
    width: 100%;
    box-shadow: var(--shadow-lg);
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.auth-header i {
    font-size: 64px;
    color: var(--primary);
    margin-bottom: 15px;
}

.auth-header h1 {
    font-size: 32px;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 8px;
}

.auth-header p {
    color: var(--gray);
    font-size: 14px;
}

.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
}

.auth-form h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--dark);
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--dark);
    font-size: 14px;
}

.form-group label i {
    margin-right: 5px;
    color: var(--gray);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.btn-primary {
    width: 100%;
    padding: 14px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    padding: 12px 24px;
    background: var(--gray-light);
    color: var(--dark);
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: var(--gray);
    color: var(--white);
}

.auth-switch {
    text-align: center;
    margin-top: 20px;
    color: var(--gray);
    font-size: 14px;
}

.auth-switch a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-switch a:hover {
    text-decoration: underline;
}

/* ========================================
   APP LAYOUT
   ======================================== */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Mobile Header */
.mobile-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: var(--white);
    box-shadow: var(--shadow);
    padding: 0 20px;
    align-items: center;
    justify-content: space-between;
    z-index: 100;
}

.mobile-header h1 {
    font-size: 20px;
    font-weight: 700;
}

.menu-toggle,
.notification-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--dark);
    cursor: pointer;
}

.notification-btn {
    position: relative;
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--danger);
    color: var(--white);
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: var(--white);
    border-right: 1px solid var(--gray-light);
    padding: 30px 20px;
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    overflow-y: auto;
    transition: transform 0.3s;
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--gray-light);
}

.sidebar-header i {
    font-size: 36px;
    color: var(--primary);
}

.sidebar-header h2 {
    font-size: 24px;
    font-weight: 800;
    color: var(--dark);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: var(--background);
    border-radius: var(--border-radius);
    margin-bottom: 25px;
}

.user-avatar {
    width: 50px;
    height: 50px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 24px;
}

.user-details h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 2px;
}

.user-details p {
    font-size: 13px;
    color: var(--gray);
}

.nav-menu {
    list-style: none;
}

.nav-menu li {
    margin-bottom: 5px;
}

.nav-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    color: var(--gray);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s;
    position: relative;
}

.nav-menu a:hover {
    background: var(--background);
    color: var(--dark);
}

.nav-menu a.active {
    background: var(--primary);
    color: var(--white);
}

.nav-menu a i {
    font-size: 20px;
    width: 24px;
}

.nav-menu .badge {
    position: absolute;
    right: 15px;
    background: var(--danger);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 10px;
    min-width: 20px;
    text-align: center;
}

.logout-link {
    color: var(--danger) !important;
}

.logout-link:hover {
    background: rgba(239, 68, 68, 0.1) !important;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    padding: 40px;
    min-height: 100vh;
}

.page {
    display: none;
}

.page.active {
    display: block;
    animation: fadeIn 0.3s;
}

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

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
}

.page-header h1 {
    font-size: 32px;
    font-weight: 800;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 12px;
}

.page-header h1 i {
    color: var(--primary);
}

.page-header .btn-primary {
    width: auto;
    padding: 12px 24px;
}

/* ========================================
   STATS GRID
   ======================================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--white);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: transform 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.stat-card i {
    font-size: 40px;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.stat-primary i { background: rgba(16, 185, 129, 0.1); color: var(--primary); }
.stat-success i { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.stat-warning i { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.stat-danger i { background: rgba(239, 68, 68, 0.1); color: var(--danger); }

.stat-content h3 {
    font-size: 28px;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 5px;
}

.stat-content p {
    color: var(--gray);
    font-size: 14px;
}

/* ========================================
   SECTION CARDS
   ======================================== */
.section-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 25px;
    margin-bottom: 25px;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--gray-light);
}

.section-header h2 {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-header a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
}

.section-header a:hover {
    text-decoration: underline;
}

/* ========================================
   GAMES LIST
   ======================================== */
.games-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.game-card {
    background: var(--background);
    padding: 20px;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary);
    transition: all 0.3s;
}

.game-card:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

.game-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.game-date {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray);
    font-size: 14px;
    font-weight: 600;
}

.game-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-agendado { background: rgba(59, 130, 246, 0.1); color: var(--secondary); }
.status-confirmado { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.status-realizado { background: rgba(107, 114, 128, 0.1); color: var(--gray); }
.status-cancelado { background: rgba(239, 68, 68, 0.1); color: var(--danger); }

.game-teams {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.game-team {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.game-team-logo {
    width: 50px;
    height: 50px;
    background: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--primary);
    box-shadow: var(--shadow);
}

.game-team-info h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--dark);
}

.game-team-info p {
    font-size: 13px;
    color: var(--gray);
}

.game-vs {
    font-size: 16px;
    font-weight: 800;
    color: var(--gray);
    padding: 0 20px;
}

.game-location {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray);
    font-size: 14px;
    margin-bottom: 10px;
}

.game-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--gray-light);
}

.game-actions button {
    flex: 1;
    padding: 8px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-success {
    background: var(--success);
    color: var(--white);
}

.btn-danger {
    background: var(--danger);
    color: var(--white);
}

.btn-info {
    background: var(--secondary);
    color: var(--white);
}

.btn-success:hover,
.btn-danger:hover,
.btn-info:hover {
    opacity: 0.9;
    transform: scale(1.05);
}

/* ========================================
   TEAMS GRID
   ======================================== */
.teams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.team-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 25px;
    text-align: center;
    transition: all 0.3s;
    cursor: pointer;
}

.team-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.team-logo {
    width: 100px;
    height: 100px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    color: var(--white);
}

.team-card h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 8px;
}

.team-card p {
    color: var(--gray);
    font-size: 14px;
    margin-bottom: 15px;
}

.team-stats {
    display: flex;
    justify-content: space-around;
    padding: 15px 0;
    border-top: 1px solid var(--gray-light);
    border-bottom: 1px solid var(--gray-light);
    margin: 15px 0;
}

.team-stat {
    text-align: center;
}

.team-stat h4 {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
}

.team-stat p {
    font-size: 12px;
    color: var(--gray);
    margin: 0;
}

.team-payment-status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-top: 10px;
}

.payment-pago { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.payment-pendente { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.payment-atrasado { background: rgba(239, 68, 68, 0.1); color: var(--danger); }

/* ========================================
   COURTS GRID
   ======================================== */
.courts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.court-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: all 0.3s;
}

.court-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.court-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
    padding: 20px;
    text-align: center;
}

.court-header i {
    font-size: 48px;
    margin-bottom: 10px;
}

.court-header h3 {
    font-size: 20px;
    font-weight: 700;
}

.court-body {
    padding: 20px;
}

.court-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 15px;
}

.court-info-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.court-info-item i {
    color: var(--primary);
    font-size: 16px;
    margin-top: 2px;
}

.court-info-item span {
    flex: 1;
    color: var(--dark);
    font-size: 14px;
}

.court-price {
    background: var(--background);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
    margin-top: 15px;
}

.court-price strong {
    display: block;
    font-size: 24px;
    color: var(--primary);
    font-weight: 800;
}

.court-price span {
    font-size: 13px;
    color: var(--gray);
}

.court-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.court-actions button {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

/* ========================================
   CHAT
   ======================================== */
.chat-container {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 20px;
    height: calc(100vh - 200px);
}

.chat-sidebar {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.chat-search {
    padding: 15px;
    border-bottom: 1px solid var(--gray-light);
}

.chat-search input {
    width: 100%;
    padding: 10px 15px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    font-size: 14px;
}

.chat-list {
    flex: 1;
    overflow-y: auto;
}

.chat-item {
    padding: 15px;
    border-bottom: 1px solid var(--gray-light);
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-item:hover,
.chat-item.active {
    background: var(--background);
}

.chat-item-avatar {
    width: 50px;
    height: 50px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 24px;
}

.chat-item-info {
    flex: 1;
}

.chat-item-info h4 {
    font-size: 15px;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 4px;
}

.chat-item-info p {
    font-size: 13px;
    color: var(--gray);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-main {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
}

.chat-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--gray);
}

.chat-empty i {
    font-size: 80px;
    margin-bottom: 20px;
}

.chat-active {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.chat-header {
    padding: 20px;
    border-bottom: 2px solid var(--gray-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.chat-header-info h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 4px;
}

.chat-header-info p {
    font-size: 13px;
    color: var(--gray);
}

.btn-whatsapp {
    background: #25d366;
    color: var(--white);
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.btn-whatsapp:hover {
    background: #20ba5a;
    transform: scale(1.05);
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.message {
    display: flex;
    gap: 12px;
    max-width: 70%;
}

.message.sent {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.message-avatar {
    width: 40px;
    height: 40px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 18px;
    flex-shrink: 0;
}

.message-content {
    background: var(--background);
    padding: 12px 16px;
    border-radius: 12px;
    flex: 1;
}

.message.sent .message-content {
    background: var(--primary);
    color: var(--white);
}

.message-text {
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 5px;
}

.message-time {
    font-size: 11px;
    color: var(--gray);
}

.message.sent .message-time {
    color: rgba(255, 255, 255, 0.8);
}

.chat-input {
    padding: 20px;
    border-top: 2px solid var(--gray-light);
    display: flex;
    gap: 10px;
}

.chat-input input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid var(--gray-light);
    border-radius: 8px;
    font-size: 14px;
}

.chat-input button {
    width: 50px;
    height: 50px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 8px;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s;
}

.chat-input button:hover {
    background: var(--primary-dark);
    transform: scale(1.1);
}

/* ========================================
   PAYMENTS
   ======================================== */
.payment-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.payment-card {
    background: var(--white);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 20px;
}

.payment-card i {
    font-size: 40px;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.payment-total i { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.payment-pending i { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.payment-overdue i { background: rgba(239, 68, 68, 0.1); color: var(--danger); }

.payment-card h3 {
    font-size: 24px;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 5px;
}

.payment-card p {
    font-size: 14px;
    color: var(--gray);
}

.payments-table {
    overflow-x: auto;
}

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

.payments-table th,
.payments-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--gray-light);
}

.payments-table th {
    background: var(--background);
    font-weight: 600;
    color: var(--dark);
    font-size: 14px;
}

.payments-table td {
    font-size: 14px;
}

.payment-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

/* ========================================
   TABS
   ======================================== */
.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    border-bottom: 2px solid var(--gray-light);
}

.tab-btn {
    padding: 12px 24px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--gray);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.tab-btn:hover {
    color: var(--dark);
}

.tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.tab-content {
    display: none;
}

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

/* ========================================
   CALENDAR
   ======================================== */
.calendar-container {
    background: var(--white);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

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

.calendar-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
}

.calendar-nav {
    display: flex;
    gap: 10px;
}

.calendar-nav button {
    width: 40px;
    height: 40px;
    background: var(--background);
    border: none;
    border-radius: 8px;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.3s;
}

.calendar-nav button:hover {
    background: var(--primary);
    color: var(--white);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
}

.calendar-day-header {
    text-align: center;
    font-weight: 600;
    color: var(--gray);
    padding: 10px;
    font-size: 13px;
}

.calendar-day {
    aspect-ratio: 1;
    background: var(--background);
    border-radius: 8px;
    padding: 10px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.calendar-day:hover {
    background: var(--primary);
    color: var(--white);
}

.calendar-day.has-game {
    background: rgba(16, 185, 129, 0.1);
    border: 2px solid var(--primary);
}

.calendar-day.today {
    background: var(--secondary);
    color: var(--white);
}

/* ========================================
   MODALS
   ======================================== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: var(--border-radius);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-large {
    max-width: 900px;
}

.modal-header {
    padding: 25px;
    border-bottom: 2px solid var(--gray-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-close {
    width: 40px;
    height: 40px;
    background: var(--background);
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.modal-close:hover {
    background: var(--danger);
    color: var(--white);
}

.modal-content form {
    padding: 25px;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.modal-actions button {
    flex: 1;
}

/* ========================================
   TEAM DETAILS MODAL
   ======================================== */
.team-detail-container {
    padding: 25px;
}

.team-detail-info {
    background: var(--background);
    padding: 25px;
    border-radius: var(--border-radius);
    margin-bottom: 25px;
}

.team-logo-large {
    width: 120px;
    height: 120px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 60px;
    color: var(--white);
}

.team-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin: 20px 0;
}

.info-item label {
    display: block;
    font-size: 12px;
    color: var(--gray);
    font-weight: 600;
    margin-bottom: 5px;
    text-transform: uppercase;
}

.info-item p {
    font-size: 16px;
    color: var(--dark);
    font-weight: 600;
}

.team-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.team-actions button {
    flex: 1;
}

.team-players h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.players-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.player-card {
    background: var(--white);
    padding: 15px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    text-align: center;
}

.player-number {
    width: 50px;
    height: 50px;
    margin: 0 auto 10px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 800;
    color: var(--white);
}

.player-card h4 {
    font-size: 15px;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 5px;
}

.player-card p {
    font-size: 13px;
    color: var(--gray);
}

/* ========================================
   ACTIVITY LIST
   ======================================== */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: var(--background);
    border-radius: var(--border-radius);
}

.activity-icon {
    width: 45px;
    height: 45px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 18px;
}

.activity-content {
    flex: 1;
}

.activity-content p {
    font-size: 14px;
    color: var(--dark);
    margin-bottom: 5px;
}

.activity-content span {
    font-size: 12px;
    color: var(--gray);
}

/* ========================================
   TUTORIAL LIST
   ======================================== */
.tutorial-list {
    list-style: none;
    padding-left: 0;
}

.tutorial-list li {
    padding: 10px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--dark);
    font-size: 14px;
}

.tutorial-list i {
    color: var(--success);
    font-size: 18px;
}

/* ========================================
   TOAST NOTIFICATION
   ======================================== */
.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--dark);
    color: var(--white);
    padding: 16px 24px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    display: none;
    align-items: center;
    gap: 12px;
    z-index: 2000;
    animation: slideInUp 0.3s;
}

.toast.show {
    display: flex;
}

.toast.success {
    background: var(--success);
}

.toast.error {
    background: var(--danger);
}

.toast.warning {
    background: var(--warning);
}

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

/* ========================================
   EMPTY STATE
   ======================================== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--gray);
}

.empty-state i {
    font-size: 80px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 10px;
}

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

/* ========================================
   RESPONSIVE
   ======================================== */
@media (max-width: 1024px) {
    .chat-container {
        grid-template-columns: 300px 1fr;
    }
}

@media (max-width: 768px) {
    .mobile-header {
        display: flex;
    }
    
    .sidebar {
        transform: translateX(-100%);
        z-index: 200;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
        padding: 20px;
        padding-top: calc(var(--header-height) + 20px);
    }
    
    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .page-header .btn-primary {
        width: 100%;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .teams-grid,
    .courts-grid {
        grid-template-columns: 1fr;
    }
    
    .chat-container {
        grid-template-columns: 1fr;
        height: calc(100vh - 150px);
    }
    
    .chat-sidebar {
        display: none;
    }
    
    .game-teams {
        flex-direction: column;
        gap: 15px;
    }
    
    .game-vs {
        transform: rotate(90deg);
        padding: 15px 0;
    }
    
    .modal-content {
        max-width: 100%;
    }
    
    .team-info-grid {
        grid-template-columns: 1fr;
    }
    
    .payment-summary {
        grid-template-columns: 1fr;
    }
    
    .tabs {
        overflow-x: auto;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .stat-card {
        padding: 20px;
    }
    
    .game-actions {
        flex-direction: column;
    }
    
    .players-grid {
        grid-template-columns: 1fr;
    }
    
    .modal-actions {
        flex-direction: column;
    }
}
