/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #742ad9;
    --primary-hover: #5d22ad;
    --secondary-color: #64748b;
    --accent-color: #EC4899;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --bg-primary: #ffffff;
    --bg-secondary: #fafafa;
    --bg-accent: #f8fafc;
    --border-color: #e2e8f0;
    --success-color: #10b981;
    --gradient-primary: linear-gradient(135deg, #742ad9 0%, #EC4899 100%);
    --gradient-secondary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-background: linear-gradient(135deg, #f8fafc 0%, #faf5ff 50%, #fdf2f8 100%);
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-colored: 0 10px 25px -5px rgb(116 42 217 / 0.3), 0 8px 10px -6px rgb(116 42 217 / 0.1);
    --radius: 0.75rem;
    --radius-lg: 1rem;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    font-size: 16px;
}

.chinese {
    font-family: 'Noto Sans SC', 'Microsoft YaHei', sans-serif;
}

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

/* Navigation */
.nav {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(116, 42, 217, 0.1);
    z-index: 100;
    transition: all 0.3s ease;
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 4.5rem;
    position: relative;
    padding-bottom: 0;
}

.nav-buttons {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-image {
    width: 48px;
    height: 48px;
    border-radius: 8px;
}

.logo-text {
    font-size: 1.75rem;
    font-weight: 800;
    color: #000000;
}

.logo-chinese {
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: color 0.2s;
}

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

/* Buttons */
.cta-button {
    background: #8B5CF6;
    color: white;
    border: none;
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius);
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 0 var(--primary-hover);
    transform: translateY(0);
}

.cta-button:hover {
    transform: translateY(1px);
    box-shadow: 0 3px 0 var(--primary-hover);
    background: var(--primary-color);
}

.cta-button:active {
    transform: translateY(4px);
    box-shadow: none;
}

.cta-button.large {
    padding: 1rem 2rem;
    font-size: 1rem;
}

.cta-button.primary {
    background: var(--primary-color);
}

.cta-button.white {
    background: white;
    color: #4B5563;
    border: 2px solid #E5E7EB;
    box-shadow: 0 8px 0 #E5E7EB;
}

.cta-button.white:hover {
    transform: translateY(2px);
    box-shadow: 0 6px 0 #E5E7EB;
    background: white;
}

.cta-button.white:active {
    transform: translateY(8px);
    box-shadow: none;
}

/* Hero Section */
.hero {
    padding: 8rem 0 6rem;
    background: var(--bg-primary);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(116, 42, 217, 0.05);
    animation: float 20s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(1deg);
    }
}

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

.hero-title {
    font-size: 3.75rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.025em;
    position: relative;
    z-index: 1;
}

.gradient-text {
    background: linear-gradient(135deg, #C4B5FD 0%, #6D28D9 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: gradientShift 4s ease infinite;
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

.hero-subtitle {
    font-size: 1.375rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    line-height: 1.6;
    font-weight: 400;
    position: relative;
    z-index: 1;
}

.hero-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.stat-number {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

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

/* Mobile Chat Window */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem 0;
    width: 50%;
}

.mobile-chat-window {
    width: 375px;
    height: 80vh;
    max-height: 800px;
    min-height: 600px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
}

/* Chat Header */
.chat-header {
    background: rgba(116, 42, 217, 0.05);
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-bottom: 1px solid #e5e7eb;
    gap: 0;
}

.tutor-avatar {
    width: 56px;
    height: 56px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.tutor-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tutor-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tutor-name {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    display: inline-block;
}

.chat-title {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Chat Area */
.chat-area {
    flex: 1;
    background: white;
    padding: 1rem;
}

/* Chat Message */
.chat-message {
    margin-bottom: 1rem;
    max-width: 80%;
    width: fit-content;
}

.chat-message.student {
    margin-left: auto;
}

.message-content {
    background: oklch(.928 .006 264.531);
    padding: 0.75rem 1rem;
    border-radius: 10px;
    border-bottom-left-radius: 0;
    font-size: 1rem;
    line-height: 1.5;
    color: var(--text-primary);
    text-align: left;
}

.student .message-content {
    background: var(--primary-color);
    color: white;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 0;
}

.student .message-header {
    color: white;
}

.student .sender-name {
    color: white;
}

.student .message-time {
    color: rgba(255, 255, 255, 0.9);
}

.student .pinyin {
    color: rgba(255, 255, 255, 0.8);
}

.student .hanzi {
    color: white;
}

.message-header {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.sender-name,
.message-time {
    color: var(--text-secondary);
}

.message-text {
    line-height: 1.8;
}

/* Chinese Word Display */
.chinese-word {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    margin: 0 0.25rem;
    padding-top: 1rem;
    vertical-align: bottom;
}

.pinyin {
    font-size: 0.875rem;
    color: var(--text-secondary);
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
}

.hanzi {
    font-family: 'Noto Sans SC', 'Geist Sans', system-ui, sans-serif;
    font-size: 1.5rem;
    font-weight: 400;
}

/* Flow Progress Message */
.flow-progress-message {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: oklch(.962 .044 156.743);
    color: oklch(.448 .119 151.328);
    padding: 0.75rem 1rem;
    border-radius: 10px;
    margin: 1rem auto;
    width: fit-content;
    font-weight: 400;
}

.flow-progress-message svg {
    flex-shrink: 0;
}


@keyframes fillDown {
    from {
        transform: scaleY(0);
        transform-origin: top;
    }

    to {
        transform: scaleY(1);
        transform-origin: top;
    }
}

/* Language Carousel (removed) */
.language-carousel {
    position: relative;
    width: 400px;
    height: 400px;
    overflow: hidden;
}

.language-item {
    position: absolute;
    background: #ffffff;
    border-radius: var(--radius);
    padding: 1rem 1.5rem;
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 1.4rem;
    font-weight: 600;
    box-shadow: var(--shadow-md);
    border: 2px solid transparent;
    transition: all 0.3s ease;
    animation: bounce 4s ease-in-out infinite;
}

.language-item:hover {
    background: #f0f9ff;
    border-color: var(--primary-color);
    transform: scale(1.05);
}

/* Position items in a circular pattern with more variety */
.language-item:nth-child(1) {
    top: 10%;
    left: 45%;
    animation-delay: 0s;
}

.language-item:nth-child(2) {
    top: 25%;
    right: 15%;
    animation-delay: 0.3s;
}

.language-item:nth-child(3) {
    top: 50%;
    right: 5%;
    animation-delay: 0.6s;
}

.language-item:nth-child(4) {
    bottom: 25%;
    right: 20%;
    animation-delay: 0.9s;
}

.language-item:nth-child(5) {
    bottom: 10%;
    left: 40%;
    animation-delay: 1.2s;
}

.language-item:nth-child(6) {
    bottom: 25%;
    left: 10%;
    animation-delay: 1.5s;
}

.language-item:nth-child(7) {
    top: 45%;
    left: 5%;
    animation-delay: 1.8s;
}

.language-item:nth-child(8) {
    top: 15%;
    left: 20%;
    animation-delay: 2.1s;
}

.language-item:nth-child(9) {
    top: 35%;
    left: 30%;
    animation-delay: 2.4s;
}

.language-item:nth-child(10) {
    bottom: 45%;
    left: 35%;
    animation-delay: 2.7s;
}

.language-item:nth-child(11) {
    top: 65%;
    right: 35%;
    animation-delay: 3.0s;
}

.language-item:nth-child(12) {
    bottom: 60%;
    right: 40%;
    animation-delay: 3.3s;
}

.language-item:nth-child(13) {
    top: 75%;
    left: 15%;
    animation-delay: 3.6s;
}

.language-item:nth-child(14) {
    bottom: 5%;
    right: 30%;
    animation-delay: 3.9s;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0px) scale(1) rotate(0deg);
        opacity: 0.8;
    }

    25% {
        transform: translateY(-15px) scale(1.02) rotate(1deg);
        opacity: 1;
    }

    50% {
        transform: translateY(-25px) scale(1.05) rotate(-1deg);
        opacity: 1;
    }

    75% {
        transform: translateY(-10px) scale(1.02) rotate(0.5deg);
        opacity: 0.9;
    }
}

/* Features Section */
.features {
    padding: 6rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.75rem;
    font-weight: 800;
    margin-bottom: 1rem;
    letter-spacing: -0.025em;
    color: var(--text-primary);
}

.section-header p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    font-weight: 400;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

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

.feature-card {
    background: #ffffff;
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(116, 42, 217, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: #8B5CF6;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(116, 42, 217, 0.2);
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-icon {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    margin-bottom: 1.5rem;
    display: inline-block;
    padding: 1rem;
    background: rgba(116, 42, 217, 0.1);
    border-radius: var(--radius);
    transition: all 0.3s ease;
    color: var(--primary-color);
    min-width: 8rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(116, 42, 217, 0.2);
    text-align: center;
    line-height: 1.2;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1);
    background: rgba(116, 42, 217, 0.15);
    border-color: rgba(116, 42, 217, 0.4);
    color: var(--primary-hover);
}

.feature-card h3 {
    font-size: 1.375rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
    letter-spacing: -0.025em;
}

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

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

.how-it-works h2 {
    font-size: 2.75rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 1rem;
    letter-spacing: -0.025em;
    color: var(--text-primary);
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 4rem;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    align-items: start;
}

.step {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    background: #8B5CF6;
    color: white;
    border-radius: 50%;
    font-size: 1.375rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-colored);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}


.step-number::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.step:hover .step-number::before {
    left: 100%;
}

.step:hover .step-number {
    transform: scale(1.1);
    box-shadow: 0 15px 35px -5px rgb(139 92 246 / 0.4), 0 10px 15px -6px rgb(139 92 246 / 0.2);
}

.step h3 {
    font-size: 1.375rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
    letter-spacing: -0.025em;
}

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

/* Curriculum Section */
.curriculum {
    padding: 6rem 0;
}

.curriculum h2 {
    font-size: 2.75rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 1rem;
    letter-spacing: -0.025em;
    color: var(--text-primary);
}

.curriculum-preview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin-top: 4rem;
}

.conversation-examples {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.conversation-bubble {
    background: white;
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.conversation-bubble.user {
    margin-left: 2rem;
    background: var(--bg-accent);
}

.conversation-bubble.ai {
    margin-right: 2rem;
    background: white;
}

.conversation-bubble .chinese {
    display: block;
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.conversation-bubble .pinyin {
    display: block;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.conversation-bubble .english {
    display: block;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1rem;
}

.checkmark {
    color: var(--success-color);
    font-weight: bold;
}

/* Testimonials */
.testimonials {
    padding: 6rem 0;
    background: var(--bg-primary);
}

.testimonials h2 {
    font-size: 2.75rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 4rem;
    letter-spacing: -0.025em;
    color: var(--text-primary);
}

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

.testimonial {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.testimonial::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: #8B5CF6;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.testimonial:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(116, 42, 217, 0.2);
}

.testimonial:hover::before {
    opacity: 1;
}

.testimonial-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.check-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #10B981;
}

.testimonial-title h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.rating {
    margin-bottom: 1rem;
    font-size: 1.125rem;
}

.testimonial p {
    margin-bottom: 1.5rem;
    line-height: 1.6;
    color: var(--text-primary);
}

.author strong {
    display: block;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.author span {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

/* CTA Section */
.cta-section {
    padding: 8rem 0;
    background: #8B5CF6;
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: rgba(255, 255, 255, 0.05);
    animation: float 15s ease-in-out infinite reverse;
}

.cta-content h2 {
    font-size: 2.75rem;
    font-weight: 800;
    margin-bottom: 1rem;
    letter-spacing: -0.025em;
    position: relative;
    z-index: 1;
}

.cta-content p {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
    position: relative;
    z-index: 1;
    font-weight: 400;
}

/* CTA section button styling */
.cta-section .cta-button {
    background: white;
    color: #8B5CF6;
    box-shadow: 0 8px 0 rgba(0, 0, 0, 0.1);
}

.cta-section .cta-button:hover {
    transform: translateY(2px);
    box-shadow: 0 6px 0 rgba(0, 0, 0, 0.1);
    background: white;
}

.cta-section .cta-button:active {
    transform: translateY(8px);
    box-shadow: none;
}


.cta-note {
    margin-top: 1rem;
    font-size: 0.875rem;
    opacity: 0.8;
}

/* Lesson Nodes Preview */
.lesson-nodes-preview {
    margin-top: 1.5rem;
    padding: 1rem 0;
}

.lesson-node-container {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
}

.lesson-node {
    position: relative;
    width: 96px;
    height: 96px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.1s ease;
    padding: 0.75rem;
}

.lesson-node:active {
    transform: translateY(6px);
}

.lesson-emoji {
    font-size: 1.5rem;
    line-height: 1;
}

.lesson-checkmark {
    font-size: 1.5rem;
    color: white;
    font-weight: bold;
}

.lesson-name {
    text-align: center;
    line-height: 1.2;
    max-width: 80px;
    word-wrap: break-word;
}

/* 3D Button Effects */
.btn-3d-primary {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 6px 0 #5d22ad;
}

.btn-3d-primary:active {
    box-shadow: 0 0 0 #5d22ad;
}

.btn-3d-primary.in-progress {
    background-color: var(--primary-color);
}

.btn-3d-green {
    background-color: var(--success-color);
    color: white;
    box-shadow: 0 6px 0 #0f7635;
}

.btn-3d-green:active {
    box-shadow: 0 0 0 #0f7635;
}

/* Progress Circle */
.progress-circle {
    position: relative;
    width: 36px;
    height: 36px;
}

.progress-svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.progress-arc {
    transition: stroke-dashoffset 0.3s;
}

.progress-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.625rem;
    font-weight: bold;
    color: var(--primary-color);
}

/* Roleplay Preview */
.roleplay-preview {
    margin-top: 1.5rem;
}

.roleplay-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    max-width: 400px;
}

@media (max-width: 768px) {
    .roleplay-grid {
        grid-template-columns: 1fr;
        max-width: none;
    }
}

.roleplay-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1rem;
    transition: all 0.2s ease;
    cursor: pointer;
}

.roleplay-card:hover {
    border-color: var(--primary-color);
}

.roleplay-card.custom {
    border: 2px dashed rgba(139, 92, 246, 0.3);
}

.roleplay-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
}

.roleplay-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
    flex: 1;
    margin-right: 0.5rem;
}

.roleplay-emoji {
    font-size: 1.25rem;
    line-height: 1;
}

.roleplay-footer {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tag-badge {
    font-size: 0.625rem;
    font-weight: 500;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    background-color: #f3f4f6;
    color: #6b7280;
}

.roleplay-subtitle {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* Feedback Preview */
.feedback-preview {
    margin-top: 1.5rem;
}

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

.grade-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 1.25rem;
    position: relative;
}

.grade-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
}

.grade-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.grade-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 2rem;
    height: 2rem;
    background-color: rgba(34, 197, 94, 0.1);
    color: #15803d;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    font-weight: 700;
}

.grade-feedback {
    font-size: 0.75rem;
    line-height: 1.5;
    color: var(--text-secondary);
    margin: 0;
}

.grade-feedback .chinese {
    font-family: 'Noto Sans SC', sans-serif;
}

/* Footer */
.footer {
    padding: 3rem 0 2rem;
    background: #1e293b;
    color: white;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(116, 42, 217, 0.5);
}

.footer-section h4 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

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

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-section ul li a:hover {
    color: white;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.footer-left .logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

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

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

.footer-bottom p {
    margin: 0;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.2s;
}

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

/* Desktop styles */
@media (min-width: 769px) {
    .hero {
        padding: 0;
    }

    .hero-visual {
        width: auto;
        flex: 1;
    }

    .mobile-chat-window {
        width: 500px;
        max-height: none;
        height: auto;
        min-height: 600px;
    }
}

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

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

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

    .curriculum-preview {
        grid-template-columns: 1fr;
    }

    .footer-top {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .footer-left {
        justify-content: center;
    }

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

    .hero-stats {
        justify-content: center;
    }

    .hero-content {
        flex-direction: column;
        gap: 3rem;
    }

    .hero-text,
    .hero-visual {
        width: 100%;
    }

    .hero {
        padding: 2rem 0;
    }

    .hero-visual {
        padding: 0;
    }

    .mobile-chat-window {
        width: 100%;
        min-height: calc(100dvh - 7.5rem);
        height: auto;
        border-radius: 10px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

    .hero {
        padding: 5rem 0 4rem;
    }

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

    .hero-subtitle {
        font-size: 1.125rem;
    }

    .features,
    .how-it-works,
    .curriculum,
    .testimonials {
        padding: 4rem 0;
    }

    .section-header h2,
    .how-it-works h2,
    .curriculum h2,
    .testimonials h2 {
        font-size: 2.25rem;
    }

    .cta-section {
        padding: 5rem 0;
    }

    .cta-content h2 {
        font-size: 2.25rem;
    }

    .footer {
        padding: 3rem 0 1.5rem;
    }


    .language-carousel {
        width: 250px;
        height: 250px;
    }

    .language-item {
        font-size: 1.25rem;
        padding: 0.75rem 1rem;
    }

    .feature-icon {
        min-width: 7rem;
        height: 2.5rem;
        font-size: 0.625rem;
        padding: 0.75rem;
    }
}

/* Scenario Modal Container Styles */
.scenario-modal-container {
    background-color: #fff;
    border-radius: 10px;
    width: 100%;
    max-width: 450px;
    padding: 25px;
    position: relative;
    margin-top: 2rem;
}

.scenario-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.scenario-title {
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #333;
    margin: 0;
}

.scenario-title .scenario-emoji {
    font-size: 20px;
}

.scenario-close-button {
    background: none;
    border: none;
    font-size: 24px;
    color: #777;
    cursor: pointer;
    padding: 0;
}

.scenario-description {
    font-size: 15px;
    line-height: 1.6;
    color: #555;
    margin-bottom: 30px;
    text-align: left;
}

.scenario-roles-header {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.scenario-roles-header .scenario-emoji {
    font-size: 18px;
}

.scenario-role-card {
    background-color: var(--bg-secondary);
    border-radius: 10px;
    padding: 18px 20px;
    margin-bottom: 15px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
    line-height: 1.5;
}

.scenario-role-card:last-child {
    margin-bottom: 0;
}

.scenario-role-card .scenario-icon {
    font-size: 20px;
    color: #777;
}

.scenario-role-card .scenario-role-text {
    display: flex;
    flex-direction: column;
}

.scenario-role-card .scenario-label {
    font-weight: 600;
    font-size: 15px;
    color: #333;
}

.scenario-role-card .scenario-value {
    font-size: 15px;
    color: #555;
}

/* Scenario Modal Scrollbar styling */
.scenario-modal-container::-webkit-scrollbar {
    width: 8px;
}

.scenario-modal-container::-webkit-scrollbar-track {
    background: #f0f0f0;
    border-radius: 10px;
}

.scenario-modal-container::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 10px;
}

.scenario-modal-container::-webkit-scrollbar-thumb:hover {
    background: #b3b3b3;
}

/* Scenario Carousel Styles */
.scenario-carousel-container {
    position: relative;
    width: 100%;
    max-width: 450px;
    overflow: hidden;
    margin-top: 2rem;
    min-height: 400px;
    background-color: transparent;
}

.scenario-carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
    background: white;
    border-radius: 10px;
}

.scenario-carousel-container .scenario-modal-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    opacity: 0;
    transform: translateX(100%);
    margin-top: 0;
    pointer-events: none;
    visibility: hidden;
}

.scenario-carousel-container .scenario-modal-container.active {
    position: relative;
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
    visibility: visible;
    transition: none;
}

.scenario-carousel-container .scenario-modal-container.slide-out {
    position: absolute;
    animation: slideOut 1s ease-in-out forwards;
    pointer-events: none;
    visibility: visible;
}

.scenario-carousel-container .scenario-modal-container.slide-in {
    position: absolute;
    animation: slideIn 1s ease-in-out forwards;
    pointer-events: auto;
    visibility: visible;
}

@keyframes slideOut {
    0% {
        opacity: 1;
        transform: translateX(0);
    }

    100% {
        opacity: 0;
        transform: translateX(-100%);
    }
}

@keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateX(100%);
    }

    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Learned Words Card Styles */
.learned-words-card {
    background: white;
    border: none;
    border-radius: 12px;
    margin-top: 2rem;
    max-width: 450px;
    min-height: 400px;
}

.learned-words-card .card-header {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem;
}

.learned-words-card .card-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.learned-words-card .card-description {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.4;
    text-align: left;
}

.learn-words-button {
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    cursor: pointer;
    transition: background-color 0.2s;
    white-space: nowrap;
}

.learn-words-button:hover {
    background: var(--primary-dark);
}

.learned-words-card .card-content {
    padding: 0 1.5rem 1.5rem;
}

.vocabulary-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.vocab-item {
    position: relative;
    background: oklch(.962 .044 156.743);
    border-radius: var(--radius);
    padding: 1rem 0.75rem 0.5rem;
    display: inline-block;
}

.vocab-item .close-btn {
    display: none;
}

.vocab-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding-top: 0.5rem;
}

.vocab-content .pinyin {
    font-size: 0.75rem;
    color: oklch(.627 .194 149.214);
    margin-top: 0.5rem;
}

.vocab-content .hanzi {
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 1.5rem;
    color: oklch(.627 .194 149.214);
    font-weight: 500;
}

.review-info {
    margin-top: 0.125rem;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.review-time {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    color: oklch(.627 .194 149.214);
}

.review-time svg {
    color: oklch(.627 .194 149.214);
}

.progress-bar {
    width: 100%;
    height: 0.25rem;
    background: oklch(.90 .044 156.743);
    border-radius: 9999px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: oklch(.627 .194 149.214);
    transition: width 0.5s ease;
    transform-origin: left;
}

/* Time Spent Chart Styles */
.time-spent-wrapper {
    background-color: white;
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
    height: 400px;
    display: flex;
    flex-direction: column;
}

.time-spent-card {
    background-color: white;
    border-radius: 8px;
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 450px;
}

.time-spent-card .stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.time-spent-card .stat-item {
    text-align: center;
}

.time-spent-card .stat-label {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 4px;
}

.time-spent-card .stat-value {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    font-weight: 600;
    font-size: 14px;
}

.time-spent-card .clock-icon {
    width: 16px;
    height: 16px;
    color: #8b5cf6;
}

.time-spent-card .goal-button {
    display: flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 2px 4px;
    border-radius: 6px;
    transition: background-color 0.2s;
    font-weight: 600;
}

.time-spent-card .goal-button:hover {
    background-color: rgba(139, 92, 246, 0.1);
}

.time-spent-card .chevron-icon {
    width: 12px;
    height: 12px;
    opacity: 0.5;
}

.time-spent-card .chart-container {
    flex: 1;
    position: relative;
    padding-left: 35px;
    padding-bottom: 30px;
    min-height: 200px;
}

.time-spent-card .chart {
    position: absolute;
    top: 0;
    left: 35px;
    right: 0;
    bottom: 30px;
    display: flex;
    align-items: flex-end;
    gap: 6px;
    border-left: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
    padding: 0 10px;
}

.time-spent-card .bar-wrapper {
    flex: 1;
    position: relative;
    height: 100%;
    display: flex;
    align-items: flex-end;
}

.time-spent-card .bar-background {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 100%;
    background-color: #8b5cf6;
    opacity: 0.1;
    border-radius: 6px 6px 0 0;
}

.time-spent-card .bar {
    width: 100%;
    background-color: #8b5cf6;
    border-radius: 6px 6px 0 0;
    position: relative;
    transition: height 0.3s ease;
}

.time-spent-card .y-axis {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    text-align: right;
    font-size: 11px;
    color: #666;
}

.time-spent-card .x-axis {
    position: absolute;
    bottom: 0;
    left: 35px;
    right: 0;
    height: 25px;
    display: flex;
    padding: 0 10px;
    gap: 6px;
}

.time-spent-card .x-label {
    flex: 1;
    text-align: center;
    font-size: 11px;
    color: #666;
    padding-top: 6px;
}

/* Fix vertical alignment for the three step cards */
.time-spent-wrapper {
    margin-top: 2rem;
    min-height: 400px;
    width: 100%;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.learned-words-card {
    margin-top: 2rem;
    min-height: 400px;
    width: 100%;
    max-width: 450px;
    margin-left: auto;
    margin-right: auto;
}

.learned-words-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 12px;
    padding: 25px;
}