/* Extra-Cool IRC Website Styles */

:root {
    --primary-color: #2c3e50;
    --secondary-color: #34495e;
    --accent-color: #3498db;
    --success-color: #27ae60;
    --warning-color: #f39c12;
    --error-color: #e74c3c;
    --background-color: #f5f7fb;
    --text-color: #2c3e50;
    --text-light: #6b7280;
    --border-color: #d1d5db;
    --white: #ffffff;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.12);
    --border-radius: 12px;
    --transition: all 0.25s ease;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--white);
    padding-top: 70px; /* compensate fixed navbar height */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Focus visible global */
:focus-visible { outline: 3px solid var(--accent-color); outline-offset: 2px; }
.skip-link { position:absolute; left:-9999px; top:auto; width:1px; height:1px; overflow:hidden; }
.skip-link:focus { position: absolute; left: 16px; top: 16px; width: auto; height: auto; padding: 10px 14px; background: #000; color:#fff; border-radius: 6px; z-index: 2000; }

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

/* Navigation */
.navbar {
    background: rgba(255, 255, 255, 0.7);
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    backdrop-filter: saturate(180%) blur(10px);
    box-shadow: var(--shadow);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 700;
    font-size: 1.5rem;
}

.logo {
    height: 40px;
    margin-right: 10px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 14px;
}

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 600;
    letter-spacing: .2px;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-color);
}

.btn-login {
    background: var(--accent-color);
    color: var(--white) !important;
    padding: 10px 20px;
    border-radius: var(--border-radius);
    transition: var(--transition);
}
/* Dropdown */
.dropdown { position: relative; }
.dropdown-toggle { background: transparent; border: 0; cursor: pointer; }
.dropdown-toggle::after { content: '▾'; margin-left: 6px; font-size: .9em; }
.dropdown-menu { position: absolute; top: 100%; left: 0; min-width: 200px; background: #fff; box-shadow: var(--shadow-lg); border-radius: 8px; padding: 8px; display: none; z-index: 1001; }
.dropdown:hover .dropdown-menu, .dropdown:focus-within .dropdown-menu { display: block; }
.dropdown-item { display: block; padding: 10px 12px; text-decoration: none; color: var(--text-color); border-radius: 6px; }
.dropdown-item:hover, .dropdown-item.active { background: #f2f4f7; color: var(--accent-color); }


.btn-login:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    margin: 3px 0;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    background: radial-gradient(1200px 600px at 20% 0%, rgba(255,255,255,0.05), transparent), linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    padding: 96px 0 64px;
    min-height: 60vh;
    display: flex;
    align-items: center;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-subtitle {
    display: block;
    font-size: 1.5rem;
    font-weight: 400;
    opacity: 0.9;
    margin-top: 10px;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-color);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-contrast {
    background: rgba(255,255,255,0.12);
    color: var(--white);
}
.btn-contrast:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

.floating-badges { display:flex; gap:10px; margin: 10px 20px; flex-wrap: wrap; }
.badge { background: rgba(255,255,255,0.12); color:#fff; padding:8px 12px; border-radius:999px; text-decoration:none; font-weight:600; }
.badge:hover { background: rgba(255,255,255,0.2); }

/* Chat page */
.page-main { display:block; }
.chat-section { padding: 0; background: var(--background-color); }
.chat-container { padding: 16px 20px; }
.chat-header { text-align: center; margin-bottom: 12px; }
.chat-title { font-size: 2rem; font-weight: 700; color: var(--primary-color); margin-bottom: 4px; }
.chat-subtitle { color: var(--text-light); }
.chat-shell { position: relative; width: 100%; height: calc(100vh - 140px); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); background: #fff; }
.chat-frame { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.loading { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 16px; background: linear-gradient(180deg, rgba(245,247,251,.9), rgba(255,255,255,.9)); color: var(--primary-color); z-index: 2; }
.spinner { width: 28px; height: 28px; border: 3px solid #cfd8e3; border-top-color: var(--accent-color); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading.fade-out { opacity: 0; pointer-events: none; transition: opacity .35s ease; }

/* Error UI */
.error-ui { position: absolute; inset: 0; display: grid; place-items: center; background: #fff; z-index: 3; padding: 16px; }
.error-inner { max-width: 560px; width: 100%; border: 1px solid var(--border-color); border-radius: 12px; padding: 20px; box-shadow: var(--shadow); text-align: center; }
.error-actions { margin-top: 14px; display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }

@media (max-width: 960px) {
  .chat-title { font-size: 1.6rem; }
  .chat-shell { height: calc(100vh - 120px); border-radius: 0; box-shadow: none; }
}

/* Dark theme example */
:root.dark {
  --background-color: #0b1220;
  --white: #0f172a;
  --text-color: #e5e7eb;
  --text-light: #9ca3af;
  --border-color: #334155;
  --primary-color: #e2e8f0;
  --secondary-color: #94a3b8;
  --accent-color: #60a5fa;
}

/* Mobile responsive */
@media (max-width: 960px) {
  .hero-container { grid-template-columns: 1fr; gap: 24px; }
  .nav-menu { position: fixed; top: 70px; right: 0; left: 0; background: #fff; flex-direction: column; gap: 12px; padding: 16px; box-shadow: var(--shadow); transform: translateY(-200%); transition: var(--transition); }
  .nav-menu.open { transform: translateY(0); }
  .nav-link { padding: 10px 6px; }
  .dropdown { width: 100%; }
  .dropdown-menu { position: static; display: none; box-shadow: none; padding: 0; background: transparent; }
  .dropdown.open .dropdown-menu { display: block; }
  .dropdown-item { padding: 8px 6px; }
  .nav-toggle { display: flex; }
}

.btn-secondary {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-secondary:hover {
    background: var(--white);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.btn-large {
    padding: 20px 40px;
    font-size: 1.1rem;
}

.hero-image img {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
}

/* Features Section */
.features {
    padding: 80px 0;
    background: var(--background-color);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 60px;
    color: var(--primary-color);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.feature-card {
    background: var(--white);
    padding: 40px 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    text-align: center;
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.feature-card p {
    color: var(--text-light);
    line-height: 1.6;
}

/* Stats Section */
.stats {
    padding: 80px 0;
    background: var(--primary-color);
    color: var(--white);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    text-align: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--accent-color);
    margin-bottom: 10px;
}

.stat-label {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* CTA Section */
.cta {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--primary-color) 100%);
    color: var(--white);
    text-align: center;
}

.cta h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.cta p {
    font-size: 1.2rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

/* Footer */
.footer {
    background: var(--primary-color);
    color: var(--white);
    padding: 60px 0 20px;
}

.footer { margin-top: auto; }

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 20px;
    color: var(--accent-color);
}

.footer-section ul {
    list-style: none;
}

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

.footer-section ul li a {
    color: var(--white);
    text-decoration: none;
    opacity: 0.8;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    opacity: 1;
    color: var(--accent-color);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-link {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: var(--accent-color);
    color: var(--white);
    text-decoration: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.social-link:hover {
    background: var(--white);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.footer-bottom {
    border-top: 1px solid var(--secondary-color);
    padding-top: 20px;
    text-align: center;
    opacity: 0.8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
}

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

.feature-card,
.stat-item {
    animation: fadeInUp 0.6s ease-out;
}

/* Utility Classes */
.text-center {
    text-align: center;
}

.mb-20 {
    margin-bottom: 20px;
}

.mb-40 {
    margin-bottom: 40px;
}

.mt-20 {
    margin-top: 20px;
}

.mt-40 {
    margin-top: 40px;
} 