/* ---------------- BASE STYLES ---------------- */
:root {
    --bg-color: #0d0d0d;
    --card-bg: #1a1a1a;
    --accent-gold: #c5a059;
    --text-main: #ffffff;
    --text-muted: #a0a0a0;
    --border-color: #333;
    --header-bg: #1a1a1a;
}

[data-theme="light"] {
    --bg-color: #f5f5f5;
    --card-bg: #ffffff;
    --accent-gold: #b8941e;
    --text-main: #1a1a1a;
    --text-muted: #666666;
    --border-color: #e0e0e0;
    --header-bg: #ffffff;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    transition: background-color 0.3s ease, color 0.3s ease;
    line-height: 1.7;
}

/* ---------------- HEADER STYLES ---------------- */
.site-header {
    background: var(--header-bg);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    transition: background-color 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    width: 100%;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-gold);
    text-decoration: none;
    letter-spacing: 0.5px;
}

.logo-divider {
    width: 1px;
    height: 30px;
    background: var(--border-color);
}

.logo-text {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    line-height: 1.2;
}

.back-link {
    color: var(--text-main);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: var(--accent-gold);
}

.nav-and-theme {
    display: flex;
    align-items: center;
    gap: 40px;
}

.main-nav {
    display: flex;
    gap: 35px;
    align-items: center;
}

.main-nav a {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-main);
    text-decoration: none;
    position: relative;
    transition: color 0.3s ease;
    padding: 5px 0;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gold);
    transition: width 0.3s ease;
}

.main-nav a:hover {
    color: var(--accent-gold);
}

.main-nav a:hover::after {
    width: 100%;
}

.theme-toggle-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.theme-icon {
    font-size: 1.2rem;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.theme-icon.active {
    opacity: 1;
    color: var(--accent-gold);
}

.toggle-switch {
    position: relative;
    width: 50px;
    height: 26px;
    background: var(--border-color);
    border-radius: 50px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.toggle-switch:hover {
    background: var(--accent-gold);
}

.toggle-slider {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    background: var(--text-main);
    border-radius: 50%;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

[data-theme="light"] .toggle-slider {
    transform: translateX(24px);
}

/* ---------------- FOOTER STYLES ---------------- */
footer {
    background: var(--header-bg);
    border-top: 1px solid var(--border-color);
    padding: 40px 20px;
    margin-top: 60px;
    width: 100%;
    display: block;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    text-align: center;
}

.footer-logo {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    color: var(--accent-gold);
    margin-bottom: 15px;
}

.footer-text {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 20px;
    line-height: 1.4;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 20px;
}

.footer-links a {
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--accent-gold);
}

.copyright {
    color: var(--text-muted);
    font-size: 0.85rem;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

/* ---------------- PROFILE SPECIFIC STYLES ---------------- */
.profile-hero {
    background: linear-gradient(to bottom, var(--header-bg), var(--bg-color));
    padding: 60px 20px;
    border-bottom: 1px solid var(--border-color);
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: row;
    gap: 60px;
    align-items: flex-start;
}

.hero-image-wrapper {
    flex: 0 0 350px;
    width: 350px;
    position: relative;
}

.hero-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    border: 2px solid var(--accent-gold);
}

.rank-badge {
    position: absolute;
    top: -15px;
    left: -15px;
    background: var(--accent-gold);
    color: #000;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(197, 160, 89, 0.4);
    z-index: 10;
}

.rank-number {
    font-size: 2.5rem;
    line-height: 1;
}

.rank-text {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.hero-content {
    flex: 1;
    padding-top: 20px;
}

.category-tag {
    display: inline-block;
    background: var(--accent-gold);
    color: #000;
    padding: 8px 20px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.hero-name {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    margin-bottom: 15px;
    line-height: 1.1;
}

.hero-title {
    font-size: 1.4rem;
    color: var(--text-muted);
    margin-bottom: 30px;
    font-weight: 400;
}

.hero-excerpt {
    font-size: 1.15rem;
    line-height: 1.8;
    color: var(--text-main);
    margin-bottom: 25px;
}

.key-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 30px;
}

.stat-item {
    text-align: center;
    padding: 15px;
    background: var(--card-bg);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-gold);
    display: block;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 5px;
}

.main-content {
    max-width: 1200px;
    margin: 60px auto;
    padding: 0 40px;
}

.content-section {
    margin-bottom: 60px;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    color: var(--accent-gold);
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--accent-gold);
}

.section-text {
    font-size: 1.05rem;
    line-height: 1.9;
    margin-bottom: 20px;
}

.highlight-box {
    background: var(--card-bg);
    border-left: 4px solid var(--accent-gold);
    padding: 30px;
    margin: 30px 0;
    border-radius: 4px;
}

.two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin: 40px 0;
}

.column-box {
    background: var(--card-bg);
    padding: 30px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.column-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--accent-gold);
}

.timeline {
    position: relative;
    padding-left: 40px;
    margin: 40px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--accent-gold);
}

.timeline-item {
    position: relative;
    margin-bottom: 35px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -47px;
    top: 5px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-gold);
    border: 3px solid var(--bg-color);
}

.timeline-year {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent-gold);
    margin-bottom: 8px;
}

.timeline-content {
    font-size: 1rem;
    line-height: 1.7;
}

/* ---------------- RESPONSIVE ---------------- */
@media (max-width: 1024px) {
    .header-container { padding: 0 20px; }
    .hero-container { flex-direction: column; align-items: center; gap: 40px; }
    .hero-image-wrapper { max-width: 400px; width: 100%; flex: auto; }
    .hero-content { width: 100%; text-align: center; }
    .two-column { grid-template-columns: 1fr; }
    .key-stats { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .header-container { height: 70px; }
    .logo { font-size: 1.5rem; }
    .hero-name { font-size: 2.5rem; }
    .hero-title { font-size: 1.1rem; }
    .main-content { padding: 0 20px; }
    .key-stats { grid-template-columns: 1fr; }
    .timeline { padding-left: 30px; }
    .footer-links { flex-direction: column; gap: 15px; }
}