/* ========================================
   MentorPlay Website Styles
   Matching iOS App Design System
   ======================================== */

/* ========== CSS Variables (App Colors) ========== */
:root {
    /* Premium Brand Colors */
    --primary-orange: #FF6B35;
    --primary-yellow: #F7B801;
    --warm-orange: #FF6B35;
    --warm-yellow: #F7B801;
    --primary-gradient: linear-gradient(135deg, #FF6B35 0%, #F7B801 100%);

    /* Dark Theme Base */
    --bg-dark: #0F1115;
    --bg-card: rgba(255, 255, 255, 0.03);
    --bg-glass: rgba(255, 255, 255, 0.05);

    /* Text Colors */
    --text-primary: #FFFFFF;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-tertiary: rgba(255, 255, 255, 0.4);

    /* Accents */
    --accent-success: #48BB78;
    --accent-glow: rgba(255, 107, 53, 0.3);

    /* Glassmorphism */
    --glass-border: 1px solid rgba(255, 255, 255, 0.1);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --backdrop-blur: blur(12px);
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.15);

    /* Spacing System (8px base) */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-xxl: 48px;
    --spacing-xxxl: 64px;

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    /* Spacing & Layout */
    --container-width: 1200px;
    --header-height: 80px;

    /* Animation */
    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-spring: cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --transition-fast: 0.15s;
    --transition-base: 0.3s;
    --transition-slow: 0.5s;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-primary);
    background: var(--bg-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* ========== Typography ========== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'DM Serif Display', serif;
    line-height: 1.2;
    font-weight: 400;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

@media (max-width: 768px) {
    .container {
        padding: 0 var(--spacing-md);
    }
}

/* ========== Navigation ========== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: rgba(15, 17, 21, 0.8);
    backdrop-filter: var(--backdrop-blur);
    border-bottom: var(--glass-border);
    z-index: 1000;
    transition: all 0.3s var(--ease-out-expo);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    position: relative;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text-primary);
}

.logo-icon {
    font-size: 28px;
}

.logo-text {
    font-family: 'DM Serif Display', serif;
    font-size: 24px;
    color: var(--text-primary);
    letter-spacing: 0.5px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
}

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

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

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

.nav-links {
    display: flex;
    list-style: none;
    gap: var(--spacing-xl);
    align-items: center;
}

.nav-links li {
    white-space: nowrap;
}

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

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

.nav-links a:not(.btn):hover {
    color: var(--text-primary);
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
}

/* ========== Buttons ========== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    min-height: 44px; /* iOS minimum touch target */
    border-radius: 100px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s var(--ease-out-expo);
    cursor: pointer;
    border: none;
    font-size: 15px;
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
}

.btn:active {
    transform: scale(0.97);
}

.btn:focus-visible {
    outline: 3px solid rgba(255, 107, 53, 0.5);
    outline-offset: 2px;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 4px 20px rgba(255, 107, 53, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 107, 53, 0.5);
}

.btn-primary:active {
    transform: translateY(0) scale(0.97);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.btn-white {
    background: white;
    color: var(--bg-dark);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.btn-white:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 255, 255, 0.3);
}

.btn-large {
    padding: 16px 32px;
    font-size: 17px;
    min-height: 52px;
}

/* ========== Hero Section ========== */
/* ========== Hero Section ========== */
.hero {
    padding: 180px 0 100px;
    background: radial-gradient(circle at 50% 0%, #1a1d26 0%, var(--bg-dark) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: var(--primary-orange);
    filter: blur(150px);
    opacity: 0.15;
    border-radius: 50%;
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -10%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: var(--primary-yellow);
    filter: blur(150px);
    opacity: 0.1;
    border-radius: 50%;
    pointer-events: none;
}

.hero-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 64px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 72px;
    margin-bottom: 24px;
    line-height: 1.05;
    color: var(--text-primary);
}

.gradient-text {
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.6;
    max-width: 540px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    margin-bottom: 64px;
}

.hero-stats {
    display: flex;
    gap: 48px;
    padding: 32px;
    background: var(--bg-glass);
    border: var(--glass-border);
    border-radius: 24px;
    backdrop-filter: var(--backdrop-blur);
}

.stat {
    text-align: left;
}

.stat-number {
    font-size: 36px;
    font-family: 'DM Serif Display', serif;
    color: var(--text-primary);
    margin-bottom: 4px;
    background: none;
    -webkit-text-fill-color: var(--text-primary);
}

.stat-label {
    color: var(--text-tertiary);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-top: 0;
}

/* Phone Mockup */
.phone-mockup {
    position: relative;
    width: 320px;
    height: 640px;
    margin: 0 auto;
    border-radius: 48px;
    background: #2a2a2a;
    padding: 12px;
    box-shadow:
        0 0 0 2px #3a3a3a,
        0 20px 50px -10px rgba(0, 0, 0, 0.5);
    transform: perspective(1000px) rotateY(-10deg) rotateX(5deg);
    transition: transform 0.5s var(--ease-out-expo);
}

.phone-mockup:hover {
    transform: perspective(1000px) rotateY(-5deg) rotateX(2deg) translateY(-10px);
}

.phone-screen {
    width: 100%;
    height: 100%;
    border-radius: 36px;
    background: #000;
    overflow: hidden;
    position: relative;
}

.screen-content {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #1a1d26 0%, #000 100%);
}

.app-preview {
    text-align: center;
}

.preview-text {
    font-size: 48px;
    opacity: 0.5;
}

/* ========== Features Section ========== */
.features {
    padding: var(--spacing-xxxl) 0;
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-xxxl);
}

.section-title {
    font-size: 48px;
    margin-bottom: var(--spacing-md);
}

.section-subtitle {
    font-size: 20px;
    color: var(--text-secondary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-xl);
}

.feature-card {
    background: var(--bg-card);
    padding: 40px;
    border-radius: 24px;
    border: var(--glass-border);
    transition: all 0.4s var(--ease-out-expo);
}

.feature-card:hover {
    transform: translateY(-10px);
    background: var(--bg-glass);
    box-shadow: var(--glass-shadow);
    border-color: rgba(255, 255, 255, 0.2);
}

.feature-icon {
    font-size: 48px;
    margin-bottom: 24px;
    background: var(--bg-glass);
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
}

.feature-title {
    font-size: 24px;
    margin-bottom: 12px;
    color: var(--text-primary);
}

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

/* ========== How It Works Section ========== */
.how-it-works {
    padding: 100px 0;
    background: linear-gradient(180deg, var(--bg-dark) 0%, #151820 100%);
}

.steps {
    max-width: 800px;
    margin: 0 auto;
}

.step {
    display: flex;
    gap: var(--spacing-xl);
    margin-bottom: var(--spacing-xxxl);
    align-items: flex-start;
}

.step:last-child {
    margin-bottom: 0;
}

.step-number {
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-family: 'DM Serif Display', serif;
    background: linear-gradient(135deg, var(--warm-orange) 0%, var(--warm-yellow) 100%);
    color: white;
    border-radius: 50%;
    box-shadow: var(--shadow-soft);
}

.step-content {
    flex: 1;
}

.step-title {
    font-size: 28px;
    margin-bottom: var(--spacing-sm);
}

.step-description {
    color: var(--text-secondary);
    font-size: 18px;
    line-height: 1.7;
}

/* ========== Mentors Section ========== */
.mentors {
    padding: var(--spacing-xxxl) 0;
}

.mentor-highlights {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-lg);
}

.highlight-card {
    background: var(--bg-card);
    padding: 32px;
    border-radius: 24px;
    border: var(--glass-border);
    text-align: center;
    transition: all 0.4s var(--ease-out-expo);
}

.highlight-card:hover {
    transform: translateY(-10px);
    background: var(--bg-glass);
    box-shadow: var(--glass-shadow);
}

.highlight-icon {
    font-size: 56px;
    margin-bottom: 24px;
    display: inline-block;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.2));
}

.highlight-stat {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.highlight-text {
    color: var(--text-secondary);
    font-size: 14px;
}

/* ========== CTA Section ========== */
.cta {
    padding: var(--spacing-xxxl) 0;
    background: linear-gradient(135deg, var(--warm-orange) 0%, var(--warm-yellow) 100%);
    color: white;
}

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

.cta-title {
    font-size: 48px;
    margin-bottom: var(--spacing-md);
    color: white;
}

.cta-subtitle {
    font-size: 20px;
    margin-bottom: var(--spacing-xl);
    opacity: 0.9;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
}

.cta-note {
    opacity: 0.8;
    font-size: 14px;
}

.waitlist-form {
    display: flex;
    gap: var(--spacing-md);
    max-width: 600px;
    margin: 0 auto var(--spacing-lg);
}

.waitlist-input {
    flex: 1;
    padding: var(--spacing-md) var(--spacing-lg);
    min-height: 52px;
    border-radius: var(--radius-md);
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 16px;
    transition: all 0.3s ease;
    -webkit-appearance: none;
}

.waitlist-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.waitlist-input:focus {
    outline: none;
    border-color: white;
    background: rgba(255, 255, 255, 0.2);
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.1);
}

.waitlist-input.error {
    border-color: #FF4444;
    animation: shake 0.3s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

.stat-number {
    font-size: 48px;
    font-family: 'DM Serif Display', serif;
    background: linear-gradient(135deg, var(--warm-orange) 0%, var(--warm-yellow) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

/* ========== Footer ========== */
.footer {
    background: #000;
    color: white;
    padding: 80px 0 40px;
    border-top: var(--glass-border);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: var(--spacing-xxxl);
    margin-bottom: var(--spacing-xl);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
}

.footer-tagline {
    color: var(--text-tertiary);
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-xl);
}

.footer-heading {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    color: white;
}

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

.footer-column li {
    margin-bottom: var(--spacing-sm);
}

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

.footer-column a:hover {
    color: var(--warm-orange);
}

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

/* ========== Responsive Design ========== */
@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: var(--header-height);
        left: 0;
        right: 0;
        background: rgba(15, 17, 21, 0.98);
        backdrop-filter: var(--backdrop-blur);
        flex-direction: column;
        padding: 24px;
        gap: 24px;
        border-bottom: var(--glass-border);
        transform: translateY(-100%);
        opacity: 0;
        transition: all 0.3s var(--ease-out-expo);
        pointer-events: none;
        max-height: calc(100vh - var(--header-height));
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }

    .nav-links li {
        width: 100%;
        text-align: center;
        opacity: 0;
        transform: translateY(-20px);
        animation: slideDown 0.3s forwards;
    }

    .nav-links.active li:nth-child(1) { animation-delay: 0.05s; }
    .nav-links.active li:nth-child(2) { animation-delay: 0.1s; }
    .nav-links.active li:nth-child(3) { animation-delay: 0.15s; }
    .nav-links.active li:nth-child(4) { animation-delay: 0.2s; }

    @keyframes slideDown {
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .nav-links .btn {
        width: 100%;
        justify-content: center;
    }

    .hero {
        padding: 140px 0 60px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
    }

    .hero-title {
        font-size: 36px;
        margin-bottom: 16px;
        text-align: center;
    }

    .hero-subtitle {
        font-size: 16px;
        margin-bottom: 32px;
        text-align: center;
    }

    .hero-image {
        order: -1;
        display: flex;
        justify-content: center;
    }

    .phone-mockup {
        width: 220px;
        height: 440px;
        transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
    }

    .phone-mockup:hover {
        transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .hero-buttons .btn {
        width: 100%;
    }

    .hero-stats {
        flex-direction: row;
        gap: 16px;
        text-align: center;
        padding: 20px;
        width: 100%;
        justify-content: space-between;
    }

    .stat {
        text-align: center;
        flex: 1;
    }

    .stat-number {
        font-size: 24px;
    }

    .stat-label {
        font-size: 11px;
    }

    .features {
        padding: 60px 0;
    }

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

    .feature-card {
        padding: 28px;
    }

    .mentor-highlights {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .highlight-card {
        padding: 24px;
    }

    .highlight-icon {
        font-size: 48px;
    }

    .highlight-stat {
        font-size: 18px;
    }

    .footer {
        padding: 60px 0 32px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-xxl);
    }

    .footer-links {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }

    .section-header {
        margin-bottom: 40px;
    }

    .section-title {
        font-size: 32px;
    }

    .section-subtitle {
        font-size: 16px;
    }

    .btn-large {
        padding: 14px 28px;
        font-size: 16px;
    }

    .waitlist-form {
        flex-direction: column;
        max-width: 100%;
        gap: 12px;
    }

    .waitlist-input {
        width: 100%;
    }

    .cta {
        padding: 60px 0;
    }

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

    .cta-subtitle {
        font-size: 16px;
    }

    .how-it-works {
        padding: 60px 0;
    }

    .steps {
        max-width: 100%;
    }

    .step {
        gap: var(--spacing-md);
        margin-bottom: var(--spacing-xxl);
    }

    .step-number {
        width: 48px;
        height: 48px;
        font-size: 24px;
    }

    .step-title {
        font-size: 22px;
    }

    .step-description {
        font-size: 15px;
    }

    .feature-icon {
        font-size: 40px;
        width: 72px;
        height: 72px;
    }

    .feature-title {
        font-size: 20px;
    }

    .container {
        padding: 0 var(--spacing-md);
    }

    .legal-page {
        padding: 100px var(--spacing-md) 48px;
    }
}

/* Tablet optimization */
@media (min-width: 769px) and (max-width: 1024px) {
    .hero-title {
        font-size: 56px;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .mentor-highlights {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========== Legal Pages Shared Styles ========== */
.legal-page {
    padding: 120px var(--spacing-lg) 64px;
    max-width: 800px;
    margin: 0 auto;
}

.legal-page h1 {
    font-size: 48px;
    margin-bottom: 16px;
}

.legal-page h2 {
    font-size: 32px;
    margin-top: 48px;
    margin-bottom: 16px;
}

.legal-page p {
    margin-bottom: 16px;
    line-height: 1.8;
    color: var(--text-secondary);
}

.legal-page ul {
    margin-bottom: 16px;
    padding-left: 32px;
}

.legal-page li {
    margin-bottom: 8px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ========== Animations ========== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.feature-card,
.step,
.highlight-card {
    animation: fadeIn 0.6s ease-out;
}

/* Scroll reveal animations */
.reveal-element {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s var(--ease-out-expo);
}

.reveal-element.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Performance optimization */
.btn,
.feature-card,
.highlight-card,
.phone-mockup {
    will-change: transform;
}

/* Accessibility - Skip to content link */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--primary-orange);
    color: white;
    padding: 12px 24px;
    text-decoration: none;
    z-index: 10000;
    border-radius: 0 0 8px 0;
    font-weight: 600;
}

.skip-link:focus {
    top: 0;
}

/* Focus visible for links */
a:focus-visible {
    outline: 2px solid var(--primary-orange);
    outline-offset: 4px;
    border-radius: 4px;
}

/* Smooth loading state */
.loading {
    pointer-events: none;
    opacity: 0.6;
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Success feedback animation */
@keyframes successPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.success-feedback {
    animation: successPulse 0.3s ease;
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}