/* ========================================
   ClassFlow Landing Page - Styles
   ======================================== */

/* CSS Variables */
:root {
    --primary: #4CAF50;
    --primary-dark: #3d8b40;
    --primary-light: #81C784;
    --accent: #2E7D32;
    --background: #FAFAFA;
    --background-alt: #FFFFFF;
    --foreground: #1a1a1a;
    --foreground-light: #6B7280;
    --card: #FFFFFF;
    --border: #E5E7EB;
    --shadow: rgba(0, 0, 0, 0.1);
    --shadow-lg: rgba(0, 0, 0, 0.15);
    --radius: 12px;
    --radius-lg: 24px;
    --radius-xl: 48px;
    --transition: 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

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

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
}

/* Container */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ========================================
   Header & Navigation
   ======================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: background-color var(--transition), box-shadow var(--transition);
}

.header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px var(--shadow);
}

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

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

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

.logo-icon {
    width: 40px;
    height: 40px;
    background: var(--primary);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.logo-icon-img {
    width: 40px;
    height: 40px;
    border-radius: var(--radius);
    object-fit: cover;
}

.logo-icon-img-footer {
    width: 40px;
    height: 40px;
    border-radius: var(--radius);
    object-fit: cover;
    background-color: #1a1a1a;
}

.logo-text {
    font-size: 20px;
    font-weight: 700;
    color: var(--foreground);
}

.nav-links {
    display: none;
    align-items: center;
    gap: 32px;
}

.nav-links a {
    font-weight: 500;
    color: var(--foreground-light);
    transition: color var(--transition);
}

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

.mobile-menu-btn {
    display: flex;
    padding: 8px;
    color: var(--foreground);
}

.mobile-menu-btn .close-icon {
    display: none;
}

.mobile-menu-btn.active .menu-icon {
    display: none;
}

.mobile-menu-btn.active .close-icon {
    display: block;
}

/* ========================================
   Language Selector
   ======================================== */
.language-selector {
    position: relative;
    margin-right: auto;
    margin-left: 24px;
}

.language-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    color: var(--foreground);
    cursor: pointer;
    transition: all var(--transition);
}

.language-btn:hover {
    border-color: var(--primary);
    background: rgba(76, 175, 80, 0.05);
}

.language-btn .chevron {
    transition: transform var(--transition);
}

.language-selector.open .language-btn .chevron {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 150px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: 0 10px 40px var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition);
    z-index: 100;
    overflow: hidden;
}

.language-selector.open .language-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.language-option {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--foreground);
    background: transparent;
    border: none;
    cursor: pointer;
    transition: background var(--transition);
    text-align: left;
}

.language-option:hover {
    background: rgba(76, 175, 80, 0.08);
}

.language-option.active {
    background: rgba(76, 175, 80, 0.12);
    color: var(--primary);
}

.lang-flag {
    font-size: 18px;
    line-height: 1;
}

.mobile-menu {
    display: none;
    flex-direction: column;
    gap: 16px;
    padding: 20px;
    margin-top: 8px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 40px var(--shadow-lg);
}

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

.mobile-link {
    padding: 12px 0;
    font-weight: 500;
    color: var(--foreground-light);
    transition: color var(--transition);
}

.mobile-link:hover {
    color: var(--primary);
}

.hidden {
    display: none !important;
}

/* ========================================
   Buttons
   ======================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px 24px;
    font-weight: 600;
    border-radius: 999px;
    transition: all var(--transition);
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 14px rgba(76, 175, 80, 0.4);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.5);
}

.btn-dark {
    background: var(--foreground);
    color: white;
    box-shadow: 0 4px 20px var(--shadow-lg);
}

.btn-dark:hover {
    background: #2a2a2a;
    transform: translateY(-2px);
    box-shadow: 0 8px 30px var(--shadow-lg);
}

.btn-outline {
    background: var(--card);
    color: var(--foreground);
    border: 2px solid var(--border);
}

.btn-outline:hover {
    border-color: var(--primary);
    background: rgba(76, 175, 80, 0.05);
}

.btn-white {
    background: white;
    color: var(--primary);
    box-shadow: 0 4px 20px var(--shadow-lg);
}

.btn-white:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px var(--shadow-lg);
}

.btn-large {
    padding: 16px 32px;
    font-size: 16px;
    border-radius: var(--radius-lg);
}

.btn-nav {
    padding: 10px 24px;
}

.btn-mobile {
    width: 100%;
    padding: 14px 24px;
    text-align: center;
}

.btn-text-group {
    text-align: left;
}

.btn-text-small {
    display: block;
    font-size: 12px;
    opacity: 0.8;
    font-weight: 400;
}

.btn-text-large {
    display: block;
    font-size: 18px;
    font-weight: 600;
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    padding-top: 80px;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.1) 0%, var(--background) 50%, rgba(46, 125, 50, 0.05) 100%);
}

.hero-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
}

.hero-blob-1 {
    top: 80px;
    right: 0;
    width: 400px;
    height: 400px;
    background: rgba(76, 175, 80, 0.2);
}

.hero-blob-2 {
    bottom: 80px;
    left: 0;
    width: 320px;
    height: 320px;
    background: rgba(46, 125, 50, 0.15);
}

.hero-content {
    position: relative;
    z-index: 10;
}

.hero-grid {
    display: grid;
    gap: 48px;
    align-items: center;
}

.hero-text {
    text-align: center;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(76, 175, 80, 0.1);
    color: var(--primary);
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 24px;
}

.hero-title {
    font-size: 40px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    text-wrap: balance;
}

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

.text-accent {
    color: var(--accent);
}

.hero-description {
    font-size: 18px;
    color: var(--foreground-light);
    margin-bottom: 32px;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
    text-wrap: pretty;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 16px;
    justify-content: center;
}

/* Hero Phone */
.hero-phone {
    display: flex;
    justify-content: center;
}

.phone-mockup {
    position: relative;
}

.phone-glow {
    position: absolute;
    inset: 0;
    background: rgba(76, 175, 80, 0.2);
    border-radius: var(--radius-xl);
    filter: blur(40px);
    transform: scale(0.9);
}

.phone-frame {
    position: relative;
    background: var(--foreground);
    border-radius: var(--radius-xl);
    padding: 12px;
    box-shadow: 0 25px 50px -12px var(--shadow-lg);
}

.phone-screen {
    background: var(--card);
    border-radius: 40px;
    overflow: hidden;
    width: 260px;
}

.phone-screen img {
    width: 100%;
    height: auto;
}

/* Animation */
.animate-float {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--foreground-light);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}

/* ========================================
   Sections
   ======================================== */
.section {
    padding: 80px 0;
}

.section-alt {
    background: var(--card);
}

.section-header {
    text-align: center;
    margin-bottom: 64px;
}

.section-label {
    display: inline-block;
    color: var(--primary);
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}

.section-label.accent {
    color: var(--accent);
}

.section-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
    text-wrap: balance;
}

.section-title-left {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
    text-wrap: balance;
}

.section-description {
    font-size: 18px;
    color: var(--foreground-light);
    max-width: 600px;
    margin: 0 auto;
}

.section-description-left {
    font-size: 18px;
    color: var(--foreground-light);
    margin-bottom: 40px;
}

/* ========================================
   Features Section
   ======================================== */
.features-grid {
    display: grid;
    gap: 48px;
    align-items: center;
}

.features-phone {
    display: flex;
    justify-content: center;
    order: 2;
}

.phone-mockup-small {
    position: relative;
}

.phone-glow-small {
    position: absolute;
    inset: 0;
    background: rgba(76, 175, 80, 0.1);
    border-radius: var(--radius-xl);
    filter: blur(30px);
    transform: scale(0.95);
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    order: 1;
}

.feature-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    border-radius: var(--radius-lg);
    border: 2px solid transparent;
    background: var(--background);
    text-align: left;
    transition: all var(--transition);
}

.feature-item:hover {
    border-color: var(--border);
    background: rgba(76, 175, 80, 0.02);
}

.feature-item.active {
    background: rgba(76, 175, 80, 0.1);
    border-color: var(--primary);
    box-shadow: 0 4px 20px rgba(76, 175, 80, 0.15);
}

.feature-number {
    width: 48px;
    height: 48px;
    border-radius: var(--radius);
    background: var(--border);
    color: var(--foreground-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    flex-shrink: 0;
    transition: all var(--transition);
}

.feature-item.active .feature-number {
    background: var(--primary);
    color: white;
}

.feature-content {
    flex: 1;
}

.feature-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 4px;
    transition: color var(--transition);
}

.feature-item.active .feature-title {
    color: var(--primary);
}

.feature-description {
    font-size: 14px;
    color: var(--foreground-light);
}

/* ========================================
   Two Column Layout
   ======================================== */
.two-column-grid {
    display: grid;
    gap: 48px;
    align-items: center;
}

.column-text {
    order: 1;
}

.column-images {
    order: 2;
}

.two-column-grid.reverse .column-text {
    order: 2;
}

.two-column-grid.reverse .column-images {
    order: 1;
}

.images-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.image-card {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 16px;
    box-shadow: 0 4px 20px var(--shadow);
    border: 1px solid var(--border);
}

.image-card img {
    border-radius: var(--radius);
}

.image-card.offset {
    margin-top: 32px;
}

/* Benefits List */
.benefits-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.benefit-item {
    display: flex;
    gap: 16px;
}

.benefit-icon {
    width: 48px;
    height: 48px;
    background: rgba(76, 175, 80, 0.1);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    flex-shrink: 0;
}

.benefit-icon.accent {
    background: rgba(46, 125, 50, 0.1);
    color: var(--accent);
}

.benefit-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.benefit-description {
    font-size: 14px;
    color: var(--foreground-light);
}

/* ========================================
   CTA Section
   ======================================== */
.cta-section {
    position: relative;
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    overflow: hidden;
}

.cta-bg {
    position: absolute;
    inset: 0;
}

.cta-blob {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    filter: blur(60px);
}

.cta-blob-1 {
    top: 0;
    left: 0;
    width: 400px;
    height: 400px;
    transform: translate(-50%, -50%);
}

.cta-blob-2 {
    bottom: 0;
    right: 0;
    width: 320px;
    height: 320px;
    transform: translate(50%, 50%);
}

.cta-content {
    position: relative;
    z-index: 10;
    text-align: center;
}

.cta-title {
    font-size: 32px;
    font-weight: 700;
    color: white;
    margin-bottom: 16px;
    text-wrap: balance;
}

.cta-description {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 32px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: var(--foreground);
    color: white;
    padding: 48px 0;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.footer-logo .logo-text {
    color: white;
}

.footer-links {
    display: flex;
    gap: 32px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    transition: color var(--transition);
}

.footer-links a:hover {
    color: white;
}

.footer-copyright {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
}

/* ========================================
   Responsive Design
   ======================================== */

/* Tablet */
@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }

    .mobile-menu-btn {
        display: none;
    }

    .language-selector {
        margin-left: 0;
        margin-right: 0;
    }

    .hero-title {
        font-size: 56px;
    }

    .hero-buttons {
        flex-direction: row;
    }

    .phone-screen {
        width: 288px;
    }

    .section {
        padding: 120px 0;
    }

    .section-title,
    .section-title-left {
        font-size: 40px;
    }

    .cta-title {
        font-size: 40px;
    }

    .footer-content {
        flex-direction: row;
        justify-content: space-between;
    }
}

/* Desktop */
@media (min-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr 1fr;
    }

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

    .hero-description {
        margin-left: 0;
        margin-right: 0;
    }

    .hero-buttons {
        justify-content: flex-start;
    }

    .hero-phone {
        justify-content: flex-end;
    }

    .hero-title {
        font-size: 64px;
    }

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

    .features-phone {
        order: 1;
    }

    .features-list {
        order: 2;
    }

    .two-column-grid {
        grid-template-columns: 1fr 1fr;
        gap: 64px;
    }

    .two-column-grid.reverse .column-text {
        order: 2;
    }

    .two-column-grid.reverse .column-images {
        order: 1;
    }

    .section-title,
    .section-title-left {
        font-size: 48px;
    }

    .cta-section {
        padding: 120px 0;
    }

    .cta-title {
        font-size: 48px;
    }
}
