/* CSS Variables */
:root {
    --primary-color: #6c5ce7;
    --secondary-color: #a29bfe;
    --accent-color: #fd79a8;
    --dark-bg: #1a1a2e;
    --card-bg: #16213e;
    --light-bg: #0f3460;
    --text-primary: #f1f1f1;
    --text-secondary: #a5a5a5;
    --success-color: #00b894;
    --error-color: #d63031;
    --border-radius: 12px;
    --transition: all 0.3s ease;

    /* Skill Level Colors */
    --newcomer-color: #95e1d3;
    --bronze-color: #cd7f32;
    --silver-color: #c0c0c0;
    --gold-color: #ffd700;
    --novice-color: #a29bfe;
    --prechamp-color: #fd79a8;
    --championship-color: #00b894;
    --master-color: #ff9966;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--light-bg) 100%);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
}

.hidden {
    display: none !important;
}

/* Loading Screen */
.loading-screen {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: var(--bg-color);
}

.loading-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

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

.loading-title {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin: 0;
    font-weight: 700;
}

.loading-progress-container {
    width: 220px;
    height: 6px;
    background: var(--secondary-color);
    border-radius: 3px;
    overflow: hidden;
}

.loading-progress-bar {
    height: 100%;
    width: 0%;
    background: var(--primary-color);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.loading-status {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin: 0;
}

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

/* Auth Screen */
.screen {
    min-height: 100vh;
}

#auth-screen {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.auth-container {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 40px;
    max-width: 450px;
    width: 100%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

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

.auth-header h1 {
    font-size: 2rem;
    margin-bottom: 10px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.auth-header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.auth-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
}

.auth-tab {
    flex: 1;
    padding: 12px;
    background: transparent;
    border: 2px solid var(--secondary-color);
    border-radius: var(--border-radius);
    color: var(--text-primary);
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
}

.auth-tab:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.auth-tab.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.form-group input {
    padding: 12px;
    background: var(--dark-bg);
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition);
}

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

.btn {
    padding: 12px 24px;
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: var(--border-radius);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    background: rgba(20, 28, 45, 0.9);
    color: white;
}

.btn:hover {
    background: rgba(50, 60, 85, 0.9);
    border-color: rgba(108, 92, 231, 0.8);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), #5a4fcf);
    border-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 92, 231, 0.4);
}

.btn-secondary {
    background: rgba(20, 28, 45, 0.9);
    color: white;
    border: 2px solid rgba(108, 92, 231, 0.6);
}

.btn-secondary:hover {
    background: rgba(50, 60, 85, 0.9);
    border-color: rgba(108, 92, 231, 0.8);
    color: white;
}

.btn-small {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.auth-error {
    color: var(--error-color);
    font-size: 0.9rem;
    text-align: center;
    min-height: 20px;
}

.auth-success {
    color: var(--success-color, #4ade80);
    font-size: 0.9rem;
    text-align: center;
    background: rgba(74, 222, 128, 0.1);
    padding: 12px;
    border-radius: 8px;
    border: 1px solid rgba(74, 222, 128, 0.3);
}

.forgot-password-link,
.back-to-login {
    text-align: center;
    margin-top: 10px;
}

.forgot-password-link a,
.back-to-login a {
    color: var(--accent-color);
    text-decoration: none;
    font-size: 0.9rem;
}

.forgot-password-link a:hover,
.back-to-login a:hover {
    text-decoration: underline;
}

.reset-instructions {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.auth-footer {
    margin-top: 20px;
    text-align: center;
}

/* Main Screen */
#main-screen {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Navigation */
.navbar {
    background: var(--card-bg);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.nav-brand {
    font-size: 1.5rem;
    font-weight: bold;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.nav-item {
    padding: 10px 20px;
    background: transparent;
    border: none;
    border-radius: var(--border-radius);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
}

.nav-item:hover {
    color: var(--text-primary);
    background: var(--dark-bg);
}

.nav-item.active {
    color: var(--text-primary);
    background: var(--primary-color);
}

.affiliation-icon-img {
    height: 45px;
    vertical-align: middle;
    border: 2px solid rgba(108, 92, 231, 0.8);
    border-radius: 8px;
    padding: 4px;
    background: white;
}

/* Pages */
.page {
    flex: 1;
    padding: 30px 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.page-header {
    margin-bottom: 30px;
    position: relative;
}

.page-header h2 {
    font-size: 2rem;
    margin-bottom: 10px;
}

.page-header p {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Dashboard */
.points-summary {
    margin-bottom: 30px;
}

.points-summary h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
}

.points-summary-card {
    background: var(--card-bg);
    padding: 30px;
    border-radius: var(--border-radius);
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.points-summary-card h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--accent-color);
}

.stats-row {
    display: grid;
    grid-template-columns: 100px 1fr 1fr;
    gap: 20px;
    margin-top: 25px; /* Extra spacing to prevent overlap with bird icon in header */
}

.stat {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary-color);
}

/* Level Bubbles */
.level-bubbles {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.level-bubble {
    padding: 8px 16px;
    border-radius: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
    color: white;
    cursor: help;
    transition: transform 0.2s ease;
    white-space: nowrap;
}

.level-bubble:hover {
    transform: scale(1.1);
}

/* Level bubble colors matching header colors */
.level-bubble.level-newcomer {
    background: linear-gradient(135deg, #95e1d3, #74b9ff);
}

.level-bubble.level-bronze {
    background: linear-gradient(135deg, #cd7f32, #b8860b);
}

.level-bubble.level-silver {
    background: linear-gradient(135deg, #c0c0c0, #a8a8a8);
}

.level-bubble.level-gold {
    background: linear-gradient(135deg, #ffd700, #ffb700);
}

.level-bubble.level-novice {
    background: linear-gradient(135deg, #a29bfe, #6c5ce7);
}

.level-bubble.level-prechamp {
    background: linear-gradient(135deg, #fd79a8, #e84393);
}

.level-bubble.level-championship {
    background: linear-gradient(135deg, #00b894, #00cec9);
}

.category-section {
    margin-bottom: 40px;
}

.category-section h4 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

.style-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.style-card {
    background: var(--card-bg);
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.style-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(108, 92, 231, 0.3);
}

.style-card h5 {
    font-size: 1.1rem;
    margin-bottom: 15px;
    color: var(--accent-color);
    border-bottom: 2px solid var(--light-bg);
    padding-bottom: 10px;
}

.dance-list {
    list-style: none;
}

.dance-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid var(--light-bg);
}

.dance-list li:last-child {
    border-bottom: none;
}

.dance-name {
    color: var(--text-primary);
}

.dance-points {
    font-weight: bold;
    color: var(--primary-color);
}

/* Search */
.search-container {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: nowrap;
    align-items: center;
}

.search-input {
    flex: 1;
    padding: 12px;
    background: var(--card-bg);
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition);
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.search-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 30px;
}

.search-controls label {
    color: var(--text-secondary);
    font-weight: 500;
}

.sort-select {
    padding: 8px 12px;
    background: var(--card-bg);
    border: 2px solid var(--light-bg);
    border-radius: var(--border-radius);
    color: var(--text-primary);
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition);
}

.sort-select:hover {
    border-color: var(--primary-color);
}

.sort-select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* Season Dividers */
.season-divider {
    margin: 30px 0 20px 0;
    padding: 15px 0;
    border-bottom: 2px solid rgba(108, 92, 231, 0.4);
}

.season-divider:first-child {
    margin-top: 0;
}

.season-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-color);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 15px;
}

.season-title::after {
    content: '';
    flex: 1;
    height: 2px;
    background: linear-gradient(90deg, rgba(108, 92, 231, 0.3) 0%, transparent 100%);
}

/* Current Season Styling */
.season-divider.current-season {
    border-bottom-color: rgba(46, 204, 113, 0.5);
}

.season-divider.current-season .season-title {
    color: #2ecc71;
}

.season-divider.current-season .season-title::after {
    background: linear-gradient(90deg, rgba(46, 204, 113, 0.4) 0%, transparent 100%);
}

.current-season-badge {
    font-size: 0.7rem;
    font-weight: 600;
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(46, 204, 113, 0.3);
}

.dancer-card {
    background: var(--card-bg);
    padding: 20px;
    padding-bottom: 100px; /* Extra padding for bird icon */
    border-radius: var(--border-radius);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    position: relative;
}

.dancer-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(108, 92, 231, 0.3);
}

/* Competition cards need no padding so header fills edge-to-edge */
.dancer-card.competition-card {
    padding: 0;
    padding-bottom: 0;
    background: transparent;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border: 2px solid rgba(108, 92, 231, 0.35);
}

.dancer-card.competition-card .comp-body {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.dancer-card h4 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: inherit;
    text-align: center;
    font-weight: 700;
}

.skill-indicator {
    font-size: 0.7rem;
    padding: 4px 8px;
    border-radius: 12px;
    font-weight: bold;
    color: white;
    white-space: nowrap;
}

.skill-indicator-bird {
    width: 80px;
    height: 80px;
    border-radius: 6px;
    border: 3px solid white;
    object-fit: cover;
    background: white;
    padding: 4px;
    position: absolute;
    bottom: 15px;
    right: 15px;
}

/* Level-based border colors for bird icons - background is one level down */
.skill-indicator-bird.level-newcomer {
    background: #95e1d3; /* Newcomer uses same color for background */
    box-shadow: 0 0 0 4px #95e1d3, 0 0 0 8px #95e1d3;
}

.skill-indicator-bird.level-bronze {
    background: #95e1d3; /* Newcomer color */
    box-shadow: 0 0 0 4px #cd7f32, 0 0 0 8px #cd7f32;
}

.skill-indicator-bird.level-silver {
    background: #cd7f32; /* Bronze color */
    box-shadow: 0 0 0 4px #c0c0c0, 0 0 0 8px #c0c0c0;
}

.skill-indicator-bird.level-gold {
    background: #c0c0c0; /* Silver color */
    box-shadow: 0 0 0 4px #ffd700, 0 0 0 8px #ffd700;
}

.skill-indicator-bird.level-novice {
    background: #ffd700; /* Gold color */
    box-shadow: 0 0 0 4px #a29bfe, 0 0 0 8px #a29bfe;
}

.skill-indicator-bird.level-prechamp {
    background: #a29bfe; /* Novice color */
    box-shadow: 0 0 0 4px #fd79a8, 0 0 0 8px #fd79a8;
}

.skill-indicator-bird.level-championship {
    background: #fd79a8; /* Prechamp color */
    box-shadow: 0 0 0 4px #00b894, 0 0 0 8px #00b894;
}

.skill-indicator-bird.level-master {
    background: #00b894; /* Championship color */
    box-shadow: 0 0 0 4px #ff9966, 0 0 0 8px #ff9966;
}

.dancer-stats {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    align-items: flex-start;
}

.dancer-stats .stat {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    flex-wrap: wrap;
    width: 100%;
}

.dancer-stats .level-bubbles {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.level-bubbles-grid {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: flex-start;
}

.bubble-row {
    display: flex;
    gap: 5px;
    justify-content: flex-start;
}

/* Profile */
.profile-container {
    max-width: 800px;
}

.profile-section {
    background: var(--card-bg);
    padding: 30px;
    border-radius: var(--border-radius);
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.profile-section h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

.info-row {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px solid var(--light-bg);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 600;
    color: var(--text-secondary);
    min-width: 120px;
}

.info-message {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.success-message {
    color: var(--success-color);
    font-size: 0.95rem;
    padding: 15px;
    background: rgba(0, 184, 148, 0.1);
    border-radius: var(--border-radius);
    margin-top: 15px;
}

/* Link Results */
.link-results-list h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.link-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: var(--dark-bg);
    border-radius: var(--border-radius);
    margin-bottom: 10px;
    gap: 20px;
}

.link-result-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
}

.link-result-info strong {
    color: var(--text-primary);
    font-size: 1.1rem;
}

.link-result-info span {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* Friends Section */
.friends-subsection {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--text-secondary);
}

.friends-primary-section {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

.friends-list-box {
    background: var(--dark-bg);
    border-radius: var(--border-radius);
    padding: 20px;
    border: 1px solid rgba(108, 92, 231, 0.2);
}

.friends-subsection h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.friends-subsection h5 {
    font-size: 1rem;
    margin: 15px 0 10px 0;
    color: var(--text-secondary);
}

/* Friend Cards */
.friend-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: var(--dark-bg);
    border-radius: var(--border-radius);
    margin-bottom: 10px;
    gap: 15px;
}

.friend-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    flex: 1;
}

.friend-name-with-bird {
    display: flex;
    align-items: center;
    gap: 10px;
}

.friend-info h4 {
    color: var(--text-primary);
    font-size: 1.1rem;
    margin: 0;
}

.friend-info span {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.friend-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* Bird Icon Wrapper - matches "Current Bird" structure */
.bird-icon-wrapper {
    flex-shrink: 0;
    margin-right: 10px;
}

/* Friend Request Items */
.friend-request-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    margin-bottom: 8px;
    gap: 15px;
}

.request-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.request-info strong {
    color: var(--text-primary);
    font-size: 1rem;
}

.request-info span {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.request-actions {
    display: flex;
    gap: 8px;
}

/* Friend Search Results */
.friend-search-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: var(--dark-bg);
    border-radius: var(--border-radius);
    margin-bottom: 10px;
    gap: 15px;
}

.friend-search-result-item:hover {
    background: var(--light-bg);
    transition: var(--transition);
}

/* Empty State Messages */
.friends-empty-message {
    padding: 20px;
    text-align: center;
    color: var(--text-secondary);
    font-style: italic;
}

/* Responsive */
@media (max-width: 768px) {
    .friend-card,
    .friend-request-item,
    .friend-search-result-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .friend-actions,
    .request-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 20px;
}

.modal-content {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    max-width: 1400px;
    width: 95vw;
    max-height: 90vh;
    overflow-y: auto;
    padding: 30px;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--text-primary);
}

.profile-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}

.unlock-conditions-modal {
    max-width: 1100px;
}

.unlock-section {
    margin-top: 20px;
}

.unlock-bird-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
}

.unlock-bird-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--dark-bg);
    border-radius: 10px;
    padding: 12px 16px;
    border: 1px solid var(--light-bg);
}

.unlock-bird-icon {
    width: 44px;
    height: 44px;
    background: #ffffff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.unlock-bird-icon img {
    width: 36px;
    height: 36px;
}

.unlock-bird-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.unlock-color-header,
.unlock-color-row {
    display: grid;
    grid-template-columns: 160px 1fr 1fr;
    gap: 12px;
    align-items: center;
}

.unlock-color-header {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.85rem;
    padding: 8px 6px;
}

.unlock-color-row {
    background: var(--dark-bg);
    border-radius: 10px;
    padding: 10px 12px;
    border: 1px solid var(--light-bg);
    margin-bottom: 8px;
}

.unlock-color-name {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-primary);
    font-weight: 600;
}

.unlock-color-swatch {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: inline-block;
}

.unlock-color-requirement {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

@media (max-width: 800px) {
    .unlock-color-header,
    .unlock-color-row {
        grid-template-columns: 1fr;
    }

    .unlock-color-header {
        display: none;
    }
}

/* Scoreboard modal tabs */
.scoreboard-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
}

.scoreboard-tab {
    background: var(--dark-bg);
    color: var(--text-secondary);
    border: 1px solid var(--light-bg);
    border-radius: 999px;
    padding: 6px 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.scoreboard-tab.active {
    color: var(--text-primary);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 1px rgba(108, 92, 231, 0.3);
}

.scoreboard-tab-content {
    display: none;
}

.scoreboard-tab-content.active {
    display: block;
}

/* Chat Modal */
.chat-modal-content {
    max-width: 600px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    padding: 0;
}

.chat-header {
    padding: 20px;
    border-bottom: 1px solid var(--light-bg);
    background: var(--dark-bg);
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.chat-header-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.chat-header-info h3 {
    margin: 0;
    color: var(--text-primary);
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    min-height: 300px;
    max-height: 500px;
}

.chat-message {
    margin-bottom: 15px;
    display: flex;
}

.chat-message.my-message {
    justify-content: flex-end;
}

.chat-message.their-message {
    justify-content: flex-start;
}

.message-bubble {
    max-width: 70%;
    padding: 10px 15px;
    border-radius: 15px;
}

.my-message .message-bubble {
    background: var(--primary-color);
    color: white;
}

.their-message .message-bubble {
    background: var(--light-bg);
    color: var(--text-primary);
}

.message-text {
    word-wrap: break-word;
    margin-bottom: 5px;
}

.message-time {
    font-size: 0.7rem;
    opacity: 0.7;
    text-align: right;
}

.chat-input-container {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    border-top: 1px solid var(--light-bg);
    background: var(--dark-bg);
    border-radius: 0 0 var(--border-radius) var(--border-radius);
}

.chat-input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid var(--light-bg);
    border-radius: 20px;
    background: var(--card-bg);
    color: var(--text-primary);
    font-size: 0.95rem;
}

.chat-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Notification Badge */
.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--error-color);
    color: white;
    border-radius: 10px;
    padding: 2px 6px;
    font-size: 0.7rem;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
}

.bird-notification-badge {
    position: absolute;
    top: -3px;
    right: -3px;
    background: var(--error-color);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
    border: 2px solid var(--dark-bg);
    z-index: 10;
}

.nav-item {
    position: relative;
}

/* Responsive Design */
@media (max-width: 768px) {
    /* Navigation — scrollable tab bar */
    .navbar {
        flex-direction: column;
        gap: 10px;
        padding: 10px 15px;
    }

    .nav-menu {
        flex-direction: row;
        overflow-x: auto;
        width: 100%;
        gap: 6px;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .nav-menu::-webkit-scrollbar {
        display: none;
    }

    .nav-item {
        width: auto;
        text-align: center;
        white-space: nowrap;
        padding: 8px 14px;
        font-size: 0.85rem;
        flex-shrink: 0;
    }

    .nav-right {
        gap: 8px;
    }

    /* Spacing & padding reductions */
    .page {
        padding: 15px 10px;
    }

    .page-header {
        margin-bottom: 15px;
    }

    .page-header h2 {
        font-size: 1.5rem;
    }

    .points-summary-card {
        padding: 15px;
    }

    .points-summary-card h3 {
        font-size: 1.3rem;
    }

    .profile-section {
        padding: 20px;
    }

    .category-section {
        margin-bottom: 20px;
    }

    .auth-container {
        padding: 30px 20px;
    }

    /* Grids */
    .stats-row {
        grid-template-columns: 1fr;
    }

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

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

    /* Style boxes: horizontal scroll on mobile */
    .style-boxes-container {
        display: flex;
        overflow-x: auto;
        gap: 10px;
        margin-top: 15px;
        padding-bottom: 8px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scroll-snap-type: x mandatory;
    }

    .style-boxes-container::-webkit-scrollbar {
        height: 4px;
    }

    .style-boxes-container::-webkit-scrollbar-thumb {
        background: rgba(108, 92, 231, 0.4);
        border-radius: 4px;
    }

    .style-box {
        min-width: 260px;
        max-width: 300px;
        flex: 0 0 auto;
        scroll-snap-align: start;
    }

    /* Search */
    .search-container {
        flex-direction: column;
    }

    .competition-list-header {
        flex-direction: column !important;
        gap: 10px;
    }

    /* Dancer cards */
    .dancer-card {
        padding-bottom: 70px;
    }

    .dancer-card h4 {
        font-size: 1.3rem;
    }

    .skill-indicator-bird {
        width: 60px;
        height: 60px;
    }

    /* Profile */
    .link-result-item {
        flex-direction: column;
        align-items: flex-start;
    }

    /* Modals */
    .modal-content {
        padding: 15px;
    }

    .dancer-profile-modal {
        padding: 15px;
    }

    /* Tables */
    .results-table th,
    .results-table td {
        padding: 8px 6px;
    }

    /* Affiliation icon */
    .affiliation-icon-img {
        height: 35px;
    }

    /* Dashboard header row */
    .dashboard-header-row {
        margin-bottom: 15px !important;
    }

    /* Style box headers */
    .style-box-header {
        padding: 12px;
        min-height: 50px;
    }

    .style-box-header h4 {
        font-size: 1rem;
    }

    .style-box-header .current-level {
        font-size: 0.75rem;
        padding: 3px 8px;
    }

    /* Style box content */
    .style-box-content {
        padding: 12px;
    }

    /* Event performance cards: stack elements vertically */
    .event-title-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .event-action-buttons {
        flex-wrap: wrap;
        width: 100%;
    }

    .btn-view-event,
    .btn-points-breakdown {
        flex: 1;
        text-align: center;
        min-width: 0;
    }

    .event-title {
        font-size: 0.95rem;
    }

    /* Results/marks table: horizontal scroll */
    .event-detail {
        overflow: hidden;
        padding: 15px;
    }

    .round-section {
        overflow: hidden;
        padding: 12px;
    }

    .dance-results,
    .overall-results,
    .round-content {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .results-table {
        min-width: 500px;
    }

    .couple-cell {
        min-width: 120px;
        max-width: 200px;
    }
}

@media (max-width: 480px) {
    .auth-header h1 {
        font-size: 1.5rem;
    }

    .nav-brand {
        font-size: 1.2rem;
    }

    .points-summary-card h3 {
        font-size: 1.2rem;
    }

    .stat-value {
        font-size: 1.5rem;
    }

    .page-header h2 {
        font-size: 1.2rem;
    }

    .page-header p {
        font-size: 0.85rem;
    }

    /* Profile */
    .info-label {
        min-width: 80px;
    }

    .info-row {
        flex-wrap: wrap;
    }

    /* Color/bird grids */
    .color-option {
        width: 55px;
        height: 55px;
    }

    /* Dashboard header stacks vertically on small phones */
    .dashboard-header-row {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 10px;
    }

    /* Level bubbles smaller on phones */
    .level-bubble {
        padding: 6px 10px;
        font-size: 0.8rem;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--dark-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Style Boxes Container */
.style-boxes-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 20px;
    width: 100%;
    min-width: 0; /* Allow items to shrink below their minimum content size */
}

/* Style Box */
.style-box {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.style-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(108, 92, 231, 0.3);
}

/* Style Box Header */
.style-box-header {
    padding: 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
    gap: 10px;
    flex-wrap: wrap;
    min-height: 70px;
}

.style-box-header:hover {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
}

/* Level-based colors */
.style-box-header.level-newcomer {
    background: linear-gradient(135deg, #95e1d3, #74b9ff);
}

.style-box-header.level-newcomer:hover {
    background: linear-gradient(135deg, #74b9ff, #95e1d3);
}

.style-box-header.level-bronze {
    background: linear-gradient(135deg, #cd7f32, #b8860b);
}

.style-box-header.level-bronze:hover {
    background: linear-gradient(135deg, #b8860b, #cd7f32);
}

.style-box-header.level-silver {
    background: linear-gradient(135deg, #c0c0c0, #a8a8a8);
}

.style-box-header.level-silver:hover {
    background: linear-gradient(135deg, #a8a8a8, #c0c0c0);
}

.style-box-header.level-gold {
    background: linear-gradient(135deg, #ffd700, #ffb700);
}

.style-box-header.level-gold:hover {
    background: linear-gradient(135deg, #ffb700, #ffd700);
}

.style-box-header.level-novice {
    background: linear-gradient(135deg, #a29bfe, #6c5ce7);
}

.style-box-header.level-novice:hover {
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
}

.style-box-header.level-prechamp {
    background: linear-gradient(135deg, #fd79a8, #e84393);
}

.style-box-header.level-prechamp:hover {
    background: linear-gradient(135deg, #e84393, #fd79a8);
}

.style-box-header.level-championship {
    background: linear-gradient(135deg, #00b894, #00cec9);
}

.style-box-header.level-championship:hover {
    background: linear-gradient(135deg, #00cec9, #00b894);
}

.style-box-header h4 {
    margin: 0;
    font-size: 1.4rem;
    color: white;
}

.style-box-header .current-level {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.2);
    padding: 4px 12px;
    border-radius: 20px;
    white-space: nowrap;
}

.style-box-header .expand-icon {
    font-size: 1.2rem;
    color: white;
    transition: transform 0.3s ease;
}

/* Style Box Content */
.style-box-content {
    padding: 20px;
    max-height: 600px;
    overflow-y: auto;
}

/* Level Section */
.level-section {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.level-section:last-child {
    border-bottom: none;
}

.level-section h5 {
    color: var(--secondary-color);
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.level-section .dance-list {
    list-style: none;
    padding: 0;
}

.level-section .dance-list li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.level-section .dance-list li:last-child {
    border-bottom: none;
}

.level-section .dance-name {
    color: var(--text-primary);
}

.level-section .dance-points {
    color: var(--accent-color);
    font-weight: 600;
}

.level-section .total-points {
    font-size: 1.2rem;
    color: var(--accent-color);
    font-weight: 600;
    text-align: center;
    padding: 10px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 8px;
}

/* Style Box Current Level */
.style-box-current {
    padding: 15px 20px;
}

.style-box-current .dance-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.style-box-current .dance-list li {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.style-box-current .dance-list li:last-child {
    border-bottom: none;
}

.style-box-current .dance-name {
    color: var(--text-primary);
    font-size: 0.9rem;
}

.style-box-current .dance-points {
    color: var(--accent-color);
    font-weight: 600;
}

.style-box-current .total-points {
    font-size: 1.1rem;
    color: var(--accent-color);
    font-weight: 600;
    text-align: center;
    padding: 8px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 8px;
}

.style-box-current .open-level-points {
    display: grid;
    gap: 10px;
}


/* Points Table View */
.points-table-container {
    margin-top: 30px;
    overflow-x: auto;
}

.points-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
}

.points-table th {
    background: var(--light-bg);
    color: var(--text-primary);
    padding: 12px 8px;
    text-align: center;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.points-table th.dance-header {
    font-size: 0.85rem;
    padding: 8px 4px;
}

.points-table td {
    padding: 10px 8px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.points-table td.level-name {
    font-weight: 600;
    text-align: left;
    padding-left: 15px;
    background: var(--light-bg);
}

.points-table td.completed {
    background: rgba(0, 184, 148, 0.2);
    color: var(--success-color);
    font-weight: 600;
}

.points-table td.points-exempt {
    background: rgba(255, 182, 193, 0.3);
    color: #FFB6C1;
    font-weight: 600;
}

.points-table td.points-complete {
    background: rgba(135, 206, 250, 0.3);
    color: #87CEEB;
    font-weight: 600;
}

.points-table td.points-partial {
    background: rgba(255, 215, 0, 0.25);
    color: #FFD700;
    font-weight: 600;
}

.points-table td.points-pending-complete {
    background: rgba(0, 255, 127, 0.25);
    color: #00ff7f;
    font-weight: 600;
}

.points-table td.merged-cell {
    font-weight: 600;
    background: rgba(108, 92, 231, 0.1);
}

.points-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

.view-toggle {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
}

.view-toggle button {
    padding: 10px 20px;
    background: var(--card-bg);
    color: var(--text-secondary);
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.view-toggle button.active {
    background: var(--primary-color);
    color: white;
}

.view-toggle button:hover {
    transform: translateY(-2px);
}

/* Pending Points Toggle */
.pending-points-toggle {
    margin-bottom: 15px;
    padding: 8px 14px;
    background: rgba(0, 255, 127, 0.08);
    border: 1px solid rgba(0, 255, 127, 0.25);
    border-radius: var(--border-radius);
}

.pending-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.pending-checkbox input[type="checkbox"] {
    accent-color: #00ff7f;
}

/* Pending complete indicator in box view dance lists */
.dance-points.pending-complete {
    color: #00ff7f;
    font-weight: 700;
}

.current-level.has-pending {
    color: #00ff7f;
}

.current-level.has-pending::after {
    content: ' *';
    font-size: 0.85em;
}

.total-points.pending-row,
.total-points.pending-row .dance-points,
.total-points.pending-row strong {
    color: #00ff7f;
}

.pending-legend {
    font-size: 0.8rem;
    color: #00ff7f;
    opacity: 0.7;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* Help Page */
.help-container {
    max-width: 900px;
    margin: 0 auto;
}

.help-intro {
    margin-bottom: 20px;
}

.help-intro h3 {
    margin: 0 0 8px 0;
    color: var(--text-primary);
    font-size: 2rem;
}

.help-section {
    background: var(--card-bg);
    padding: 30px;
    border-radius: var(--border-radius);
    margin-bottom: 30px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

.help-section h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.help-section h4 {
    color: var(--accent-color);
    margin-top: 20px;
    margin-bottom: 10px;
}

.help-section p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 15px;
}

.help-section ul {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-left: 25px;
}

.help-section ul li {
    margin-bottom: 10px;
}

.help-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

/* Help Dropdown Styles */
.help-dropdown {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    margin-bottom: 12px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(108, 92, 231, 0.2);
    overflow: hidden;
}

.help-dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    background: rgba(108, 92, 231, 0.1);
    transition: background 0.2s ease;
    list-style: none;
}

.help-dropdown-header::-webkit-details-marker {
    display: none;
}

.help-dropdown-header:hover {
    background: rgba(108, 92, 231, 0.2);
}

.help-dropdown[open] .help-dropdown-header {
    background: rgba(108, 92, 231, 0.25);
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
}

.dropdown-arrow {
    font-size: 0.8rem;
    color: var(--accent-color);
    transition: transform 0.3s ease;
}

.help-dropdown[open] .dropdown-arrow {
    transform: rotate(180deg);
}

.help-dropdown-content {
    padding: 20px 25px;
}

.help-dropdown-content p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 12px;
}

.help-dropdown-content ul {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-left: 25px;
    margin-bottom: 12px;
}

.help-dropdown-content ul li {
    margin-bottom: 8px;
}

.help-dropdown-content .info-note {
    background: rgba(108, 92, 231, 0.15);
    padding: 12px 16px;
    border-radius: 8px;
    border-left: 3px solid var(--accent-color);
    font-size: 0.9rem;
    margin-top: 15px;
}

/* Help Dropdown Color Variants */
.help-color-purple .help-dropdown-header { border-left: 4px solid #9b87f5; }
.help-color-purple[open] .help-dropdown-header { background: rgba(155, 135, 245, 0.15); }

.help-color-blue .help-dropdown-header { border-left: 4px solid #6b9fff; }
.help-color-blue[open] .help-dropdown-header { background: rgba(107, 159, 255, 0.15); }

.help-color-teal .help-dropdown-header { border-left: 4px solid #4ecdc4; }
.help-color-teal[open] .help-dropdown-header { background: rgba(78, 205, 196, 0.15); }

.help-color-gold .help-dropdown-header { border-left: 4px solid #f0c674; }
.help-color-gold[open] .help-dropdown-header { background: rgba(240, 198, 116, 0.15); }

.help-color-green .help-dropdown-header { border-left: 4px solid #7bc96f; }
.help-color-green[open] .help-dropdown-header { background: rgba(123, 201, 111, 0.15); }

.help-color-orange .help-dropdown-header { border-left: 4px solid #e8a87c; }
.help-color-orange[open] .help-dropdown-header { background: rgba(232, 168, 124, 0.15); }

.help-color-pink .help-dropdown-header { border-left: 4px solid #e898b8; }
.help-color-pink[open] .help-dropdown-header { background: rgba(232, 152, 184, 0.15); }

.help-color-cyan .help-dropdown-header { border-left: 4px solid #7dd3fc; }
.help-color-cyan[open] .help-dropdown-header { background: rgba(125, 211, 252, 0.15); }

.help-color-bronze .help-dropdown-header { border-left: 4px solid #cd9575; }
.help-color-bronze[open] .help-dropdown-header { background: rgba(205, 149, 117, 0.15); }

.help-color-red .help-dropdown-header { border-left: 4px solid #e87d7d; }
.help-color-red[open] .help-dropdown-header { background: rgba(232, 125, 125, 0.15); }

.help-color-silver .help-dropdown-header { border-left: 4px solid #a8b4c0; }
.help-color-silver[open] .help-dropdown-header { background: rgba(168, 180, 192, 0.15); }

.help-color-indigo .help-dropdown-header { border-left: 4px solid #818cf8; }
.help-color-indigo[open] .help-dropdown-header { background: rgba(129, 140, 248, 0.15); }

.help-color-slate .help-dropdown-header { border-left: 4px solid #94a3b8; }
.help-color-slate[open] .help-dropdown-header { background: rgba(148, 163, 184, 0.15); }

.help-color-gray .help-dropdown-header { border-left: 4px solid #9ca3af; }
.help-color-gray[open] .help-dropdown-header { background: rgba(156, 163, 175, 0.15); }

.help-item {
    background: var(--light-bg);
    padding: 15px;
    border-radius: var(--border-radius);
}

.help-item h4 {
    color: var(--primary-color);
    margin-top: 0;
}

.help-item p {
    font-size: 0.9rem;
    margin: 0;
}

.help-subsection {
    margin-top: 25px;
}

.help-subsection h4 {
    color: var(--secondary-color);
    margin-top: 0;
}

.level-progression {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.level-badge {
    padding: 8px 16px;
    border-radius: 25px;
    font-weight: bold;
    color: white;
    font-size: 0.9rem;
}

.arrow {
    color: var(--text-secondary);
    font-size: 1.5rem;
}

.color-legend {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.legend-item span:last-child {
    color: var(--text-secondary);
}

/* Bird Customization */
.bird-preview {
    margin-bottom: 30px;
    text-align: center;
}

.bird-display-large {
    display: inline-block;
    margin-top: 15px;
}

.bird-display-large img {
    /* Sizing handled by inline styles from generateBirdIconHTML */
}

.skill-indicator-bird-custom {
    width: 120px;
    height: 120px;
    border-radius: 8px;
    object-fit: cover;
}

.bird-options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 15px;
    margin-top: 15px;
    margin-bottom: 30px;
}

.bird-option {
    cursor: pointer;
    border: 3px solid transparent;
    border-radius: 8px;
    padding: 5px;
    transition: var(--transition);
    background: #e0e0e0;
    position: relative;
}

.bird-option:hover {
    border-color: var(--primary-color);
    transform: scale(1.05);
}

.bird-option.selected {
    border-color: var(--accent-color);
    box-shadow: 0 0 15px rgba(253, 121, 168, 0.5);
}

.bird-option.locked {
    opacity: 0.4;
    cursor: not-allowed;
}

.bird-option.locked:hover .tooltip {
    background-color: rgba(0, 0, 0, 0.95);
}

.bird-option.locked:hover {
    transform: none;
    border-color: transparent;
}

.bird-option img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}

.bird-option.nightclub-bird {
    background: #1a1a1a;
}

.bird-option .lock-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2rem;
    color: var(--text-secondary);
}

.color-options {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 15px;
    margin-bottom: 30px;
}

.color-section-label {
    width: 100%;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.color-option {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    cursor: pointer;
    border: 4px solid transparent;
    transition: var(--transition);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.color-option:hover {
    transform: scale(1.1);
    border-color: white;
}

.color-option.selected {
    border-color: #ffffff;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.color-option.locked {
    opacity: 0.4;
    cursor: not-allowed;
}

.color-option.locked:hover {
    transform: none;
    border-color: transparent;
}

.color-option.locked:hover .tooltip {
    background-color: rgba(0, 0, 0, 0.95);
}

.lock-icon-color {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.5rem;
}

.info-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 5px;
}

/* Custom Tooltips */
.tooltip {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 110%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.9);
    color: white;
    text-align: center;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    white-space: nowrap;
    z-index: 1000;
    pointer-events: none;
    transition: opacity 0.2s, visibility 0.2s;
}

.tooltip::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: rgba(0, 0, 0, 0.9) transparent transparent transparent;
}

.bird-option:hover .tooltip,
.color-option:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

/* Competition Styles */
.competition-detail-header {
    margin-bottom: 25px;
}

.competition-detail-header h2 {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.affiliate-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #ff9f43, #ee5a24);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
    cursor: pointer;
    vertical-align: middle;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.affiliate-badge:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(238, 90, 36, 0.4);
}

.affiliate-badge i {
    font-size: 0.85rem;
}

.competition-stats-row {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.stat-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--card-bg);
    padding: 10px 15px;
    border-radius: 8px;
    border: 2px solid rgba(108, 92, 231, 0.3);
}

.stat-icon {
    font-size: 1.3rem;
}

.competition-nav {
    display: flex;
    gap: 10px;
    margin: 20px 0;
    border-bottom: 2px solid rgba(108, 92, 231, 0.3);
    padding-bottom: 10px;
}

.event-categories {
    background: var(--card-bg);
    padding: 25px;
    border-radius: var(--border-radius);
    margin-top: 20px;
}

.event-search-box {
    display: flex;
    gap: 10px;
    margin: 20px 0;
}

.event-quick-links {
    margin-top: 25px;
}

.quick-link-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.event-info-box {
    background: rgba(108, 92, 231, 0.1);
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid var(--primary-color);
    margin-top: 20px;
}

.event-loader {
    background: var(--card-bg);
    padding: 25px;
    border-radius: var(--border-radius);
    margin-top: 20px;
}

.file-loader-box {
    background: rgba(108, 92, 231, 0.1);
    padding: 20px;
    border-radius: 8px;
    margin: 15px 0;
}

.event-detail {
    background: var(--card-bg);
    padding: 25px;
    border-radius: var(--border-radius);
    margin-top: 20px;
}

.event-meta {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin: 15px 0;
    padding: 15px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 8px;
}

.judges-list {
    margin: 15px 0;
    padding: 15px;
    background: var(--surface-color);
    border-radius: 8px;
}

.judge-badge {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.85rem;
    margin: 3px;
}

.rounds-container {
    margin-top: 25px;
}

.round-section {
    background: var(--surface-color);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.round-header {
    font-size: 1.3rem;
    color: var(--accent-color);
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(253, 121, 168, 0.3);
}

.round-header.final-round {
    color: #ffd700;
    border-bottom-color: rgba(255, 215, 0, 0.5);
}

.round-content {
    margin-top: 15px;
}

.dance-results {
    margin-bottom: 25px;
}

.dance-name {
    font-size: 1.1rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.results-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
}

.results-table thead {
    background: rgba(108, 92, 231, 0.2);
}

.results-table th {
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: var(--text-primary);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.results-table td {
    padding: 10px 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.results-table tbody tr:hover {
    background: rgba(108, 92, 231, 0.1);
}

.placement-cell {
    font-weight: bold;
    color: var(--accent-color);
    font-size: 1.1rem;
}

.tie-indicator {
    color: #ffd700;
    font-size: 1.2rem;
    margin-left: 3px;
    cursor: help;
}

.judge-col {
    font-size: 0.65rem;
    padding: 6px 4px;
    text-align: center;
    max-width: 60px;
    vertical-align: middle;
}

.judge-mark {
    text-align: center;
    font-weight: 500;
    font-size: 0.95rem;
}

.judge-mark.last-judge {
    border-right: 3px solid rgba(255, 255, 255, 0.3) !important;
}

.skating-col {
    background: rgba(108, 92, 231, 0.15);
    font-size: 0.6rem;
    padding: 6px 3px;
    text-align: center;
    font-weight: 600;
    max-width: 40px;
    min-width: 35px;
    white-space: nowrap;
}

.skating-value {
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-secondary);
    white-space: nowrap;
}

.skating-value.majority {
    font-weight: bold;
    color: var(--accent-color);
}

.skating-value.last-skating {
    border-right: 3px solid rgba(255, 255, 255, 0.3) !important;
}

.bib-cell {
    font-weight: 600;
    color: var(--primary-color);
}

.couple-cell {
    font-weight: 500;
    font-size: 0.7rem;
    border-right: 3px solid rgba(255, 255, 255, 0.3) !important;
    max-width: 400px;
    min-width: 200px;
    word-wrap: break-word;
    white-space: normal;
}

.marks-cell {
    font-family: monospace;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.recalls-cell {
    font-weight: 600;
    color: var(--accent-color);
}

.search-info-box {
    background: rgba(108, 92, 231, 0.1);
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
}

.error-box {
    background: rgba(255, 99, 71, 0.1);
    border: 2px solid rgba(255, 99, 71, 0.3);
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
    text-align: center;
}

/* Competitor search results */
.competitor-search-results {
    margin-top: 20px;
}

.competitor-result-card {
    background: rgba(30, 40, 60, 0.8);
    border: 2px solid rgba(108, 92, 231, 0.35);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.competitor-result-card h4 {
    margin: 0 0 15px 0;
    color: var(--primary-color);
}

.competitor-performances,
.event-performances {
    margin-top: 15px;
}

.performance-round {
    margin-bottom: 20px;
}

.performance-round h5 {
    background: var(--background-light);
    padding: 8px 12px;
    border-radius: 4px;
    margin: 10px 0;
}

.performance-summary {
    background: var(--background-light);
    padding: 15px;
    border-radius: 6px;
    margin-top: 10px;
}

.performance-summary p {
    margin: 5px 0;
    font-size: 0.95rem;
}

.compact-table {
    font-size: 0.9rem;
}

.compact-table th,
.compact-table td {
    padding: 8px 10px;
}

.search-info-box {
    background: var(--background-light);
    border: 2px solid var(--border-color);
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
}

.search-info-box h3 {
    margin-top: 0;
    color: var(--secondary-color);
}

.search-info-box ol,
.search-info-box ul {
    margin: 15px 0;
    padding-left: 25px;
}

/* Event dropdown styling */
.event-dropdown {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: 6px;
    font-size: 1rem;
    background-color: rgba(20, 28, 45, 0.9);
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
}

.event-dropdown:hover {
    background-color: rgba(50, 60, 85, 0.9);
    border-color: rgba(108, 92, 231, 0.8);
}

.event-dropdown:focus {
    outline: none;
    border-color: var(--primary-color);
    background-color: rgba(50, 60, 85, 0.9);
}

.event-dropdown option {
    padding: 8px;
    background-color: #1e283c;
    color: var(--text-primary);
}

.event-dropdown optgroup {
    font-weight: bold;
    color: var(--secondary-color);
    background-color: #1e283c;
}

/* Event browser and filters */
.event-browser {
    margin-top: 20px;
}

.event-filters {
    background: var(--background-light);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 150px;
}

.filter-group label {
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--text-primary);
}

.filter-group.checkbox-group {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    min-width: auto;
}

.filter-group.checkbox-group label {
    font-weight: normal;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}

.filter-group.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.filter-input,
.filter-select {
    padding: 8px 12px;
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: 6px;
    font-size: 0.95rem;
    background-color: rgba(20, 28, 45, 0.9);
    color: var(--text-primary);
    transition: var(--transition);
}

.filter-input:hover,
.filter-select:hover {
    background-color: rgba(50, 60, 85, 0.9);
    border-color: rgba(108, 92, 231, 0.8);
}

.filter-input:focus,
.filter-select:focus {
    outline: none;
    border-color: var(--primary-color);
    background-color: rgba(50, 60, 85, 0.9);
}

.filter-select option {
    background-color: #1e283c;
    color: var(--text-primary);
}

.event-count {
    text-align: center;
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--secondary-color);
    margin-bottom: 15px;
}

/* Event cards grid */
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.event-card {
    background: linear-gradient(180deg, rgba(200, 200, 210, 0.3) 0%, rgba(180, 180, 190, 0.15) 100%);
    border: 2px solid rgba(108, 92, 231, 0.35);
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.event-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

.event-card-header {
    background: var(--primary-color);
    color: white;
    padding: 15px;
}

.event-header-newcomer {
    background: linear-gradient(135deg, #95e1d3, #74b9ff);
}

.event-header-bronze {
    background: linear-gradient(135deg, #cd7f32, #b8860b);
}

.event-header-silver {
    background: linear-gradient(135deg, #c0c0c0, #a8a8a8);
}

.event-header-gold {
    background: linear-gradient(135deg, #ffd700, #ffb700);
}

.event-header-novice {
    background: linear-gradient(135deg, #a29bfe, #6c5ce7);
}

.event-header-prechampionship {
    background: linear-gradient(135deg, #fd79a8, #e84393);
}

.event-header-championship {
    background: linear-gradient(135deg, #00b894, #00cec9);
}

.event-header-syllabus {
    background: linear-gradient(135deg, #fd79a8, #e84393);
}

.event-header-other {
    background: linear-gradient(135deg, #95a5a6, #7f8c8d);
}

.event-header-teammatch {
    background: linear-gradient(90deg,
        #ff6b7a 0%,
        #ffa94d 16.66%,
        #ffd93d 33.32%,
        #6bcf7f 49.98%,
        #4d9fff 66.64%,
        #b57fff 83.3%,
        #ff6b7a 100%);
}

.event-header-rookievet {
    background: linear-gradient(135deg, #cd7f32, #c0c0c0);
}

.event-header-beginner {
    background: linear-gradient(135deg, #1e3a8a, #3b82f6);
}

.event-header-intermediateadvanced {
    background: linear-gradient(135deg, #065f46, #10b981);
}

.event-card-title {
    font-size: 1.05rem;
    margin: 0;
    color: white;
    line-height: 1.4;
    font-weight: 600;
}

.event-card-info {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 12px 10px;
    background: transparent;
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
}

.event-info-bubble {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex: 1;
}

.event-info-bubble-group {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.event-info-badge {
    padding: 6px 12px;
    border-radius: 12px;
    background: rgba(108, 92, 231, 0.25);
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
    border: 2px solid rgba(108, 92, 231, 0.5);
}

.info-icon {
    font-size: 1.3rem;
}

.info-value {
    font-size: 1rem;
    font-weight: bold;
    color: var(--text-primary);
}

.info-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.event-level-badge {
    padding: 6px 14px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: bold;
    text-align: center;
}

.event-level-badge.championship {
    background: #ffd700;
    color: #1a1a2e;
}

.event-level-badge.prechampionship {
    background: #00b894;
    color: white;
}

.event-level-badge.novice {
    background: #a29bfe;
    color: white;
}

.event-level-badge.newcomer {
    background: #95e1d3;
    color: #1a1a2e;
}

.event-level-badge.syllabus {
    background: #fd79a8;
    color: white;
}

.event-level-badge.other {
    background: #95a5a6;
    color: white;
}

.event-card-body {
    padding: 15px;
}

.event-card-meta {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.event-meta-item {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.event-card-footer {
    padding: 12px 15px;
    background: rgba(30, 40, 60, 0.5);
    border-top: 1px solid rgba(108, 92, 231, 0.2);
    text-align: center;
}

.event-card-footer button {
    width: 100%;
}

/* Responsive adjustments for competition views */
@media (max-width: 768px) {
    .competition-stats-row {
        flex-direction: column;
    }

    .stat-chip {
        width: 100%;
    }

    .quick-link-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }

    .results-table {
        font-size: 0.85rem;
    }

    .results-table th,
    .results-table td {
        padding: 8px 6px;
    }

    .competitor-result-card {
        padding: 15px;
    }

    .compact-table {
        font-size: 0.85rem;
    }

    .filter-row {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-group {
        width: 100%;
    }

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

    .event-filters {
        padding: 15px;
    }
}

/* Search Progress & Enhanced Results Display */
.search-progress {
    padding: 30px;
    text-align: center;
}

.progress-bar-container {
    width: 100%;
    height: 30px;
    background-color: var(--card-bg);
    border-radius: 15px;
    overflow: hidden;
    margin: 20px 0;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #4CAF50, #8BC34A);
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
}

.search-summary {
    margin-bottom: 25px;
    text-align: center;
}

.search-stats {
    font-size: 1.1rem;
    margin: 10px 0;
}

.stat-highlight {
    color: var(--primary-color);
    font-weight: bold;
}

.competitor-result-card.expanded {
    margin-bottom: 25px;
    background: var(--card-bg);
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

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

.event-count-badge {
    background-color: var(--primary-color);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: bold;
}

.competitor-events-list {
    margin-top: 15px;
}

.event-performance {
    background-color: var(--dark-bg);
    padding: 15px;
    margin: 10px 0;
    border-left: 4px solid var(--primary-color);
    border-radius: 4px;
}

.event-title {
    margin: 0 0 10px 0;
    color: var(--primary-color);
    font-size: 1rem;
}

.event-checkmark {
    color: #4CAF50;
    font-size: 1.2rem;
    margin-right: 8px;
}

.round-summary {
    margin: 8px 0;
    padding-left: 20px;
}

.dance-results-inline {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 5px;
}

.dance-result {
    background-color: var(--light-bg);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.95rem;
}

.warning-box {
    background-color: rgba(255, 152, 0, 0.1);
    border: 2px solid #ff9800;
    border-radius: var(--border-radius);
    padding: 15px;
    margin: 15px 0;
}

.warning-box h4 {
    color: #ff9800;
    margin-bottom: 10px;
}

.warning-box details {
    margin-top: 10px;
}

/* Event title row with action buttons */
.event-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    gap: 15px;
}

.event-action-buttons {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.btn-view-event {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-view-event:hover {
    background-color: var(--secondary-color);
}

.points-bubble {
    display: inline-block;
    background: linear-gradient(135deg, #4CAF50, #45a049);
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-left: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.points-bubble:hover {
    transform: scale(1.05);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.3);
}

/* RKS Bubble */
.rks-bubble {
    display: inline-block;
    background: rgba(255, 193, 7, 0.2);
    color: #FFC107;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-left: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: var(--transition);
}

.rks-bubble:hover {
    background: rgba(255, 193, 7, 0.4);
    transform: scale(1.05);
}

/* NCP Bubble */
.ncp-bubble {
    display: inline-block;
    background: rgba(25, 64, 128, 0.6);
    color: #d6e4ff;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-left: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: var(--transition);
}

.ncp-bubble:hover {
    background: rgba(25, 64, 128, 0.8);
    transform: scale(1.05);
}

/* RKS Breakdown Modal */
.rks-breakdown-content {
    padding: 10px 0;
}

.rks-summary {
    display: flex;
    justify-content: space-around;
    gap: 20px;
    margin-bottom: 15px;
}

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

.rks-stat .stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.rks-stat .stat-value {
    display: block;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent-color);
}

.rks-calculation h5 {
    margin: 0 0 10px 0;
    color: var(--text-primary);
}

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

.rks-table td {
    padding: 10px;
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
}

.rks-table .rks-value {
    text-align: right;
    font-weight: 600;
    color: #FFC107;
}

.rks-table tfoot .rks-total-row td {
    border-top: 2px solid rgba(108, 92, 231, 0.4);
    border-bottom: none;
    padding-top: 15px;
}

.rks-note {
    margin-top: 15px;
    padding: 10px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 8px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.rks-note p {
    margin: 0;
}

.btn-points-breakdown {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-points-breakdown:hover {
    background-color: var(--secondary-color);
}

.btn-points {
    background-color: #4CAF50;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background-color 0.2s;
    font-weight: 600;
}

.btn-points:hover {
    background-color: #45a049;
}

.btn-no-points {
    background-color: #f44336;
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-block;
}

/* Points modal */
.points-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.points-modal-content {
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.points-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
}

.points-modal-header h3 {
    margin: 0;
    color: var(--primary-color);
}

.points-modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    line-height: 1;
}

.points-modal-close:hover {
    color: var(--text-primary);
}

.points-modal-body {
    padding: 20px;
}

.points-modal-body h4 {
    margin-top: 0;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.points-summary {
    background-color: var(--light-bg);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.points-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.2rem;
}

.points-label {
    font-weight: 600;
    color: var(--text-primary);
}

.points-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #4CAF50;
}

.points-breakdown-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.points-breakdown-table th,
.points-breakdown-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.points-breakdown-table th {
    background-color: var(--light-bg);
    font-weight: 600;
    color: var(--text-primary);
}

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

.points-note {
    background-color: rgba(76, 175, 80, 0.1);
    border-left: 4px solid #4CAF50;
    padding: 12px;
    border-radius: 4px;
    font-size: 0.9rem;
}

.points-note p {
    margin: 0;
    color: var(--text-secondary);
}

/* Cascade section styles */
.cascade-section {
    margin: 20px 0;
    padding: 15px;
    background-color: rgba(108, 92, 231, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(108, 92, 231, 0.2);
}

.cascade-section h5 {
    margin-top: 0;
    margin-bottom: 15px;
    color: var(--primary-color);
    font-size: 1rem;
}

.cascade-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.cascade-table th,
.cascade-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.cascade-table th {
    background-color: var(--light-bg);
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.85rem;
}

.cascade-table td {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

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

.cascade-table tr:hover {
    background-color: rgba(108, 92, 231, 0.05);
}

/* Points actions */
.points-actions {
    margin: 20px 0;
    display: flex;
    justify-content: center;
}

.btn-add-points {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.btn-add-points:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.warning-box summary {
    cursor: pointer;
    color: var(--primary-color);
    font-weight: bold;
}

.warning-box summary:hover {
    text-decoration: underline;
}

.warning-box ul {
    margin-top: 10px;
    padding-left: 20px;
}

.warning-box li {
    margin: 5px 0;
    color: var(--text-secondary);
}

/* Competition List Header & Refresh Button */
.competition-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: nowrap;
    gap: 10px;
}

.competition-list-header .search-container {
    flex-direction: row !important;
    flex-wrap: nowrap;
    flex: 1;
}

#refresh-competitions-btn {
    white-space: nowrap;
    min-width: 110px;
    flex-shrink: 0;
    font-weight: 600;
}

/* Recent Competitions Section */
.competitions-mini-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.competition-mini-card {
    border: 2px solid rgba(108, 92, 231, 0.35);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.competition-mini-card:hover {
    border-color: rgba(108, 92, 231, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.comp-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.comp-card-body {
    flex-grow: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.comp-card-header h4 {
    margin: 0;
    font-size: 1rem;
    color: var(--text-color);
}

.comp-year {
    background: var(--accent-color);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: bold;
    color: var(--bg-color);
}

.comp-card-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.comp-card-arrow {
    color: var(--primary-color);
    font-size: 1.2rem;
    font-weight: bold;
}

/* Scanning Progress */
.scanning-progress {
    text-align: center;
    padding: 30px 20px;
}

.scanning-progress p {
    margin-bottom: 15px;
    color: var(--text-muted);
    font-size: 1rem;
}

.progress-bar {
    width: 100%;
    height: 10px;
    background: var(--dark-bg);
    border-radius: 5px;
    overflow: hidden;
    border: 1px solid var(--secondary-color);
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transition: width 0.3s ease;
    border-radius: 5px;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal.hidden {
    display: none;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
}

.modal-content {
    position: relative;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    border: 1px solid var(--secondary-color);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--secondary-color);
}

.modal-header h3 {
    margin: 0;
    color: var(--text-color);
}

.modal-body {
    padding: 20px;
    max-height: 60vh;
    overflow-y: auto;
}

.close-btn {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    line-height: 30px;
    text-align: center;
    transition: color 0.2s ease;
}

.close-btn:hover {
    color: var(--primary-color);
}

/* Full Competitions List in Modal */
.competitions-full-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.competition-full-item {
    display: flex;
    flex-direction: column;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
    overflow: hidden;
}

.competition-full-item:hover {
    transform: translateX(5px);
}

.comp-full-main {
    flex: 1;
}

.comp-full-main h4 {
    margin: 0 0 5px 0;
    color: var(--text-color);
    font-size: 1rem;
}

.comp-full-stats {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Small button variant */
.btn-small {
    padding: 6px 12px;
    font-size: 0.85rem;
    min-width: auto;
}

/* ================================
   UPCOMING COMPETITIONS PAGE
   ================================ */

.upcoming-competitions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    padding: 1rem 0;
}

.upcoming-competition-card {
    border-radius: var(--border-radius);
    border: 2px solid rgba(108, 92, 231, 0.35);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    overflow: visible;
    margin-bottom: 1rem;
}

.upcoming-competition-card:hover {
    transform: translateY(-4px);
    border-color: rgba(108, 92, 231, 0.6);
    box-shadow: 0 8px 32px rgba(108, 92, 231, 0.2);
}

.upcoming-competition-card .competition-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    padding: 15px 18px;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.upcoming-competition-card .competition-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.3;
}

.upcoming-competition-card .countdown {
    font-size: 0.75rem;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
}

.countdown.happening-now {
    background: linear-gradient(135deg, #00b894 0%, #00cec9 100%);
    color: #fff;
    animation: pulse 2s infinite;
}

.countdown.tomorrow {
    background: linear-gradient(135deg, #fdcb6e 0%, #f39c12 100%);
    color: #1a1a2e;
}

.countdown.this-week {
    background: linear-gradient(135deg, #fd79a8 0%, #e84393 100%);
    color: #fff;
}

.countdown.this-month {
    background: linear-gradient(135deg, #a29bfe 0%, #6c5ce7 100%);
    color: #fff;
}

.countdown.future {
    background: rgba(108, 92, 231, 0.2);
    color: var(--secondary-color);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.upcoming-competition-card .competition-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 15px 18px;
    flex-grow: 1;
}

.upcoming-competition-card .competition-date,
.upcoming-competition-card .competition-location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin: 0;
}

.upcoming-competition-card .icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    stroke: var(--secondary-color);
}

.upcoming-competition-card .competition-actions {
    display: flex;
    gap: 0.75rem;
    padding: 0 18px 15px 18px;
}

.upcoming-competition-card .competition-actions .btn {
    flex: 1;
    text-align: center;
    text-decoration: none;
    padding: 10px 16px;
    font-size: 0.9rem;
}

.upcoming-competition-card .competition-actions .btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, #5a4fcf 100%);
}

.upcoming-competition-card .competition-actions .btn-secondary {
    background: rgba(108, 92, 231, 0.15);
    border: 1px solid rgba(108, 92, 231, 0.3);
}

.upcoming-competition-card .competition-actions .btn:hover {
    transform: translateY(-2px);
}

/* Attendance Button */
.btn-attendance {
    min-width: 130px;
    transition: var(--transition);
}

.btn-attendance.btn-not-going {
    background: rgba(20, 28, 45, 0.9);
    color: white;
    border: 2px solid rgba(108, 92, 231, 0.6);
}

.btn-attendance.btn-not-going:hover {
    background: rgba(50, 60, 85, 0.9);
    border-color: rgba(108, 92, 231, 0.8);
}

.btn-attendance.btn-going {
    font-weight: 600;
}

/* Friends Going Button */
.btn-friends-going {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: rgba(20, 28, 45, 0.9);
    color: white;
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
}

.btn-friends-going:hover {
    background: rgba(50, 60, 85, 0.9);
    border-color: rgba(108, 92, 231, 0.8);
}

.btn-friends-going .icon {
    width: 16px;
    height: 16px;
}

.friends-dropdown {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 0;
    margin-bottom: 8px;
    background: var(--dark-bg);
    border: 2px solid rgba(108, 92, 231, 0.5);
    border-radius: 12px;
    padding: 12px;
    min-width: 220px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.4);
}

.btn-friends-going.expanded .friends-dropdown {
    display: block;
}

.friends-dropdown-header {
    font-weight: 600;
    color: var(--accent-color);
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
}

.friend-tooltip-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    color: var(--text-primary);
}

/* Friends Modal List */
.friends-modal-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.friend-modal-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 15px;
    background: rgba(108, 92, 231, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(108, 92, 231, 0.2);
}

.friend-modal-item .friend-name {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-primary);
}

.friend-tooltip-item .bird-icon-tiny {
    width: 28px;
    height: 28px;
    border-radius: 4px;
}

/* Dashboard Planned Competitions */
.planned-competitions-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.planned-comp-card {
    border: 2px solid rgba(108, 92, 231, 0.35);
    border-radius: var(--border-radius);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
}

.planned-comp-card:hover {
    border-color: rgba(108, 92, 231, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.remove-planned-comp-btn:hover {
    background: rgba(231, 76, 60, 0.8) !important;
    color: white !important;
    transform: scale(1.1);
}

/* Empty state for upcoming competitions */
#upcoming-competitions-container .empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    background: rgba(22, 33, 62, 0.5);
    border-radius: var(--border-radius);
    border: 1px dashed rgba(108, 92, 231, 0.3);
}

#upcoming-competitions-container .empty-state p {
    color: var(--text-secondary);
    margin: 0.5rem 0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .upcoming-competitions-grid {
        grid-template-columns: 1fr;
    }
    
    .upcoming-competition-card .competition-header {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .upcoming-competition-card .competition-actions {
        flex-direction: column;
    }
}

/* ============================================
   Large Modal - Dancer Profile View
   ============================================ */

.modal-large {
    max-width: 1000px !important;
    width: 95vw !important;
    max-height: 90vh !important;
    overflow-y: auto !important;
    padding: 0 !important;
}

.dancer-profile-modal {
    padding: 30px;
}

.dancer-profile-header {
    display: flex;
    gap: 25px;
    align-items: flex-start;
    padding-bottom: 25px;
    border-bottom: 1px solid rgba(108, 92, 231, 0.3);
    margin-bottom: 25px;
}

.dancer-profile-bird {
    flex-shrink: 0;
}

.dancer-profile-info {
    flex: 1;
}

.dancer-profile-info h2 {
    font-size: 2rem;
    color: var(--accent-color);
    margin: 0 0 15px 0;
}

.dancer-profile-stats {
    display: flex;
    gap: 30px;
    margin-bottom: 15px;
}

.dancer-profile-stats .stat-item {
    display: flex;
    flex-direction: column;
}

.dancer-profile-stats .stat-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.dancer-profile-stats .stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.dancer-profile-levels {
    margin-top: 10px;
}

.dancer-profile-sections {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.dancer-profile-sections .profile-section {
    background: rgba(22, 33, 62, 0.5);
    border-radius: var(--border-radius);
    padding: 20px;
}

.dancer-profile-sections .profile-section h3 {
    margin: 0 0 15px 0;
    font-size: 1.2rem;
    color: var(--text-color);
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
    padding-bottom: 10px;
}

/* Recent competitions in modal */
.recent-comps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.recent-comp-card {
    background: transparent;
    border-radius: 8px;
    padding: 0;
    border: 1px solid rgba(108, 92, 231, 0.2);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.recent-comp-card .comp-body {
    flex: 1;
    display: flex;
    align-items: flex-end;
}

.recent-comp-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(108, 92, 231, 0.25);
}

.recent-comp-card .comp-name {
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 5px;
}

.recent-comp-card .comp-details {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Responsive for modal */
@media (max-width: 600px) {
    .dancer-profile-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .dancer-profile-info h2 {
        justify-content: center;
    }

    .dancer-profile-stats {
        justify-content: center;
    }

    .dancer-profile-levels {
        display: flex;
        justify-content: center;
    }
}

/* ============================================
   Scoreboard Styles
   ============================================ */

#scoreboard-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.scoreboard-column {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 20px;
    border: 2px solid rgba(108, 92, 231, 0.35);
}

.scoreboard-column.scoreboard-full-width {
    grid-column: 1 / -1;
}

.scoreboard-title {
    margin: 0 0 15px 0;
    font-size: 1.2rem;
    color: var(--accent-color);
    font-weight: 600;
    text-align: center;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(108, 92, 231, 0.2);
}

.scoreboard-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.scoreboard-row {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    background: rgba(20, 28, 45, 0.6);
    border-radius: 8px;
    border: 2px solid transparent;
    transition: var(--transition);
}

.scoreboard-row:hover {
    background: rgba(30, 40, 60, 0.8);
    border-color: rgba(108, 92, 231, 0.3);
}

/* Medal rankings */
.scoreboard-row.rank-gold {
    border-color: #FFD700;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.15) 0%, rgba(20, 28, 45, 0.6) 100%);
}

.scoreboard-row.rank-silver {
    border-color: #C0C0C0;
    background: linear-gradient(135deg, rgba(192, 192, 192, 0.15) 0%, rgba(20, 28, 45, 0.6) 100%);
}

.scoreboard-row.rank-bronze {
    border-color: #CD7F32;
    background: linear-gradient(135deg, rgba(205, 127, 50, 0.15) 0%, rgba(20, 28, 45, 0.6) 100%);
}

.scoreboard-rank {
    width: 30px;
    font-weight: 700;
    color: var(--accent-color);
    flex-shrink: 0;
}

.scoreboard-couple {
    flex: 1;
    color: var(--text-primary);
    line-height: 1.3;
}

.scoreboard-couple .partner-name {
    color: inherit;
    display: block;
    font-size: 0.95em;
}

.scoreboard-points {
    background: rgba(255, 193, 7, 0.2);
    color: #FFC107;
    padding: 4px 10px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
    margin-left: 10px;
}

.scoreboard-points-ncp {
    background: rgba(25, 64, 128, 0.6);
    color: #d6e4ff;
}

.scoreboard-empty {
    text-align: center;
    color: var(--text-secondary);
    padding: 20px;
}

.season-banner {
    background: linear-gradient(135deg, rgba(108, 92, 231, 0.3) 0%, rgba(0, 184, 148, 0.2) 100%);
    border: 2px solid rgba(108, 92, 231, 0.5);
    border-radius: var(--border-radius);
    padding: 15px 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-primary);
    font-size: 1rem;
}

.season-banner .banner-icon {
    font-size: 1.5rem;
}

.btn-icon {
    width: 32px;
    height: 32px;
    padding: 0;
    font-size: 1.1rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    margin-left: 10px;
    vertical-align: middle;
}

.scoreboard-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.scoreboard-controls label {
    color: var(--text-secondary);
    font-weight: 500;
}

.scoreboard-controls select {
    padding: 8px 12px;
    background: rgba(20, 28, 45, 0.9);
    border: 2px solid rgba(108, 92, 231, 0.6);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition);
}

.scoreboard-controls select:hover {
    background: rgba(50, 60, 85, 0.9);
    border-color: rgba(108, 92, 231, 0.8);
}

@media (max-width: 768px) {
    #scoreboard-container {
        grid-template-columns: 1fr;
    }

    .scoreboard-controls {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Dashboard Rankings Year Tabs */
.rankings-year-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    overflow-x: auto;
    padding-bottom: 5px;
    -webkit-overflow-scrolling: touch;
}
.rankings-year-tab {
    opacity: 0.6;
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}
.rankings-year-tab.active {
    opacity: 1;
    background: var(--primary-color) !important;
    color: white !important;
}
.rankings-year-tab:hover {
    opacity: 0.9;
}
