/* ========================================
   SpellFlare - Landing Page Styles
   Color Palette matches the app:
   - Primary: Purple gradient (#4B1A8F to #6B2EB5)
   - Accent: Cyan (#00D4FF)
   - Background: Dark purple (#1A0A2E)
   ======================================== */

:root {
    --primary-dark: #1A0A2E;
    --primary-purple: #4B1A8F;
    --primary-light: #6B2EB5;
    --accent-cyan: #00D4FF;
    --accent-cyan-light: #5CE1FF;
    --white: #FFFFFF;
    --white-dim: rgba(255, 255, 255, 0.8);
    --white-muted: rgba(255, 255, 255, 0.6);
    --card-bg: rgba(255, 255, 255, 0.1);
    --card-border: rgba(255, 255, 255, 0.2);
    --success-green: #4CAF50;
    --font-family: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background: var(--primary-dark);
    color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

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

/* ========================================
   Navigation
   ======================================== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: background 0.3s ease;
}

.navbar.scrolled {
    background: rgba(26, 10, 46, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 800;
}

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

.logo-text {
    background: linear-gradient(135deg, var(--accent-cyan), var(--white));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

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

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

/* ========================================
   Hero Section
   ======================================== */
.hero {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary-purple) 0%, var(--primary-light) 50%, var(--primary-dark) 100%);
    position: relative;
    overflow: hidden;
    padding: 120px 40px 60px;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    gap: 60px;
    position: relative;
    z-index: 10;
}

.hero-text {
    flex: 1;
    max-width: 550px;
}

.hero-text h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
}

.highlight {
    color: var(--accent-cyan);
    text-shadow: 0 0 30px rgba(0, 212, 255, 0.5);
}

.tagline {
    font-size: 1.3rem;
    color: var(--white-dim);
    margin-bottom: 30px;
}

.hero-features {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 40px;
}

.hero-feature {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.1rem;
}

.check-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--accent-cyan);
    color: var(--primary-dark);
    border-radius: 50%;
    font-weight: bold;
    font-size: 0.9rem;
}

.hero-image {
    flex: 1;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 20px;
    position: relative;
}

.phone-mockup {
    width: 280px;
    height: 580px;
    background: #1a1a1a;
    border-radius: 40px;
    padding: 10px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4);
    overflow: hidden;
}

.phone-mockup img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 30px;
}

.watch-mockup {
    width: 160px;
    height: 190px;
    background: #1a1a1a;
    border-radius: 35px;
    padding: 8px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    overflow: hidden;
    position: relative;
    top: -30px;
}

.watch-mockup img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 28px;
}

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

.app-store-btn img {
    height: 50px;
    transition: transform 0.3s ease;
}

.app-store-btn:hover img {
    transform: scale(1.05);
}

/* Floating Elements Animation */
.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.float-letter, .float-star {
    position: absolute;
    left: var(--x);
    top: var(--y);
    font-size: 3rem;
    opacity: 0.15;
    animation: float 6s ease-in-out infinite;
    animation-delay: var(--delay);
}

.float-letter {
    font-weight: 800;
    color: var(--accent-cyan);
}

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

/* ========================================
   Section Styles
   ======================================== */
section {
    padding: 100px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 15px;
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--white-muted);
    text-align: center;
    margin-bottom: 60px;
}

/* ========================================
   Features Section
   ======================================== */
.features-section {
    background: linear-gradient(180deg, var(--primary-dark) 0%, #2A1245 100%);
}

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

.feature-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 212, 255, 0.1);
    border-color: var(--accent-cyan);
}

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

.feature-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--accent-cyan);
}

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

/* ========================================
   Screenshots Section
   ======================================== */
.screenshots-section {
    background: var(--primary-dark);
}

.device-title {
    font-size: 1.5rem;
    color: var(--accent-cyan);
    text-align: center;
    margin: 40px 0 25px;
    font-weight: 700;
}

.device-title:first-of-type {
    margin-top: 0;
}

.screenshots-tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 40px;
}

.tab-btn {
    padding: 12px 30px;
    border: 2px solid var(--card-border);
    background: transparent;
    color: var(--white);
    font-family: var(--font-family);
    font-size: 1rem;
    font-weight: 600;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    border-color: var(--accent-cyan);
}

.tab-btn.active {
    background: var(--accent-cyan);
    border-color: var(--accent-cyan);
    color: var(--primary-dark);
}

.screenshots-row {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.screenshots-row.hidden {
    display: none;
}

.screenshot-item {
    text-align: center;
}

.screenshot-img {
    object-fit: contain;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    border: 3px solid var(--card-border);
    background: #1a1a1a;
}

.screenshot-img.iphone {
    width: 200px;
    height: 430px;
    border-radius: 25px;
}

.screenshot-img.watch {
    width: 140px;
    height: 170px;
    border-radius: 35px;
}

/* Placeholder for missing images */
.screenshot-item img[src=""],
.screenshot-item img:not([src]),
.screenshot-item img[src*="placeholder"] {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Image placeholder fallback */
.screenshot-item img {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-light));
    object-fit: cover;
}

.phone-mockup img,
.watch-mockup img {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-light));
}

/* Screenshot Placeholders */
.screenshot-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-light));
    border: 3px solid var(--card-border);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.screenshot-placeholder.iphone {
    width: 200px;
    height: 430px;
    border-radius: 25px;
}

.screenshot-placeholder.watch {
    width: 140px;
    height: 170px;
    border-radius: 30px;
}

.placeholder-emoji {
    font-size: 50px;
    margin-bottom: 10px;
}

.screenshot-placeholder.watch .placeholder-emoji {
    font-size: 35px;
    margin-bottom: 5px;
}

.placeholder-text {
    font-size: 14px;
    font-weight: 600;
    color: var(--white);
}

.screenshot-placeholder.watch .placeholder-text {
    font-size: 11px;
}

/* Hero Mockup Placeholders */
.mockup-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-light));
    border-radius: 30px;
}

.mockup-placeholder.watch {
    border-radius: 28px;
}

.mockup-emoji {
    font-size: 60px;
    margin-bottom: 15px;
    animation: bounce 2s ease-in-out infinite;
}

.mockup-placeholder.watch .mockup-emoji {
    font-size: 40px;
    margin-bottom: 8px;
}

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

.mockup-title {
    font-size: 24px;
    font-weight: 800;
    color: var(--white);
    text-align: center;
}

.mockup-subtitle {
    font-size: 18px;
    font-weight: 600;
    color: var(--accent-cyan);
    margin-top: 5px;
}

.mockup-placeholder.watch .mockup-subtitle {
    font-size: 12px;
}

.mockup-levels {
    display: flex;
    gap: 8px;
    margin-top: 30px;
}

.level-dot {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.level-dot.active {
    background: var(--accent-cyan);
    border-color: var(--accent-cyan);
}

.screenshot-caption {
    margin-top: 15px;
    font-weight: 600;
    color: var(--white-muted);
}

/* ========================================
   Grades Section
   ======================================== */
.grades-section {
    background: linear-gradient(180deg, #2A1245 0%, var(--primary-dark) 100%);
}

.grades-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.grade-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.grade-card:hover {
    transform: scale(1.02);
    border-color: var(--accent-cyan);
}

.grade-card.featured {
    border: 2px solid var(--accent-cyan);
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.2);
}

.grade-card.featured::before {
    content: '🏆 Challenge';
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 0.75rem;
    background: var(--accent-cyan);
    color: var(--primary-dark);
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 700;
}

.grade-number {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-cyan-light));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin: 0 auto 20px;
}

.grade-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.grade-card p {
    color: var(--white-muted);
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.word-examples {
    font-style: italic;
    color: var(--accent-cyan);
    font-size: 0.9rem;
}

/* ========================================
   How It Works Section
   ======================================== */
.how-it-works {
    background: var(--primary-dark);
}

.steps-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 40px;
}

.step {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    width: 280px;
}

.step-number {
    width: 50px;
    height: 50px;
    background: var(--accent-cyan);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-dark);
    margin: 0 auto 20px;
}

.step h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: var(--accent-cyan);
}

.step p {
    color: var(--white-muted);
}

.step-arrow {
    font-size: 2rem;
    color: var(--accent-cyan);
}

/* ========================================
   Privacy Section
   ======================================== */
.privacy-section {
    background: linear-gradient(180deg, var(--primary-dark) 0%, #2A1245 100%);
}

.privacy-content {
    max-width: 900px;
    margin: 0 auto;
}

.privacy-card.main {
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.2), rgba(107, 46, 181, 0.2));
    border: 1px solid var(--accent-cyan);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    margin-bottom: 40px;
}

.privacy-card.main h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.privacy-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 50px;
}

.privacy-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 15px;
    padding: 20px;
}

.privacy-item.safe .icon {
    background: var(--success-green);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    flex-shrink: 0;
}

.privacy-item h4 {
    font-size: 1rem;
    margin-bottom: 5px;
}

.privacy-item p {
    font-size: 0.9rem;
    color: var(--white-muted);
}

.permissions-section {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 30px;
}

.permissions-section h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    text-align: center;
}

.permissions-intro {
    text-align: center;
    color: var(--white-muted);
    margin-bottom: 30px;
}

.permission-item {
    display: flex;
    gap: 20px;
    padding: 25px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 15px;
    margin-bottom: 20px;
}

.permission-item:last-child {
    margin-bottom: 0;
}

.permission-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.permission-details h4 {
    font-size: 1.2rem;
    color: var(--accent-cyan);
    margin-bottom: 10px;
}

.permission-details p {
    margin-bottom: 8px;
    color: var(--white-dim);
    font-size: 0.95rem;
}

.permission-details p strong {
    color: var(--white);
}

.privacy-policy-link {
    text-align: center;
}

.btn-secondary {
    display: inline-block;
    padding: 15px 40px;
    border: 2px solid var(--accent-cyan);
    color: var(--accent-cyan);
    text-decoration: none;
    font-weight: 700;
    border-radius: 30px;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: var(--accent-cyan);
    color: var(--primary-dark);
}

/* ========================================
   Testimonials Section
   ======================================== */
.testimonials-section {
    background: var(--primary-dark);
}

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

.testimonial-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 30px;
}

.stars {
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.testimonial-card p {
    font-size: 1.1rem;
    font-style: italic;
    color: var(--white-dim);
    margin-bottom: 20px;
    line-height: 1.7;
}

.testimonial-author {
    color: var(--accent-cyan);
    font-weight: 600;
}

/* ========================================
   Contact Section
   ======================================== */
.contact-section {
    background: linear-gradient(180deg, #2A1245 0%, var(--primary-dark) 100%);
}

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

.contact-info {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 25px;
    padding: 50px 40px;
    margin-bottom: 30px;
}

.bee-mascot {
    font-size: 4rem;
    margin-bottom: 20px;
}

.contact-info h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.contact-info > p {
    color: var(--white-muted);
    margin-bottom: 30px;
    line-height: 1.7;
}

.email-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 18px 40px;
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-cyan-light));
    color: var(--primary-dark);
    text-decoration: none;
    font-weight: 700;
    font-size: 1.1rem;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

.email-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 212, 255, 0.4);
}

.email-icon {
    font-size: 1.3rem;
}

.email-note {
    margin-top: 15px;
    font-size: 0.9rem;
    color: var(--white-muted);
}

.contact-topics {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 30px;
    text-align: left;
}

.contact-topics h4 {
    margin-bottom: 15px;
    color: var(--accent-cyan);
}

.contact-topics ul {
    list-style: none;
}

.contact-topics li {
    padding: 10px 0;
    color: var(--white-dim);
    border-bottom: 1px solid var(--card-border);
}

.contact-topics li:last-child {
    border-bottom: none;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: rgba(0, 0, 0, 0.3);
    padding: 50px 0 30px;
}

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

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    font-weight: 700;
}

.footer-links {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: var(--white-muted);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--accent-cyan);
}

.footer-copyright {
    text-align: center;
    color: var(--white-muted);
    font-size: 0.9rem;
}

.footer-copyright p:last-child {
    margin-top: 5px;
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 992px) {
    .hero-content {
        flex-direction: column;
        text-align: center;
    }

    .hero-text {
        max-width: 100%;
    }

    .hero-features {
        align-items: center;
    }

    .hero-image {
        margin-top: 40px;
    }

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

    .watch-mockup {
        width: 130px;
        height: 155px;
    }

    .nav-links {
        display: none;
    }

    .steps-container {
        flex-direction: column;
    }

    .step-arrow {
        transform: rotate(90deg);
    }
}

@media (max-width: 768px) {
    .hero {
        padding: 100px 20px 40px;
    }

    .hero-text h1 {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .navbar {
        padding: 15px 20px;
    }

    .screenshot-img.iphone {
        width: 160px;
        height: 345px;
    }

    .screenshot-img.watch {
        width: 120px;
        height: 145px;
    }

    .permission-item {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 2rem;
    }

    .phone-mockup {
        width: 200px;
        height: 420px;
    }

    .watch-mockup {
        width: 100px;
        height: 120px;
    }

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