/* ===================================================================
   MC MORTGAGE SOLUTIONS - PREMIUM CORE STYLESHEET
   Brand: Purple (#47235b) & Mortgage Alliance Teal (#007664) & Gold (#c59b27)
   License: FSRA Lic. # 10530 | Ancaster, Ontario
   =================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Inter:wght@400;500;600;700&display=swap');

:root {
    --primary: #47235b;
    --primary-dark: #321841;
    --primary-light: #5f317b;
    --primary-soft: #f4edf7;

    --teal: #007664;
    --teal-dark: #005a4d;
    --teal-light: #0d9488;
    --teal-soft: #e6f6f4;

    --gold: #c59b27;
    --gold-dark: #9e7a1b;
    --gold-light: #e6b83f;
    --gold-soft: #fdf8eb;

    --slate-900: #0f172a;
    --slate-800: #1e293b;
    --slate-700: #334155;
    --slate-600: #475569;
    --slate-500: #64748b;
    --slate-400: #94a3b8;
    --slate-300: #cbd5e1;
    --slate-200: #e2e8f0;
    --slate-100: #f1f5f9;
    --slate-50: #f8fafc;
    --white: #ffffff;

    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;
    --font-sub: 'Inter', sans-serif;

    --shadow-sm: 0 2px 4px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 12px 28px rgba(15, 23, 42, 0.1);
    --shadow-xl: 0 20px 40px -10px rgba(71, 35, 91, 0.16);
    --shadow-glow: 0 0 25px rgba(197, 155, 39, 0.3);

    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    --container-max: 1440px;
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--slate-700);
    background-color: var(--white);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

ul,
ol {
    list-style: none;
}

button,
input,
select,
textarea {
    font-family: inherit;
    font-size: inherit;
    outline: none;
}

.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 2.5rem;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--slate-900);
    font-weight: 700;
    line-height: 1.25;
}

h1 {
    font-size: clamp(2.25rem, 5vw, 3.5rem);
    letter-spacing: -0.02em;
}

h2 {
    font-size: clamp(1.85rem, 3.5vw, 2.5rem);
    letter-spacing: -0.015em;
}

h3 {
    font-size: clamp(1.35rem, 2.5vw, 1.75rem);
}

h4 {
    font-size: 1.2rem;
}

h5 {
    font-size: 1.05rem;
}

.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.95rem;
    background: var(--primary-soft);
    color: var(--primary);
    border: 1px solid rgba(71, 35, 91, 0.15);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
}

.section-tag.teal {
    background: var(--teal-soft);
    color: var(--teal);
    border-color: rgba(0, 118, 100, 0.2);
}

.section-tag.gold {
    background: var(--gold-soft);
    color: var(--gold-dark);
    border-color: rgba(197, 155, 39, 0.25);
}

.section-title-center {
    text-align: center;
    max-width: 760px;
    margin: 0 auto 3.5rem auto;
}

.section-title-center h2 {
    margin-bottom: 1rem;
}

.section-title-center p {
    color: var(--slate-600);
    font-size: 1.1rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.85rem 1.75rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    box-shadow: 0 4px 14px rgba(71, 35, 91, 0.25);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    box-shadow: 0 8px 22px rgba(71, 35, 91, 0.35);
    transform: translateY(-2px);
    color: var(--white);
}

.btn-teal {
    background: linear-gradient(135deg, var(--teal) 0%, var(--teal-light) 100%);
    color: var(--white);
    box-shadow: 0 4px 14px rgba(0, 118, 100, 0.25);
}

.btn-teal:hover {
    background: linear-gradient(135deg, var(--teal-dark) 0%, var(--teal) 100%);
    box-shadow: 0 8px 22px rgba(0, 118, 100, 0.35);
    transform: translateY(-2px);
    color: var(--white);
}

.btn-gold {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: var(--slate-900);
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(197, 155, 39, 0.3);
}

.btn-gold:hover {
    box-shadow: 0 8px 22px rgba(197, 155, 39, 0.45);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-outline-white {
    background: transparent;
    color: var(--white);
    border: 1.5px solid rgba(255, 255, 255, 0.6);
}

.btn-outline-white:hover {
    background: var(--white);
    color: var(--slate-900);
    border-color: var(--white);
    transform: translateY(-2px);
}

.btn-sm {
    padding: 0.55rem 1.15rem;
    font-size: 0.85rem;
    border-radius: var(--radius-sm);
}

.btn-lg {
    padding: 1.1rem 2.25rem;
    font-size: 1.05rem;
    border-radius: var(--radius-lg);
}

/* Top Notification / Contact Bar */
.topbar {
    background: var(--slate-900);
    color: var(--slate-300);
    font-size: 0.825rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    position: relative;
    z-index: 101;
}

.topbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.45rem;
    padding-bottom: 0.45rem;
}

.topbar-left,
.topbar-right {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.topbar-item {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.topbar-item svg {
    width: 14px;
    height: 14px;
    color: var(--gold);
}

.topbar-item a:hover {
    color: var(--white);
}

.topbar-badge {
    background: rgba(255, 255, 255, 0.1);
    color: var(--slate-200);
    padding: 0.15rem 0.6rem;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    letter-spacing: 0.02em;
}

/* Header & Main Navigation */
.site-header {
    background: var(--white);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
    transition: var(--transition);
}

.site-header.scrolled {
    box-shadow: 0 8px 30px rgba(15, 23, 42, 0.12);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}

.brand-wrapper {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.brand-logo-main {
    height: 72px;
    width: auto;
    object-fit: contain;
}

.brand-divider {
    width: 1px;
    height: 38px;
    background: var(--slate-200);
}

.brand-logo-partner {
    height: 28px;
    width: auto;
    object-fit: contain;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 1.75rem;
}

.nav-menu a {
    color: var(--slate-700);
    font-weight: 600;
    font-size: 0.925rem;
    position: relative;
    padding: 0.4rem 0;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2.5px;
    background: var(--primary);
    border-radius: var(--radius-full);
    transition: var(--transition);
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.nav-ctas {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-toggle span {
    display: block;
    width: 24px;
    height: 2.5px;
    background: var(--slate-800);
    margin: 5px 0;
    border-radius: 2px;
    transition: var(--transition);
}

/* Mobile Nav Drawer */
.mobile-nav-drawer {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(8px);
    z-index: 200;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-nav-drawer.active {
    opacity: 1;
    pointer-events: auto;
}

.drawer-content {
    position: absolute;
    top: 0;
    right: 0;
    width: 310px;
    height: 100%;
    background: var(--white);
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.15);
}

.mobile-nav-drawer.active .drawer-content {
    transform: translateX(0);
}

.drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--slate-100);
}

.drawer-close {
    background: none;
    border: none;
    font-size: 1.8rem;
    color: var(--slate-600);
    cursor: pointer;
}

.drawer-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overflow-y: auto;
}

.drawer-links a {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--slate-800);
    padding: 0.75rem 0.5rem;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background 0.15s ease, color 0.15s ease;
    border-bottom: 1px solid var(--slate-100);
}

.drawer-links a:active,
.drawer-links a:hover,
.drawer-links a.active {
    color: var(--primary);
    background: rgba(43, 17, 57, 0.05);
}

/* Hero Section */
.hero-section {
    position: relative;
    background: linear-gradient(135deg, #2b1139 0%, #47235b 50%, #20112a 100%);
    color: var(--white);
    padding: 5rem 0 5.5rem 0;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 85% 30%, rgba(0, 118, 100, 0.25) 0%, transparent 60%),
        radial-gradient(circle at 15% 80%, rgba(197, 155, 39, 0.2) 0%, transparent 50%);
    pointer-events: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 3.5rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    color: var(--white);
    margin-bottom: 1.25rem;
}

.hero-content h1 span.gold {
    color: var(--gold-light);
    display: block;
}

.hero-lead {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.88);
    margin-bottom: 2rem;
    line-height: 1.7;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2.25rem;
}

.hero-badge-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.9rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 500;
}

.hero-badge-item svg {
    color: var(--gold);
    width: 16px;
    height: 16px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.hero-card-visual {
    position: relative;
}

.hero-image-frame {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.hero-image-frame img {
    width: 100%;
    height: auto;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.hero-image-frame:hover img {
    transform: scale(1.02);
}

.hero-float-badge {
    position: absolute;
    bottom: -1.5rem;
    left: -1.5rem;
    background: var(--white);
    color: var(--slate-900);
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 3;
}

.float-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    background: var(--teal-soft);
    color: var(--teal);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.float-text strong {
    display: block;
    font-size: 1.25rem;
    color: var(--slate-900);
    font-weight: 800;
}

.float-text span {
    font-size: 0.825rem;
    color: var(--slate-500);
}

/* Trust Bar / Stats Section */
.trust-bar {
    background: var(--white);
    padding: 2.5rem 0;
    border-bottom: 1px solid var(--slate-100);
    box-shadow: var(--shadow-sm);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.stat-item {
    text-align: center;
    padding: 0.5rem 1rem;
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
    margin-bottom: 0.35rem;
}

.stat-number span.accent {
    color: var(--gold);
}

.stat-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--slate-600);
}

/* Standard Section Layouts */
.section {
    padding: 5.5rem 0;
}

.section-bg-slate {
    background-color: var(--slate-50);
}

.section-bg-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: var(--white);
}

.section-bg-primary h2,
.section-bg-primary h3 {
    color: var(--white);
}

/* Service Cards Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.services-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

/* Process Highlight Steps Grid — separate from services-grid to avoid inline override */
.process-steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    position: relative;
}

/* Connector line between steps (desktop only) */
.process-steps-grid::before {
    content: '';
    position: absolute;
    top: 2.75rem; /* align with center of icon */
    left: calc(16.67% + 1rem);
    right: calc(16.67% + 1rem);
    height: 2px;
    background: linear-gradient(90deg, var(--primary-soft), var(--teal-soft), var(--gold-soft));
    z-index: 0;
    pointer-events: none;
}

.process-step-card {
    position: relative;
    z-index: 1;
}

.process-step-content {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.process-step-content .service-card-link {
    margin-top: auto;
}

.process-step-card .service-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    width: fit-content;
    background: var(--primary-soft);
    color: var(--primary);
    border: 1px solid rgba(71, 35, 91, 0.12);
    transition: var(--transition);
}

.process-step-card:nth-child(2) .service-card-link {
    background: var(--teal-soft);
    color: var(--teal);
    border-color: rgba(13, 148, 136, 0.15);
}

.process-step-card:nth-child(3) .service-card-link {
    background: var(--gold-soft);
    color: var(--gold-dark);
    border-color: rgba(217, 119, 6, 0.2);
}

.process-step-card:hover .service-card-link {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.process-step-num {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 800;
    width: 56px;
    height: 56px;
    flex-shrink: 0;
}

.service-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 2.25rem 2rem;
    border: 1px solid var(--slate-200);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--gold));
    opacity: 0;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(71, 35, 91, 0.2);
}

.service-card:hover::before {
    opacity: 1;
}

.service-card-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    background: var(--primary-soft);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    font-size: 1.6rem;
    transition: var(--transition);
}

.service-card:hover .service-card-icon {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.05);
}

.service-card h3 {
    font-size: 1.35rem;
    margin-bottom: 0.85rem;
}

.service-card p {
    color: var(--slate-600);
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.service-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--primary);
    font-weight: 700;
    font-size: 0.9rem;
}

.service-card-link svg {
    width: 16px;
    height: 16px;
    transition: transform 0.2s ease;
}

.service-card:hover .service-card-link svg {
    transform: translateX(4px);
}

/* Interactive Calculator Container */
.calculator-card {
    background: var(--white);
    border-radius: var(--radius-xl);
    box-shadow: 0 20px 45px rgba(15, 23, 42, 0.08);
    border: 1px solid var(--slate-200);
    overflow: hidden;
}

.calc-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
}

.calc-inputs {
    padding: 2.75rem;
}

.calc-results {
    background: linear-gradient(135deg, #1e1026 0%, #351a44 100%);
    color: var(--white);
    padding: 2.75rem 2.25rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 0.925rem;
    color: var(--slate-800);
    margin-bottom: 0.5rem;
}

.form-group .value-tag {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.95rem;
}

.input-with-affix {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-affix span.prefix {
    position: absolute;
    left: 1rem;
    color: var(--slate-500);
    font-weight: 600;
    pointer-events: none;
}

.input-with-affix input {
    width: 100%;
    padding: 0.85rem 1rem 0.85rem 2rem;
    border: 1.5px solid var(--slate-200);
    border-radius: var(--radius-md);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--slate-900);
    transition: var(--transition);
}

.input-with-affix input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(71, 35, 91, 0.12);
}

.calc-input {
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1.5px solid var(--slate-200);
    border-radius: var(--radius-md);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--slate-900);
    background: var(--white);
    transition: var(--transition);
    box-sizing: border-box;
}

.calc-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(71, 35, 91, 0.12);
    outline: none;
}

.slider-control {
    width: 100%;
    height: 6px;
    background: var(--slate-200);
    border-radius: var(--radius-full);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    margin-top: 0.75rem;
}

.slider-control::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(71, 35, 91, 0.4);
    transition: transform 0.1s ease;
}

.slider-control::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.calc-select {
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1.5px solid var(--slate-200);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    color: var(--slate-900);
    background: var(--white);
    cursor: pointer;
    transition: var(--transition);
}

.calc-select:focus {
    border-color: var(--primary);
}

.calc-results-header h3 {
    color: var(--white);
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
}

.calc-results-header p {
    color: var(--slate-300);
    font-size: 0.9rem;
}

.calc-payment-display {
    text-align: center;
    padding: 2rem 0;
}

.calc-payment-label {
    font-size: 0.95rem;
    color: var(--slate-300);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.calc-payment-val {
    font-family: var(--font-heading);
    font-size: 3.25rem;
    font-weight: 800;
    color: var(--gold-light);
    line-height: 1;
}

.calc-payment-sub {
    font-size: 0.85rem;
    color: var(--slate-300);
    margin-top: 0.5rem;
}

.calc-breakdown-row {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.925rem;
}

.calc-breakdown-row span:first-child {
    color: var(--slate-300);
}

.calc-breakdown-row span:last-child {
    font-weight: 700;
    color: var(--white);
}

/* Feature Spotlight Layout (2 cols alternating) */
.feature-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.feature-split.reverse {
    direction: rtl;
}

.feature-split.reverse>* {
    direction: ltr;
}

.feature-text h2 {
    margin-bottom: 1.25rem;
}

.feature-text p {
    font-size: 1.05rem;
    color: var(--slate-600);
    margin-bottom: 1.75rem;
    line-height: 1.7;
}

.feature-list {
    margin-bottom: 2rem;
}

.feature-list-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 0.9rem;
    font-size: 0.975rem;
    color: var(--slate-700);
}

.feature-list-item svg {
    width: 20px;
    height: 20px;
    color: var(--teal);
    flex-shrink: 0;
    margin-top: 2px;
}

.feature-img-frame {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--slate-200);
    position: relative;
}

.feature-img-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Team Section */
.team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.25rem;
}

.team-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--slate-200);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.team-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(71, 35, 91, 0.25);
}

.team-img-wrap {
    height: 320px;
    overflow: hidden;
    position: relative;
    background: var(--slate-900);
}

.team-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transition: transform 0.5s ease;
}

.team-card:hover .team-img-wrap img {
    transform: scale(1.05);
}

.team-content {
    padding: 1.75rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.team-header h3 {
    font-size: 1.35rem;
    margin-bottom: 0.25rem;
}

.team-role {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--teal);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
    display: block;
}

.team-bio {
    color: var(--slate-600);
    font-size: 0.925rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.team-actions {
    display: flex;
    gap: 0.75rem;
}

/* Testimonial Cards */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.review-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid var(--slate-200);
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.review-stars {
    color: #f59e0b;
    display: flex;
    gap: 0.25rem;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.review-quote {
    color: var(--slate-700);
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.reviewer-meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.reviewer-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary-soft);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}

.reviewer-info strong {
    display: block;
    font-size: 0.95rem;
    color: var(--slate-900);
}

.reviewer-info span {
    font-size: 0.8rem;
    color: var(--slate-500);
}

/* Call to Action Banner */
.cta-banner {
    position: relative;
    background: linear-gradient(135deg, #321841 0%, #47235b 50%, #007664 100%);
    color: var(--white);
    border-radius: var(--radius-xl);
    padding: 4rem 3.5rem;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.cta-banner-content {
    position: relative;
    z-index: 2;
    max-width: 680px;
}

.cta-banner h2 {
    color: var(--white);
    margin-bottom: 1rem;
}

.cta-banner p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

.cta-banner-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

/* Page Hero Header (For Subpages) */
.page-hero {
    background: linear-gradient(135deg, #1c0e25 0%, #3e1e50 60%, #152e2a 100%);
    color: var(--white);
    padding: 4.5rem 0 4.5rem 0;
    position: relative;
    overflow: hidden;
}

.page-hero-content {
    max-width: 820px;
    position: relative;
    z-index: 2;
}

.page-hero h1 {
    color: var(--white);
    margin-bottom: 1rem;
}

.page-hero p {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.65;
}

.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--slate-400);
    margin-bottom: 1rem;
}

.breadcrumbs a {
    color: var(--slate-300);
}

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

/* FAQ Accordion */
.faq-list {
    max-width: 860px;
    margin: 0 auto;
}

.faq-item {
    background: var(--white);
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    border: 1px solid var(--slate-200);
    overflow: hidden;
    transition: var(--transition);
}

.faq-question {
    width: 100%;
    padding: 1.35rem 1.75rem;
    text-align: left;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--slate-900);
    cursor: pointer;
}

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

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

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, padding 0.35s ease;
    padding: 0 1.75rem;
    color: var(--slate-600);
    line-height: 1.65;
    font-size: 0.95rem;
}

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

/* Contact Hub & Form Styles */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 3.5rem;
}

.contact-info-cards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-info-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    border: 1px solid var(--slate-200);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
}

.contact-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    background: var(--primary-soft);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.contact-details h4 {
    font-size: 1.1rem;
    margin-bottom: 0.35rem;
}

.contact-details p {
    color: var(--slate-600);
    font-size: 0.95rem;
}

.form-card {
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: 2.75rem;
    border: 1px solid var(--slate-200);
    box-shadow: var(--shadow-lg);
}

.form-card h3 {
    font-size: 1.6rem;
    margin-bottom: 0.5rem;
}

.form-card p.form-sub {
    color: var(--slate-600);
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.input-field {
    width: 100%;
    padding: 0.85rem 1.15rem;
    border: 1.5px solid var(--slate-200);
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    color: var(--slate-800);
    background: var(--white);
    transition: var(--transition);
}

.input-field:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(71, 35, 91, 0.12);
}

textarea.input-field {
    resize: vertical;
    min-height: 120px;
}

/* Multi-Step Application Form (Get Started Wizard) */
.wizard-container {
    max-width: 820px;
    margin: 0 auto;
    background: var(--white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--slate-200);
    overflow: hidden;
}

.wizard-progress-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: var(--slate-50);
    border-bottom: 1px solid var(--slate-200);
}

.step-indicator {
    padding: 1.25rem 1rem;
    text-align: center;
    position: relative;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.step-indicator:hover {
    background: rgba(43, 17, 57, 0.04);
}

.step-indicator.active {
    background: var(--white);
    border-bottom: 3px solid var(--primary);
}

.step-indicator.completed {
    background: rgba(0, 118, 100, 0.04);
    border-bottom: 3px solid var(--teal);
}

.step-indicator.completed .step-title {
    color: var(--teal);
    font-weight: 700;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--slate-200);
    color: var(--slate-600);
    font-weight: 700;
    font-size: 0.8rem;
    margin-bottom: 0.25rem;
}

.step-indicator.active .step-number {
    background: var(--primary);
    color: var(--white);
}

.step-indicator.completed .step-number {
    background: var(--teal);
    color: var(--white);
}

.step-title {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--slate-600);
}

.step-indicator.active .step-title {
    color: var(--primary);
    font-weight: 700;
}

.wizard-body {
    padding: 3rem 2.5rem;
}

.wizard-step {
    display: none;
    animation: fadeIn 0.3s ease;
}

.wizard-step.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

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

.choice-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.choice-card {
    border: 2px solid var(--slate-200);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.choice-card:hover {
    border-color: var(--primary-light);
    background: var(--primary-soft);
}

.choice-card.selected {
    border-color: var(--primary);
    background: var(--primary-soft);
    box-shadow: 0 4px 12px rgba(71, 35, 91, 0.15);
}

.choice-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    background: var(--white);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    box-shadow: var(--shadow-sm);
    flex-shrink: 0;
}

.choice-card.selected .choice-icon {
    background: var(--primary);
    color: var(--white);
}

.choice-text strong {
    display: block;
    font-size: 1rem;
    color: var(--slate-900);
}

.choice-text span {
    font-size: 0.825rem;
    color: var(--slate-500);
}

.wizard-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--slate-200);
}

/* Toast Notification */
.toast-msg {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--slate-900);
    color: var(--white);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border-left: 4px solid var(--teal);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.95rem;
    font-weight: 500;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 999;
}

.toast-msg.show {
    transform: translateY(0);
    opacity: 1;
}

/* Footer */
.site-footer {
    background: #0b1120;
    color: var(--slate-400);
    padding: 5rem 0 2rem 0;
    font-size: 0.925rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.3fr;
    gap: 3.5rem;
    margin-bottom: 4rem;
}

.footer-brand-col p {
    margin: 1.25rem 0;
    line-height: 1.65;
    color: var(--slate-400);
}

.footer-logos {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    background: var(--white);
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius-md);
    display: inline-flex;
}

.footer-logos img {
    height: 38px;
    width: auto;
}

.footer-col h4 {
    color: var(--white);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-col h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 32px;
    height: 2.5px;
    background: var(--gold);
    border-radius: var(--radius-full);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-links a {
    color: var(--slate-400);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--gold-light);
    transform: translateX(3px);
}

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1rem;
    color: var(--slate-300);
}

.footer-contact-item svg {
    width: 18px;
    height: 18px;
    color: var(--gold);
    flex-shrink: 0;
    margin-top: 3px;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--slate-500);
}

.footer-bottom a:hover {
    color: var(--white);
}

/* Responsiveness */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .hero-float-badge {
        bottom: 1rem;
        left: 1rem;
    }

    .services-grid,
    .services-grid-4,
    .team-grid,
    .reviews-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    /* Hide connector line on tablet and below */
    .process-steps-grid::before {
        display: none;
    }

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

    .feature-split {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .feature-split.reverse {
        direction: ltr;
    }

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

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

@media (max-width: 768px) {
    .topbar {
        display: none;
    }

    .nav-menu {
        display: none;
    }

    .nav-ctas .btn {
        display: none;
    }

    .mobile-toggle {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        width: 44px;
        height: 44px;
        background: var(--slate-100);
        border-radius: var(--radius-md);
        border: 1px solid var(--slate-200);
        z-index: 101;
    }

    .mobile-toggle span {
        width: 22px;
        height: 2px;
        background: var(--slate-800);
        margin: 3px 0;
        border-radius: 2px;
    }

    .brand-logo-main {
        height: 52px;
    }

    .brand-logo-partner {
        height: 22px;
    }

    .mobile-nav-drawer {
        display: block;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .services-grid,
    .services-grid-4,
    .team-grid,
    .reviews-grid {
        grid-template-columns: 1fr !important;
        gap: 1.5rem;
    }

    .service-card {
        padding: 1.75rem 1.5rem;
    }

    /* Process steps: single column on mobile, horizontal card layout */
    .process-steps-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .process-step-card {
        flex-direction: row;
        align-items: flex-start;
        gap: 1.25rem;
        padding: 1.5rem 1.25rem;
    }

    .process-step-card .process-step-num {
        flex-shrink: 0;
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
        margin-bottom: 0;
    }

    .process-step-content {
        flex: 1;
        min-width: 0;
        display: flex;
        flex-direction: column;
    }

    .process-step-card h3 {
        font-size: 1.15rem;
        font-weight: 700;
        margin-bottom: 0.45rem;
        line-height: 1.35;
    }

    .process-step-card p {
        font-size: 0.92rem;
        line-height: 1.6;
        margin-bottom: 0.85rem;
    }

    .process-step-card .service-card-link {
        margin-top: 0;
        font-size: 0.8rem;
    }

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

    .cta-banner {
        padding: 3rem 1.75rem;
    }

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

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }

    /* Mobile Step Indicators */
    .step-indicator {
        padding: 0.85rem 0.5rem;
        font-size: 0.8rem;
    }

    .step-indicator .step-num {
        width: 24px;
        height: 24px;
        font-size: 0.75rem;
        margin-bottom: 0.25rem;
    }

    .wizard-body {
        padding: 2rem 1.25rem;
    }

    .wizard-actions {
        display: flex;
        gap: 0.75rem;
        align-items: stretch;
        margin-top: 1.75rem;
        padding-top: 1.25rem;
    }

    .wizard-actions .btn {
        padding: 0.85rem 1rem;
        font-size: 0.9rem;
    }

    .wizard-actions #wizardPrev {
        flex: 0 0 auto;
        min-width: 80px;
        padding: 0.85rem 1rem;
        justify-content: center;
    }

    .wizard-actions #wizardNext,
    .wizard-actions #wizardSubmit {
        flex: 1;
        min-width: 0;
        padding: 0.85rem 1rem;
        font-size: 0.92rem;
        white-space: nowrap;
        justify-content: center;
        text-align: center;
    }

    /* Button stack on small screens */
    .hero-actions,
    .cta-banner-actions {
        flex-direction: column;
        width: 100%;
    }

    .hero-actions .btn,
    .cta-banner-actions .btn {
        width: 100%;
        text-align: center;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .hero-h1 {
        font-size: 2.15rem;
    }

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

    .section {
        padding: 3.5rem 0;
    }

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

    .process-step-card {
        gap: 1rem;
        padding: 1.25rem 1rem;
    }

    .process-step-card .process-step-num {
        width: 44px;
        height: 44px;
        font-size: 1.15rem;
    }

    .process-step-card h3 {
        font-size: 1.05rem;
        margin-bottom: 0.35rem;
    }

    .process-step-card p {
        font-size: 0.88rem;
        line-height: 1.55;
        margin-bottom: 0.75rem;
    }

    .service-card {
        padding: 1.5rem 1.25rem;
    }

    .wizard-actions {
        gap: 0.65rem;
    }

    .wizard-actions .btn {
        padding: 0.8rem 0.85rem;
        font-size: 0.88rem;
    }

    .wizard-actions #wizardPrev {
        min-width: 75px;
        padding: 0.8rem 0.75rem;
    }

    .wizard-actions #wizardNext,
    .wizard-actions #wizardSubmit {
        padding: 0.8rem 0.85rem;
        font-size: 0.88rem;
    }

    /* Fixed Mobile Action Bar at bottom */
    body {
        padding-bottom: 64px;
    }

    .mobile-bottom-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        background: #ffffff;
        border-top: 1px solid #e2e8f0;
        z-index: 99;
        box-shadow: 0 -4px 16px rgba(0,0,0,0.08);
    }

    .mobile-bottom-bar a {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 0.5rem 0.25rem;
        font-size: 0.72rem;
        font-weight: 600;
        color: #475569;
        text-decoration: none;
        gap: 0.2rem;
    }

    .mobile-bottom-bar a svg {
        width: 20px;
        height: 20px;
        stroke: currentColor;
    }

    .mobile-bottom-bar a.active,
    .mobile-bottom-bar a:hover {
        color: var(--primary);
    }

    .mobile-bottom-bar a.bar-cta {
        background: var(--primary);
        color: #ffffff;
    }

    .mobile-bottom-bar a.bar-cta svg {
        stroke: #ffffff;
    }
}

@media (min-width: 481px) {
    .mobile-bottom-bar {
        display: none !important;
    }
}

@media (max-width: 360px) {
    .process-step-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }

    .process-step-card .process-step-num {
        margin-bottom: 0.25rem;
    }

    .wizard-actions {
        flex-direction: column-reverse;
    }

    .wizard-actions #wizardPrev[style*="hidden"] {
        display: none;
    }

    .wizard-actions #wizardPrev,
    .wizard-actions #wizardNext,
    .wizard-actions #wizardSubmit {
        width: 100%;
        flex: none;
    }
}