:root {
    --primary-color: #2563eb; /* Royal Blue */
    --primary-hover: #1d4ed8;
    --secondary-color: #0f172a; /* Slate 900 */
    --accent-color: #3b82f6;
    --text-color: #334155; /* Slate 700 */
    --heading-color: #1e293b; /* Slate 800 */
    --bg-color: #f8fafc; /* Slate 50 */
    --card-bg: #ffffff;
    --footer-bg: #0f172a;
    --success-color: #10b981;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    margin: 0;
    padding: 0;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

#page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
}

.site-main {
    flex-grow: 1;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--heading-color);
    font-weight: 700;
    margin-top: 0;
}

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

/* Header */
.site-header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 40px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 24px;
}

.site-title {
    margin: 0;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.site-title a {
    color: var(--primary-color);
    text-decoration: none;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.main-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 24px;
}

.main-navigation a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.main-navigation a:hover {
    color: var(--primary-color);
}

.language-switcher {
    position: relative;
    cursor: pointer;
    font-weight: 600;
    color: var(--text-color);
}

.language-switcher .current-lang {
    display: flex;
    align-items: center;
    gap: 4px;
}

.language-switcher .current-lang::after {
    content: '';
    display: inline-block;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 4px solid currentColor;
    margin-left: 4px;
    transform: translateY(2px);
}

.language-switcher .lang-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 0;
    list-style: none;
    display: none;
    min-width: 80px;
    z-index: 100;
    margin-top: 8px;
}

.language-switcher .lang-dropdown::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    width: 100%;
    height: 10px;
    background: transparent;
}

.language-switcher:hover .lang-dropdown {
    display: block;
}

.language-switcher .lang-dropdown li a {
    display: block;
    padding: 8px 16px;
    color: var(--text-color);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
}

.language-switcher .lang-dropdown li a:hover {
    background: #f8fafc;
    color: var(--primary-color);
}

.header-auth {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-auth .btn {
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    padding: 8px 20px;
    border-radius: 50px;
    transition: all 0.2s;
}

.header-auth .btn-login {
    color: var(--text-color);
}

.header-auth .btn-login:hover {
    color: var(--primary-color);
}

.header-auth .btn-register,
.header-auth .btn-dashboard {
    background: var(--primary-color);
    color: #fff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.header-auth .btn-register:hover,
.header-auth .btn-dashboard:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.3);
}

/* Hero Section */
.hero-section {
    background: radial-gradient(circle at top right, #eff6ff, #f8fafc);
    padding: 120px 0 100px;
    text-align: center;
    overflow: hidden;
    position: relative;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.05) 0%, transparent 70%);
    transform: rotate(30deg);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 56px;
    line-height: 1.1;
    margin-bottom: 24px;
    background: linear-gradient(135deg, #0f172a 0%, #334155 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 20px;
    color: #64748b;
    margin-bottom: 48px;
    font-weight: 400;
    min-height: 1.6em; /* Reserve space to prevent layout shift */
}

.typewriter-cursor {
    animation: blink 1s step-end infinite;
    margin-left: 2px;
    color: #64748b;
}

@keyframes blink {
    from, to { opacity: 1; }
    50% { opacity: 0; }
}

.cta-button {
    display: inline-flex;
    align-items: center;
    background: var(--primary-color);
    color: #fff;
    padding: 16px 32px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.4);
}

.cta-button:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px rgba(37, 99, 235, 0.5);
}

/* Stats / Trust Section */
.stats-section {
    padding: 40px 0;
    background: #fff;
    border-bottom: 1px solid #f1f5f9;
}

.stats-grid {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
    color: #64748b;
    font-weight: 600;
    font-size: 18px;
}

/* Features Section */
.features-section {
    padding: 100px 0;
    background: #fff;
}

.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 60px;
}

.section-title {
    font-size: 36px;
    margin-bottom: 16px;
}

.section-desc {
    color: #64748b;
    font-size: 18px;
}

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

.feature-card {
    background: #fff;
    padding: 40px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

/* Models Section */
.models-section {
    padding: 80px 0;
    background: #f8fafc;
    border-top: 1px solid #f1f5f9;
}

.models-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
    max-width: 900px;
    margin: 0 auto;
}

.model-item {
    background: #fff;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 600;
    color: var(--text-color);
    border: 1px solid #e2e8f0;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.model-item:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

/* Code Demo Section */
.code-section {
    padding: 100px 0;
    background: #0f172a; /* Dark background */
    color: #fff;
    position: relative;
    overflow: hidden;
}

.code-wrapper {
    background: #1e293b;
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.1);
    max-width: 800px;
    margin: 0 auto;
    font-family: 'Consolas', 'Monaco', 'Andale Mono', monospace;
    font-size: 16px;
    line-height: 1.6;
    overflow-x: auto;
    text-align: left;
}

.code-wrapper pre {
    margin: 0;
    color: #e2e8f0;
}

.code-comment { color: #64748b; }
.code-keyword { color: #c084fc; } /* Purple */
.code-string { color: #4ade80; } /* Green */
.code-function { color: #60a5fa; } /* Blue */

/* Footer */
.site-footer {
    background-color: var(--footer-bg);
    color: #94a3b8;
    padding: 60px 0 30px;
    margin-top: auto;
    border-top: 1px solid #1e293b;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-left .site-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}

.footer-left .sep {
    color: #475569;
}

.footer-left a {
    color: #e2e8f0;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-left a:hover {
    color: #fff;
}

.footer-right .footer-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 24px;
}

.footer-right .footer-menu a {
    color: #94a3b8;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s;
}

.footer-right .footer-menu a:hover {
    color: #fff;
}

@media (max-width: 768px) {
    .footer-inner {
        flex-direction: column;
        text-align: center;
        gap: 24px;
    }
    
    .footer-right .footer-menu {
        justify-content: center;
    }
}
