/* ===========================
   Variables & Reset
   =========================== */
:root {
    --primary: #5865F2;
    --primary-dark: #4752C4;
    --secondary: #E8F0FA;
    --secondary-dark: #D4E4F7;
    --success: #10b981;
    --danger: #ef4444;
    --dark: #2C3E50;
    --darker: #1a252f;
    --light: #E8F0FA;
    --gray: #6c757d;
    --gradient: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    --shadow: 0 4px 15px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.15);
    --border-radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--light);
    color: var(--dark);
    min-height: 100vh;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===========================
   Header & Navigation
   =========================== */
.header {
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1.2rem 0;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
}

.nav {
    display: flex;
    gap: 2.5rem;
}

.nav-link {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: color 0.3s;
    font-size: 1rem;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary);
}

/* ===========================
   Hero Section
   =========================== */
.hero {
    padding: 5rem 0 6rem;
    text-align: center;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
                url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><rect fill="%232C3E50" width="1200" height="600"/></svg>');
    background-size: cover;
    background-position: center;
    position: relative;
}

.hero::before {
    content: '❄';
    position: absolute;
    top: 10%;
    left: 10%;
    font-size: 2rem;
    opacity: 0.7;
    animation: float 3s ease-in-out infinite;
}

.hero::after {
    content: '❄';
    position: absolute;
    top: 20%;
    right: 15%;
    font-size: 1.5rem;
    opacity: 0.6;
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

.hero-title {
    font-size: 3.5rem;
    color: white;
    margin-bottom: 1rem;
    font-weight: 700;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.5);
}

.hero-subtitle {
    font-size: 1.3rem;
    color: rgba(255,255,255,0.95);
    margin-bottom: 3rem;
    font-weight: 400;
}

/* ===========================
   Code Entry Card
   =========================== */
.code-entry-card {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    max-width: 600px;
    margin: 0 auto;
    box-shadow: var(--shadow-lg);
}

.code-entry-card h3 {
    color: var(--dark);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.hint {
    color: var(--gray);
    margin-bottom: 2rem;
}

.hint code {
    background: var(--light);
    padding: 0.25rem 0.5rem;
    border-radius: 5px;
    font-family: 'Courier New', monospace;
    color: var(--primary);
}

.code-input-group {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 2rem;
}

.code-input {
    width: 60px;
    height: 70px;
    font-size: 2rem;
    text-align: center;
    border: 3px solid #e0e0e0;
    border-radius: 10px;
    font-weight: bold;
    text-transform: uppercase;
    transition: all 0.3s;
}

.code-input:focus {
    outline: none;
    border-color: var(--primary);
    transform: scale(1.05);
    box-shadow: 0 0 0 3px rgba(88, 101, 242, 0.2);
}

/* ===========================
   Buttons
   =========================== */
.btn {
    padding: 0.85rem 2.5rem;
    border: 2px solid transparent;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn i {
    font-size: 1.1rem;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(88, 101, 242, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--primary);
    border-color: var(--primary);
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.btn-danger {
    background: var(--danger);
    color: white;
    border-color: var(--danger);
}

.btn-danger:hover {
    background: #dc2626;
    border-color: #dc2626;
}

.error-message {
    color: var(--danger);
    margin-top: 1rem;
    display: none;
}

/* ===========================
   Profile Section
   =========================== */
.profile-section {
    padding: 2rem 0 4rem;
    background: var(--light);
}

.player-header {
    background: white;
    border-radius: var(--border-radius);
    padding: 2.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 2rem;
    border: 1px solid rgba(0,0,0,0.05);
}

.player-avatar img {
    width: 100px;
    height: 100px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border: 3px solid white;
}

.player-info h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: var(--dark);
    font-weight: 700;
}

.player-uuid,
.player-code {
    color: var(--gray);
    font-size: 0.95rem;
}

.player-code span {
    font-weight: 600;
    color: var(--primary);
}

.player-stats-mini {
    margin-left: auto;
    display: flex;
    gap: 2.5rem;
}

.stat-mini {
    text-align: center;
}

.stat-mini i {
    font-size: 2rem;
    color: var(--primary);
    display: block;
    margin-bottom: 0.5rem;
}

.stat-mini span {
    font-size: 1.8rem;
    font-weight: 700;
    display: block;
    color: var(--dark);
}

.stat-mini small {
    color: var(--gray);
    font-size: 0.85rem;
}

/* ===========================
   Tabs
   =========================== */
.tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    background: white;
    border-radius: var(--border-radius);
    padding: 0.75rem;
    box-shadow: var(--shadow);
    border: 1px solid rgba(0,0,0,0.05);
}

.tab {
    flex: 1;
    padding: 1rem;
    border: none;
    background: transparent;
    color: var(--gray);
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s;
    font-size: 0.95rem;
}

.tab:hover {
    background: var(--light);
    color: var(--dark);
}

.tab.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 2px 8px rgba(88, 101, 242, 0.25);
}

.tab i {
    margin-right: 0.5rem;
}

/* ===========================
   Tab Content
   =========================== */
.tab-content {
    background: white;
    border-radius: var(--border-radius);
    padding: 2.5rem;
    box-shadow: var(--shadow);
    min-height: 400px;
    border: 1px solid rgba(0,0,0,0.05);
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--light);
}

.section-header h3 {
    font-size: 1.5rem;
    color: var(--dark);
    font-weight: 700;
}

.section-header i {
    margin-right: 0.5rem;
    color: var(--primary);
}

/* ===========================
   Photos Grid
   =========================== */
.photos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

.photo-card {
    background: var(--light);
    border-radius: 15px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.photo-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.photo-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.photo-card-info {
    padding: 1rem;
}

.photo-card-title {
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.photo-card-date {
    color: var(--gray);
    font-size: 0.9rem;
}

/* ===========================
   Stats Grid
   =========================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--light);
    border-radius: 15px;
    padding: 2rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
}

.stat-icon {
    width: 60px;
    height: 60px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.stat-content h4 {
    font-size: 2rem;
    margin-bottom: 0.25rem;
}

.stat-content p {
    color: var(--gray);
    text-transform: uppercase;
    font-size: 0.9rem;
}

/* ===========================
   Chart
   =========================== */
.chart-container {
    background: var(--light);
    border-radius: 15px;
    padding: 2rem;
    margin-top: 2rem;
}

.chart-container h4 {
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    color: var(--dark);
}

/* ===========================
   Settings
   =========================== */
.settings-section {
    background: var(--light);
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 1.5rem;
}

.settings-section h4 {
    margin-bottom: 1rem;
    color: var(--dark);
}

.settings-section .btn {
    margin-right: 1rem;
    margin-top: 1rem;
}

/* ===========================
   No Data State
   =========================== */
.no-data {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--gray);
}

.no-data i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.no-data p {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

/* ===========================
   Modal
   =========================== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
}

.modal-content {
    position: relative;
    background: white;
    border-radius: 20px;
    max-width: 900px;
    max-height: 90vh;
    overflow: auto;
    padding: 2rem;
    box-shadow: var(--shadow-lg);
    animation: modalFadeIn 0.3s;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--danger);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s;
}

.modal-close:hover {
    transform: rotate(90deg);
}

.modal-content img {
    width: 100%;
    border-radius: 15px;
    margin-bottom: 1.5rem;
}

.modal-info {
    text-align: center;
}

.modal-info h3 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}

.modal-info p {
    color: var(--gray);
    margin-bottom: 1.5rem;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* ===========================
   Footer
   =========================== */
.footer {
    background: rgba(255, 255, 255, 0.95);
    padding: 2rem 0;
    text-align: center;
    color: var(--gray);
    margin-top: 4rem;
}

/* ===========================
   Responsive
   =========================== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }

    .nav {
        gap: 1rem;
    }

    .nav-link {
        font-size: 0.8rem;
    }

    .code-input {
        width: 45px;
        height: 55px;
        font-size: 1.5rem;
    }

    .player-header {
        flex-direction: column;
        text-align: center;
    }

    .player-stats-mini {
        margin-left: 0;
        justify-content: center;
    }

    .tabs {
        flex-wrap: wrap;
    }

    .photos-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }
}

