﻿/* ============================================================
   KOLKATA CRICKET LEAGUE — DESIGN SYSTEM
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800;900&family=Rajdhani:wght@500;600;700&display=swap');

/* ---------- CSS Variables ---------- */
:root {
    --bg-base: #0f0608;
    --bg-surface: #180b0e;
    --bg-card: #200d11;
    --bg-card-hover: #2a1118;
    --bg-elevated: #32161c;

    --primary: #c0392b;
    --primary-dark: #922b21;
    --primary-light: #e74c3c;
    --primary-glow: rgba(192, 57, 43, 0.35);

    --gold: #f0c040;
    --gold-light: #f7d870;
    --gold-dim: rgba(240, 192, 64, 0.18);

    --text-primary: #f5e9ea;
    --text-secondary: #c9aaad;
    --text-muted: #7a5860;
    --text-gold: #f0c040;

    --border: rgba(192, 57, 43, 0.25);
    --border-hover: rgba(192, 57, 43, 0.55);
    --border-gold: rgba(240, 192, 64, 0.35);

    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 32px;

    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(192, 57, 43, 0.15);
    --shadow-glow: 0 0 32px rgba(192, 57, 43, 0.4);
    --shadow-gold: 0 0 20px rgba(240, 192, 64, 0.3);

    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --font-main: 'Outfit', sans-serif;
    --font-display: 'Rajdhani', sans-serif;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background: var(--bg-base);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
}

button {
    cursor: pointer;
    border: none;
    outline: none;
    font-family: var(--font-main);
}

input,
select,
textarea {
    font-family: var(--font-main);
    outline: none;
}

ul {
    list-style: none;
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-base);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 3px;
}

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.page-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(15, 6, 8, 0.92);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    padding: 0 24px;
}

.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 68px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 0.5px;
}

.nav-logo img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.nav-logo span em {
    display: block;
    font-style: normal;
    font-size: 0.7rem;
    font-family: var(--font-main);
    color: var(--text-secondary);
    font-weight: 400;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
    background: rgba(192, 57, 43, 0.12);
}

.nav-link.active {
    color: var(--gold);
}

.nav-cta {
    padding: 9px 22px;
    background: var(--primary);
    color: white;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
    box-shadow: 0 2px 12px rgba(192, 57, 43, 0.4);
}

.nav-cta:hover {
    background: var(--primary-light);
    transform: translateY(-1px);
    box-shadow: var(--shadow-glow);
}

.nav-hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    padding: 4px;
}

.nav-hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition);
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero {
    position: relative;
    overflow: hidden;
    min-height: 520px;
    display: flex;
    align-items: center;
    background: var(--bg-surface);
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../assets/images/hero_stadium_cup.png');
    background-size: cover;
    background-position: center;
    opacity: 0.7;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(15, 6, 8, 0.95) 0%, rgba(192, 57, 43, 0.18) 50%, rgba(15, 6, 8, 0.9) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 24px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--gold-dim);
    border: 1px solid var(--border-gold);
    color: var(--gold);
    border-radius: 100px;
    padding: 6px 16px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.hero-badge::before {
    content: '🏏';
}

.hero h1 {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 16px;
}

.hero h1 span {
    color: var(--gold);
}

.hero p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 520px;
    margin-bottom: 36px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 28px;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-weight: 600;
    transition: var(--transition);
    border: 2px solid transparent;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 20px rgba(192, 57, 43, 0.45);
}

.btn-primary:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border-color: var(--border-hover);
}

.btn-outline:hover {
    border-color: var(--gold);
    color: var(--gold);
    transform: translateY(-2px);
}

.btn-gold {
    background: var(--gold);
    color: #1a0a0c;
    font-weight: 700;
    box-shadow: 0 4px 20px rgba(240, 192, 64, 0.35);
}

.btn-gold:hover {
    background: var(--gold-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-gold);
}

.btn-sm {
    padding: 8px 18px;
    font-size: 0.85rem;
}

.btn-danger {
    background: #7b2020;
    color: white;
}

.btn-danger:hover {
    background: #9b2626;
}

/* Hero Stats */
.hero-stats {
    display: flex;
    gap: 40px;
    margin-top: 48px;
    flex-wrap: wrap;
}

.hero-stat-item {
    text-align: left;
}

.hero-stat-item .stat-num {
    font-family: var(--font-display);
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--gold);
}

.hero-stat-item .stat-lbl {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.section-header {
    margin-bottom: 40px;
}

.section-header h2 {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 700;
    color: var(--text-primary);
}

.section-header h2 span {
    color: var(--gold);
}

.section-header p {
    color: var(--text-secondary);
    margin-top: 8px;
}

.section-divider {
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    border-radius: 2px;
    margin: 12px 0 16px;
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    transition: var(--transition);
}

.card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-card), var(--shadow-glow);
    transform: translateY(-2px);
}

.card-body {
    padding: 24px;
}

/* ============================================================
   TEAM CARDS
   ============================================================ */
.teams-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.team-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition);
    cursor: pointer;
    position: relative;
}

.team-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-card), var(--shadow-glow);
}

.team-card-banner {
    height: 90px;
    background: linear-gradient(135deg, var(--primary-dark), var(--bg-elevated));
    position: relative;
    overflow: hidden;
}

.team-card-banner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(45deg, transparent, transparent 8px, rgba(255, 255, 255, 0.02) 8px, rgba(255, 255, 255, 0.02) 16px);
}

.team-card-logo {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: 3px solid var(--gold);
    object-fit: cover;
    background: var(--bg-elevated);
    position: absolute;
    bottom: -35px;
    left: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.team-card-body {
    padding: 44px 24px 24px;
}

.team-card-name {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.team-card-meta {
    font-size: 0.82rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.team-card-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.team-stat-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.team-stat {
    text-align: center;
}

.team-stat .val {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--gold);
}

.team-stat .lbl {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.team-rank-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--gold-dim);
    border: 1px solid var(--border-gold);
    color: var(--gold);
    border-radius: 100px;
    padding: 4px 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ============================================================
   PLAYER CARDS
   ============================================================ */
.players-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.player-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.player-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-card), var(--shadow-glow);
}

.player-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    opacity: 0;
    transition: var(--transition);
}

.player-card:hover::before {
    opacity: 1;
}

.player-avatar:hover .identity-overlay,
.profile-img-container:hover .identity-overlay,
.team-card-logo-container:hover .identity-overlay,
.team-logo-container:hover .identity-overlay {
    opacity: 1;
}

.camera-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 42px;
    height: 42px;
    background: var(--bg-elevated);
    border: 3px solid var(--bg-surface);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold);
    font-size: 1.2rem;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    z-index: 25;
}

.camera-badge:hover {
    background: var(--primary);
    color: white;
    transform: scale(1.1);
    box-shadow: var(--shadow-glow);
}

.profile-img-container,
.team-logo-container {
    position: relative;
    border-radius: 50%;
}

.identity-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
    pointer-events: none;
    border-radius: 50%;
    z-index: 10;
}

.player-card:hover .player-avatar {
    border-color: var(--gold);
}

.player-name {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 4px;
}

.player-role {
    display: inline-block;
    background: var(--primary-glow);
    border: 1px solid var(--border);
    color: var(--primary-light);
    border-radius: 100px;
    padding: 2px 10px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.player-stats-mini {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.mini-stat {
    background: var(--bg-elevated);
    border-radius: var(--radius-sm);
    padding: 8px;
}

.mini-stat .mv {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gold);
}

.mini-stat .ml {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.player-rank-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 28px;
    height: 28px;
    background: var(--gold);
    color: #1a0a0c;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 900;
    box-shadow: 0 2px 8px rgba(240, 192, 64, 0.4);
}

.rank-1 {
    background: var(--gold);
}

.rank-2 {
    background: #b0b0b0;
}

.rank-3 {
    background: #cd7f32;
}

/* ============================================================
   RANKING TABLE
   ============================================================ */
.ranking-table-wrap {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
}

.ranking-table {
    width: 100%;
    border-collapse: collapse;
}

.ranking-table thead th {
    padding: 14px 20px;
    background: var(--bg-elevated);
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1px;
    font-weight: 600;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.ranking-table tbody tr {
    border-bottom: 1px solid rgba(192, 57, 43, 0.1);
    transition: var(--transition);
    cursor: pointer;
}

.ranking-table tbody tr:hover {
    background: rgba(192, 57, 43, 0.06);
}

.ranking-table tbody tr:last-child {
    border-bottom: none;
}

.ranking-table td {
    padding: 14px 20px;
    font-size: 0.92rem;
}

.rank-num {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    width: 40px;
    text-align: center;
}

.rank-gold {
    color: var(--gold);
}

.rank-silver {
    color: #b0b0b0;
}

.rank-bronze {
    color: #cd7f32;
}

.rank-medal {
    font-size: 1.1rem;
}

.table-player-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.table-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border);
    background: var(--bg-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: var(--text-muted);
    overflow: hidden;
}

.table-player-name {
    font-weight: 600;
}

.table-player-team {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.stat-pill {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 100px;
    font-size: 0.8rem;
    font-weight: 600;
    background: var(--bg-elevated);
}

.stat-pill.gold {
    background: var(--gold-dim);
    color: var(--gold);
}

.points-score {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary-light);
}

/* ============================================================
   MODALS
   ============================================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.8), var(--shadow-glow);
    transform: scale(0.95) translateY(20px);
    transition: var(--transition);
}

.modal-overlay.open .modal {
    transform: scale(1) translateY(0);
}

.modal-header {
    padding: 28px 28px 0;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    padding-bottom: 20px;
}

.modal-header h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
}

.modal-header h3 span {
    color: var(--gold);
}

.modal-close {
    width: 36px;
    height: 36px;
    background: var(--bg-elevated);
    border-radius: 50%;
    color: var(--text-muted);
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
}

.modal-close:hover {
    background: var(--primary);
    color: white;
}

.modal-body {
    padding: 28px;
}

/* ============================================================
   FORMS
   ============================================================ */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: var(--transition);
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.15);
    background: var(--bg-card);
}

.form-control::placeholder {
    color: var(--text-muted);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

select.form-control {
    appearance: none;
    cursor: pointer;
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

.form-hint {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 5px;
}

/* ============================================================
   TABS
   ============================================================ */
.tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 28px;
    overflow-x: auto;
}

.tab-btn {
    padding: 12px 22px;
    border-radius: var(--radius-sm) var(--radius-sm) 0 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    background: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    transition: var(--transition);
    white-space: nowrap;
}

.tab-btn:hover {
    color: var(--text-primary);
}

.tab-btn.active {
    color: var(--gold);
    border-bottom-color: var(--gold);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* ============================================================
   SEARCH & FILTERS
   ============================================================ */
.search-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 28px;
}

.search-input-wrap {
    position: relative;
    flex: 1;
    min-width: 200px;
}

.search-input-wrap .icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1rem;
}

.search-input-wrap input {
    width: 100%;
    padding: 11px 16px 11px 42px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.92rem;
    transition: var(--transition);
}

.search-input-wrap input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.filter-select {
    padding: 11px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.88rem;
    cursor: pointer;
    appearance: none;
    padding-right: 32px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%237a5860' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
}

/* ============================================================
   PAGINATION
   ============================================================ */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 36px;
}

.page-btn {
    width: 36px;
    height: 36px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.page-btn:hover,
.page-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* ============================================================
   PLAYER PROFILE PAGE
   ============================================================ */
.profile-header {
    background: var(--bg-surface);
    padding: 48px 0 0;
    border-bottom: 1px solid var(--border);
}

.profile-header-inner {
    display: flex;
    align-items: flex-end;
    gap: 32px;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px 32px;
}

.profile-avatar-wrap {
    position: relative;
    flex-shrink: 0;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid var(--gold);
    object-fit: cover;
    background: var(--bg-elevated);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: var(--text-muted);
    overflow: hidden;
}

.profile-avatar-edit {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 30px;
    height: 30px;
    background: var(--primary);
    border-radius: 50%;
    color: white;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 2px solid var(--bg-base);
    transition: var(--transition);
}

.profile-avatar-edit:hover {
    background: var(--primary-light);
    transform: scale(1.1);
}

.profile-info {
    flex: 1;
}

.profile-name {
    font-family: var(--font-display);
    font-size: 2.2rem;
    font-weight: 700;
}

.profile-team {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.profile-tags {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.profile-tag {
    padding: 4px 14px;
    border-radius: 100px;
    font-size: 0.82rem;
    font-weight: 600;
}

.tag-role {
    background: var(--primary-glow);
    border: 1px solid var(--primary);
    color: var(--primary-light);
}

.tag-rating {
    background: var(--gold-dim);
    border: 1px solid var(--border-gold);
    color: var(--gold);
}

.profile-tabs {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.profile-tabs .tabs {
    border-bottom: none;
}

.profile-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 32px 24px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 20px;
    text-align: center;
    transition: var(--transition);
}

.stat-card:hover {
    border-color: var(--border-hover);
}

.stat-card .sc-val {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
    color: var(--gold);
}

.stat-card .sc-lbl {
    font-size: 0.78rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

.stat-card .sc-icon {
    font-size: 1.5rem;
    margin-bottom: 8px;
}

/* ============================================================
   TEAM DETAIL PAGE
   ============================================================ */
.team-detail-header {
    background: var(--bg-surface);
    padding: 48px 0 32px;
    border-bottom: 1px solid var(--border);
}

.team-detail-inner {
    display: flex;
    align-items: center;
    gap: 28px;
    flex-wrap: wrap;
}

.team-detail-logo {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid var(--gold);
    object-fit: cover;
    background: var(--bg-elevated);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    flex-shrink: 0;
}

.team-detail-name {
    font-family: var(--font-display);
    font-size: 2rem;
    font-weight: 700;
}

.team-detail-meta {
    color: var(--text-muted);
    margin: 6px 0 12px;
}

/* ============================================================
   ALERTS & NOTIFICATIONS
   ============================================================ */
.alert {
    padding: 14px 20px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 16px;
}

.alert-success {
    background: rgba(39, 174, 96, 0.15);
    border: 1px solid rgba(39, 174, 96, 0.4);
    color: #2ecc71;
}

.alert-error {
    background: rgba(192, 57, 43, 0.15);
    border: 1px solid rgba(192, 57, 43, 0.4);
    color: var(--primary-light);
}

.alert-info {
    background: rgba(52, 152, 219, 0.15);
    border: 1px solid rgba(52, 152, 219, 0.4);
    color: #3498db;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--border);
    padding: 48px 24px 24px;
    margin-top: 80px;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
}

.footer-brand .nav-logo {
    margin-bottom: 16px;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.9rem;
    max-width: 300px;
}

.footer-col h4 {
    color: var(--gold);
    font-weight: 600;
    margin-bottom: 16px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-col a {
    display: block;
    color: var(--text-muted);
    font-size: 0.88rem;
    margin-bottom: 10px;
    transition: var(--transition);
}

.footer-col a:hover {
    color: var(--text-primary);
    padding-left: 4px;
}

.footer-bottom {
    max-width: 1200px;
    margin: 40px auto 0;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.82rem;
    flex-wrap: wrap;
    gap: 10px;
}

/* ============================================================
   EMPTY STATES
   ============================================================ */
.empty-state {
    text-align: center;
    padding: 80px 24px;
    color: var(--text-muted);
}

.empty-state .empty-icon {
    font-size: 4rem;
    margin-bottom: 16px;
    opacity: 0.4;
}

.empty-state h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    color: var(--text-secondary);
}

.empty-state p {
    font-size: 0.9rem;
    margin-bottom: 20px;
}

/* ============================================================
   LOADING & ANIMATIONS
   ============================================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse-glow {

    0%,
    100% {
        box-shadow: 0 0 12px rgba(192, 57, 43, 0.3);
    }

    50% {
        box-shadow: 0 0 28px rgba(192, 57, 43, 0.7);
    }
}

@keyframes shimmer {
    from {
        background-position: -200% 0;
    }

    to {
        background-position: 200% 0;
    }
}

.animate-in {
    animation: fadeInUp 0.4s ease both;
}

.animate-in-delay-1 {
    animation-delay: 0.08s;
}

.animate-in-delay-2 {
    animation-delay: 0.16s;
}

.animate-in-delay-3 {
    animation-delay: 0.24s;
}

.skeleton {
    background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-elevated) 50%, var(--bg-card) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-sm);
}

/* ============================================================
   TROPHY / PODIUM decorative
   ============================================================ */
.trophy-icon {
    font-size: 1.2rem;
}

/* ============================================================
   PAGE SECTIONS
   ============================================================ */
.section {
    padding: 64px 0;
}

.section-alt {
    background: var(--bg-surface);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
    .footer-inner {
        grid-template-columns: 1fr 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {

    .nav-links,
    .nav-cta {
        display: none;
    }

    .nav-hamburger {
        display: flex;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .footer-inner {
        grid-template-columns: 1fr;
    }

    .hero-stats {
        gap: 24px;
    }

    .modal {
        border-radius: var(--radius-lg);
    }

    .profile-header-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .teams-grid {
        grid-template-columns: 1fr;
    }

    .players-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .ranking-table thead {
        display: none;
    }

    .ranking-table td {
        padding: 10px 12px;
        font-size: 0.82rem;
    }
}

@media (max-width: 420px) {
    .players-grid {
        grid-template-columns: 1fr;
    }
}

/* Mobile nav open state */
.nav-mobile-open .nav-links {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 68px 0 0;
    background: var(--bg-surface);
    padding: 24px;
    z-index: 999;
    gap: 4px;
    align-items: flex-start;
}

.nav-mobile-open .nav-cta {
    display: inline-flex;
    margin-top: 16px;
}

/* ============================================================
   UTILITY CLASSES
   ============================================================ */
.text-gold {
    color: var(--gold);
}

.text-muted {
    color: var(--text-muted);
}

.text-primary-color {
    color: var(--primary-light);
}

.font-display {
    font-family: var(--font-display);
}

.d-flex {
    display: flex;
}

.align-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-8 {
    gap: 8px;
}

.gap-12 {
    gap: 12px;
}

.gap-16 {
    gap: 16px;
}

.mb-0 {
    margin-bottom: 0;
}

.mb-8 {
    margin-bottom: 8px;
}

.mb-16 {
    margin-bottom: 16px;
}

.mb-24 {
    margin-bottom: 24px;
}

.mb-32 {
    margin-bottom: 32px;
}

.fw-700 {
    font-weight: 700;
}

.hide {
    display: none !important;
}

/* ============================================================
   CLASSY PLAYER PROFILE (Inspired by Referene Image)
   ============================================================ */
:root {
    --profile-bg: #2d0a0a;
    --profile-card-bg: rgba(255, 255, 255, 0.05);
    --profile-accent: #f1c40f;
    --profile-text: #ffffff;
    --profile-muted: rgba(255, 255, 255, 0.7);
}

.classy-profile-container {
    background: var(--profile-bg);
    min-height: 100vh;
    padding-bottom: 80px;
}

.classy-profile {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
    display: flex;
    gap: 60px;
    color: var(--profile-text);
    align-items: flex-start;
}

.profile-sidebar {
    flex: 0 0 350px;
    position: sticky;
    top: 100px;
}

.profile-image-card {
    width: 100%;
    aspect-ratio: 2/3;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-image-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-main {
    flex: 1;
}

.classy-name {
    font-family: var(--font-display);
    font-size: 4.5rem;
    font-weight: 800;
    color: var(--profile-accent);
    margin-bottom: 12px;
    line-height: 1;
    letter-spacing: -2px;
}

.classy-sub {
    font-family: var(--font-main);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 3px;
    color: #e74c3c;
    text-transform: uppercase;
    margin-bottom: 48px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.classy-sub .sep {
    opacity: 0.3;
    color: #fff;
}

/* Stats Grid */
.classy-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 48px;
}

.classy-stat-card {
    background: var(--profile-card-bg);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 28px 12px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(8px);
}

.classy-stat-card:hover {
    transform: translateY(-8px);
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.15);
}

.classy-stat-val {
    font-family: var(--font-display);
    font-size: 2.3rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
    line-height: 1;
}

.classy-stat-lbl {
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--profile-muted);
    font-weight: 700;
}

.classy-section-title {
    font-family: var(--font-display);
    font-size: 1.8rem;
    color: var(--profile-accent);
    margin: 48px 0 20px;
    letter-spacing: -0.5px;
}

.classy-text-block {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--profile-muted);
    margin-bottom: 32px;
    max-width: 800px;
}

.classy-link-box {
    margin-top: 12px;
    font-size: 1.1rem;
}

.classy-link {
    color: var(--profile-accent);
    text-decoration: none;
    font-weight: 600;
    padding-bottom: 2px;
    border-bottom: 2px solid rgba(241, 196, 15, 0.3);
    transition: all 0.3s;
}

.classy-link:hover {
    border-bottom-color: var(--profile-accent);
    background: rgba(241, 196, 15, 0.1);
    padding-left: 4px;
    padding-right: 4px;
}

.profile-actions {
    display: flex;
    gap: 16px;
    margin-bottom: 40px;
}

@media (max-width: 1100px) {
    .classy-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .classy-profile {
        flex-direction: column;
        padding: 40px 20px;
        gap: 40px;
    }

    .profile-sidebar {
        position: static;
        flex: 0 0 auto;
        width: 320px;
        margin: 0 auto;
    }

    .classy-name {
        font-size: 3rem;
        text-align: center;
    }

    .classy-sub {
        justify-content: center;
        flex-wrap: wrap;
        font-size: 0.85rem;
    }
}