/* CSS Variables - BattleGuess Color Scheme */
:root {
    --primary: #F97316;
    --primary-light: #FB923C;
    --primary-dark: #EA580C;
    --secondary: #FDBA74;
    --secondary-light: #FED7AA;
    --accent: #C2410C;
    --success: #22C55E;
    --error: #EF4444;
    --warning: #F59E0B;
    
    --background: #FFFBF7;
    --background-dark: #FFF7ED;
    --card: #FFFFFF;
    --card-border: #FED7AA;
    
    --text: #1C1917;
    --text-secondary: #78716C;
    --text-light: #A8A29E;
    --text-inverse: #FFFFFF;
    
    --streak: #F97316;
    --hearts: #EF4444;
    --xp: #F59E0B;
    
    --ancient: #92400E;
    --medieval: #78716C;
    --napoleonic: #C2410C;
    --ww1: #84CC16;
    --ww2: #A16207;
    --modern: #EA580C;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--background);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

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

/* Navigation */
.navbar {
    position: sticky;
    top: 0;
    background-color: var(--card);
    border-bottom: 1px solid var(--card-border);
    z-index: 1000;
    padding: 1rem 0;
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text);
    text-decoration: none;
}

.logo-icon {
    font-size: 2rem;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
}

.nav-cta {
    background-color: var(--primary);
    color: var(--text-inverse) !important;
    padding: 0.5rem 1.5rem;
    border-radius: 8px;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.nav-cta:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    width: 24px;
    height: 3px;
    background-color: var(--text);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

@media (max-width: 968px) {
    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--card);
        flex-direction: column;
        padding: 2rem;
        border-bottom: 1px solid var(--card-border);
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
}

/* Hero Section */
.hero {
    padding: 4rem 0 6rem;
    background: linear-gradient(to bottom, var(--background) 0%, var(--background-dark) 100%);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--text);
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.7;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: inline-block;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--text-inverse);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(249, 115, 22, 0.3);
}

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

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

.hero-stats {
    display: flex;
    gap: 3rem;
}

.stat {
    text-align: left;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Phone Mockup */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.phone-mockup {
    position: relative;
    width: 300px;
    height: 600px;
    background: linear-gradient(145deg, #ffffff 0%, #f8f8f8 100%);
    border-radius: 40px;
    padding: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2), 0 0 0 8px rgba(0, 0, 0, 0.1);
}

.phone-screen {
    width: 100%;
    height: 100%;
    background-color: var(--background);
    border-radius: 30px;
    overflow: hidden;
    position: relative;
}

.screen-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    height: 100%;
}

.mockup-header {
    background-color: var(--card);
    padding: 1rem;
    border-radius: 12px;
}

.mockup-stats {
    display: flex;
    gap: 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
}

.mockup-path {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
    justify-content: center;
}

.mockup-node {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.mockup-node.active {
    border: 4px solid var(--secondary);
    animation: pulse 2s infinite;
}

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

.mockup-path-line {
    width: 4px;
    height: 30px;
    background-color: var(--secondary);
    border-radius: 2px;
}

.mockup-battle-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: var(--text-inverse);
    padding: 1.5rem;
    border-radius: 16px;
}

.mockup-battle-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.mockup-battle-card p {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Section Header */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text);
}

.section-header p {
    font-size: 1.25rem;
    color: var(--text-secondary);
}

/* Features Section */
.features {
    padding: 6rem 0;
    background-color: var(--card);
}

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

.feature-card {
    background-color: var(--background);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid var(--card-border);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
    border-color: var(--primary);
}

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

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text);
}

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

/* Eras Section */
.eras {
    padding: 6rem 0;
    background: linear-gradient(to bottom, var(--background-dark) 0%, var(--background) 100%);
}

.eras-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.era-card {
    background-color: var(--card);
    padding: 2.5rem 2rem;
    border-radius: 20px;
    border: 2px solid var(--card-border);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.era-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.era-card:hover::before {
    transform: scaleX(1);
}

.era-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.15);
}

.era-card.ancient::before {
    background: var(--ancient);
}

.era-card.medieval::before {
    background: var(--medieval);
}

.era-card.napoleonic::before {
    background: var(--napoleonic);
}

.era-card.ww1::before {
    background: var(--ww1);
}

.era-card.ww2::before {
    background: var(--ww2);
}

.era-card.modern::before {
    background: var(--modern);
}

.era-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.era-card h3 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text);
}

.era-card > p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.era-battles {
    list-style: none;
    padding-top: 1rem;
    border-top: 1px solid var(--card-border);
}

.era-battles li {
    color: var(--text-secondary);
    padding: 0.5rem 0;
    font-size: 0.95rem;
}

.era-battles li:before {
    content: '• ';
    color: var(--primary);
    font-weight: bold;
    margin-right: 0.5rem;
}

/* How It Works Section */
.how-it-works {
    padding: 6rem 0;
    background-color: var(--card);
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
}

.step {
    text-align: center;
    position: relative;
}

.step-number {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: var(--text-inverse);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0 auto 1.5rem;
    box-shadow: 0 8px 20px rgba(249, 115, 22, 0.3);
}

.step h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text);
}

.step p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* Download Section */
.download {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    color: var(--text-inverse);
}

.download-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.download-content h2 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.download-content > p {
    font-size: 1.25rem;
    margin-bottom: 3rem;
    opacity: 0.95;
}

.download-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.download-btn {
    display: flex;
    align-items: center;
    gap: 1rem;
    background-color: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-inverse);
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    min-width: 200px;
}

.download-btn:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
}

.download-icon {
    font-size: 2.5rem;
}

.download-text {
    text-align: left;
}

.download-label {
    font-size: 0.85rem;
    opacity: 0.9;
}

.download-name {
    font-size: 1.25rem;
    font-weight: 700;
}

.download-note {
    font-size: 1rem;
    opacity: 0.9;
}

/* Footer */
.footer {
    background-color: var(--text);
    color: var(--text-light);
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand .logo {
    color: var(--text-inverse);
    margin-bottom: 1rem;
}

.footer-brand p {
    color: var(--text-light);
    max-width: 300px;
}

.footer-column h4 {
    color: var(--text-inverse);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

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

.footer-column ul li {
    margin-bottom: 0.75rem;
}

.footer-column ul li a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-column ul li a:hover {
    color: var(--text-inverse);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-light);
}

/* Responsive Design */
@media (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-visual {
        order: -1;
    }

    .phone-mockup {
        width: 250px;
        height: 500px;
    }

    .nav-links {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .hero-stats {
        gap: 2rem;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

@media (max-width: 640px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-description {
        font-size: 1.1rem;
    }

    .hero-cta {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    .features-grid,
    .eras-grid {
        grid-template-columns: 1fr;
    }

    .download-content h2 {
        font-size: 2rem;
    }

    .download-buttons {
        flex-direction: column;
        align-items: center;
    }

    .download-btn {
        width: 100%;
        max-width: 300px;
    }
}
