* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: all 0.2s ease;
}

:root {
    /* Default light theme */
    --primary: #4A6CF7;
    --text-primary: #1E293B;
    --text-secondary: #64748B;
    --bg: #F8FAFC;
    --card-bg: #FFFFFF;
    --border: #E2E8F0;
    --shadow: rgba(0, 0, 0, 0.05);
    --hover-bg: #F1F5F9;
    --success: #10B981;
    --font-family: 'Inter', sans-serif;
    --base-font-size: 1rem;
    --line-height: 1.6;
}

/* ===== THEME DEFINITIONS ===== */
/* Normal themes */
.normal-light {
    --primary: #4A6CF7;
    --text-primary: #1E293B;
    --text-secondary: #64748B;
    --bg: #F8FAFC;
    --card-bg: #FFFFFF;
    --border: #E2E8F0;
    --shadow: rgba(0, 0, 0, 0.05);
    --hover-bg: #F1F5F9;
    --success: #10B981;
    --font-family: 'Inter', sans-serif;
    --base-font-size: 1rem;
}

.normal-dark {
    --primary: #6C8DFA;
    --text-primary: #E2E8F0;
    --text-secondary: #94A3B8;
    --bg: #0F172A;
    --card-bg: #1E293B;
    --border: #334155;
    --shadow: rgba(0, 0, 0, 0.2);
    --hover-bg: #1E293B;
    --success: #34D399;
    --font-family: 'Roboto', sans-serif;
    --base-font-size: 1rem;
}

/* Gamer themes */
.gamer-neon {
    --primary: #0f0;
    --text-primary: #ffffff;
    --text-secondary: #c0c0c0;
    --bg: #121212;
    --card-bg: #1a1a1a;
    --border: #333;
    --shadow: rgba(0, 255, 0, 0.1);
    --hover-bg: #222;
    --success: #00ff00;
    --font-family: 'Orbitron', sans-serif;
    --base-font-size: 0.95rem; /* Slightly smaller for better fit */
}

.gamer-rgb {
    --primary: #ff073a;
    --text-primary: #ffffff;
    --text-secondary: #d0d0d0;
    --bg: #0a0a0a;
    --card-bg: #141414;
    --border: #444;
    --shadow: rgba(255, 7, 58, 0.1);
    --hover-bg: #222;
    --success: #00ffff;
    --font-family: 'Orbitron', sans-serif;
    --base-font-size: 0.95rem;
}

.gamer-pixel {
    --primary: #5533ff;
    --text-primary: #ffcc00;
    --text-secondary: #ffe57d;
    --bg: #0d0d0d;
    --card-bg: #1a1a1a;
    --border: #333;
    --shadow: rgba(85, 51, 255, 0.1);
    --hover-bg: #222;
    --success: #00ff00;
    --font-family: 'Press Start 2P', cursive;
    --base-font-size: 0.7rem; /* Smaller for pixel font */
    --line-height: 1.8; /* More spacing for readability */
}

/* Event themes */
.event-christmas {
    --primary: #d50000;
    --text-primary: #1a1a1a;
    --text-secondary: #4d4d4d;
    --bg: #f5f5f5;
    --card-bg: #ffffff;
    --border: #e0e0e0;
    --shadow: rgba(213, 0, 0, 0.1);
    --hover-bg: #ffe6e6;
    --success: #2e7d32;
    --font-family: 'Mountains of Christmas', cursive;
    --base-font-size: 1.1rem; /* Slightly larger for decorative font */
}

/* Fixed Halloween theme with better colors */
.event-halloween {
    --primary: #ff8f00; /* Pumpkin orange */
    --text-primary: #ffffff; /* White for better contrast */
    --text-secondary: #e0e0e0; /* Light gray */
    --bg: #1a1a1a; /* Dark background */
    --card-bg: #2a2a2a; /* Slightly lighter dark */
    --border: #5e3500; /* Orange border */
    --shadow: rgba(255, 143, 0, 0.2);
    --hover-bg: #333333; /* Darker on hover */
    --success: #ff5252; /* Blood red */
    --font-family: 'Creepster', cursive;
    --base-font-size: 1.05rem; /* Slightly larger for decorative font */
}

.event-valentine {
    --primary: #ff4081;
    --text-primary: #1a1a1a;
    --text-secondary: #4d4d4d;
    --bg: #fff5f7;
    --card-bg: #ffffff;
    --border: #ffd1dc;
    --shadow: rgba(255, 64, 129, 0.1);
    --hover-bg: #ffeef2;
    --success: #e91e63;
    --font-family: 'Dancing Script', cursive;
    --base-font-size: 1.15rem; /* Larger for script font */
    --line-height: 1.8; /* More spacing for script */
}

/* Aesthetic themes */
.aesthetic-cyberpunk {
    --primary: #8a2be2;
    --text-primary: #ffffff;
    --text-secondary: #cccccc;
    --bg: #0a0a1a;
    --card-bg: #14142a;
    --border: #33335a;
    --shadow: rgba(138, 43, 226, 0.1);
    --hover-bg: #1e1e3a;
    --success: #00ff9d;
    --font-family: 'Rajdhani', sans-serif;
    --base-font-size: 1rem;
}

.aesthetic-vaporwave {
    --primary: #ff71ce;
    --text-primary: #ffffff;
    --text-secondary: #e0e0e0;
    --bg: #000;
    --card-bg: #1a1a1a;
    --border: #444;
    --shadow: rgba(255, 113, 206, 0.1);
    --hover-bg: #222;
    --success: #01cdfe;
    --font-family: 'Comfortaa', cursive;
    --base-font-size: 1rem;
}

.aesthetic-minimal {
    --primary: #333333;
    --text-primary: #000000;
    --text-secondary: #666666;
    --bg: #ffffff;
    --card-bg: #f9f9f9;
    --border: #e0e0e0;
    --shadow: rgba(0, 0, 0, 0.05);
    --hover-bg: #f0f0f0;
    --success: #4caf50;
    --font-family: 'Quicksand', sans-serif;
    --base-font-size: 1rem;
}

/* ===== GLOBAL STYLES ===== */
body {
    font-family: var(--font-family);
    font-size: var(--base-font-size);
    line-height: var(--line-height, 1.6);
    background-color: var(--bg);
    color: var(--text-primary);
    min-height: 100vh;
    max-width: 1400px;
    margin: 0 auto;
}

h1, h2, h3, h4 {
    color: var(--text-primary);
    font-weight: 700;
    line-height: 1.3;
}

h1 {
    font-size: calc(var(--base-font-size) * 2.5);
}

h2 {
    font-size: calc(var(--base-font-size) * 2);
    border-bottom: 2px solid var(--primary);
}

h3 {
    font-size: calc(var(--base-font-size) * 1.5);
}

p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    background: var(--primary);
    color: white;
    margin: 0.5rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: calc(var(--base-font-size) * 0.9);
}

.btn:hover {
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px var(--shadow);
}

.btn-secondary {
    background: var(--card-bg);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

/* Theme container */
.theme-dialog {
    min-width: 330px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.theme-container h2 {
    margin-bottom: 20px;
    border-bottom: 2px solid var(--primary);
}

.theme-container {
    padding: 10px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: var(--card-bg);
    border: 1px solid var(--border);
}

.theme-category {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin-bottom: 10px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 10px;
}

.theme-buttons {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
}

.theme-btn {
    font-family: var(--font-family);
    padding: 5px 10px;
    border: 2px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
    background: var(--card-bg);
    color: var(--primary);
    text-align: center;
    transition: all 0.2s ease;
}

.theme-btn:hover {
    background-color: var(--hover-bg);
    transform: translateY(-5%);
}

.theme-btn.active {
    background-color: var(--hover-bg);
    transform: translateY(-5%);
    border: 1px solid var(--success);
}

/* ===== NAVBAR ===== */
.hamburg-open {
    transform: scale(0);
}

.hamburg-close {
    transform: scale(0);
}

.navbar {
    max-width: 98%;
    height: 5.5rem;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1rem;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    background: var(--bg);
    z-index: 100;
}

.navbar .logo {
    font-size: 1.75rem;
    font-weight: 700;
    user-select: none;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-hamburg {
    display: flex;
    align-items: center;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: all 0.3s ease;
    text-wrap: nowrap;
}

.nav-links a:hover, .nav-links button:hover {
    background: var(--hover-bg);
}

.nav-links a:last-child {
    color: var(--bg);
}

.nav-links a:last-child:hover {
    background: var(--primary);
}

.nav-links button {
    font-family: var(--font-family);
    font-size: calc(var(--base-font-size) * 0.95);
    padding: 0.6rem 1.2rem;
}


/* Footer */

.footer {
  border-top: 1px solid var(--border);
  color: var(--text-secondary);
  padding: 3rem 2rem 1rem;
  font-family: 'Segoe UI', sans-serif;
  margin-top: 10rem;
}

.footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  max-width: 1200px;
  margin: 0 auto 3rem;
}

.footer-branding .logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.footer-branding p {
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.footer-branding .social-icons {
  margin: 1rem 0;
}

.footer-branding .mail {
  font-size: 1rem;
  text-decoration: none;
  color: var(--text-primary);
}

.footer-branding .mail:hover {
  opacity: 0.9;
  text-decoration: underline;
}

.social-icons a {
  color: var(--text-secondary);
  margin-right: 0.8rem;
  font-size: 1.2rem;
  transition: color 0.3s;
}

.social-icons a:hover {
  color: var(--text-primary);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 3rem;
}

.link-column h4 {
  color: var(--text-primary);
  font-size: 1.1rem;
  margin-bottom: 0.7rem;
}

.link-column a {
  display: block;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
  transition: color 0.3s;
}

.link-column a:hover {
  color: var(--text-primary);
}

.footer-copy {
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-top: 2rem;
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}


@media (max-width: 620px) {
    .hamburg-open {
        transform: scale(1.7);
        cursor: pointer;
    }
    .hamburg-open:hover {
        transform: scale(1.8);
    }

    .nav-links {
        width: 250px;
        height: 100vh;
        background-color: var(--border);
        position: absolute;
        top: 0;
        right: -255px;
        display: none;
        z-index: 100;
    }

    .nav-links.open {
        display: flex;
        flex-direction: column;
        right: -5px;
        padding-top: 5rem;
        gap: 0;
    }
    .nav-links.open .btn {
        width: 90%;
        margin: 5px 0;
        border-radius: 10px;
        border: none;
        justify-content: center;
        padding: 1rem 0;
        font-size: 1.2rem;
        background-color: transparent;
        color: var(--primary);
    }
    
    .nav-links.open .btn:hover {
        background-color: var(--primary);
        color: var(--bg);
    }
    
    .nav-links.open .btn.btn-secondary {
        color: var(--text-primary);
    }

    .nav-links.open .btn.btn-secondary:hover {
        background-color: var(--text-secondary);
        color: var(--bg);
    }

    .nav-links.open .hamburg-close {
        cursor: pointer;
        transform: scale(1.7);
        position: absolute;
        right: 20px;
        top: 35px;
    }

    .nav-links.open .hamburg-close:hover {
        transform: scale(1.8);
    }

    .footer-branding {
        max-width: 346px;
        margin-bottom: 3rem;
    }
}