/* LungChat Modern Welcome Page Styles - Matching Theme System */

:root {
    /* Match theme.json light mode colors */
    --font-sans: 'Inter', sans-serif;
    --background: hsl(0, 0%, 100%);
    --foreground: hsl(0, 0%, 5%);
    --card: hsl(0, 0%, 100%);
    --card-foreground: hsl(0, 0%, 5%);
    --primary: hsl(220, 60%, 52%);
    --primary-foreground: hsl(0, 0%, 100%);
    --secondary: hsl(210, 40%, 96.1%);
    --secondary-foreground: hsl(222.2, 47.4%, 11.2%);
    --muted: hsl(0, 0%, 90%);
    --muted-foreground: hsl(0, 0%, 36%);
    --accent: hsl(0, 0%, 95%);
    --accent-foreground: hsl(222.2, 47.4%, 11.2%);
    --border: hsl(0, 0%, 90%);
    --input: hsl(0, 0%, 90%);
    --ring: hsl(220, 60%, 52%);
    --radius: 0.75rem;

    /* Derived colors for gradients */
    --primary-light: hsl(220, 60%, 70%);
    --primary-dark: hsl(220, 60%, 40%);

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

/* Dark mode - match theme.json dark mode colors */
.dark {
    --background: hsl(0, 0%, 13%);
    --foreground: hsl(0, 0%, 93%);
    --card: hsl(0, 0%, 18%);
    --card-foreground: hsl(210, 40%, 98%);
    --primary: hsl(220, 60%, 52%);
    --primary-foreground: hsl(0, 0%, 100%);
    --secondary: hsl(0, 0%, 19%);
    --secondary-foreground: hsl(210, 40%, 98%);
    --muted: hsl(0, 1%, 26%);
    --muted-foreground: hsl(0, 0%, 71%);
    --accent: hsl(0, 0%, 26%);
    --accent-foreground: hsl(210, 40%, 98%);
    --border: hsl(0, 1%, 26%);
    --input: hsl(0, 1%, 26%);
    --ring: hsl(220, 60%, 52%);

    /* Derived colors for gradients */
    --primary-light: hsl(220, 60%, 60%);
    --primary-dark: hsl(220, 60%, 45%);

    /* Darker shadows for dark mode */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background: var(--secondary);
    color: var(--foreground);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background 0.3s ease, color 0.3s ease;
}

/* Header */
.header {
    background: transparent;
    padding: 0.5rem 1rem;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header.scrolled {
    background: transparent;
    padding: 0.5rem 1rem;
}

.header-content {
    max-width: 100%;
    margin: 0;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 2rem;
}

.logo-container {
    display: flex;
    align-items: center;
    transition: transform 0.2s ease;
    cursor: pointer;
    flex-shrink: 0;
    margin-left: 2rem;
    margin-top: 1.5rem;
}

.logo-container:hover {
    transform: scale(1.02);
}

/* Logo images - light mode logo shown by default, dark mode logo shown in dark mode */
.logo-light {
    height: 79px;
    width: auto;
    display: block;
}

.logo-dark {
    height: 79px;
    width: auto;
    display: none;
}

.dark .logo-light {
    display: none;
}

.dark .logo-dark {
    display: block;
}

.nav-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    background: var(--card);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
    margin-right: 0 rem;
    margin-top: 0;
    transition: background 0.3s ease, border-color 0.3s ease;
}

.nav-link {
    color: var(--muted-foreground);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    white-space: nowrap;
}

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

.btn-try-now {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--primary-foreground);
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px hsla(220, 60%, 52%, 0.3);
}

.btn-try-now:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px hsla(220, 60%, 52%, 0.4);
}

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

.mobile-menu-btn span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--foreground);
    transition: all 0.3s ease;
}

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

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

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

/* Hero Section */
.hero {
    max-width: 1400px;
    margin: 0 auto;
    padding: 12rem 2rem 6rem;
    text-align: center;
}

.hero-title {
    font-size: clamp(2.5rem, 7vw, 5rem);
    font-weight: 800;
    color: var(--foreground);
    margin-bottom: 1.5rem;
    line-height: 1.1;
    letter-spacing: -0.02em;
}

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

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    color: var(--muted-foreground);
    margin-bottom: 3rem;
    font-weight: 400;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.hero-stats {
    display: flex;
    gap: 3rem;
    justify-content: center;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

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

.stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.95rem;
    color: var(--muted-foreground);
    font-weight: 500;
}

/* CTA Buttons */
.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 4rem;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1.1rem 2.5rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--primary-foreground);
    text-decoration: none;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px hsla(220, 60%, 52%, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px hsla(220, 60%, 52%, 0.5);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1.1rem 2.5rem;
    background: var(--card);
    color: var(--primary);
    text-decoration: none;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border: 2px solid var(--border);
}

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

/* Hero Visual */
.hero-visual {
    max-width: 800px;
    margin: 0 auto;
    perspective: 1000px;
}

.visual-card {
    background: var(--card);
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border);
    transition: transform 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}

.visual-card:hover {
    transform: translateY(-8px) rotateX(2deg);
}

.code-snippet {
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Fira Code', monospace;
    font-size: 0.95rem;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.code-line {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.code-user {
    color: var(--primary);
    font-weight: 600;
}

.code-agent {
    color: hsl(142.1, 76.2%, 36.3%);
    font-weight: 600;
}

.dark .code-agent {
    color: hsl(142.1, 70.6%, 45.3%);
}

.code-result {
    color: hsl(142.1, 76.2%, 36.3%);
    font-size: 1.2rem;
}

.dark .code-result {
    color: hsl(142.1, 70.6%, 45.3%);
}

.typing-text {
    color: var(--foreground);
}

.typing-cursor {
    display: inline-block;
    color: var(--primary);
    font-weight: bold;
    animation: blink 1s infinite;
    margin-left: 2px;
}

@keyframes blink {

    0%,
    50% {
        opacity: 1;
    }

    51%,
    100% {
        opacity: 0;
    }
}

/* Section Styles */
section {
    max-width: 1400px;
    margin: 0 auto;
    padding: 5rem 2rem;
}

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

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: var(--foreground);
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--muted-foreground);
    font-weight: 400;
}

/* About Section */
.about-section {
    background: var(--card);
    border-radius: var(--radius);
    margin: 4rem auto;
    box-shadow: var(--shadow-md);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

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

.about-description {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--muted-foreground);
    margin-bottom: 2rem;
}

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

.about-feature-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1rem;
    color: var(--foreground);
}

.feature-check {
    width: 24px;
    height: 24px;
    color: hsl(142.1, 76.2%, 36.3%);
    flex-shrink: 0;
}

.dark .feature-check {
    color: hsl(142.1, 70.6%, 45.3%);
}

.architecture-img {
    width: 100%;
    height: auto;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
}

/* Capabilities Grid */
.capabilities-section {
    background: var(--secondary);
    transition: background 0.3s ease;
}

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

.capability-card {
    background: var(--card);
    padding: 2.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.capability-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.capability-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
}

.capability-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, hsl(220, 100%, 97%) 0%, hsl(220, 100%, 92%) 100%);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--primary);
    transition: background 0.3s ease;
}

.dark .capability-icon {
    background: linear-gradient(135deg, hsl(220, 20%, 20%) 0%, hsl(220, 20%, 25%) 100%);
}

.capability-icon svg {
    width: 28px;
    height: 28px;
}

.capability-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.75rem;
}

.capability-description {
    font-size: 1rem;
    color: var(--muted-foreground);
    line-height: 1.7;
}

/* Team Section */
.team-section {
    background: var(--secondary);
    transition: background 0.3s ease;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
    justify-items: center;
}

.team-card {
    background: var(--card);
    padding: 2rem;
    border-radius: var(--radius);
    text-align: center;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
    opacity: 1;
    transform: scale(1);
    animation: fadeInUp 0.6s ease forwards;
}

.team-card.animate-in {
    opacity: 1;
    transform: scale(1);
}

.team-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary);
}

.team-image-wrapper {
    margin-bottom: 1rem;
}

.team-image-wrapper img {
    width: 180px !important;
    height: 220px !important;
    border-radius: var(--radius);
    object-fit: cover;
    object-position: top center;
    margin: 0 auto;
    display: block;
    border: 2px solid var(--border);
    transition: border-color 0.3s ease;
}

.team-image-placeholder {
    width: 180px;
    height: 220px;
    margin: 0 auto;
    background: linear-gradient(135deg, var(--accent) 0%, var(--border) 100%);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted-foreground);
}

.team-image-placeholder svg {
    width: 60px;
    height: 60px;
}

.team-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 0.25rem;
}

.team-role {
    font-size: 0.9rem;
    color: var(--muted-foreground);
    margin-bottom: 0;
    min-height: 0;
    display: none;
}

.team-link {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: transform 0.2s ease;
}

.team-link:hover {
    transform: translateX(4px);
}

.team-link svg {
    width: 16px;
    height: 16px;
}

/* FAQ Section */
.faq-section {
    background: var(--card);
    border-radius: var(--radius);
    margin: 4rem auto;
    box-shadow: var(--shadow-md);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.faq-container {
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    border-bottom: 1px solid var(--border);
    transition: all 0.3s ease;
}

.faq-item:last-child {
    border-bottom: none;
}

.faq-question {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.5rem 0;
    background: none;
    border: none;
    text-align: left;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--foreground);
    cursor: pointer;
    transition: color 0.2s ease;
}

.faq-question:hover {
    color: var(--primary);
}

.faq-icon {
    width: 24px;
    height: 24px;
    color: var(--muted-foreground);
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
    color: var(--primary);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 500px;
    padding-bottom: 1.5rem;
}

.faq-answer p {
    color: var(--muted-foreground);
    line-height: 1.7;
    font-size: 1rem;
}

/* Paper Section */
.paper-section {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: var(--radius);
    color: var(--primary-foreground);
    text-align: center;
    margin: 4rem auto;
}

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

.paper-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
}

.paper-icon svg {
    width: 40px;
    height: 40px;
}

.paper-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.paper-description {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 2.5rem;
    opacity: 0.95;
}

.btn-paper {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2.5rem;
    background: var(--primary-foreground);
    color: var(--primary);
    text-decoration: none;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.btn-paper:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

/* Contact Section */
.contact-section {
    background: var(--secondary);
    transition: background 0.3s ease;
}

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

.contact-card {
    background: var(--card);
    padding: 2.5rem;
    border-radius: var(--radius);
    text-align: center;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.contact-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
    cursor: pointer;
}

.contact-icon {
    width: 56px;
    height: 56px;
    color: var(--primary);
    margin: 0 auto 1.5rem;
}

.contact-card h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--foreground);
    margin-bottom: 1rem;
}

.contact-card p,
.contact-card a {
    font-size: 1rem;
    color: var(--muted-foreground);
    line-height: 1.7;
    text-decoration: none;
    transition: color 0.2s ease;
}

.contact-card a:hover {
    color: var(--primary);
}

.contact-card p a:hover {
    color: var(--primary);
}

a.contact-card {
    color: inherit;
}

a.contact-card:hover {
    color: inherit;
}

a.contact-card h3,
a.contact-card p {
    color: inherit;
}

/* Footer */
.footer {
    background: var(--foreground);
    color: var(--primary-foreground);
    margin-top: 4rem;
    transition: background 0.3s ease;
}

.dark .footer {
    background: hsl(0, 0%, 8%);
    /* Even darker than normal dark background */
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 4rem 2rem 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
}

.footer-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--primary-foreground);
}

.footer-section a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
    transition: color 0.2s ease;
}

.footer-section a:hover {
    color: var(--primary-foreground);
}

/* Footer logo switching - light logo in dark footer */
.footer-logo-light {
    height: 126px;
    margin-top: 1.5rem;
    display: block;
}

.footer-logo-dark {
    height: 126px;
    margin-top: 1.5rem;
    display: none;
}

/* In dark mode, footer background is still dark, so show light logo */
.dark .footer-logo-light {
    display: block;
}

.dark .footer-logo-dark {
    display: none;
}

.footer-bottom {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .about-content {
        grid-template-columns: 1fr;
    }

    .capabilities-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    .header {
        padding: 1rem 1.5rem;
    }

    .nav-links {
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        background: var(--card);
        flex-direction: column;
        padding: 2rem;
        gap: 1.5rem;
        transform: translateY(-150%);
        transition: transform 0.3s ease;
        box-shadow: var(--shadow-lg);
        border-bottom: 1px solid var(--border);
    }

    .nav-links.active {
        transform: translateY(0);
    }

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

    .hero {
        padding: 8rem 1.5rem 4rem;
    }

    .hero-stats {
        gap: 2rem;
    }

    section {
        padding: 3rem 1.5rem;
    }

    .team-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 1.5rem;
    }

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

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

    .stat-value {
        font-size: 2rem;
    }

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

    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }

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

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

.animate-in {
    animation: fadeInUp 0.6s ease forwards;
}