/* =========================================================================
   MN LAKE HOMES - MASTER DESIGN SYSTEM
   ========================================================================= 
   1. VARIABLES & RESETS
   2. TYPOGRAPHY & UTILITIES
   3. STRUCTURAL LAYOUTS
   4. COMPONENTS (Cards, Buttons, Modals)
   5. FORMS
   6. PAGE-SPECIFIC ZONES
========================================================================= */

/* 1. VARIABLES & RESETS */
:root {
    --bg-dark: #000000;
    --text-primary: #ffffff;
    --text-secondary: #a3a3a3;
    --highlight-color: #8c9ba5; /* Grey/blue metallic tone */
    --accent-blue: #1d6df2;
    --accent-blue-hover: #155bc8;
    --border-color: rgba(255, 255, 255, 0.1);
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-family);
}

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Navbar */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 3rem;
    background-color: var(--bg-dark);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 50;
    box-sizing: border-box;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.15rem;
    letter-spacing: -0.5px;
}

.logo-icon {
    width: 24px;
    height: 24px;
    background-color: #fff;
    border-radius: 50%;
    display: inline-block;
    position: relative;
}

.logo-icon::after {
    content: '';
    position: absolute;
    width: 10px;
    height: 10px;
    background-color: var(--bg-dark);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.nav-links {
    display: flex;
    gap: 2rem;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: opacity 0.2s ease;
}

.nav-links a:hover {
    opacity: 0.7;
}

/* Full-width header megamenu — matches footer style */
.nav-megamenu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    width: 100%;
    background-color: var(--bg-dark);
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    padding: 3rem 3rem;
    box-shadow: 0 20px 40px rgba(0,0,0,0.25);
    animation: nav-megamenu-fade 0.15s ease-out;
}
.nav-megamenu::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 0;
    right: 0;
    height: 20px;
}
@keyframes nav-megamenu-fade {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}
.nav-megamenu-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}
.nav-megamenu-col { display: flex; flex-direction: column; }
.nav-megamenu-heading {
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin: 0 0 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.nav-megamenu-col a {
    color: #cbd5e0;
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    padding: 0.5rem 0;
    transition: color 0.15s ease;
}
.nav-megamenu-col a:hover { color: #fff; opacity: 1; }

/* ─── Mobile hamburger toggle + slide-out menu ─── */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 8px;
    margin-left: 0.5rem;
    transition: background 0.15s;
    align-items: center;
    justify-content: center;
}
.mobile-menu-toggle:hover { background: rgba(255,255,255,0.08); }

.mobile-menu-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1100;
    opacity: 0;
    transition: opacity 0.25s ease;
}
.mobile-menu-backdrop.open { display: block; opacity: 1; }

.mobile-menu {
    display: flex;
    position: fixed;
    top: 0; right: 0; bottom: 0;
    width: min(360px, 85vw);
    background-color: var(--bg-dark);
    border-left: 1px solid rgba(255,255,255,0.08);
    z-index: 1200;
    transform: translateX(100%);
    transition: transform 0.28s cubic-bezier(0.25, 1, 0.5, 1);
    flex-direction: column;
    overflow: hidden;
}
.mobile-menu.open { transform: translateX(0); }

.mobile-menu-hdr {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    flex-shrink: 0;
}
.mobile-menu-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    padding: 0.35rem;
    border-radius: 6px;
    display: inline-flex;
}
.mobile-menu-close:hover { background: rgba(255,255,255,0.08); color: #fff; }

.mobile-menu-body {
    flex: 1;
    overflow-y: auto;
    padding: 1rem 0 0.5rem;
    -webkit-overflow-scrolling: touch;
}

.mobile-menu-section { border-bottom: 1px solid rgba(255,255,255,0.06); }
.mobile-menu-section:last-child { border-bottom: none; }

.mobile-menu-section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: none;
    border: none;
    color: #fff;
    font-family: inherit;
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: -0.2px;
    padding: 1rem 1.5rem;
    cursor: pointer;
    text-align: left;
    transition: background 0.15s;
}
.mobile-menu-section-title:hover,
.mobile-menu-section-title:focus-visible { background: rgba(255,255,255,0.04); outline: none; }
.mobile-menu-chevron { transition: transform 0.2s ease; color: #94a3b8; flex-shrink: 0; }
.mobile-menu-section.open .mobile-menu-chevron { transform: rotate(180deg); color: #fff; }

.mobile-menu-section-body {
    display: none;
    padding: 0 1.5rem 0.75rem;
    animation: mobileAccordionFade 0.2s ease-out;
}
.mobile-menu-section.open .mobile-menu-section-body { display: block; }
@keyframes mobileAccordionFade { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

.mobile-menu-col + .mobile-menu-col { margin-top: 0.5rem; }
.mobile-menu-col-heading {
    font-size: 0.65rem;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    padding: 0.6rem 0 0.25rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    margin-top: 0.5rem;
}
.mobile-menu-col:first-of-type .mobile-menu-col-heading { border-top: none; margin-top: 0; padding-top: 0.2rem; }

.mobile-menu-link {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.55rem 0;
    color: #cbd5e0;
    font-size: 0.92rem;
    font-weight: 500;
    text-decoration: none;
}
.mobile-menu-link:hover { color: #fff; }
.mobile-menu-link-primary {
    color: #60a5fa;
    font-weight: 700;
    padding: 0.5rem 0 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    margin-bottom: 0.25rem;
}
.mobile-menu-link-primary:hover { color: #93c5fd; }

.mobile-menu-footer {
    padding: 1.25rem 1.5rem 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.08);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex-shrink: 0;
}
.mobile-menu-cta-outline,
.mobile-menu-cta-primary {
    display: block;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.95rem;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    border: none;
    font-family: inherit;
}
.mobile-menu-cta-outline {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.2);
}
.mobile-menu-cta-outline:hover { background: rgba(255,255,255,0.05); }
.mobile-menu-cta-primary {
    background: var(--accent-blue);
    color: #fff;
}
.mobile-menu-cta-primary:hover { background: var(--accent-blue-hover); }

/* Show hamburger + hide desktop nav/actions on small screens */
@media (max-width: 900px) {
    .mobile-menu-toggle { display: inline-flex; }
}

@media (max-width: 780px) {
    .nav-megamenu { padding: 2rem 1.5rem; }
    .nav-megamenu-inner { grid-template-columns: 1fr; gap: 2rem; }
}

.nav-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.btn {
    padding: 0.6rem 1.25rem;
    border-radius: 50px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s ease;
    cursor: pointer;
    display: inline-block;
    border: none;
}

.btn-outline {
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.btn-outline:hover {
    border-color: var(--text-primary);
    background-color: rgba(255, 255, 255, 0.05);
}

.btn-primary {
    background-color: var(--accent-blue);
    color: #fff;
}

.btn-primary:hover {
    background-color: var(--accent-blue-hover);
}

.btn-white {
    background-color: #fff;
    color: var(--bg-dark);
    padding: 0.6rem 1.25rem;
    border-radius: 50px;
}

.btn-white:hover {
    background-color: #f0f0f0;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
}

/* Hero Section */
.hero-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 4rem;
    position: relative;
    padding-bottom: 8rem; /* Space for floating promo */
}

.hero-content {
    text-align: center;
    z-index: 2;
    margin-top: 5.5rem;
    margin-bottom: 2rem;
}

.subtitle {
    color: #cccccc;
    font-size: 0.95rem;
    font-weight: 500;
    margin-bottom: 2rem;
    letter-spacing: 0.2px;
}

.title {
    font-size: 6rem;
    line-height: 1.05;
    font-weight: 700;
    letter-spacing: -2.5px;
}

.text-highlight {
    color: var(--highlight-color);
}

.text-blue {
    color: var(--accent-blue);
}

.text-slate {
    color: #728193;
}

/* Showcase Grid */
.hero-showcase {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 1.5rem;
    width: 100%;
    max-width: 1200px;
    margin-top: 1rem;
    position: relative;
    z-index: 1;
}

.showcase-card {
    border-radius: 20px;
    overflow: hidden;
    background: #111;
    position: relative;
}

.showcase-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s ease;
}

.showcase-card:hover img {
    transform: scale(1.03);
}

/* Specific image sizing to match reference */
.left-card, .right-card {
    width: 320px;
    height: 480px;
    margin-top: 5rem; /* Staggered effect */
}

.center-card {
    width: 500px;
    height: 520px;
    z-index: 2;
}


/* Floating Promo */
.floating-promo {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translate(-50%, 40px);
    background: linear-gradient(90deg, #184cc2 0%, #3074ff 100%);
    border: 2px solid #5a91ff;
    border-radius: 12px;
    padding: 0.75rem 1rem 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 0 40px rgba(29, 109, 242, 0.3);
    z-index: 100;
    width: max-content;
    max-width: calc(100vw - 2rem);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
                visibility 0.6s;
}

.floating-promo.revealed {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translate(-50%, 0);
}

.floating-promo.hide-promo,
.floating-promo.dismissed {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: translate(-50%, 40px) !important;
}

.promo-close {
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    padding: 0.35rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: color 0.2s, background 0.2s;
    line-height: 0;
    flex-shrink: 0;
}
.promo-close:hover {
    color: #fff;
    background: rgba(255,255,255,0.1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translate(-50%, 40px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

.promo-content p {
    font-size: 0.95rem;
    color: #ffffff;
    line-height: 1.4;
    margin: 0;
}

.promo-content strong {
    font-weight: 700;
}

/* Flex Section */
.flex-section {
    background-color: #ffffff;
    color: #000000;
    width: 100%;
    padding: 6rem 2rem;
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 5;
}

.flex-container {
    width: 100%;
    max-width: 1000px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.flex-title {
    font-size: 4rem;
    font-weight: 700;
    text-align: center;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 3rem;
}

.flex-tab-container {
    display: flex;
    align-self: flex-start;
    margin-left: 0;
}

.flex-tab {
    background: transparent;
    border: none;
    padding: 1rem 1.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border-radius: 12px 12px 0 0;
    color: #000;
    transition: all 0.2s;
}

.flex-tab.active {
    background: #000;
    color: #fff;
}

.flex-card {
    background: #000;
    border-radius: 0 12px 12px 12px;
    padding: 3rem;
    width: 100%;
    color: #fff;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.flex-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.flex-card-header p {
    font-size: 1.1rem;
    color: #e0e0e0;
    max-width: 50%;
    line-height: 1.4;
}

/* New split layout — text left, image right */
.flex-split {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 3rem;
    align-items: center;
}

.flex-split-text {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    max-width: 520px;
}

.flex-split-heading {
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.75px;
    line-height: 1.15;
    margin: 0;
}

.flex-split-text p {
    font-size: 1.05rem;
    color: #cbd5e0;
    line-height: 1.6;
    margin: 0;
}

.flex-split-text .btn {
    align-self: flex-start;
    padding: 0.9rem 1.75rem;
    font-size: 0.95rem;
    margin-top: 0.25rem;
}

.flex-split-image { display: flex; justify-content: center; }

.flex-images {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

.flex-img {
    width: 100%;
    max-width: 780px;
    min-width: 0;
    height: 420px;
    object-fit: cover;
    border-radius: 14px;
}

/* Flex section — responsive tabs + card */
@media (max-width: 900px) {
    .flex-section { padding: 4rem 1.25rem; }
    .flex-title { font-size: 3rem; margin-bottom: 2rem; letter-spacing: -1px; }
    .flex-tab-container {
        align-self: stretch;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .flex-tab-container::-webkit-scrollbar { display: none; }
    .flex-tab { white-space: nowrap; flex: 0 0 auto; padding: 0.85rem 1.1rem; font-size: 0.85rem; }
    .flex-card { padding: 2rem 1.5rem; border-radius: 12px; }
    .flex-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.25rem;
        margin-bottom: 1.75rem;
    }
    .flex-card-header p { max-width: 100%; font-size: 1rem; }
    .flex-card-header .btn { align-self: flex-start; }
    .flex-images { flex-direction: column; gap: 1rem; }
    .flex-img { height: 220px; }

    /* Split layout stacks on mobile — image below text */
    .flex-split { grid-template-columns: 1fr; gap: 1.75rem; }
    .flex-split-heading { font-size: 1.5rem; }
    .flex-split-text p { font-size: 0.95rem; }
}

@media (max-width: 600px) {
    .flex-title { font-size: 2.25rem; }
    .flex-card { padding: 1.5rem 1.25rem; }
    .flex-img { height: 180px; }
}

/* Responsive */
@media (max-width: 1200px) {
    .title {
        font-size: 5rem;
    }
    .left-card, .right-card {
        width: 250px;
        height: 380px;
    }
    .center-card {
        width: 400px;
        height: 480px;
    }
}

@media (max-width: 900px) {
    .title {
        font-size: 4rem;
    }
    .nav-links,
    .nav-actions {
        display: none;
    }
    /* Mobile hero: horizontal swipeable carousel — wraps infinitely via JS */
    .hero-showcase {
        flex-direction: row;
        align-items: center;
        gap: 1rem;
        margin-top: 2rem;
        padding: 0 1rem 0.5rem;
        width: 100%;
        max-width: 100vw;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        scroll-padding: 1rem;
        scrollbar-width: none;
    }
    .hero-showcase::-webkit-scrollbar { display: none; }
    .left-card, .right-card, .center-card {
        margin-top: 0;
        flex: 0 0 88vw;
        max-width: 440px;
        height: 340px;
        scroll-snap-align: center;
    }
    .hero-section { padding-bottom: 6rem; }
    .hero-content { margin-top: 4.5rem; }
}

@media (max-width: 600px) {
    .title {
        font-size: 3rem;
    }
    .floating-promo {
        width: calc(100vw - 1.5rem);
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
        padding: 1rem 1rem 0.9rem;
        bottom: 1rem;
        position: fixed;
    }
    .floating-promo .promo-close {
        position: absolute;
        top: 0.35rem;
        right: 0.35rem;
    }
    .promo-content p { font-size: 0.85rem; line-height: 1.45; }
    .promo-content p br { display: none; }
    .nav-actions {
        display: none;
    }
    .navbar { padding: 1.1rem 1.25rem; }
    .hero-content { margin-top: 5rem; }
}

@media (max-width: 400px) {
    .title { font-size: 2.5rem; letter-spacing: -1.5px; }
}

/* Hero CTAs */
.hero-ctas {
    display: flex;
    gap: 1rem;
    margin-top: 2.5rem;
    flex-wrap: wrap;
    justify-content: center;
    position: relative;
    z-index: 5;
}
.hero-cta {
    padding: 1.2rem 2.5rem;
    font-size: 1.1rem;
}
.hero-cta-ghost {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    text-decoration: none;
    border-radius: 99px;
}
@media (max-width: 600px) {
    .hero-ctas { gap: 0.75rem; margin-top: 1.75rem; flex-direction: column; width: 100%; max-width: 320px; margin-left: auto; margin-right: auto; }
    .hero-cta { width: 100%; padding: 1rem 1.5rem; font-size: 1rem; }
}

/* Info Split Section */
.info-split-section {
    background-color: #ffffff;
    width: 100%;
    padding: 2rem 2rem 8rem;
    display: flex;
    justify-content: center;
}

.info-split-container {
    width: 100%;
    max-width: 1000px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 4rem;
}

.info-title {
    font-size: 3.2rem;
    font-weight: 600;
    line-height: 1.15;
    color: #000;
    letter-spacing: -1.5px;
    flex: 1;
}

.info-desc {
    font-size: 1.05rem;
    color: #556070;
    line-height: 1.6;
    flex: 1;
    font-weight: 500;
}

@media (max-width: 768px) {
    .info-split-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 1.5rem;
    }
    .info-title {
        font-size: 2.5rem;
    }
}

/* Business Type Section */
.business-type-section {
    background-color: #f7f9fa; /* Very light grey */
    width: 100%;
    padding: 6rem 2rem;
    display: flex;
    justify-content: center;
}

.business-type-container {
    width: 100%;
    max-width: 1000px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 4rem;
}

.business-text {
    flex: 1;
}

.business-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    color: #000;
    letter-spacing: -1.5px;
    margin-bottom: 1rem;
}

.business-desc {
    font-size: 1.05rem;
    color: #556070;
    line-height: 1.5;
}

.business-form {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 350px;
}

.business-form label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #556070;
}

.select-wrapper {
    position: relative;
    width: 100%;
}

.select-wrapper select {
    width: 100%;
    padding: 1.25rem 3rem 1.25rem 1.5rem;
    font-size: 1rem;
    border: 1px solid #edf0f3;
    border-radius: 12px;
    appearance: none;
    -webkit-appearance: none;
    background-color: #fcfcfd;
    cursor: pointer;
    font-weight: 400;
    color: #a0aec0;
    font-family: inherit;
    transition: border-color 0.2s, background-color 0.2s, color 0.2s;
}

.select-wrapper select:valid,
.select-wrapper select:not(:has(option[value=""]:checked)) {
    color: #1a202c;
}

.select-wrapper select:focus {
    outline: none;
    border-color: var(--accent-blue);
    background-color: #fff;
}

.select-wrapper::after {
    content: "";
    position: absolute;
    right: 1.5rem;
    top: 50%;
    width: 10px;
    height: 10px;
    border-right: 2px solid #718096;
    border-bottom: 2px solid #718096;
    transform: translateY(-70%) rotate(45deg);
    pointer-events: none;
    transition: border-color 0.2s;
}

.select-wrapper:focus-within::after {
    border-color: var(--accent-blue);
}

/* Modal CSS */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.modal-content {
    background: #fff;
    width: 90%;
    max-width: 600px;
    border-radius: 16px;
    padding: 4rem 3rem;
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s ease;
    color: #000;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
    transition: background 0.2s;
}

.modal-close:hover {
    background: #e0e0e0;
}

.modal-step {
    display: none;
    flex-direction: column;
    align-items: flex-start;
    animation: fadeIn 0.4s ease;
}

.modal-step.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateX(10px); }
    to { opacity: 1; transform: translateX(0); }
}

.modal-step h2 {
    font-size: 2.5rem;
    font-weight: 700;
    letter-spacing: -1px;
    margin-bottom: 0.5rem;
}

.modal-step p {
    color: #556070;
    font-size: 1.05rem;
    margin-bottom: 2rem;
}

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

.form-group input, .form-group select {
    width: 100%;
    padding: 1.25rem 1.5rem;
    font-size: 1rem;
    border: 1px solid #dcdfe3;
    border-radius: 12px;
    background-color: #fafafa;
    color: #000;
    transition: border-color 0.2s, background-color 0.2s;
}

.form-group input:focus, .form-group select:focus {
    outline: none;
    border-color: var(--accent-blue);
    background-color: #fff;
}

.modal-next-btn {
    width: 100%;
    padding: 1.25rem;
    border-radius: 12px;
    font-size: 1.1rem;
    margin-top: 1rem;
    text-align: center;
}

.success-icon {
    width: 80px;
    height: 80px;
    background: var(--accent-blue);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

@media (max-width: 768px) {
    .business-type-section { padding: 4rem 1.25rem; }
    .business-type-container {
        flex-direction: column;
        align-items: stretch;
        gap: 2rem;
    }
    .business-title {
        font-size: 2.25rem;
        letter-spacing: -1px;
    }
    .business-form { width: 100%; }
    .business-form .btn { width: 100%; }
}

/* Mission section mobile */
@media (max-width: 768px) {
    .mission-section { padding: 5rem 1.25rem; }
    .mission-title { font-size: 2.5rem; margin-bottom: 1.5rem; }
    .mission-desc { font-size: 1rem; }
}
@media (max-width: 480px) {
    .mission-title { font-size: 2rem; }
}

/* Mission Section */
.mission-section {
    background-color: #ffffff;
    width: 100%;
    padding: 8rem 2rem;
    display: flex;
    justify-content: center;
}

.mission-container {
    width: 100%;
    max-width: 800px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.mission-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    color: #000;
    letter-spacing: -1px;
    margin-bottom: 2.5rem;
}

.text-underline {
    position: relative;
    display: inline-block;
}

.text-underline::after {
    content: "";
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: var(--accent-blue);
    border-radius: 2px;
}

.mission-desc {
    font-size: 1.25rem;
    color: #000;
    line-height: 1.7;
    margin-bottom: 3rem;
    font-weight: 500;
}

.btn-lg {
    padding: 1rem 2.5rem;
    font-size: 1rem;
}

/* Testimonial Section */
.testimonial-section {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    width: 100%;
    padding: 8rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.testimonial-top {
    width: 100%;
    max-width: 1100px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 5rem;
}

.testimonial-main-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -1.5px;
    max-width: 650px;
}

.testimonial-controls {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 600;
}

.slide-nav-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.2s;
    letter-spacing: -0.5px;
}

.slide-nav-btn:hover {
    color: #fff;
}

.slide-count {
    letter-spacing: 0.5px;
}

.testimonial-bottom {
    width: 100%;
    max-width: 900px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 3rem;
}

.testimonial-info {
    flex: 1 1 auto;
    max-width: 780px;
    text-align: center;
    margin-bottom: 0;
}

.testimonial-category {
    font-size: 1.15rem;
    color: #a0aab2;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.testimonial-brand {
    font-size: 2.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.testimonial-quote {
    color: #e2e8f0;
    line-height: 1.55;
    margin-bottom: 0;
    font-size: 1.9rem;
    font-weight: 400;
    letter-spacing: -0.5px;
}

.testimonial-link {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(255,255,255,0.3);
    padding-bottom: 4px;
    transition: border-color 0.2s;
}

.testimonial-link:hover {
    border-color: #fff;
}

.testimonial-media {
    flex: 1;
    position: relative;
    display: flex;
    justify-content: flex-end;
}

.media-image-wrapper {
    width: 100%;
    max-width: 650px;
    height: 400px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
}

.media-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 76px;
    height: 76px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.8);
    background: rgba(0, 0, 0, 0.25);
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

.play-button:hover {
    transform: translate(-50%, -50%) scale(1.05);
    background: rgba(0, 0, 0, 0.5);
}

.media-vertical-tab {
    display: none !important;
}

@media (max-width: 900px) {
    .testimonial-top, .testimonial-bottom {
        flex-direction: column;
        align-items: flex-start;
    }
    .testimonial-controls {
        margin-top: 2rem;
    }
    .testimonial-media {
        width: 100%;
        margin-top: 3rem;
    }
    .testimonial-info {
        flex: auto;
        margin-bottom: 0;
    }
    .media-vertical-tab {
        display: none;
    }
}

/* Pricing Section */
.pricing-section {
    background-color: #ffffff;
    width: 100%;
    padding: 8rem 2rem;
    display: flex;
    justify-content: center;
}

.pricing-container {
    width: 100%;
    max-width: 1200px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pricing-header {
    text-align: center;
    margin-bottom: 5rem;
}

.pricing-header h2 {
    font-size: 3.5rem;
    font-weight: 700;
    color: #000;
    letter-spacing: -1.5px;
    margin-bottom: 1rem;
}

.pricing-header p {
    font-size: 1.15rem;
    color: #556070;
}

.pricing-cards {
    display: flex;
    width: 100%;
    gap: 2rem;
    justify-content: center;
    align-items: stretch;
}

.pricing-card {
    background-color: #fff;
    border: 1px solid #e2e6ea;
    border-radius: 16px;
    padding: 3rem 2.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.05);
}

.popular-card {
    background-color: #000;
    color: #fff;
    border-color: #000;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    transform: scale(1.03);
}

.popular-card:hover {
    transform: scale(1.03) translateY(-5px);
    box-shadow: 0 25px 45px rgba(0,0,0,0.3);
}

.popular-badge {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--accent-blue);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 0.4rem 1rem;
    border-radius: 50px;
}

.plan-name {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #000;
}

.popular-card .plan-name {
    color: #fff;
}

.plan-desc {
    font-size: 0.95rem;
    color: #6c757d;
    margin-bottom: 2rem;
    min-height: 40px;
}

.popular-card .plan-desc {
    color: #a0aab2;
}

.plan-price {
    font-size: 3.5rem;
    font-weight: 700;
    color: #000;
    display: flex;
    align-items: baseline;
    margin-bottom: 0.5rem;
    letter-spacing: -2px;
}

.popular-card .plan-price {
    color: #fff;
}

.plan-price .currency {
    font-size: 1.5rem;
    font-weight: 600;
    vertical-align: super;
    margin-right: 0.2rem;
}

.plan-price .term {
    font-size: 1rem;
    font-weight: 500;
    color: #6c757d;
    letter-spacing: normal;
    margin-left: 0.2rem;
}

.popular-card .plan-price .term {
    color: #a0aab2;
}

.processing-fee {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent-blue);
    margin-bottom: 2.5rem;
}

.pricing-btn {
    width: 100%;
    text-align: center;
    margin-bottom: 2.5rem;
    padding: 1rem;
    display: block;
    box-sizing: border-box;
}

.pricing-card .btn-outline {
    color: #000;
    border-color: #d1d5db;
}

.pricing-card .btn-outline:hover {
    background-color: #f7f9fa;
    border-color: #000;
}

.plan-features {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.plan-features li {
    font-size: 0.95rem;
    color: #333;
    display: flex;
    align-items: center;
}

.popular-card .plan-features li {
    color: #e0e0e0;
}

.plan-features li::before {
    content: "✓";
    color: var(--accent-blue);
    font-weight: 700;
    margin-right: 0.8rem;
    font-size: 1.1rem;
}

@media (max-width: 1024px) {
    .pricing-cards {
        flex-direction: column;
        align-items: center;
    }
    .pricing-card {
        width: 100%;
        max-width: 500px;
    }
    .popular-card {
        transform: scale(1);
    }
    .popular-card:hover {
        transform: translateY(-5px);
    }
}

/* Blog Section */
.blog-section {
    background-color: #ffffff;
    width: 100%;
    padding: 8rem 2rem;
    display: flex;
    justify-content: center;
}

.blog-container {
    width: 100%;
    max-width: 1200px;
    display: flex;
    flex-direction: column;
}

.blog-main-title {
    font-size: 3.2rem;
    font-weight: 700;
    color: #000;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 2rem;
    max-width: 600px;
}

.blog-header-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
}

.blog-arrows {
    display: flex;
    gap: 1rem;
}

.blog-nav-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background-color: #f4f5f6;
    color: #000;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.2s;
}

.blog-nav-btn:hover {
    background-color: #e2e6ea;
}

.blog-link {
    color: var(--accent-blue);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px solid var(--accent-blue);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 2px;
}

.blog-link:hover {
    color: #0d4ecc;
}

.blog-cards {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    gap: 3rem;
    padding-bottom: 2rem;
    -ms-overflow-style: none; /* IE and Edge */
    scrollbar-width: none; /* Firefox */
}

.blog-cards::-webkit-scrollbar {
    display: none; /* Chrome/WebKit */
}

.blog-card {
    flex: 0 0 calc(50% - 1.5rem);
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s;
}

.blog-card:hover {
    transform: translateY(-4px);
}

.blog-image {
    width: 100%;
    height: 380px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.blog-tag {
    background-color: #f0f4ff;
    color: var(--accent-blue);
    padding: 0.4rem 0.85rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.blog-time {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    color: #6c757d;
    font-size: 0.8rem;
    font-weight: 500;
}

.blog-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #000;
    line-height: 1.3;
}

@media (max-width: 900px) {
    .blog-card {
        flex: 0 0 calc(100% - 3rem);
    }
    .blog-section { padding: 5rem 1.25rem; }
    .blog-main-title { font-size: 2.25rem; }
    .blog-header-controls { flex-direction: column; align-items: flex-start; gap: 1rem; margin-bottom: 2rem; }
    .blog-cards { padding-bottom: 1rem; scroll-snap-type: x mandatory; }
    .blog-cards .blog-card { scroll-snap-align: start; }
}
@media (max-width: 480px) {
    .blog-main-title { font-size: 1.9rem; }
    .blog-title { font-size: 1.2rem; }
}

/* Featured Agents homepage section */
.featured-agents-section {
    background-color: #f7f9fa;
    padding: 6rem 2rem;
}
.featured-agents-header {
    max-width: 1200px;
    margin: 0 auto 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.featured-agents-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1a202c;
    letter-spacing: -1px;
    line-height: 1.1;
}
.featured-agents-header p {
    color: #718096;
    font-size: 1.05rem;
    line-height: 1.55;
}
.featured-agents-section .agents-grid { padding-top: 0; max-width: 1200px; margin: 0 auto; }
.featured-agents-cta {
    text-align: center;
    margin-top: 2rem;
}
.featured-agents-cta .btn { padding: 1.1rem 2.25rem; font-size: 1.05rem; text-decoration: none; }

@media (max-width: 768px) {
    .featured-agents-section { padding: 4rem 1.25rem; }
    .featured-agents-header h2 { font-size: 2rem; }
    .featured-agents-header p { font-size: 0.98rem; }
    .featured-agents-cta .btn { width: 100%; }
}

/* Agent grid mobile tuning */
@media (max-width: 600px) {
    .agents-grid { grid-template-columns: 1fr !important; gap: 1.5rem !important; padding: 0 !important; max-width: 440px; margin: 0 auto !important; }
}

/* sp-dark-section on homepage (We know MN Lakes) */
@media (max-width: 900px) {
    .sp-dark-section { padding: 5rem 1.25rem !important; }
    .sp-dark-section .sp-title { font-size: 2.5rem !important; }
    .sp-dark-section .sp-media-wrapper { height: 320px !important; }
}
@media (max-width: 480px) {
    .sp-dark-section .sp-title { font-size: 2rem !important; }
}

/* Footer Section */
.site-footer {
    background-color: var(--bg-dark);
    color: #fff;
    padding: 5rem 3rem 0;
}

.footer-container {
    display: flex;
    justify-content: space-between;
    gap: 5rem;
    max-width: 900px;
    margin: 0 auto;
    padding-bottom: 4rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    text-align: center;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.footer-brand .logo {
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.footer-brand .logo span {
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: -0.3px;
}

.footer-desc {
    color: #6b7280;
    line-height: 1.7;
    font-size: 0.88rem;
    max-width: 300px;
    margin-bottom: 1.75rem;
    text-align: left;
}

.footer-links {
    display: flex;
    gap: 4rem;
    align-items: flex-start;
}

.link-column {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.link-column h4 {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 1.25rem;
}

.link-column a {
    display: block;
    color: #6b7280;
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
    margin-bottom: 0.7rem;
    transition: color 0.15s;
}

.link-column a:hover {
    color: #fff;
}

.footer-cta {
    display: none;
}

.footer-bottom {
    padding: 2rem 0 2.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    text-align: center;
    color: #4b5563;
    font-size: 0.8rem;
    line-height: 1.6;
}

.footer-bottom .footer-copyright {
    color: #6b7280;
    font-size: 0.82rem;
}

.footer-bottom .footer-disclaimer {
    color: #4b5563;
    font-size: 0.75rem;
    max-width: 760px;
    line-height: 1.65;
}

@media (max-width: 900px) {
    .site-footer {
        padding: 4rem 2rem 0;
    }
    .footer-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 2.5rem;
    }
    .footer-links {
        flex-direction: column;
        align-items: flex-start;
        gap: 2rem;
        width: 100%;
    }
    .link-column { align-items: flex-start; width: 100%; }
}

/* ==================================================
   Subpage CSS: Card Processing (card-processing.html)
   ================================================== */
.sp-header { text-align: center; margin: 8rem auto 4rem; max-width: 800px; padding: 0 2rem; }
.sp-title { font-size: 3.5rem; font-weight: 600; line-height: 1.1; letter-spacing: -1px; margin-bottom: 1rem; color: #000; }
.sp-title span { color: #6e7a8a; } /* Slate gray highlight */
.sp-subtitle { font-size: 1.15rem; color: #4a5568; line-height: 1.6; max-width: 600px; margin: 0 auto; }

.sp-section { padding: 5rem 2rem; max-width: 1200px; margin: 0 auto; clear: both; }
.sp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }

@media (max-width: 900px) {
    .sp-grid { grid-template-columns: 1fr; gap: 2rem; }
}

.sp-media-wrapper { position: relative; border-radius: 16px; overflow: hidden; width: 100%; }
.sp-media-wrapper img { width: 100%; height: auto; display: block; border-radius: 16px; object-fit: cover; }

/* The glass stat overlay */
.sp-stat-card {
    position: absolute; bottom: 1.5rem; right: 1.5rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    border-radius: 12px;
    padding: 1.5rem;
    min-width: 220px;
    text-align: center;
    z-index: 5;
}
.sp-stat-title { font-size: 0.8rem; color: #4a5568; margin-bottom: 0.5rem; }
.sp-stat-value { font-size: 2.5rem; font-weight: 700; color: #000; margin-bottom: 0.5rem; }
.sp-stat-delta { font-size: 0.85rem; color: #059669; font-weight: 600; margin-bottom: 0.25rem; }
.sp-stat-desc { font-size: 0.75rem; color: #a0aec0; }

/* The icon feature stack */
.sp-feat-list { display: flex; flex-direction: column; gap: 2.5rem; }
.sp-feat-item { display: flex; gap: 1.25rem; align-items: flex-start; }
.sp-feat-icon { flex-shrink: 0; color: #000; margin-top: 2px; }
.sp-feat-content h4 { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.5rem; color: #000; }
.sp-feat-content p { font-size: 0.95rem; line-height: 1.6; color: #4a5568; }

/* The Grey block layout */
.sp-grey-box { background: #f5f6f8; border-radius: 20px; padding: 4rem 3rem; }

/* The Testimonial Layout */
.sp-quote-wrapper { background: #eef4ff; border-radius: 20px; padding: 4rem 3rem; display: flex; flex-direction: column; justify-content: center; height: 100%; box-sizing: border-box; }
.sp-quote-mark { font-size: 5rem; line-height: 1; color: #2b6cb0; margin-bottom: 1rem; font-family: Georgia, serif; font-style: italic; }
.sp-quote-text { font-size: 1.4rem; line-height: 1.5; font-weight: 500; color: #000; margin-bottom: 2rem; }
.sp-quote-author { display: flex; align-items: center; gap: 1rem; }
.sp-quote-avatar { width: 50px; height: 50px; border-radius: 50%; object-fit: cover; }
.sp-quote-name { font-weight: 600; color: #2b6cb0; font-size: 1rem; margin-bottom: 0.2rem; }
.sp-quote-role { font-size: 0.85rem; color: #718096; }

/* Extended Layouts (Dark Mode, 3-Col, Split Headers) */
.sp-dark-section { background: #000; color: #fff; padding: 6rem 2rem; width: 100%; border-radius: 0; }
.sp-dark-section .sp-title { color: #fff; }
.sp-dark-section .sp-subtitle { color: #a0aec0; }
.sp-dark-section .sp-quote-text { color: #fff; }

.sp-check-list { display: flex; flex-direction: column; gap: 1.5rem; margin-top: 2rem; }
.sp-check-item { display: flex; gap: 1rem; align-items: flex-start; }
.sp-check-icon { width: 24px; height: 24px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 2px; }
.sp-check-icon svg { width: 14px; height: 14px; stroke: #000; stroke-width: 3; fill: none; }
.sp-check-text { font-size: 0.95rem; line-height: 1.5; color: #e2e8f0; }

.sp-link-blue { color: #3182ce; text-decoration: none; font-weight: 500; font-size: 0.95rem; display: inline-flex; align-items: center; gap: 0.5rem; margin-top: 2rem; transition: opacity 0.2s; }
.sp-link-blue:hover { opacity: 0.8; }

.sp-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3rem; margin-top: 3rem; }
@media (max-width: 900px) { .sp-grid-3 { grid-template-columns: 1fr; } }
.sp-fw-image { width: 100%; height: 500px; object-fit: cover; border-radius: 20px; margin-top: 2rem; }

.sp-header-split { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: end; margin-bottom: 2rem; }
@media (max-width: 900px) { .sp-header-split { grid-template-columns: 1fr; gap: 1.5rem; align-items: start; } }

/* ============================================================
   Responsive — Buy / Sell / Rent / generic subpage sections
   ============================================================ */
@media (max-width: 900px) {
    .sp-section { padding: 3rem 1.25rem !important; }
    .sp-section[style*="padding: 10rem"] { padding: 6rem 1.25rem 3rem !important; }
    .sp-section[style*="padding-bottom: 8rem"] { padding-bottom: 4rem !important; }
    .sp-grid { grid-template-columns: 1fr !important; gap: 1.5rem !important; }
    .sp-grid > .sp-media-wrapper { height: 320px !important; }
    .sp-grid > .sp-media-wrapper[style*="600px"] { height: 340px !important; }
    .sp-grey-box { padding: 2.5rem 1.75rem !important; }
    .sp-grey-box .sp-title { font-size: 2rem !important; }
    .sp-fw-image { height: 320px !important; }
    .sp-title { font-size: 2.25rem; letter-spacing: -1px; }
    .sp-grid-3 { gap: 2rem !important; margin-top: 2rem !important; }
    .sp-stat-card { min-width: 0; padding: 1rem 1.25rem; right: 1rem; bottom: 1rem; }
    .sp-stat-value { font-size: 1.75rem; }
    .sp-check-list { gap: 1rem; }
    .sp-feat-list { gap: 1.75rem; }
    .sp-dark-section .sp-grid { align-items: stretch !important; }
}
@media (max-width: 600px) {
    .sp-title { font-size: 1.9rem; }
    .sp-grey-box { padding: 2rem 1.25rem !important; }
    .sp-grey-box .sp-title { font-size: 1.75rem !important; }
    .sp-fw-image { height: 240px !important; border-radius: 14px; }
    .sp-grid > .sp-media-wrapper { height: 260px !important; }
    .sp-grid > .sp-media-wrapper[style*="600px"] { height: 260px !important; }
}

/* Team Section (About page) */
.team-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2rem;
}
@media (max-width: 900px) { .team-grid { grid-template-columns: 1fr; max-width: 420px; margin: 0 auto; } }

.team-card {
    perspective: 1500px;
    aspect-ratio: 4 / 5;
    min-height: 360px;
}

.team-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.7s cubic-bezier(0.4, 0.2, 0.2, 1);
    transform-style: preserve-3d;
}

.team-card.is-flipped .team-card-inner {
    transform: rotateY(180deg);
}

.team-card-face {
    position: absolute;
    inset: 0;
    border-radius: 20px;
    overflow: hidden;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transform: translate3d(0, 0, 0);
    -webkit-transform: translate3d(0, 0, 0);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
}

.team-card-face *,
.team-card-face::before,
.team-card-face::after {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.team-card-front {
    background: #000;
    color: #fff;
    position: absolute;
    inset: 0;
}

.team-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.team-card-front::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.35) 35%, rgba(0,0,0,0) 60%);
    pointer-events: none;
}

.team-card-front .team-info {
    position: absolute;
    left: 1.5rem;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 2;
}

.team-card-front .team-info h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    letter-spacing: -0.5px;
    color: #fff;
}

.team-card-front .team-info p {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.9);
    font-weight: 500;
}

.team-card-back {
    background: #f7f9fa;
    color: #1a202c;
    transform: rotateY(180deg);
    padding: 2.5rem 2rem;
    justify-content: center;
}

.team-card-back h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    letter-spacing: -0.5px;
}

.team-card-back .team-role {
    font-size: 0.72rem;
    color: #2b6cb0;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 1.25rem;
}

.team-card-back p {
    color: #4a5568;
    line-height: 1.65;
    font-size: 0.95rem;
}

.team-flip-btn {
    position: absolute;
    right: 1rem;
    bottom: 1rem;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(255,255,255,0.95);
    color: #1a202c;
    border: none;
    border-radius: 999px;
    padding: 0.55rem 1rem;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
    font-family: inherit;
    white-space: nowrap;
}

.team-flip-btn:hover {
    background: #fff;
    transform: translateY(-1px);
}

.team-card-back .team-flip-btn {
    background: #1a202c;
    color: #fff;
}

.team-card-back .team-flip-btn:hover {
    background: #000;
}

/* Blog Grid Overrides */
.blog-grid .blog-card {
    flex: auto;
}

/* Agent Grid Styles */
.agents-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2.5rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 2rem 4rem 2rem;
}

.agent-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    border: 1px solid #edf2f7;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.agent-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.1);
}

.agent-image {
    width: 100%;
    height: 320px;
    object-fit: cover;
    border-bottom: 1px solid #edf2f7;
}
@media (max-width: 600px) {
    .agent-image { height: 260px; }
    .agent-info { padding: 1.25rem; }
}

.agent-info {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.agent-name {
    font-size: 1.35rem;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 0.25rem;
}

.agent-title {
    font-size: 0.9rem;
    color: var(--accent-blue);
    font-weight: 600;
    margin-bottom: 1.25rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.agent-bio {
    font-size: 0.95rem;
    color: #4a5568;
    line-height: 1.6;
    margin-bottom: 2rem;
    flex: 1;
}

.agent-contact {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #4a5568;
    border-top: 1px solid #edf2f7;
    padding-top: 1.25rem;
}

.agent-contact span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.agent-icon {
    color: var(--accent-blue);
}


/* =========================================================================
   4. REUSABLE COMPONENTS
   ========================================================================= */

.card-ds {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    border: 1px solid var(--border-color);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.card-ds:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.1);
}

.badge {
    padding: 0.25rem 0.6rem;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-block;
}

.badge-primary {
    background: var(--accent-blue);
    color: #fff;
}

/* =========================================================================
   5. UNIFIED FORMS
   ========================================================================= */

.form-group-sys {
    margin-bottom: 1.5rem;
    text-align: left;
}

.input-sys {
    width: 100%;
    padding: 1rem;
    border: 1px solid #cbd5e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.input-sys:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 3px rgba(43, 108, 176, 0.2);
}


/* -------------------------------------
   Universal Card Inner Details
   ------------------------------------- */
.card-image {
    width: 100%;
    height: 320px;
    object-fit: cover;
    border-bottom: 1px solid var(--border-color);
}

.card-info {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.card-name {
    font-size: 1.35rem;
    font-weight: 700;
    color: #1a202c;
    margin-bottom: 0.25rem;
}

.card-title {
    font-size: 0.9rem;
    color: var(--accent-blue);
    font-weight: 600;
    margin-bottom: 1.25rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-bio {
    font-size: 0.95rem;
    color: #4a5568;
    line-height: 1.6;
    margin-bottom: 2rem;
    flex: 1;
}

.card-footer {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #4a5568;
    border-top: 1px solid #edf2f7;
    padding-top: 1.25rem;
}

.card-footer span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.card-icon {
    color: var(--accent-blue);
}

.agents-grid-sys {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2.5rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 2rem 8rem 2rem;
}

/* =========================================================================
   PORTAL & ADMIN PANEL UTILITIES
   Shared classes for admin dashboard, agent dashboard, and review pages.
   These extend style.css — no inline <style> blocks needed in those pages.
   ========================================================================= */

/* Shared Portal Layout */
.admin-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    min-height: 100vh;
    background-color: #f7f9fa;
}

.admin-sidebar {
    background-color: #1a202c;
    color: #fff;
    padding: 2rem 1.5rem;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.admin-content {
    padding: 4rem;
    overflow-y: auto;
}

.admin-nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #a0aec0;
    text-decoration: none;
    padding: 0.85rem 1rem;
    border-radius: 8px;
    margin-bottom: 0.5rem;
    font-weight: 500;
    transition: all 0.2s;
}

.admin-nav-link:hover,
.admin-nav-link.active {
    background-color: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* Metric Cards */
.metric-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.metric-card {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid #edf2f7;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
}

.metric-title {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #718096;
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: #1a202c;
    line-height: 1;
}

.metric-alert {
    color: #dd6b20;
    border-left: 3px solid #dd6b20;
    padding-left: 1rem;
    margin-top: 1rem;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Portal Panel (white card containers) */
.portal-panel {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #edf2f7;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
    padding: 3rem;
}

.portal-section-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #edf2f7;
    color: #1a202c;
}

/* Agent Dashboard Specific */
.dashboard-container {
    padding: 8rem 2rem 5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.status-banner {
    padding: 1.25rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.status-draft {
    background-color: #fffaf0;
    border-left: 4px solid #dd6b20;
    color: #9c4221;
}

.status-pending {
    background-color: #ebf8ff;
    border-left: 4px solid var(--accent-blue);
    color: #2b6cb0;
    display: none;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.photo-upload-placeholder {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background-color: #edf2f7;
    border: 2px dashed #cbd5e0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #718096;
    cursor: pointer;
    transition: all 0.2s;
}

.photo-upload-placeholder:hover {
    border-color: var(--accent-blue);
    color: var(--accent-blue);
    background-color: #ebf8ff;
}

.progress-bar-container {
    background: #edf2f7;
    border-radius: 99px;
    height: 10px;
    width: 100%;
    margin-top: 1rem;
    overflow: hidden;
}

.progress-bar {
    background: var(--accent-blue);
    height: 100%;
    width: 0%;
    transition: width 0.4s ease;
}

/* Admin Data Tables */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.data-table th {
    text-align: left;
    padding: 0.75rem 1.5rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #718096;
    font-weight: 700;
    background: #f7f9fa;
    border-bottom: 2px solid #edf2f7;
}

.data-table td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #edf2f7;
    color: #2d3748;
    vertical-align: middle;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.data-table tr:hover td {
    background-color: #f7f9fa;
}

.s-badge {
    display: inline-block;
    padding: 0.3rem 0.75rem;
    border-radius: 99px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-published  { background: #c6f6d5; color: #276749; }
.status-pending    { background: #bee3f8; color: #2b6cb0; display: inline-block; }
.status-draft      { background: #e2e8f0; color: #4a5568; display: inline-block; }
.status-suspended  { background: #fed7d7; color: #c53030; }
.status-new        { background: #fef3c7; color: #92400e; }
.status-unassigned { background: #e2e8f0; color: #4a5568; }
.type-buyer        { background: #ebf8ff; color: #2b6cb0; }
.type-general      { background: #f0fff4; color: #276749; }


/* Minnesota Photo Gallery Section */
.mn-photo-gallery {
    padding: 8rem 2rem;
    background: #f7f9fa;
}
.mn-photo-gallery-container {
    max-width: 1400px;
    margin: 0 auto;
}
.mn-photo-gallery-header {
    text-align: center;
    margin-bottom: 4rem;
}
.mn-photo-gallery-eyebrow {
    font-weight: 600;
    color: #2b6cb0;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-size: 0.85rem;
    margin-bottom: 1rem;
}
.mn-photo-gallery-title {
    font-size: 3rem;
    font-weight: 800;
    color: #1a202c;
    letter-spacing: -1.5px;
    line-height: 1.1;
    margin: 0 0 1.25rem;
}
.mn-photo-gallery-subtitle {
    color: #4a5568;
    font-size: 1.15rem;
    line-height: 1.6;
    max-width: 640px;
    margin: 0 auto;
}
.mn-photo-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1rem;
}
.mn-photo-gallery-grid img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 12px;
    display: block;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    box-shadow: 0 4px 14px rgba(0,0,0,0.05);
}
.mn-photo-gallery-grid img:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0,0,0,0.12);
}
.mn-photo-gallery-grid .tall {
    aspect-ratio: 3 / 4;
}
.mn-photo-gallery-grid .wide {
    grid-column: span 2;
    aspect-ratio: 16 / 9;
}
@media (max-width: 700px) {
    .mn-photo-gallery {
        padding: 5rem 1.25rem;
    }
    .mn-photo-gallery-title {
        font-size: 2.2rem;
    }
    .mn-photo-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.6rem;
    }
    .mn-photo-gallery-grid .wide {
        grid-column: span 2;
    }
}
