/* ================================================================
   Clarion AI Landing Page
   ================================================================ */

/* --- 1. CSS Custom Properties (Design Tokens) --- */
:root {
    --lp-slate-900: #0F172A;
    --lp-slate-800: #1E293B;
    --lp-slate-700: #334155;
    --lp-slate-500: #64748B;
    --lp-slate-400: #94A3B8;
    --lp-slate-200: #E2E8F0;
    --lp-slate-100: #F1F5F9;
    --lp-slate-50:  #F8FAFC;
    --lp-white:     #FFFFFF;

    --lp-blue-700:  #1D4ED8;
    --lp-blue-600:  #2563EB;
    --lp-blue-50:   #EFF6FF;

    --lp-emerald-600: #059669;
    --lp-emerald-500: #10B981;
    --lp-emerald-50:  #ECFDF5;

    --lp-red-600:   #DC2626;
    --lp-red-50:    #FEF2F2;

    --lp-font: 'Inter', system-ui, -apple-system, sans-serif;

    --lp-navbar-height: 72px;
    --lp-container-max: 1200px;
    --lp-radius: 12px;
    --lp-radius-sm: 8px;
    --lp-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --lp-shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
}


/* --- 2. Reset & Base Styles --- */
@font-face {
    font-family: 'Inter';
    src: url('../assets/fonts/InterVariable.woff2') format('woff2');
    font-weight: 100 900;
    font-display: swap;
    font-style: normal;
}

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

html {
    scroll-padding-top: var(--lp-navbar-height);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--lp-font);
    font-size: 1.0625rem;
    line-height: 1.6;
    color: var(--lp-slate-700);
    background: var(--lp-white);
}

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

a {
    color: var(--lp-blue-700);
    text-decoration: none;
}

a:hover {
    color: var(--lp-blue-600);
}

ul {
    list-style: none;
}


/* --- 3. Typography --- */
h1, h2, h3, h4 {
    color: var(--lp-slate-900);
    line-height: 1.2;
    font-weight: 700;
}

h1 { font-size: 2rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.125rem; font-weight: 600; }


/* --- 4. Layout Utilities --- */
.lp-container {
    max-width: var(--lp-container-max);
    margin: 0 auto;
    padding: 0 24px;
}

.lp-section-label {
    display: block;
    text-align: center;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--lp-blue-700);
    margin-bottom: 12px;
}

.lp-section-heading {
    text-align: center;
    margin-bottom: 16px;
}

.lp-section-subtitle {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 48px;
    color: var(--lp-slate-500);
    font-size: 1.0625rem;
}

.lp-badge {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--lp-blue-700);
    background: var(--lp-blue-50);
    padding: 4px 14px;
    border-radius: 100px;
    margin-bottom: 20px;
}

.lp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--lp-font);
    font-weight: 600;
    border: none;
    border-radius: var(--lp-radius-sm);
    cursor: pointer;
    transition: background-color 200ms ease, transform 200ms ease;
    text-decoration: none;
}

.lp-btn--primary {
    background: var(--lp-blue-700);
    color: var(--lp-white);
    font-size: 0.9375rem;
    padding: 12px 28px;
}

.lp-btn--primary:hover {
    background: var(--lp-blue-600);
    color: var(--lp-white);
}

.lp-btn--lg {
    font-size: 1rem;
    padding: 14px 32px;
}

.lp-btn--xl {
    font-size: 1.125rem;
    padding: 16px 40px;
}

.lp-skip-link {
    position: absolute;
    left: -9999px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
    z-index: 1000;
    background: var(--lp-blue-700);
    color: var(--lp-white);
    padding: 12px 24px;
    border-radius: var(--lp-radius-sm);
}

.lp-skip-link:focus {
    position: fixed;
    left: 16px;
    top: 16px;
    width: auto;
    height: auto;
    overflow: visible;
}


/* --- 5. Navbar --- */
.lp-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--lp-navbar-height);
    z-index: 100;
    background: transparent;
    transition: background-color 200ms ease, box-shadow 200ms ease;
}

.lp-navbar--scrolled {
    background: var(--lp-white);
    box-shadow: 0 1px 0 var(--lp-slate-200);
}

.lp-navbar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.lp-navbar__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 1.125rem;
    color: var(--lp-slate-900);
    text-decoration: none;
    flex-shrink: 0;
}

.lp-navbar__logo:hover {
    color: var(--lp-slate-900);
}

.lp-navbar__logo svg {
    flex-shrink: 0;
}

.lp-navbar__links {
    display: none;
    align-items: center;
    gap: 32px;
}

.lp-navbar__links a {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--lp-slate-700);
    transition: color 200ms ease;
}

.lp-navbar__links a:hover {
    color: var(--lp-blue-700);
}

.lp-navbar__actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.lp-navbar__login {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--lp-slate-700);
    transition: color 200ms ease;
}

.lp-navbar__login:hover {
    color: var(--lp-blue-700);
}

.lp-navbar__cta {
    display: none;
}

.lp-navbar__hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
}

.lp-navbar__hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--lp-slate-700);
    border-radius: 1px;
    transition: transform 200ms ease, opacity 200ms ease;
}

/* Mobile nav open state */
.lp-navbar__links.lp-mobile-nav--open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--lp-navbar-height);
    left: 0;
    right: 0;
    background: var(--lp-white);
    padding: 24px;
    gap: 20px;
    box-shadow: var(--lp-shadow-md);
    border-bottom: 1px solid var(--lp-slate-200);
}

.lp-navbar__links.lp-mobile-nav--open a {
    font-size: 1.0625rem;
}


/* --- 6. Hero Section --- */
.lp-hero {
    padding: 120px 0 48px;
    background: linear-gradient(180deg, var(--lp-slate-50) 0%, var(--lp-white) 100%);
}

.lp-hero__inner {
    display: flex;
    flex-direction: column;
    gap: 48px;
}

.lp-hero__headline {
    margin-bottom: 20px;
}

.lp-hero__subtitle {
    font-size: 1.0625rem;
    color: var(--lp-slate-500);
    margin-bottom: 32px;
    max-width: 540px;
}

.lp-hero__cta-group {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 32px;
}

.lp-hero__secondary-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--lp-blue-700);
}

.lp-hero__secondary-link:hover {
    color: var(--lp-blue-600);
}

.lp-hero__proof {
    font-size: 0.875rem;
    color: var(--lp-slate-500);
}

.lp-hero__visual {
    width: 100%;
}

.lp-hero__screenshot-wrapper {
    border-radius: var(--lp-radius);
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    background: var(--lp-slate-100);
    aspect-ratio: 16 / 10;
}

.lp-hero__screenshot {
    width: 100%;
    height: 100%;
    object-fit: cover;
}


/* --- 7. Problem Section --- */
.lp-problem {
    padding: 64px 0;
    background: var(--lp-white);
}

.lp-stat-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 32px;
}

.lp-stat-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: var(--lp-white);
    border: 1px solid var(--lp-slate-200);
    border-radius: var(--lp-radius);
    padding: 32px 24px;
}

.lp-stat-card__icon {
    color: var(--lp-blue-700);
    margin-bottom: 16px;
}

.lp-stat-card__number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--lp-slate-900);
    line-height: 1;
    margin-bottom: 8px;
}

.lp-stat-card__label {
    font-size: 0.9375rem;
    color: var(--lp-slate-500);
}

.lp-callout {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: var(--lp-slate-50);
    border-radius: var(--lp-radius-sm);
    padding: 16px 20px;
    font-size: 0.9375rem;
    color: var(--lp-slate-700);
}

.lp-callout__icon {
    flex-shrink: 0;
    color: var(--lp-blue-700);
    margin-top: 2px;
}


/* --- 8. How It Works Section --- */
.lp-how-it-works {
    padding: 64px 0;
    background: var(--lp-slate-50);
}

.lp-steps {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    max-width: 900px;
    margin: 0 auto;
}

.lp-step {
    text-align: center;
}

.lp-step__number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--lp-blue-700);
    color: var(--lp-white);
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.lp-step__title {
    margin-bottom: 8px;
}

.lp-step__desc {
    font-size: 0.9375rem;
    color: var(--lp-slate-500);
    max-width: 300px;
    margin: 0 auto;
}


/* --- 8b. Showcase Screenshots --- */
.lp-how-it-works__screenshot,
.lp-feature-showcase {
    margin-top: 48px;
    border-radius: var(--lp-radius);
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    background: var(--lp-slate-100);
}

.lp-showcase__img {
    width: 100%;
    height: auto;
    display: block;
}


/* --- 9. Features Grid --- */
.lp-features {
    padding: 64px 0;
    background: var(--lp-white);
}

.lp-feature-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.lp-feature-card {
    background: var(--lp-white);
    border: 1px solid var(--lp-slate-200);
    border-radius: var(--lp-radius);
    padding: 32px;
    transition: transform 200ms ease, box-shadow 200ms ease;
}

.lp-feature-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--lp-shadow-md);
}

.lp-feature-card__icon {
    width: 40px;
    height: 40px;
    color: var(--lp-blue-700);
    margin-bottom: 16px;
}

.lp-feature-card__title {
    margin-bottom: 8px;
}

.lp-feature-card__desc {
    font-size: 0.9375rem;
    color: var(--lp-slate-500);
    line-height: 1.6;
}


/* --- 10. Before/After Comparison --- */
.lp-comparison {
    padding: 64px 0;
    background: var(--lp-slate-50);
}

.lp-comparison__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}

.lp-comparison__card {
    background: var(--lp-white);
    border-radius: var(--lp-radius);
    padding: 32px;
    border-top: 4px solid var(--lp-slate-200);
}

.lp-comparison__card--without {
    border-top-color: var(--lp-red-600);
}

.lp-comparison__card--with {
    border-top-color: var(--lp-emerald-500);
}

.lp-comparison__card-title {
    font-size: 1.0625rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.lp-timeline {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
}

.lp-timeline__item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    font-size: 0.9375rem;
    color: var(--lp-slate-700);
}

.lp-timeline__item--done {
    color: var(--lp-slate-900);
}

.lp-timeline__item--done::before {
    content: '';
    display: inline-block;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    margin-top: 2px;
    border-radius: 50%;
    background: var(--lp-emerald-50);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23059669' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
    background-size: 12px;
    background-repeat: no-repeat;
    background-position: center;
}

.lp-timeline__time {
    font-family: 'Courier New', monospace;
    font-size: 0.8125rem;
    color: var(--lp-slate-500);
    white-space: nowrap;
    flex-shrink: 0;
    min-width: 68px;
}

.lp-comparison__summary {
    font-weight: 600;
    font-size: 0.9375rem;
    padding-top: 16px;
    border-top: 1px solid var(--lp-slate-200);
}

.lp-comparison__summary--bad {
    color: var(--lp-red-600);
}

.lp-comparison__summary--good {
    color: var(--lp-emerald-600);
}


/* --- 11. Pricing --- */
.lp-pricing {
    padding: 64px 0;
    background: var(--lp-slate-50);
}

.lp-pricing__card {
    max-width: 560px;
    margin: 0 auto;
    background: var(--lp-white);
    border: 2px solid var(--lp-blue-700);
    border-radius: var(--lp-radius);
    padding: 40px 32px;
    text-align: center;
}

.lp-pricing__card-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 24px;
}

.lp-pricing__features {
    display: flex;
    flex-direction: column;
    gap: 14px;
    text-align: left;
    margin-bottom: 32px;
}

.lp-pricing__features li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1rem;
    color: var(--lp-slate-700);
}

.lp-pricing__features svg {
    flex-shrink: 0;
    color: var(--lp-emerald-500);
}

.lp-pricing__cta {
    width: 100%;
    margin-bottom: 16px;
}

.lp-pricing__note {
    font-size: 0.875rem;
    color: var(--lp-slate-500);
}


/* --- 12. FAQ Accordion --- */
.lp-faq {
    padding: 64px 0;
    background: var(--lp-slate-50);
}

.lp-faq__list {
    max-width: 720px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lp-faq__item {
    background: var(--lp-white);
    border-radius: var(--lp-radius-sm);
    border: 1px solid var(--lp-slate-200);
    overflow: hidden;
}

.lp-faq__question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 20px 24px;
    font-family: var(--lp-font);
    font-size: 1rem;
    font-weight: 600;
    color: var(--lp-slate-900);
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    gap: 16px;
}

.lp-faq__question:hover {
    color: var(--lp-blue-700);
}

.lp-faq__chevron {
    flex-shrink: 0;
    transition: transform 200ms ease;
    color: var(--lp-slate-500);
}

.lp-faq__question[aria-expanded="true"] .lp-faq__chevron {
    transform: rotate(180deg);
}

.lp-faq__answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 300ms ease;
}

.lp-faq__answer p {
    padding: 0 24px 20px;
    font-size: 0.9375rem;
    color: var(--lp-slate-500);
    line-height: 1.7;
}


/* --- 13. Final CTA --- */
.lp-final-cta {
    padding: 80px 0;
    background: var(--lp-slate-900);
}

.lp-final-cta__inner {
    text-align: center;
}

.lp-final-cta__heading {
    color: var(--lp-white);
    margin-bottom: 16px;
}

.lp-final-cta__subtitle {
    color: var(--lp-slate-400);
    font-size: 1.0625rem;
    margin-bottom: 32px;
}

.lp-final-cta__note {
    margin-top: 16px;
    font-size: 0.875rem;
    color: var(--lp-slate-500);
}


/* --- 14. Footer --- */
.lp-footer {
    background: var(--lp-slate-900);
    border-top: 1px solid var(--lp-slate-800);
}

.lp-footer__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    padding-top: 48px;
    padding-bottom: 32px;
}

.lp-footer__brand .lp-navbar__logo--light {
    color: var(--lp-white);
    margin-bottom: 12px;
}

.lp-footer__brand .lp-navbar__logo--light:hover {
    color: var(--lp-white);
}

.lp-footer__tagline {
    font-size: 0.875rem;
    color: var(--lp-slate-400);
}

.lp-footer__links h4 {
    color: var(--lp-slate-400);
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.lp-footer__links ul {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lp-footer__links a {
    font-size: 0.9375rem;
    color: var(--lp-slate-400);
    transition: color 200ms ease;
}

.lp-footer__links a:hover {
    color: var(--lp-white);
}

.lp-footer__bottom {
    border-top: 1px solid var(--lp-slate-800);
    padding: 20px 0;
}

.lp-footer__bottom p {
    font-size: 0.8125rem;
    color: var(--lp-slate-500);
}


/* --- 15. Animations --- */
.lp-animate {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 500ms ease, transform 500ms ease;
}

.lp-animate--visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children for grids */
.lp-animate--visible .lp-stat-card,
.lp-animate--visible .lp-feature-card,
.lp-animate--visible .lp-step,
.lp-animate--visible .lp-comparison__card {
    opacity: 0;
    animation: fadeInUp 400ms ease forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.lp-animate--visible .lp-stat-card:nth-child(1),
.lp-animate--visible .lp-feature-card:nth-child(1),
.lp-animate--visible .lp-step:nth-child(1),
.lp-animate--visible .lp-comparison__card:nth-child(1) { animation-delay: 0ms; }

.lp-animate--visible .lp-stat-card:nth-child(2),
.lp-animate--visible .lp-feature-card:nth-child(2),
.lp-animate--visible .lp-step:nth-child(2),
.lp-animate--visible .lp-comparison__card:nth-child(2) { animation-delay: 100ms; }

.lp-animate--visible .lp-stat-card:nth-child(3),
.lp-animate--visible .lp-feature-card:nth-child(3),
.lp-animate--visible .lp-step:nth-child(3) { animation-delay: 200ms; }

.lp-animate--visible .lp-feature-card:nth-child(4) { animation-delay: 300ms; }
.lp-animate--visible .lp-feature-card:nth-child(5) { animation-delay: 400ms; }
.lp-animate--visible .lp-feature-card:nth-child(6) { animation-delay: 500ms; }


/* --- 16. Responsive Breakpoints --- */

/* 640px — Large phones / small tablets */
@media (min-width: 640px) {
    .lp-hero__cta-group {
        flex-direction: row;
        align-items: center;
    }

    .lp-stat-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* 768px — Tablets */
@media (min-width: 768px) {
    :root {
        --lp-navbar-height: 72px;
    }

    .lp-container {
        padding: 0 40px;
    }

    h1 { font-size: 2.5rem; }
    h2 { font-size: 1.75rem; }

    .lp-navbar__links {
        display: flex;
    }

    .lp-navbar__cta {
        display: inline-flex;
    }

    .lp-navbar__hamburger {
        display: none;
    }

    .lp-hero {
        padding: 140px 0 64px;
    }

    .lp-problem,
    .lp-how-it-works,
    .lp-features,
    .lp-comparison,
    .lp-pricing,
    .lp-faq {
        padding: 80px 0;
    }

    .lp-final-cta {
        padding: 100px 0;
    }

    .lp-steps {
        grid-template-columns: repeat(3, 1fr);
        gap: 24px;
        position: relative;
    }

    /* Dashed connector between steps */
    .lp-steps::before {
        content: '';
        position: absolute;
        top: 24px;
        left: calc(16.67% + 24px);
        right: calc(16.67% + 24px);
        height: 0;
        border-top: 2px dashed var(--lp-slate-200);
    }

    .lp-step__number {
        position: relative;
        z-index: 1;
    }

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

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

    .lp-footer__inner {
        grid-template-columns: 2fr 1fr 1fr;
        gap: 48px;
    }
}

/* 1024px — Desktops */
@media (min-width: 1024px) {
    h1 { font-size: 3.5rem; }
    h2 { font-size: 2rem; }

    .lp-hero {
        padding: 160px 0 80px;
    }

    .lp-hero__inner {
        flex-direction: row;
        align-items: center;
        gap: 64px;
    }

    .lp-hero__content {
        flex: 0 0 55%;
    }

    .lp-hero__visual {
        flex: 0 0 45%;
    }

    .lp-problem,
    .lp-how-it-works,
    .lp-features,
    .lp-comparison,
    .lp-pricing,
    .lp-faq {
        padding: 100px 0;
    }

    .lp-final-cta {
        padding: 120px 0;
    }

    .lp-feature-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .lp-section-subtitle {
        margin-bottom: 56px;
    }
}

/* 1280px — Large desktops */
@media (min-width: 1280px) {
    .lp-hero__inner {
        gap: 80px;
    }
}


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

    .lp-animate {
        opacity: 1;
        transform: none;
    }
}


/* --- Focus Visible --- */
:focus-visible {
    outline: 2px solid var(--lp-blue-700);
    outline-offset: 2px;
}

button:focus-visible {
    outline: 2px solid var(--lp-blue-700);
    outline-offset: 2px;
}
