/* ============================================
   V8Loans — Premium Fintech Design System
   British Racing Green + Gold
   ============================================ */

:root {
    /* Color System */
    --green-950: #001A0D;
    --green-900: #003D1E;
    --green-800: #004D2C;
    --green-700: #006B3D;
    --green-600: #008A4F;
    --green-500: #00B368;
    --green-400: #2DD88A;
    --green-300: #6EEAB2;
    --green-200: #A8F4D2;
    --green-100: #D4FAE9;
    --green-50: #EDFDF5;

    --gold-600: #A3842E;
    --gold-500: #C6A14E;
    --gold-400: #D4B46A;
    --gold-300: #E2C88E;
    --gold-200: #EFD9AD;
    --gold-100: #F7ECDA;

    --neutral-950: #0C0D0E;
    --neutral-900: #1A1D1F;
    --neutral-800: #2E3134;
    --neutral-700: #44484C;
    --neutral-600: #5C6166;
    --neutral-500: #7A7F84;
    --neutral-400: #A1A5A9;
    --neutral-300: #C8CACF;
    --neutral-200: #E2E3E6;
    --neutral-100: #F0F1F3;
    --neutral-50: #F9F9FA;

    --cream: #FAF9F6;
    --white: #FFFFFF;

    /* Semantic Tokens */
    --primary: var(--green-800);
    --primary-hover: var(--green-700);
    --primary-foreground: var(--white);
    --accent: var(--green-500);
    --gold: var(--gold-500);
    --background: var(--cream);
    --surface: var(--white);
    --foreground: var(--neutral-900);
    --foreground-muted: var(--neutral-600);
    --border: var(--neutral-200);
    --border-light: var(--neutral-100);

    /* Typography */
    --font-display: 'Bricolage Grotesque', Georgia, serif;
    --font-body: 'DM Sans', system-ui, sans-serif;

    /* Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.25rem;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.06), 0 2px 4px -2px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.06), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.06), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
    --shadow-card: 0 0 0 1px var(--border-light), 0 2px 4px rgba(0, 0, 0, 0.03), 0 8px 20px rgba(0, 0, 0, 0.04);
    --shadow-card-hover: 0 0 0 1px var(--border), 0 4px 8px rgba(0, 0, 0, 0.05), 0 16px 32px rgba(0, 0, 0, 0.06);
}

/* ---- Reset & Base ---- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body) !important;
    background: var(--background) !important;
    color: var(--foreground) !important;
    line-height: 1.6;
    font-size: 16px;
    margin: 0;
}

/* ---- Typography ---- */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display) !important;
    font-weight: 700 !important;
    color: var(--foreground) !important;
    line-height: 1.12;
    letter-spacing: -0.025em;
}

p {
    line-height: 1.7;
}

sup {
    font-size: 0.65em;
    opacity: 0.6;
}

/* ---- Navigation ---- */
.nav-link {
    position: relative;
    color: var(--foreground);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9375rem;
    transition: color 0.2s ease;
    padding: 0.25rem 0;
}

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

.nav-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 1.5px;
    background: var(--green-700);
    transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-link:hover::after {
    width: 100%;
}

/* ---- Buttons ---- */
.button-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: var(--primary) !important;
    color: var(--primary-foreground) !important;
    font-family: var(--font-body) !important;
    font-weight: 600 !important;
    font-size: 0.9375rem;
    border: none;
    border-radius: var(--radius-lg) !important;
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0, 77, 44, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

.button-primary:hover {
    background: var(--primary-hover) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(0, 77, 44, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

.button-primary:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(0, 77, 44, 0.15) !important;
}

.button-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: transparent;
    color: var(--foreground);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.9375rem;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
}

.button-outline:hover {
    border-color: var(--green-700);
    color: var(--green-700);
    background: var(--green-50);
}

/* ---- Cards ---- */
.card {
    background: var(--surface) !important;
    border: 1px solid var(--border-light) !important;
    border-radius: var(--radius-xl) !important;
    padding: 1.5rem !important;
    box-shadow: var(--shadow-card) !important;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.card:hover {
    box-shadow: var(--shadow-card-hover) !important;
    transform: translateY(-2px);
}

/* ---- Badge ---- */
.badge-trust {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--foreground-muted);
    padding: 0.375rem 0.75rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-full);
    transition: all 0.2s ease;
    box-shadow: none !important;
    transform: none !important;
}

.badge-trust:hover {
    border-color: var(--green-200);
    background: var(--green-50);
    color: var(--green-800);
    box-shadow: none !important;
    transform: none !important;
}

/* ---- Section Label ---- */
.section-label {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--green-700);
    padding: 0.3rem 0.75rem;
    background: var(--green-50);
    border: 1px solid var(--green-200);
    border-radius: var(--radius-full);
}

/* ---- Form Elements ---- */
input,
select,
textarea {
    background: var(--surface) !important;
    border: 1.5px solid var(--border) !important;
    border-radius: var(--radius-md) !important;
    padding: 0.75rem 1rem !important;
    font-family: var(--font-body) !important;
    font-size: 0.9375rem !important;
    color: var(--foreground) !important;
    outline: none !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: none !important;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--green-600) !important;
    box-shadow: 0 0 0 3px rgba(0, 179, 104, 0.1) !important;
}

/* ---- FAQ ---- */
.faq-item {
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background: var(--surface);
}

.faq-item:hover {
    border-color: var(--neutral-300);
    box-shadow: var(--shadow-sm);
}

.faq-chevron {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 2rem;
    height: 2rem;
    border-radius: var(--radius-full);
    background: var(--neutral-50);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--foreground-muted);
}

.faq-item:hover .faq-chevron {
    background: var(--green-50);
    color: var(--green-700);
}

/* ---- Footer ---- */
footer {
    background: var(--surface) !important;
    color: var(--foreground-muted) !important;
    font-size: 0.9375rem !important;
    border-top: 1px solid var(--border) !important;
}

/* ---- Scroll Reveal ---- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.stagger > .reveal:nth-child(1) { transition-delay: 0ms; }
.stagger > .reveal:nth-child(2) { transition-delay: 80ms; }
.stagger > .reveal:nth-child(3) { transition-delay: 160ms; }
.stagger > .reveal:nth-child(4) { transition-delay: 240ms; }
.stagger > .reveal:nth-child(5) { transition-delay: 320ms; }
.stagger > .reveal:nth-child(6) { transition-delay: 400ms; }

/* Hero entrance animation */
.hero-enter {
    opacity: 0;
    transform: translateY(30px);
    animation: heroFadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.hero-enter:nth-child(1) { animation-delay: 0.1s; }
.hero-enter:nth-child(2) { animation-delay: 0.2s; }
.hero-enter:nth-child(3) { animation-delay: 0.3s; }
.hero-enter:nth-child(4) { animation-delay: 0.4s; }
.hero-enter:nth-child(5) { animation-delay: 0.5s; }

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

/* Grain texture overlay for dark sections */
.grain-overlay {
    position: relative;
}

.grain-overlay::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.35;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.7' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 256px;
    pointer-events: none;
    z-index: 1;
    border-radius: inherit;
}

/* Step number badge */
.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: var(--radius-xl);
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.125rem;
    flex-shrink: 0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.step-card:hover .step-number {
    transform: scale(1.08);
    box-shadow: 0 4px 12px rgba(0, 77, 44, 0.2);
}

/* Step connector (desktop only) */
@media (min-width: 768px) {
    .step-connector {
        position: absolute;
        top: 1.5rem;
        left: calc(100% + 0.5rem);
        width: calc(100% - 3rem);
        height: 1px;
        background: linear-gradient(90deg, var(--green-300), var(--border));
    }
}

/* Disclaimers */
.disclaimerWrap p {
    margin-bottom: 0.6em;
    font-size: 0.75rem;
    line-height: 1.6;
    opacity: 0.6;
}

.disclaimerWrap p strong {
    opacity: 1;
    font-weight: 600;
}

/* Utility: no-hover for form card */
.card-static:hover {
    transform: none !important;
    box-shadow: var(--shadow-card) !important;
}
