/* CSS Variables for Theme */
:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-card: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-accent: #3b82f6;
    --border-color: #e2e8f0;
    --shadow-light: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-medium: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-large: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --discord-color: #5865f2;
    --discord-hover: #4752c4;
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-accent: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-warm: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    --gradient-cool: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
    --glass-bg: rgba(255, 255, 255, 0.25);
    --glass-border: rgba(255, 255, 255, 0.18);
}

[data-theme="dark"] {
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-card: #334155;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-accent: #60a5fa;
    --border-color: #475569;
    --shadow-light: 0 1px 3px 0 rgba(0, 0, 0, 0.3), 0 1px 2px 0 rgba(0, 0, 0, 0.2);
    --shadow-medium: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
    --shadow-large: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.3);
    --glass-bg: rgba(51, 65, 85, 0.25);
    --glass-border: rgba(148, 163, 184, 0.18);
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
    position: relative;
}

/* Animated Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.3) 0%, transparent 50%);
    z-index: -1;
    animation: backgroundShift 20s ease-in-out infinite;
}

@keyframes backgroundShift {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.1) rotate(180deg); }
}

/* Theme Toggle */
.theme-toggle {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 1000;
    width: 3.5rem;
    height: 3.5rem;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-large);
    animation: fadeInDown 0.8s ease-out 0.5s both;
}

.theme-toggle:hover {
    transform: scale(1.1) rotate(10deg);
    box-shadow: var(--shadow-xl);
    background: var(--glass-bg);
}

.theme-toggle:active {
    transform: scale(0.95);
}

.theme-toggle svg {
    width: 1.5rem;
    height: 1.5rem;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.theme-toggle .moon-icon {
    display: none;
}

[data-theme="dark"] .theme-toggle .sun-icon {
    display: none;
}

[data-theme="dark"] .theme-toggle .moon-icon {
    display: block;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Hero Section */
.hero-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    background: var(--gradient-primary);
    margin: 0 -2rem;
    padding: 0 2rem;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 70% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    animation: heroGlow 15s ease-in-out infinite;
}

@keyframes heroGlow {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 3rem;
    animation: fadeInUp 1s ease-out;
    position: relative;
    z-index: 2;
}

.logo {
    width: 6rem;
    height: 6rem;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border: 2px solid var(--glass-border);
    border-radius: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-xl);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.logo::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s ease;
    opacity: 0;
}

.logo:hover::before {
    opacity: 1;
    transform: rotate(45deg) translate(50%, 50%);
}

.logo:hover {
    transform: rotate(5deg) scale(1.1);
    box-shadow: var(--shadow-xl), 0 0 30px rgba(255, 255, 255, 0.2);
}

.logo-svg {
    width: 3.5rem;
    height: 3.5rem;
    color: var(--text-primary);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.server-name {
    font-size: 4rem;
    font-weight: 900;
    color: white;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #ffffff 0%, #f0f9ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

.server-name::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: var(--gradient-accent);
    border-radius: 2px;
    animation: pulse 2s ease-in-out infinite;
}

.hero-content {
    max-width: 700px;
    animation: fadeInUp 1s ease-out 0.3s both;
    position: relative;
    z-index: 2;
}

.welcome-title {
    font-size: 3.5rem;
    font-weight: 800;
    color: white;
    margin-bottom: 1.5rem;
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    background: linear-gradient(135deg, #ffffff 0%, #e0f2fe 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.375rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 2rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    font-weight: 300;
}

/* About Section */
.about-section {
    padding: 8rem 0;
    background: var(--bg-secondary);
    margin: 0 -2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
    padding-left: 2rem;
    padding-right: 2rem;
    position: relative;
}

.about-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 10% 20%, rgba(120, 119, 198, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 90% 80%, rgba(255, 119, 198, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.content-card {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    padding: 3rem;
    border-radius: 2rem;
    box-shadow: var(--shadow-large);
    transition: all 0.4s ease;
    border: 1px solid var(--glass-border);
    animation: fadeInUp 0.8s ease-out both;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.content-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-cool);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.content-card:nth-child(1) { 
    animation-delay: 0.1s; 
}
.content-card:nth-child(2) { 
    animation-delay: 0.2s;
}
.content-card:nth-child(3) { 
    animation-delay: 0.3s;
}
.content-card:nth-child(4) { 
    animation-delay: 0.4s;
}

.content-card:nth-child(2)::before {
    background: var(--gradient-warm);
}

.content-card:nth-child(3)::before {
    background: var(--gradient-accent);
}

.content-card:nth-child(4)::before {
    background: var(--gradient-secondary);
}

.content-card:hover {
    transform: translateY(-1rem) scale(1.02);
    box-shadow: var(--shadow-xl), 0 0 40px rgba(0, 0, 0, 0.1);
}

.content-card:hover::before {
    opacity: 0.05;
}

.card-icon {
    width: 4rem;
    height: 4rem;
    background: var(--gradient-secondary);
    border-radius: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.content-card:nth-child(1) .card-icon {
    background: var(--gradient-cool);
}

.content-card:nth-child(2) .card-icon {
    background: var(--gradient-warm);
}

.content-card:nth-child(3) .card-icon {
    background: var(--gradient-accent);
}

.content-card:nth-child(4) .card-icon {
    background: var(--gradient-secondary);
}

.card-icon::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transform: rotate(45deg);
    transition: all 0.6s ease;
    opacity: 0;
}

.content-card:hover .card-icon {
    transform: scale(1.1) rotate(10deg);
}

.content-card:hover .card-icon::before {
    opacity: 1;
    transform: rotate(45deg) translate(50%, 50%);
}

.card-icon svg {
    width: 2rem;
    height: 2rem;
    color: white;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.content-card h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    position: relative;
}

.content-card h3::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 50px;
    height: 3px;
    background: var(--gradient-accent);
    border-radius: 2px;
    transition: width 0.3s ease;
}

.content-card:hover h3::after {
    width: 80px;
}

.content-card p {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 1.1rem;
}

/* CTA Section */
.cta-section {
    padding: 8rem 0;
    text-align: center;
    background: var(--bg-primary);
    animation: fadeInUp 0.8s ease-out 0.5s both;
    position: relative;
}

.cta-content {
    position: relative;
    z-index: 2;
}

.cta-content h2 {
    font-size: 3rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1.5rem;
    position: relative;
}

.cta-content h2::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background: var(--gradient-accent);
    border-radius: 2px;
}

.cta-content p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    font-weight: 300;
}

.discord-button {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    background: var(--discord-color);
    color: white;
    padding: 1.25rem 2.5rem;
    border-radius: 1rem;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.25rem;
    transition: all 0.4s ease;
    box-shadow: var(--shadow-large);
    position: relative;
    overflow: hidden;
}

.discord-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.discord-button:hover::before {
    left: 100%;
}

.discord-button:hover {
    background: var(--discord-hover);
    transform: translateY(-0.25rem) scale(1.05);
    box-shadow: var(--shadow-xl), 0 0 30px rgba(88, 101, 242, 0.3);
}

.discord-button:active {
    transform: translateY(0) scale(1);
}

.discord-icon {
    width: 1.75rem;
    height: 1.75rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

/* Footer */
.footer {
    background: var(--bg-secondary);
    padding: 3rem 0;
    text-align: center;
    margin: 0 -2rem;
    border-top: 1px solid var(--border-color);
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--gradient-accent);
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 300;
}

/* Floating Elements */
.floating-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.floating-element {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--text-accent);
    border-radius: 50%;
    opacity: 0.3;
    animation: float 20s linear infinite;
}

.floating-element:nth-child(1) {
    left: 10%;
    animation-delay: 0s;
}

.floating-element:nth-child(2) {
    left: 20%;
    animation-delay: 2s;
}

.floating-element:nth-child(3) {
    left: 30%;
    animation-delay: 4s;
}

.floating-element:nth-child(4) {
    left: 40%;
    animation-delay: 6s;
}

.floating-element:nth-child(5) {
    left: 50%;
    animation-delay: 8s;
}

.floating-element:nth-child(6) {
    left: 60%;
    animation-delay: 10s;
}

.floating-element:nth-child(7) {
    left: 70%;
    animation-delay: 12s;
}

.floating-element:nth-child(8) {
    left: 80%;
    animation-delay: 14s;
}

.floating-element:nth-child(9) {
    left: 90%;
    animation-delay: 16s;
}

@keyframes float {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 0.3;
    }
    90% {
        opacity: 0.3;
    }
    100% {
        transform: translateY(-100vh) scale(1);
        opacity: 0;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(3rem);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-3rem);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    .theme-toggle {
        top: 1rem;
        right: 1rem;
        width: 3rem;
        height: 3rem;
    }
    
    .theme-toggle svg {
        width: 1.25rem;
        height: 1.25rem;
    }
    
    .hero-section {
        margin: 0 -1rem;
        padding: 0 1rem;
        min-height: 90vh;
    }
    
    .logo-container {
        flex-direction: column;
        gap: 1.5rem;
        margin-bottom: 2rem;
    }
    
    .logo {
        width: 5rem;
        height: 5rem;
    }
    
    .logo-svg {
        width: 3rem;
        height: 3rem;
    }
    
    .server-name {
        font-size: 2.5rem;
    }
    
    .welcome-title {
        font-size: 2.5rem;
    }
    
    .hero-description {
        font-size: 1.125rem;
    }
    
    .about-section {
        margin: 0 -1rem;
        padding: 5rem 1rem;
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .content-card {
        padding: 2rem;
    }
    
    .card-icon {
        width: 3.5rem;
        height: 3.5rem;
    }
    
    .card-icon svg {
        width: 1.75rem;
        height: 1.75rem;
    }
    
    .content-card h3 {
        font-size: 1.5rem;
    }
    
    .cta-content h2 {
        font-size: 2.25rem;
    }
    
    .discord-button {
        padding: 1rem 2rem;
        font-size: 1.125rem;
    }
    
    .discord-icon {
        width: 1.5rem;
        height: 1.5rem;
    }
    
    .footer {
        margin: 0 -1rem;
    }
}

@media (max-width: 480px) {
    .server-name {
        font-size: 2rem;
    }
    
    .welcome-title {
        font-size: 2rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .content-card {
        padding: 1.5rem;
    }
    
    .cta-content h2 {
        font-size: 1.875rem;
    }
    
    .discord-button {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

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

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--text-accent), var(--discord-color));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--discord-color), var(--text-accent));
}

/* Loading animations */
.animate-in {
    animation: slideInUp 0.6s ease-out forwards;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Focus styles for accessibility */
.keyboard-navigation *:focus {
    outline: 3px solid var(--text-accent) !important;
    outline-offset: 2px !important;
    border-radius: 4px;
}

