:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-light: #e0e7ff;
    --text-dark: #1f2937;
    --text-gray: #6b7280;
    --text-light: #9ca3af;
    --bg-body: #f9fafb;
    --bg-card: #ffffff;
    --border-color: #e5e7eb;
    --success: #10b981;
    --success-light: #d1fae5;
    --danger: #ef4444;
    --danger-light: #fee2e2;
    --warning: #f59e0b;
    --warning-light: #fef3c7;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px 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);
    --font-primary: 'Inter', sans-serif;
    --font-heading: 'Poppins', sans-serif;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-primary);
    background-color: var(--bg-body);
    color: var(--text-dark);
    height: 100vh;
    overflow: hidden;
}

/* ========== LOGIN PAGE ========== */
.login-body { overflow: auto; }
.login-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #ec4899 100%);
    display: flex; justify-content: center; align-items: center;
    z-index: 9999; padding: 20px;
}
.login-card {
    background: var(--bg-card); border-radius: 24px; padding: 48px 40px;
    width: 100%; max-width: 440px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: slideUp 0.6s ease;
}
@keyframes slideUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
.login-logo { display: flex; justify-content: center; margin-bottom: 24px; }
.login-logo img { width: 180px; height: 60px; object-fit: contain; }
.login-title { font-family: var(--font-heading); font-size: 26px; font-weight: 700; color: var(--text-dark); text-align: center; margin-bottom: 8px; }
.login-subtitle { font-size: 14px; color: var(--text-gray); text-align: center; margin-bottom: 32px; }
.login-error {
    background: var(--danger-light); color: var(--danger);
    padding: 12px 16px; border-radius: 10px; font-size: 13px;
    margin-bottom: 20px; display: flex; align-items: center; gap: 8px;
}
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; color: var(--text-dark); margin-bottom: 8px; }
.input-wrapper { position: relative; }
.input-wrapper i.input-icon {
    position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
    color: var(--text-light); font-size: 16px; pointer-events: none;
}
.input-wrapper input {
    width: 100%; padding: 14px 16px 14px 46px;
    border: 1px solid var(--border-color); border-radius: 12px;
    font-family: var(--font-primary); font-size: 14px; color: var(--text-dark);
    outline: none; background-color: #f9fafb;
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.input-wrapper input:focus { border-color: var(--primary); background: white; box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1); }
.input-wrapper input::placeholder { color: var(--text-light); }
.password-toggle {
    position: absolute; right: 16px; top: 50%; transform: translateY(-50%);
    background: none; border: none; color: var(--text-light); cursor: pointer; font-size: 15px; padding: 4px;
}
.password-toggle:hover { color: var(--primary); }
.login-options { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; font-size: 13px; }
.remember-me { display: flex; align-items: center; gap: 8px; color: var(--text-gray); cursor: pointer; user-select: none; }
.remember-me input { width: 16px; height: 16px; accent-color: var(--primary); cursor: pointer; }
.forgot-password { color: var(--primary); text-decoration: none; font-weight: 600; transition: color 0.2s; }
.forgot-password:hover { color: var(--primary-hover); }
.login-btn {
    width: 100%; padding: 15px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white; border: none; border-radius: 12px;
    font-family: var(--font-primary); font-size: 15px; font-weight: 700;
    cursor: pointer; transition: transform 0.2s, box-shadow 0.2s;
    letter-spacing: 0.5px; display: flex; justify-content: center; align-items: center; gap: 10px;
}
.login-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 25px -5px rgba(79, 70, 229, 0.4); }
.login-btn:active { transform: translateY(0); }
.login-btn:disabled { opacity: 0.7; cursor: not-allowed; transform: none; }
.login-hint {
    text-align: center; margin-top: 24px; font-size: 12px;
    color: var(--text-gray); background: #f3f4f6;
    padding: 12px; border-radius: 10px; line-height: 1.6;
}
.login-hint strong { color: var(--primary); }
.login-footer { text-align: center; margin-top: 24px; font-size: 13px; color: var(--text-gray); }
.login-footer a { color: var(--primary); font-weight: 600; text-decoration: none; }

/* ========== PORTAL LAYOUT ========== */
.portal-container { display: flex; height: 100vh; width: 100vw; }

/* ========== SIDEBAR ========== */
.sidebar {
    width: 260px; background-color: var(--bg-card); padding: 24px 20px;
    display: flex; flex-direction: column;
    border-right: 1px solid var(--border-color);
    flex-shrink: 0; z-index: 1000;
    transition: transform 0.3s ease-in-out;
}
.logo-container { display: flex; align-items: center; gap: 12px; margin-bottom: 40px; }
.logo-icon { width: 210px; height: 70px; margin-bottom: -20px; flex-shrink: 0; }
.logo-image { width: 100%; height: 100%; object-fit: contain; display: block; }
.nav-menu { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.nav-item {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 16px; border: none; background: none;
    border-radius: var(--radius-md); cursor: pointer;
    font-family: var(--font-primary); font-size: 14px; font-weight: 500;
    color: var(--text-gray); transition: all 0.2s; text-align: left;
}
.nav-item:hover { background-color: #f3f4f6; color: var(--text-dark); }
.nav-item.active { background-color: var(--primary-light); color: var(--primary); font-weight: 600; }
.nav-item i { font-size: 16px; width: 20px; text-align: center; }
.sidebar-footer { margin-top: auto; padding-top: 20px; border-top: 1px solid var(--border-color); }
.user-mini { display: flex; align-items: center; gap: 12px; }
.user-mini img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.user-mini h4 { font-size: 13px; font-weight: 600; }
.user-mini p { font-size: 10px; color: var(--text-gray); }
.logout-btn {
    display: flex; align-items: center; gap: 8px;
    padding: 8px 12px; border-radius: 8px;
    border: 1px solid var(--border-color); background: white;
    color: var(--text-gray); font-family: var(--font-primary);
    font-size: 12px; font-weight: 600; cursor: pointer;
    transition: all 0.2s; margin-top: 12px; width: 100%; justify-content: center;
    text-decoration: none;
}
.logout-btn:hover { background: var(--danger-light); border-color: var(--danger); color: var(--danger); }

/* ========== MAIN CONTENT ========== */
.main-content { flex: 1; padding: 24px 32px; overflow-y: auto; min-width: 0; }

.top-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 24px; gap: 20px; }
.header-left { display: flex; align-items: center; gap: 16px; flex: 1; }
.menu-toggle { display: none; background: none; border: none; font-size: 24px; cursor: pointer; padding: 8px; color: var(--text-dark); }
.mobile-logo { display: none; height: 40px; object-fit: contain; }
.search-bar {
    display: flex; align-items: center; gap: 10px;
    background: var(--bg-card); border: 1px solid var(--border-color);
    padding: 10px 16px; border-radius: 50px; width: 100%; max-width: 400px;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.search-bar:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }
.search-bar i { color: var(--text-light); font-size: 14px; }
.search-bar input { border: none; outline: none; background: transparent; font-family: var(--font-primary); font-size: 13px; width: 100%; color: var(--text-dark); }
.header-right { display: flex; align-items: center; gap: 16px; }
.live-clock { text-align: right; }
.live-clock h2 { font-family: var(--font-heading); font-size: 18px; font-weight: 600; color: var(--text-dark); }
.live-clock p { font-size: 11px; color: var(--text-gray); }
.icon-btn {
    width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border-color);
    background: var(--bg-card); cursor: pointer; display: flex; justify-content: center; align-items: center;
    color: var(--text-gray); transition: all 0.2s; position: relative;
}
.icon-btn:hover { background: #f3f4f6; color: var(--text-dark); }
.badge-dot { position: absolute; top: 8px; right: 10px; width: 8px; height: 8px; background: var(--danger); border-radius: 50%; border: 2px solid var(--bg-card); }

/* ========== SECTIONS ========== */
.content-section { display: none; }
.content-section.active { display: block; animation: fadeIn 0.4s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.page-header { margin-bottom: 24px; }
.page-title { font-family: var(--font-heading); font-size: 26px; font-weight: 700; color: var(--text-dark); margin-bottom: 4px; }
.page-subtitle { font-size: 14px; color: var(--text-gray); }

/* ========== CARDS ========== */
.card {
    background: var(--bg-card); border: 1px solid var(--border-color);
    border-radius: var(--radius-lg); padding: 20px; margin-bottom: 20px;
    box-shadow: var(--shadow-sm); transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { box-shadow: var(--shadow-md); }
.card h3 { font-size: 15px; font-weight: 600; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }

/* ========== FEED ========== */
.feed-layout { display: grid; grid-template-columns: 1fr 300px; gap: 24px; align-items: start; }
.feed-center { display: flex; flex-direction: column; gap: 20px; }
.create-post-card { display: flex; align-items: center; gap: 12px; padding: 16px; }
.create-post-card img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.create-post-card input { flex: 1; border: none; outline: none; background: #f3f4f6; padding: 12px 16px; border-radius: 50px; font-family: var(--font-primary); font-size: 14px; }
.btn-primary-sm { background: var(--primary); color: white; border: none; padding: 10px 20px; border-radius: 50px; cursor: pointer; font-weight: 600; font-size: 13px; display: flex; align-items: center; gap: 8px; transition: background 0.2s; }
.btn-primary-sm:hover { background: var(--primary-hover); }
.feed-post { padding: 20px; }
.post-header { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; position: relative; }
.post-header img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.post-meta h4 { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.post-meta p { font-size: 11px; color: var(--text-gray); }
.verified { color: var(--primary); font-size: 12px; }
.post-menu { margin-left: auto; background: none; border: none; color: var(--text-light); cursor: pointer; padding: 4px; }
.post-content { font-size: 14px; line-height: 1.6; color: var(--text-dark); margin-bottom: 16px; }
.post-stats { display: flex; gap: 16px; font-size: 12px; color: var(--text-gray); margin-bottom: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--border-color); }
.post-actions { display: flex; justify-content: space-around; }
.post-actions button { background: none; border: none; font-size: 13px; color: var(--text-gray); cursor: pointer; display: flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 8px; transition: all 0.2s; font-weight: 500; }
.post-actions button:hover { background: #f3f4f6; color: var(--primary); }
.feed-sidebar-right .trending-list { list-style: none; display: flex; flex-direction: column; gap: 16px; }
.trending-list li { display: flex; align-items: center; gap: 12px; }
.rank-num { width: 24px; height: 24px; border-radius: 50%; display: flex; justify-content: center; align-items: center; font-size: 11px; font-weight: 700; color: white; flex-shrink: 0; }
.rank-num.gold { background: #fbbf24; }
.rank-num.silver { background: #9ca3af; }
.rank-num.bronze { background: #d97706; }
.trending-list img { width: 36px; height: 36px; }
.trending-list h4 { font-size: 13px; font-weight: 600; }
.trending-list p { font-size: 11px; color: var(--text-gray); }
.event-list { list-style: none; display: flex; flex-direction: column; gap: 16px; }
.event-list li { display: flex; gap: 16px; align-items: center; }
.event-date { background: var(--primary-light); color: var(--primary); padding: 8px 12px; border-radius: 8px; text-align: center; font-weight: 700; font-size: 12px; line-height: 1.2; flex-shrink: 0; }
.event-date span { display: block; font-size: 16px; }
.event-info h4 { font-size: 13px; font-weight: 600; }
.event-info p { font-size: 11px; color: var(--text-gray); }

/* ========== TABLES ========== */
.full-width-card { padding: 0; overflow: hidden; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { padding: 16px 20px; text-align: left; border-bottom: 1px solid var(--border-color); font-size: 13px; }
.data-table th { font-weight: 600; color: var(--text-gray); font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; background: #f9fafb; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: #f9fafb; }
.badge { padding: 4px 12px; border-radius: 20px; font-size: 11px; font-weight: 600; display: inline-block; }
.badge.success { background: var(--success-light); color: var(--success); }
.badge.danger { background: var(--danger-light); color: var(--danger); }
.badge.warning { background: var(--warning-light); color: var(--warning); }

/* ========== LEADERBOARD ========== */
.ranking-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.rank-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-lg); padding: 30px 20px; text-align: center; position: relative; transition: transform 0.2s, box-shadow 0.2s; box-shadow: var(--shadow-sm); }
.rank-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.rank-card.gold { border: 2px solid #fbbf24; }
.rank-card.silver { border: 2px solid #9ca3af; }
.rank-card.bronze { border: 2px solid #d97706; }
.rank-badge { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); width: 32px; height: 32px; border-radius: 50%; color: white; font-weight: 700; font-size: 14px; display: flex; justify-content: center; align-items: center; box-shadow: var(--shadow-md); }
.rank-card.gold .rank-badge { background: #fbbf24; }
.rank-card.silver .rank-badge { background: #9ca3af; }
.rank-card.bronze .rank-badge { background: #d97706; }
.rank-card img { width: 64px; height: 64px; margin-bottom: 12px; }
.rank-card h3 { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.rank-card p { font-size: 13px; color: var(--text-gray); }

/* ========== SCOREBOARD ========== */
.scoreboard-layout { display: grid; grid-template-columns: minmax(0, 68%) minmax(0, 32%); gap: 20px; align-items: start; width: 100%; }
.scoreboard-panel { width: 100%; min-width: 0; padding: 20px; background: #ffffff; border: 1px solid #e2e8f0; border-radius: 16px; box-shadow: 0 4px 18px rgba(15, 23, 42, 0.06); }
.scoreboard-panel .panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid #eef0f4; }
.scoreboard-panel .panel-heading h2 { margin: 0 0 5px; font-size: 20px; font-weight: 700; color: #09287b; }
.scoreboard-panel .panel-heading p { margin: 0; font-size: 13px; color: #64748b; }
.scoreboard-panel .panel-heading > i { font-size: 24px; color: #c9ab77; }
.scoreboard-table-container { width: 100%; overflow-x: auto; border-radius: 10px; }
.scoreboard-table { width: 100%; border-collapse: collapse; background: #ffffff; }
.scoreboard-table th, .scoreboard-table td { padding: 13px 10px; text-align: left; border-bottom: 1px solid #eef0f4; font-size: 13px; }
.scoreboard-table th { background: #f8fafc; color: #475569; font-weight: 700; white-space: nowrap; }
.scoreboard-table tbody tr:last-child td { border-bottom: none; }
.scoreboard-table tbody tr:hover { background: #f8fafc; }
.team-icon-only { display: flex; flex-direction: row; align-items: center; justify-content: flex-start; gap: 6px; flex-wrap: nowrap; width: max-content; }
.team-icon-only img { display: block; flex: 0 0 32px; width: 32px; height: 32px; object-fit: contain; }
.rank-pill { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; font-weight: 700; font-size: 12px; color: white; }
.rank-pill.gold { background: #fbbf24; }
.rank-pill.silver { background: #9ca3af; }
.rank-pill.bronze { background: #d97706; }
.rank-pill.default { background: var(--text-light); }
.teams-panel { width: 100%; min-width: 0; padding: 18px; background: #ffffff; border: 1px solid #e2e8f0; border-radius: 16px; box-shadow: 0 4px 18px rgba(15, 23, 42, 0.06); }
.teams-panel .panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; padding-bottom: 14px; border-bottom: 1px solid #eef0f4; }
.teams-panel .panel-heading h2 { margin: 0 0 5px; font-size: 18px; font-weight: 700; color: #09287b; }
.teams-panel .panel-heading p { margin: 0; font-size: 12px; color: #64748b; }
.teams-panel .panel-heading > i { font-size: 21px; color: #c9ab77; }
.teams-ranking-row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 9px; width: 100%; }
.team-ranking-card { display: flex; align-items: center; gap: 10px; width: 100%; min-width: 0; padding: 9px 10px; background: #f8fafc; border: 1px solid #e8edf4; border-radius: 10px; transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease; }
.team-ranking-card:hover { background: #f1f5f9; border-color: #cbd5e1; transform: translateX(2px); }
.team-ranking-card .team-rank { flex-shrink: 0; min-width: 28px; padding: 5px 4px; text-align: center; font-size: 11px; font-weight: 800; color: #09287b; background: #e8edf9; border-radius: 6px; }
.team-ranking-card img { display: block; flex-shrink: 0; width: 36px; height: 36px; margin: 0; object-fit: contain; }
.team-ranking-card h3 { margin: 0; font-size: 12px; font-weight: 700; line-height: 1.4; color: #1e293b; overflow-wrap: anywhere; }

/* ========== EVENTS ========== */
.event-stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin-bottom: 24px; }
.event-stat-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-md); padding: 16px; display: flex; align-items: center; gap: 12px; box-shadow: var(--shadow-sm); transition: transform 0.2s, box-shadow 0.2s; }
.event-stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.event-stat-icon { width: 44px; height: 44px; border-radius: 12px; display: flex; justify-content: center; align-items: center; font-size: 18px; flex-shrink: 0; }
.event-stat-icon.total { background: #e0e7ff; color: #4f46e5; }
.event-stat-icon.upcoming { background: #d1fae5; color: #10b981; }
.event-stat-icon.ongoing { background: #fef3c7; color: #f59e0b; }
.event-stat-icon.completed { background: #f3f4f6; color: #6b7280; }
.event-stat-info h3 { font-size: 22px; font-weight: 700; color: var(--text-dark); margin-bottom: 2px; }
.event-stat-info p { font-size: 11px; color: var(--text-gray); font-weight: 500; text-transform: uppercase; letter-spacing: 0.5px; }
.event-filter-tabs { display: flex; gap: 8px; margin-bottom: 24px; flex-wrap: wrap; }
.filter-tab { padding: 8px 20px; border-radius: 50px; border: 1px solid var(--border-color); background: var(--bg-card); color: var(--text-gray); font-family: var(--font-primary); font-size: 13px; font-weight: 500; cursor: pointer; transition: all 0.2s; }
.filter-tab:hover { background: #f3f4f6; color: var(--text-dark); }
.filter-tab.active { background: var(--primary); color: white; border-color: var(--primary); }
.events-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 24px; }
.event-card { background: var(--bg-card); border: 1px solid var(--border-color); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); transition: transform 0.2s, box-shadow 0.2s; display: flex; flex-direction: column; }
.event-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.event-card-image { width: 100%; height: 160px; background: linear-gradient(135deg, var(--primary), #818cf8); position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; color: white; font-size: 44px; }
.event-card-image .event-badge { position: absolute; top: 16px; left: 16px; background: white; color: var(--primary); padding: 6px 14px; border-radius: 20px; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; z-index: 2; }
.event-card-image .event-badge.upcoming { color: var(--success); }
.event-card-image .event-badge.ongoing { color: var(--warning); }
.event-card-image .event-badge.completed { color: var(--text-gray); }
.event-card-body { padding: 20px; flex: 1; display: flex; flex-direction: column; }
.event-card-body h3 { font-family: var(--font-heading); font-size: 17px; font-weight: 600; color: var(--text-dark); margin-bottom: 10px; }
.event-card-body .event-meta { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; font-size: 12px; color: var(--text-gray); }
.event-card-body .event-meta span { display: flex; align-items: center; gap: 8px; }
.event-card-body .event-meta i { color: var(--primary); font-size: 12px; width: 14px; text-align: center; }
.event-card-body p { font-size: 13px; color: var(--text-gray); line-height: 1.6; margin-bottom: 16px; flex: 1; }
.event-card-body .event-footer { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--border-color); padding-top: 12px; margin-top: auto; }
.event-card-body .event-footer .event-status { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; padding: 4px 12px; border-radius: 20px; }
.event-card-body .event-footer .event-status.upcoming { background: var(--success-light); color: var(--success); }
.event-card-body .event-footer .event-status.ongoing { background: var(--warning-light); color: var(--warning); }
.event-card-body .event-footer .event-status.completed { background: #f3f4f6; color: var(--text-gray); }
.btn-event { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 50px; font-size: 12px; font-weight: 600; background: var(--primary); color: white; border: none; cursor: pointer; transition: background 0.2s; text-decoration: none; }
.btn-event:hover { background: var(--primary-hover); }

/* ========== PROFILE ========== */
.profile-layout { display: grid; grid-template-columns: 1fr 2fr; gap: 24px; max-width: 1000px; }
.profile-card { text-align: center; padding: 0 0 30px 0; overflow: hidden; }
.profile-cover { height: 120px; background: linear-gradient(135deg, var(--primary), #818cf8); width: 100%; }
.profile-card .profile-img { width: 100px; height: 100px; border-radius: 50%; object-fit: cover; margin-top: -50px; border: 4px solid var(--bg-card); position: relative; }
.profile-card h2 { font-family: var(--font-heading); font-size: 22px; font-weight: 600; margin-top: 12px; margin-bottom: 4px; }
.profile-card .role { font-size: 13px; color: var(--text-gray); margin-bottom: 24px; }
.profile-stats { display: flex; justify-content: center; gap: 24px; border-top: 1px solid var(--border-color); padding-top: 20px; margin: 0 20px; }
.profile-stats div { text-align: center; }
.profile-stats h4 { font-size: 18px; font-weight: 700; color: var(--primary); }
.profile-stats p { font-size: 11px; color: var(--text-gray); }
.profile-details { padding: 30px; }
.profile-details h3 { font-size: 16px; margin-bottom: 20px; }
.detail-row { display: flex; justify-content: space-between; padding: 14px 0; border-bottom: 1px solid var(--border-color); font-size: 14px; }
.detail-row span { color: var(--text-gray); }
.btn-primary { background: var(--primary); color: white; border: none; padding: 12px 24px; border-radius: var(--radius-md); cursor: pointer; font-weight: 600; font-size: 14px; width: 100%; transition: background 0.2s; display: flex; align-items: center; justify-content: center; gap: 8px; }
.btn-primary:hover { background: var(--primary-hover); }

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
    .feed-layout { grid-template-columns: 1fr; }
    .feed-sidebar-right { display: block; }
}
@media (max-width: 1024px) {
    .profile-layout { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .portal-container { flex-direction: column; }
    .sidebar { position: fixed; top: 0; left: 0; height: 100vh; transform: translateX(-100%); box-shadow: 4px 0 15px rgba(0,0,0,0.1); }
    .sidebar.active { transform: translateX(0); }
    .menu-toggle { display: block; }
    .mobile-logo { display: block; }
    .main-content { padding: 16px; height: 100vh; }
    .top-header { flex-direction: column; align-items: stretch; gap: 12px; }
    .header-left { width: 100%; justify-content: flex-start; align-items: center; flex-wrap: wrap; }
    .search-bar { max-width: 100%; flex: 1; order: 3; width: 100%; }
    .header-right { width: 100%; justify-content: space-between; align-items: center; }
    .live-clock { display: block; text-align: left; }
    .data-table th, .data-table td { padding: 10px; font-size: 12px; }
    .page-title { font-size: 22px; }
    .feed-layout { grid-template-columns: 1fr; }
    .events-grid { grid-template-columns: 1fr; }
    .event-stats-row { grid-template-columns: 1fr 1fr; }
    .scoreboard-layout { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    .login-card { padding: 32px 24px; }
}
@media (max-width: 480px) {
    .ranking-grid { grid-template-columns: 1fr; }
    .profile-stats { flex-direction: column; gap: 16px; }
    .post-actions button { padding: 8px; }
    .event-stats-row { grid-template-columns: 1fr; }
}