/* ========================================
   CSS Variables - Color Palette
   ======================================== */
:root {
    /* Primary - Slate */
    --primary: #0f172a;
    --primary-50: #f8fafc;
    --primary-100: #f1f5f9;
    --primary-200: #e2e8f0;
    --primary-300: #cbd5e1;
    --primary-400: #94a3b8;
    --primary-500: #64748b;
    --primary-600: #475569;
    --primary-700: #334155;
    --primary-800: #1e293b;
    --primary-900: #0f172a;

    /* Brand - Blue */
    --brand: #2563eb;
    --brand-50: #eff6ff;
    --brand-100: #dbeafe;
    --brand-200: #bfdbfe;
    --brand-300: #93c5fd;
    --brand-400: #60a5fa;
    --brand-500: #3b82f6;
    --brand-600: #2563eb;
    --brand-700: #1d4ed8;
    --brand-800: #1e40af;
    --brand-900: #1e3a8a;

    /* Secondary - Pink */
    --secondary: #e43a5f;
    --secondary-hover: #c92a4b;

    /* Accent - Cyan */
    --accent: #06b6d4;
    --accent-50: #ecfeff;
    --accent-100: #cffafe;
    --accent-200: #a5f3fc;
    --accent-300: #67e8f9;
    --accent-400: #22d3ee;
    --accent-500: #06b6d4;
    --accent-600: #0891b2;
    --accent-700: #0e7490;
    --accent-800: #155e75;
    --accent-900: #164e63;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background-color: #ffffff;
    color: var(--primary);
    line-height: 1.6;
}

/* ========================================
   Header
   ======================================== */
header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 20;
    padding: 1rem 1.5rem;
}

.header-container {
    max-width: 80rem;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    height: 2.5rem;
    width: auto;
}

.logo-placeholder {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--primary);
}

.logo-placeholder span {
    width: 2.5rem;
    height: 2.5rem;
    background: linear-gradient(135deg, var(--brand-600), var(--accent-500));
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    position: relative;
    padding: 8rem 1.5rem 6rem;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(255, 255, 255, 0.90), rgba(255, 255, 255, 0.85)),
        url('../img/hero.png');
    background-size: cover;
    background-position: center;
    z-index: -2;
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(1200px 400px at 50% -10%, rgba(37, 99, 235, 0.15), transparent 60%);
    animation: gradient-pulse 8s ease-in-out infinite;
    z-index: -1;
}

@keyframes gradient-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

.hero-content {
    max-width: 64rem;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 10;
}

/* Badge Styles */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.badge-coming-soon {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(37, 99, 235, 0.2);
    color: var(--primary-700);
    box-shadow: 0 2px 15px -3px rgba(0, 0, 0, 0.07), 0 10px 20px -2px rgba(0, 0, 0, 0.04);
    animation: float 3s ease-in-out infinite;
}

.badge-red {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.badge-green {
    background: #f0fdf4;
    color: #15803d;
    border: 1px solid #bbf7d0;
}

.badge-cyan {
    background: var(--accent-50);
    color: var(--accent-700);
    border: 1px solid var(--accent-200);
}

.badge-dark {
    background: #1e293b;
    color: #a5f3fc;
}

.badge-icon {
    width: 1rem;
    height: 1rem;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

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

.gradient-text {
    background: linear-gradient(to right, var(--brand-600), var(--accent-500));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Hero Description */
.hero-description {
    font-size: clamp(1.125rem, 2vw, 1.5rem);
    color: var(--primary-700);
    margin-bottom: 3rem;
    line-height: 1.7;
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
    font-weight: 500;
}

/* ========================================
   Waitlist Form
   ======================================== */
.waitlist-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    max-width: 28rem;
    margin: 0 auto;
}

.form-row {
    display: flex;
    gap: 0.75rem;
    width: 100%;
}

.email-input {
    flex: 1;
    padding: 1rem 1.25rem;
    border: 2px solid var(--primary-200);
    border-radius: 9999px;
    font-size: 1rem;
    font-family: inherit;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
    transition: all 0.3s ease;
    outline: none;
}

.email-input:focus {
    border-color: var(--brand-500);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.email-input::placeholder {
    color: var(--primary-400);
}

.btn-waitlist {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.75rem;
    background: var(--secondary);
    color: white;
    font-size: 0.875rem;
    font-weight: 600;
    border: none;
    border-radius: 9999px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    font-family: inherit;
    box-shadow: 0 4px 15px -3px rgba(228, 58, 95, 0.4);
}

.btn-waitlist:hover {
    background: var(--secondary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(228, 58, 95, 0.5);
}

.btn-waitlist:active {
    transform: translateY(0);
}

.form-note {
    font-size: 0.75rem;
    color: var(--primary-500);
    margin-top: 0.5rem;
}

/* Arrow Icon */
.arrow-icon {
    width: 1.25rem;
    height: 1.25rem;
    transition: transform 0.3s ease;
}

.btn-waitlist:hover .arrow-icon {
    transform: translateX(4px);
}

/* ========================================
   Section Headers (Shared)
   ======================================== */
.section-header {
    text-align: center;
    max-width: 48rem;
    margin: 0 auto 4rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 1rem;
    line-height: 1.2;
}

.section-description {
    font-size: 1.25rem;
    color: var(--primary-600);
    line-height: 1.7;
}

/* ========================================
   Problem Section
   ======================================== */
.problem-section {
    padding: 6rem 1.5rem;
    background: linear-gradient(to bottom,
        #ffffff 0%,
        #f9fafb 50%,
        rgba(254, 242, 242, 0.4) 100%
    );
}

.problem-container {
    max-width: 48rem;
    margin: 0 auto;
}

.problem-cards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-width: 56rem;
    margin: 0 auto;
}

.problem-card {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 4px 20px -5px rgba(0, 0, 0, 0.1);
    border: 1px solid #f1f5f9;
    transition: all 0.3s ease;
}

.problem-card:hover {
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
}

.problem-card p {
    font-size: 1.125rem;
    color: var(--primary-700);
    line-height: 1.7;
}

.problem-card strong {
    color: var(--primary-900);
    font-weight: 700;
}

/* ========================================
   Workflow Section
   ======================================== */
.workflow-section {
    padding: 6rem 1.5rem;
    background: linear-gradient(to bottom,
        rgba(240, 253, 244, 0.3) 0%,
        #f9fafb 50%,
        #ffffff 100%
    );
    position: relative;
    overflow: hidden;
}

.workflow-section::before {
    content: '';
    position: absolute;
    top: 25%;
    left: 0;
    width: 24rem;
    height: 24rem;
    background: var(--brand-200);
    border-radius: 50%;
    mix-blend-mode: multiply;
    filter: blur(80px);
    opacity: 0.2;
    z-index: 0;
}

.workflow-section::after {
    content: '';
    position: absolute;
    bottom: 25%;
    right: 0;
    width: 24rem;
    height: 24rem;
    background: var(--accent-200);
    border-radius: 50%;
    mix-blend-mode: multiply;
    filter: blur(80px);
    opacity: 0.2;
    z-index: 0;
}

.workflow-container {
    max-width: 48rem;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.workflow-steps {
    max-width: 40rem;
    margin: 0 auto;
}

.workflow-step {
    margin-bottom: 2rem;
}

.workflow-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 20px -5px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.workflow-card:hover {
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15);
}

.workflow-card.highlight {
    border-color: #c4b5fd;
    box-shadow: 0 4px 20px -5px rgba(139, 92, 246, 0.15);
}

.workflow-card-content {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.workflow-number {
    flex-shrink: 0;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 1.25rem;
    box-shadow: 0 4px 10px -2px rgba(0, 0, 0, 0.2);
}

.workflow-number.blue { background: linear-gradient(135deg, #3b82f6, #2563eb); }
.workflow-number.purple { background: linear-gradient(135deg, #a855f7, #9333ea); }
.workflow-number.emerald { background: linear-gradient(135deg, #10b981, #059669); }
.workflow-number.orange { background: linear-gradient(135deg, #f97316, #ea580c); }
.workflow-number.rose { background: linear-gradient(135deg, #f43f5e, #e11d48); }
.workflow-number.indigo { background: linear-gradient(135deg, #6366f1, #06b6d4); }

.workflow-number svg {
    width: 1.5rem;
    height: 1.5rem;
    stroke: white;
}

.workflow-text {
    flex: 1;
}

.workflow-text h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-900);
    margin-bottom: 0.25rem;
}

.workflow-text p {
    font-size: 0.9375rem;
    color: var(--primary-600);
    line-height: 1.6;
}

.workflow-icon {
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    color: var(--primary-300);
}

.ai-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.375rem 0.75rem;
    background: #f3e8ff;
    color: #7c3aed;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 9999px;
    border: 1px solid #ddd6fe;
    margin-top: 1rem;
}

.workflow-arrow {
    display: flex;
    justify-content: center;
    padding: 1rem 0;
}

.workflow-arrow-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.workflow-arrow svg {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--primary-300);
}

.workflow-arrow-line {
    width: 2px;
    height: 1rem;
    background: linear-gradient(to bottom, var(--primary-200), transparent);
}

/* ========================================
   Personas Section
   ======================================== */
.personas-section {
    padding: 5rem 1.5rem;
    background: #0f172a;
    position: relative;
    overflow: hidden;
}

.personas-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(228, 58, 95, 0.18), transparent),
        radial-gradient(ellipse 60% 40% at 90% 110%, rgba(253, 216, 53, 0.12), transparent);
}

.personas-container {
    max-width: 56rem;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.personas-header {
    text-align: center;
    max-width: 32rem;
    margin: 0 auto 4rem;
}

.personas-header h3 {
    font-size: clamp(1.875rem, 3.5vw, 2.5rem);
    font-weight: 700;
    color: white;
    margin-top: 0.75rem;
    margin-bottom: 1.5rem;
}

.personas-header p {
    font-size: 1.125rem;
    color: #94a3b8;
}

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

.persona-card {
    background: rgba(30, 41, 59, 0.5);
    padding: 1.5rem;
    border-radius: 0.75rem;
    border: 1px solid #334155;
    box-shadow: 0 4px 15px -5px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.persona-card:hover {
    background: #1e293b;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.4);
}

.persona-card svg {
    width: 2rem;
    height: 2rem;
    color: var(--accent-500);
    margin-bottom: 1rem;
}

.persona-card h4 {
    font-size: 1rem;
    font-weight: 600;
    color: white;
    margin-bottom: 0.5rem;
}

.persona-card p {
    font-size: 0.875rem;
    color: #94a3b8;
}

/* ========================================
   FAQ Section
   ======================================== */
.faq-section {
    padding: 5rem 1.5rem;
}

.faq-container {
    max-width: 72rem;
    margin: 0 auto;
}

.faq-header {
    margin-bottom: 3rem;
}

.faq-header h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 1rem;
}

.faq-header p {
    font-size: 1.125rem;
    color: var(--primary-600);
}

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

.faq-item h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-900);
    margin-bottom: 0.5rem;
}

.faq-item p {
    font-size: 0.875rem;
    color: var(--primary-600);
    line-height: 1.6;
}

/* ========================================
   Footer
   ======================================== */
.footer-wrapper {
    position: relative;
    background-size: cover;
    background-position: center;
}

.footer-overlay {
    position: relative;
}

.footer-overlay::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0.85));
}

.footer-content {
    position: relative;
}

footer {
    padding: 2.5rem 1.5rem;
    border-top: 1px solid var(--primary-200);
    background: transparent;
}

.footer-container {
    max-width: 72rem;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.footer-row {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
}

.footer-left {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer-logo {
    height: 2.25rem;
    width: auto;
    filter: grayscale(100%);
    opacity: 0.7;
}

.footer-logo-placeholder {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--primary-500);
}

.footer-logo-placeholder img {
    opacity: 0.7;
}

.footer-right {
    display: flex;
    align-items: flex-start;
}

.footer-copyright {
    font-size: 0.875rem;
    color: var(--primary-500);
}

/* ========================================
   Responsive Styles
   ======================================== */
@media (min-width: 640px) {
    header {
        padding: 1rem 1.5rem;
    }

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

    .footer-row {
        flex-direction: row;
        align-items: flex-end;
    }

    .footer-right {
        align-items: flex-end;
        text-align: right;
    }
}

@media (max-width: 480px) {
    .form-row {
        flex-direction: column;
    }

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

    .workflow-card-content {
        flex-direction: column;
    }

    .workflow-icon {
        display: none;
    }
}

/* ========================================
   Reduced Motion
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    .badge-coming-soon {
        animation: none;
    }

    .hero::after {
        animation: none;
    }

    .problem-card:hover,
    .workflow-card:hover,
    .persona-card:hover {
        transform: none;
    }

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

    .btn-waitlist:hover .arrow-icon {
        transform: none;
    }
}

/* ========================================
   Toast Notifications
   ======================================== */
#toast-container {
    position: fixed;
    top: 1.5rem;
    right: 1.5rem;
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    pointer-events: none; /* Let clicks pass through container */
}

.toast {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    min-width: 20rem;
    max-width: 24rem;
    pointer-events: auto; /* Re-enable clicks on toasts */
    animation: toast-in 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    border: 1px solid transparent;
}

.toast.hiding {
    animation: toast-out 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes toast-out {
    from {
        opacity: 1;
        transform: translateX(0);
    }
    to {
        opacity: 0;
        transform: translateX(100%);
    }
}

.toast-icon {
    flex-shrink: 0;
    width: 1.5rem;
    height: 1.5rem;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    font-size: 0.9375rem;
    margin-bottom: 0.25rem;
    color: var(--primary-900);
}

.toast-message {
    font-size: 0.875rem;
    color: var(--primary-600);
    line-height: 1.4;
}

.toast-close {
    flex-shrink: 0;
    color: var(--primary-400);
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.25rem;
    border-radius: 0.25rem;
    transition: all 0.2s;
}

.toast-close:hover {
    background: var(--primary-100);
    color: var(--primary-600);
}

/* Success State */
.toast.success {
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.toast.success .toast-title {
    color: #15803d;
}

.toast.success .toast-icon {
    color: #16a34a;
}

/* Error State */
.toast.error {
    background: #fef2f2;
    border-color: #fecaca;
}

.toast.error .toast-title {
    color: #b91c1c;
}

.toast.error .toast-icon {
    color: #dc2626;
}

/* ========================================
   Already Joined Message
   ======================================== */
.already-joined {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border: 2px solid #86efac;
    border-radius: 9999px;
    color: #15803d;
    font-size: 1rem;
    font-weight: 600;
    animation: fade-in 0.4s ease-out;
}

.already-joined-icon {
    width: 1.5rem;
    height: 1.5rem;
    color: #16a34a;
    flex-shrink: 0;
}

@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive adjustments for already-joined */
@media (max-width: 639px) {
    .already-joined {
        font-size: 0.875rem;
        padding: 0.875rem 1.25rem;
    }

    .already-joined-icon {
        width: 1.25rem;
        height: 1.25rem;
    }
}
