/* Scaftra Premium Landing Page
   Inspired by Linear, Stripe, Superhuman
   ======================================== */

/* ========================================
   CSS Custom Properties
   ======================================== */
:root {
    /* Primary - blue-teal (matching logo) */
    --primary-900: #1a3a50;
    --primary-700: #2a5a7a;
    --primary-500: #3a8fba;
    --primary-300: #7cb9da;
    --primary-100: #e6f4fc;

    /* Accent - conversion orange */
    --accent: #ff6b35;
    --accent-hover: #e55a2b;
    --accent-glow: rgba(255, 107, 53, 0.15);

    /* Neutrals - warmer grays for premium feel */
    --gray-950: #0f1419;
    --gray-900: #1a1f26;
    --gray-700: #3d4854;
    --gray-600: #4d5a68;
    --gray-500: #6b7a8a;
    --gray-400: #8b99a8;
    --gray-300: #c4cdd6;
    --gray-200: #dfe4e9;
    --gray-100: #f4f6f8;
    --gray-50: #f9fafb;

    /* Functional */
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.04);
}

/* ========================================
   Reset and Base Styles
   ======================================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--gray-700);
    background-color: #fff;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ========================================
   Navigation
   ======================================== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: #ffffff;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--gray-200);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.nav-logo {
    display: flex;
    align-items: center;
}

.nav-logo img {
    height: 44px;
    width: auto;
}

.btn-nav {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.875rem;
    text-decoration: none;
    transition: all 0.15s ease;
}

.btn-nav:hover {
    background: var(--accent-hover);
    color: #fff;
    transform: translateY(-1px);
}

/* ========================================
   Typography
   ======================================== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.15;
    color: var(--gray-900);
}

h1 {
    font-size: 4rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 1.05;
}

h2 {
    font-size: 2.25rem;
    letter-spacing: -0.02em;
    margin-bottom: 24px;
}

h3 {
    font-size: 1rem;
    font-weight: 600;
}

p {
    margin-bottom: 16px;
}

p:last-child {
    margin-bottom: 0;
}

a {
    color: var(--primary-500);
    text-decoration: none;
    transition: color 0.15s ease;
}

a:hover {
    color: var(--primary-700);
}

/* ========================================
   Buttons
   ======================================== */
.btn-primary {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    padding: 16px 32px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: -0.01em;
    border: none;
    cursor: pointer;
    transition: all 0.15s ease;
    box-shadow: var(--shadow-sm);
    text-decoration: none;
}

.btn-primary:hover {
    background: var(--accent-hover);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--accent-glow);
}

.btn-primary:active {
    transform: scale(0.98);
}

.btn-primary:disabled {
    background: var(--gray-300);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    background: linear-gradient(135deg, var(--primary-900) 0%, var(--primary-700) 100%);
    color: #fff;
    padding: 180px 0 120px; /* Extra top padding for fixed nav */
    text-align: center;
}

.hero h1 {
    color: #fff;
    margin-bottom: 24px;
}

.hero-sub {
    font-size: 1.25rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
    max-width: 540px;
    margin: 0 auto 40px;
}

.hero-hint {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 20px;
}

/* ========================================
   Outcomes Strip
   ======================================== */
.outcomes {
    padding: 48px 0;
    background: var(--gray-50);
    border-bottom: 1px solid var(--gray-100);
}

.outcomes-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    text-align: center;
}

.outcome-tile h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.outcome-tile p {
    font-size: 0.9375rem;
    color: var(--gray-500);
    margin: 0;
}

/* ========================================
   How It Works
   ======================================== */
.how-it-works {
    padding: 64px 0;
    text-align: center;
}

.how-it-works h2 {
    margin-bottom: 40px;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 48px;
    max-width: 900px;
    margin: 0 auto;
}

.step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--primary-100);
    color: var(--primary-700);
    font-weight: 600;
    font-size: 0.875rem;
    border-radius: 50%;
    margin-bottom: 16px;
}

.step h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.step p {
    font-size: 0.9375rem;
    color: var(--gray-500);
    margin: 0;
}

/* ========================================
   Product Preview Section
   ======================================== */
.product-preview {
    padding: 64px 0;
    background: linear-gradient(180deg, #fff 0%, var(--gray-50) 100%);
    text-align: center;
}

.product-preview .section-label {
    margin-bottom: 12px;
}

.product-preview h2 {
    margin-bottom: 12px;
}

.product-preview .section-sub {
    margin-bottom: 40px;
}

/* Screenshot Showcase */
.screenshot-showcase {
    max-width: 1000px;
    margin: 0 auto;
}

/* Featured Screenshot */
.screenshot-featured {
    margin-bottom: 32px;
}

.screenshot-frame {
    background: var(--gray-900);
    border-radius: 12px;
    padding: 8px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.screenshot-frame img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}

.screenshot-caption {
    margin-top: 24px;
    text-align: center;
}

.caption-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
    padding: 8px 16px;
    border-radius: 24px;
    margin-bottom: 16px;
}

.cya-score {
    font-size: 1.25rem;
    font-weight: 700;
}

.cya-label {
    font-size: 0.8125rem;
    font-weight: 500;
    opacity: 0.9;
}

.screenshot-caption h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
}

.screenshot-caption p {
    font-size: 1rem;
    color: var(--gray-500);
    max-width: 500px;
    margin: 0 auto;
}

/* Secondary Screenshots Grid */
.screenshot-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-bottom: 48px;
}

.screenshot-card {
    text-align: left;
}

.screenshot-card .screenshot-frame {
    margin-bottom: 16px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    aspect-ratio: 16 / 10;
}

.screenshot-card .screenshot-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top left;
}

.screenshot-card:hover .screenshot-frame {
    transform: translateY(-4px);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.3);
}

.screenshot-card-caption h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.screenshot-card-caption p {
    font-size: 0.875rem;
    color: var(--gray-500);
    margin: 0;
}

/* Feature Callouts */
.feature-callouts {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 32px;
}

.callout {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--gray-700);
}

.callout-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--primary-100);
    color: var(--primary-500);
    border-radius: 8px;
}

.callout-icon svg {
    width: 18px;
    height: 18px;
}

/* ========================================
   Proof Pack Section (WOW Anchor)
   ======================================== */
.proof-pack {
    padding: 120px 0;
    background: var(--gray-50);
    text-align: center;
}

.proof-pack-content {
    max-width: 560px;
    margin: 0 auto;
}

.section-label {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--primary-500);
    margin-bottom: 16px;
}

.proof-pack h2 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    margin-bottom: 16px;
}

.proof-pack-sub {
    font-size: 1.125rem;
    color: var(--gray-600);
    margin-bottom: 32px;
}

.proof-pack-list {
    list-style: none;
    padding: 0;
    margin: 0 0 40px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 24px;
}

.proof-pack-list li {
    font-size: 0.9375rem;
    color: var(--gray-700);
    position: relative;
}

.proof-pack-list li:not(:last-child)::after {
    content: '\00b7';
    position: absolute;
    right: -14px;
    color: var(--gray-300);
}

.proof-pack-hint {
    font-size: 0.875rem;
    color: var(--gray-500);
    margin-top: 20px;
    font-style: italic;
}

/* Enhanced CYA Badge */
.cya-badge-enhanced {
    margin-bottom: 24px;
}

.cya-badge-main {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
    padding: 10px 20px;
    border-radius: 24px;
    font-size: 1rem;
    margin-bottom: 8px;
}

.cya-badge-main .cya-label {
    font-weight: 500;
    opacity: 1;
    font-size: 1rem;
}

.cya-badge-main .cya-status {
    font-weight: 700;
}

.cya-badge-main .cya-score {
    font-weight: 700;
    font-size: 1rem;
}

.cya-info {
    display: inline-flex;
    align-items: center;
    opacity: 0.8;
    cursor: help;
    margin-left: 4px;
}

.cya-info svg {
    width: 16px;
    height: 16px;
}

.cya-badge-note {
    font-size: 0.8125rem;
    color: var(--gray-500);
    margin: 0;
    font-style: italic;
}

/* Proof Pack Includes paragraph */
.proof-pack-includes {
    font-size: 1rem;
    color: var(--gray-600);
    line-height: 1.6;
    margin-bottom: 32px;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

/* ========================================
   Role Views
   ======================================== */
.roles {
    padding: 120px 0;
    text-align: center;
}

.roles h2 {
    margin-bottom: 12px;
}

.section-sub {
    font-size: 1.0625rem;
    color: var(--gray-500);
    margin-bottom: 56px;
}

.roles-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.role-card {
    background: #fff;
    border: 1px solid var(--gray-100);
    border-radius: 12px;
    padding: 32px 24px;
    text-align: left;
    transition: all 0.2s ease;
}

.role-card:hover {
    border-color: var(--gray-200);
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.role-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 20px;
    color: var(--primary-500);
}

.role-icon svg {
    width: 48px;
    height: 48px;
}

.role-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.role-card p {
    font-size: 0.9375rem;
    color: var(--gray-500);
    margin: 0;
    line-height: 1.5;
}

/* ========================================
   Why Scaftra
   ======================================== */
.why {
    padding: 120px 0;
    background: var(--gray-50);
    text-align: center;
}

.why h2 {
    margin-bottom: 56px;
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.why-card {
    background: #fff;
    border: 1px solid var(--gray-100);
    border-radius: 12px;
    padding: 28px;
    text-align: center;
    transition: all 0.2s ease;
}

.why-card:hover {
    border-color: var(--gray-200);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.why-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.why-card p {
    font-size: 0.9375rem;
    color: var(--gray-500);
    margin: 0;
}

/* ========================================
   FAQ
   ======================================== */
.faq {
    padding: 120px 24px;
}

.faq .container {
    max-width: 680px;
}

.faq h2 {
    text-align: center;
    margin-bottom: 56px;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.faq-item {
    border-bottom: 1px solid var(--gray-100);
    padding: 24px 0;
}

.faq-item:first-child {
    border-top: 1px solid var(--gray-100);
}

.faq-item summary {
    font-size: 1rem;
    font-weight: 600;
    color: var(--gray-900);
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '+';
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--gray-400);
    transition: transform 0.2s ease;
    flex-shrink: 0;
    margin-left: 16px;
}

.faq-item[open] summary::after {
    transform: rotate(45deg);
}

.faq-item p {
    font-size: 0.9375rem;
    color: var(--gray-600);
    margin: 16px 0 0;
    line-height: 1.6;
    padding-right: 32px;
}

/* ========================================
   Final CTA
   ======================================== */
.final-cta {
    padding: 120px 0;
    background: linear-gradient(135deg, var(--primary-900) 0%, var(--primary-700) 100%);
    color: #fff;
    text-align: center;
}

.final-cta h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: #fff;
}

.final-cta > .container > p {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 40px;
}

.cta-form {
    max-width: 480px;
    margin: 0 auto;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.cta-form input,
.cta-form select {
    width: 100%;
    padding: 14px 16px;
    font-size: 1rem;
    font-family: inherit;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    transition: all 0.15s ease;
}

.cta-form input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.cta-form select {
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='rgba(255,255,255,0.5)' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}

.cta-form select option {
    color: var(--gray-900);
    background: #fff;
}

.cta-form input:focus,
.cta-form select:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.12);
}

.cta-form .btn-primary {
    width: 100%;
    margin-top: 8px;
}

/* Form Messages */
.form-message {
    max-width: 480px;
    margin: 16px auto 0;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 500;
    animation: fadeIn 0.3s ease;
}

.form-message.success {
    background: rgba(16, 185, 129, 0.15);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.form-message.error {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* ========================================
   Footer
   ======================================== */
.footer {
    padding: 48px 0 32px;
    background: var(--gray-950);
    color: #fff;
    text-align: center;
}

.footer-brand {
    margin-bottom: 24px;
}

.footer-logo {
    font-size: 1.25rem;
    font-weight: 700;
    display: block;
    margin-bottom: 8px;
}

.footer-brand p {
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
}

.footer-legal {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.3);
    margin: 0;
}

/* ========================================
   Scroll Reveal Animation
   ======================================== */
.reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

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

/* Stagger animation delays for grid items */
.outcomes-grid .reveal:nth-child(1) { transition-delay: 0s; }
.outcomes-grid .reveal:nth-child(2) { transition-delay: 0.1s; }
.outcomes-grid .reveal:nth-child(3) { transition-delay: 0.2s; }

.steps-grid .reveal:nth-child(1) { transition-delay: 0.1s; }
.steps-grid .reveal:nth-child(2) { transition-delay: 0.2s; }
.steps-grid .reveal:nth-child(3) { transition-delay: 0.3s; }

.roles-grid .reveal:nth-child(1) { transition-delay: 0.1s; }
.roles-grid .reveal:nth-child(2) { transition-delay: 0.15s; }
.roles-grid .reveal:nth-child(3) { transition-delay: 0.2s; }
.roles-grid .reveal:nth-child(4) { transition-delay: 0.25s; }
.roles-grid .reveal:nth-child(5) { transition-delay: 0.3s; }

.why-grid .reveal:nth-child(1) { transition-delay: 0.1s; }
.why-grid .reveal:nth-child(2) { transition-delay: 0.15s; }
.why-grid .reveal:nth-child(3) { transition-delay: 0.2s; }
.why-grid .reveal:nth-child(4) { transition-delay: 0.25s; }

/* ========================================
   Animations
   ======================================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   Responsive Design
   ======================================== */

/* Tablet */
@media (max-width: 992px) {
    h1 {
        font-size: 3rem;
    }

    h2 {
        font-size: 2rem;
    }

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

    .how-it-works,
    .product-preview,
    .proof-pack,
    .roles,
    .why,
    .faq,
    .final-cta {
        padding: 80px 0;
    }

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

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

    .steps-grid {
        gap: 32px;
    }

    .feature-callouts {
        gap: 24px;
    }
}

/* Mobile Landscape */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    .hero {
        padding: 120px 0 80px;
    }

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

    .how-it-works,
    .product-preview,
    .proof-pack,
    .roles,
    .why,
    .faq,
    .final-cta {
        padding: 64px 0;
    }

    .outcomes-grid,
    .steps-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .roles-grid,
    .why-grid {
        grid-template-columns: 1fr;
    }

    .proof-pack h2 {
        font-size: 2rem;
    }

    .proof-pack-list {
        flex-direction: column;
        gap: 8px;
    }

    .proof-pack-list li:not(:last-child)::after {
        display: none;
    }

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

    /* Product Preview Mobile */
    .screenshot-grid {
        grid-template-columns: 1fr;
    }

    .feature-callouts {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }

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

    .screenshot-card-caption {
        text-align: center;
    }
}

/* Mobile Portrait */
@media (max-width: 576px) {
    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    .hero {
        padding: 100px 0 64px;
    }

    .hero-sub {
        font-size: 1rem;
    }

    .how-it-works,
    .product-preview,
    .proof-pack,
    .roles,
    .why,
    .faq,
    .final-cta {
        padding: 56px 0;
    }

    .how-it-works h2,
    .why h2 {
        margin-bottom: 40px;
    }

    .btn-primary {
        padding: 14px 24px;
        font-size: 0.9375rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .role-card,
    .why-card {
        padding: 24px 20px;
    }

    .faq-item summary {
        font-size: 0.9375rem;
    }

    .faq-item p {
        padding-right: 0;
    }

    .final-cta h2 {
        font-size: 2rem;
    }

    /* Product Preview Mobile Portrait */
    .product-preview .section-sub {
        margin-bottom: 40px;
    }

    .screenshot-caption h3 {
        font-size: 1.125rem;
    }

    .callout {
        font-size: 0.875rem;
    }

    .callout-icon {
        width: 32px;
        height: 32px;
    }

    .callout-icon svg {
        width: 16px;
        height: 16px;
    }
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .btn-primary:hover {
        transform: none;
    }

    .role-card:hover,
    .why-card:hover {
        transform: none;
    }

    .faq-item summary::after {
        transition: none;
    }
}
