/* ========== RESET & BASE ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors */
    --bg-primary: #0B1220;
    --bg-secondary: #0F1923;
    --bg-card: #111D2B;
    --bg-darker: #070D17;
    --accent-cyan: #1DA1F2;
    --accent-cyan-light: #4DC9F6;
    --accent-cyan-dark: #0E7AC2;
    --accent-red: #E63946;
    --text-primary: #F0F4F8;
    --text-secondary: #CBD5E1;
    /* Increased brightness for better contrast */
    --text-dim: #94A3B8;
    --border: rgba(29, 161, 242, 0.12);
    --border-hover: rgba(29, 161, 242, 0.3);
    --glass-bg: rgba(11, 18, 32, 0.85);

    /* Typography */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Inter', sans-serif;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    background-color: var(--bg-darker);
}

/* --- Animated Space Background Container --- */
.space-background-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -10;
    pointer-events: none;
    background-color: #070e17;
    /* Base dark color from user */
    overflow: hidden;
}

/* --- Stars (Background Layer) --- */
.space-background-container .stars-animated {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(1px 1px at 15% 15%, #ffffff 100%, transparent),
        radial-gradient(1.5px 1.5px at 45% 45%, #ffffff 80%, transparent),
        radial-gradient(1px 1px at 75% 85%, #88b7d5 100%, transparent),
        radial-gradient(1px 1px at 55% 15%, #ffffff 100%, transparent),
        radial-gradient(1.5px 1.5px at 90% 60%, #88b7d5 80%, transparent);
    background-size: 300px 300px;
    animation: twinkle 3s ease-in-out infinite alternate;
    z-index: 1;
}

/* --- Nebulas (Blurred background lights) --- */
.space-background-container .nebula {
    position: absolute;
    border-radius: 50%;
    background: #091729;
    /* Darkened */
    filter: blur(120px);
    /* Increased blur for smoother spread */
    opacity: 0.3;
    /* Halved opacity so it doesn't look like a solid smudge */
    z-index: 2;
    pointer-events: none;
}

.space-background-container .nebula-1 {
    width: 50vw;
    height: 50vh;
    top: 10%;
    left: 20%;
    animation: drift 20s infinite ease-in-out;
}

.space-background-container .nebula-2 {
    width: 40vw;
    height: 60vh;
    bottom: -10%;
    right: 10%;
    background: #0a2038;
    animation: drift 25s infinite ease-in-out reverse;
}

/* Optimize space background for mobile: kill extreme blurs that cause scrolling stutter */
@media (max-width: 768px) {
    .space-background-container .nebula {
        filter: blur(40px);
        opacity: 0.15;
        animation: none;
    }

    .space-background-container .stars-animated {
        animation: none;
    }

    .space-background-container .space-object {
        animation: none;
    }

    .floating-star {
        animation-duration: 10s !important;
    }
}

@media (max-width: 480px) {
    .space-background-container .nebula {
        display: none;
    }

    .space-background-container .stars-animated {
        opacity: 0.5;
    }

    .floating-star {
        animation: none !important;
        opacity: 0.4 !important;
    }
}

/* --- Floating Objects (Planets and Rings) --- */
.space-background-container .space-object {
    position: absolute;
    border-radius: 50%;
    z-index: 3;
    pointer-events: none;
}

/* --- Floating Star Particles --- */
.floating-star {
    position: absolute;
    background: #ffffff;
    border-radius: 50%;
    pointer-events: none;
    z-index: 2;
    opacity: 0;
    animation: starFloat 8s ease-in-out infinite;
}

.floating-star.star-blue {
    background: #88ccff;
    box-shadow: 0 0 4px rgba(136, 204, 255, 0.6);
}

@keyframes starFloat {
    0% {
        opacity: 0;
        transform: translateY(0) translateX(0) scale(1);
    }

    20% {
        opacity: 0.9;
    }

    50% {
        opacity: 0.5;
        transform: translateY(-40px) translateX(20px) scale(1.3);
    }

    80% {
        opacity: 0.8;
    }

    100% {
        opacity: 0;
        transform: translateY(-80px) translateX(-10px) scale(0.8);
    }
}

/* Estilo para los Planetas sólidos */
.space-background-container .planet {
    background: radial-gradient(circle at 30% 30%, #1c456b, #0c1f35);
    box-shadow: inset -10px -10px 20px rgba(0, 0, 0, 0.4), 0 0 20px rgba(29, 161, 242, 0.15);
}

/* Estilo para los Anillos huecos */
.space-background-container .ring {
    border: 6px solid #143754;
    box-sizing: border-box;
    background: transparent;
    box-shadow: 0 0 15px rgba(29, 161, 242, 0.1);
}

/* Posicionamiento y tamaños específicos */
.space-background-container .obj1 {
    width: 140px;
    height: 140px;
    top: 25%;
    left: -2%;
    animation: floatVertical 8s ease-in-out infinite;
}

.space-background-container .obj2 {
    width: 60px;
    height: 60px;
    bottom: 20%;
    left: 8%;
    animation: floatHorizontal 12s ease-in-out infinite;
    border-width: 8px;
}

.space-background-container .obj3 {
    width: 130px;
    height: 130px;
    bottom: -5%;
    right: 8%;
    animation: floatVertical 10s ease-in-out infinite reverse;
    opacity: 0.9;
}

.space-background-container .obj4 {
    width: 50px;
    height: 50px;
    top: 15%;
    right: 8%;
    animation: floatHorizontal 14s ease-in-out infinite;
    border-width: 6px;
}

.space-background-container .obj5 {
    width: 80px;
    height: 80px;
    top: 10%;
    right: 28%;
    animation: floatVertical 16s ease-in-out infinite;
    border: 4px solid rgba(20, 55, 84, 0.4);
}

/* --- Animaciones (Keyframes) --- */

@keyframes twinkle {
    0% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }

    100% {
        opacity: 0.65;
    }
}

@keyframes drift {
    0% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(30px, -30px) scale(1.05);
    }

    66% {
        transform: translate(-20px, 20px) scale(0.95);
    }

    100% {
        transform: translate(0, 0) scale(1);
    }
}

@keyframes floatVertical {
    0% {
        transform: scale(1) rotate(0deg);
        opacity: 0.6;
        box-shadow: 0 0 15px rgba(29, 161, 242, 0.1);
    }

    50% {
        transform: scale(1.08) rotate(5deg);
        opacity: 1;
        box-shadow: 0 0 30px rgba(29, 161, 242, 0.25);
    }

    100% {
        transform: scale(1) rotate(0deg);
        opacity: 0.6;
        box-shadow: 0 0 15px rgba(29, 161, 242, 0.1);
    }
}

@keyframes floatHorizontal {
    0% {
        transform: scale(1) rotate(0deg);
        opacity: 0.5;
        box-shadow: 0 0 10px rgba(29, 161, 242, 0.1);
    }

    50% {
        transform: scale(1.12) rotate(-5deg);
        opacity: 0.9;
        box-shadow: 0 0 25px rgba(29, 161, 242, 0.3);
    }

    100% {
        transform: scale(1) rotate(0deg);
        opacity: 0.5;
        box-shadow: 0 0 10px rgba(29, 161, 242, 0.1);
    }
}

/* --- Animated Space Background Container --- */
.space-background-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: -10;
    pointer-events: none;
    background-color: #070e17;
    /* Base dark color from user */
    overflow: hidden;
}

/* --- Stars (Background Layer) --- */
.space-background-container .stars-animated {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* User's star gradients */
    background-image:
        radial-gradient(1px 1px at 15% 15%, #ffffff 100%, transparent),
        radial-gradient(1px 1px at 85% 25%, #ffffff 100%, transparent),
        radial-gradient(2px 2px at 45% 45%, #ffffff 80%, transparent),
        radial-gradient(1px 1px at 75% 85%, #88b7d5 100%, transparent),
        radial-gradient(1.5px 1.5px at 25% 75%, #ffffff 100%, transparent),
        radial-gradient(1px 1px at 55% 15%, #ffffff 100%, transparent),
        radial-gradient(2px 2px at 90% 60%, #88b7d5 80%, transparent);
    background-size: 250px 250px;
    animation: twinkle 4s ease-in-out infinite alternate;
    z-index: 1;
}

/* --- Nebulas (Blurred background lights) --- */
.space-background-container .nebula {
    position: absolute;
    border-radius: 50%;
    background: #091729;
    /* Darkened */
    filter: blur(120px);
    /* Increased blur for smoother spread */
    opacity: 0.3;
    /* Halved opacity so it doesn't look like a solid smudge */
    z-index: 2;
    pointer-events: none;
}

.space-background-container .nebula-1 {
    width: 50vw;
    height: 50vh;
    top: 10%;
    left: 20%;
    animation: drift 20s infinite ease-in-out;
}

.space-background-container .nebula-2 {
    width: 40vw;
    height: 60vh;
    bottom: -10%;
    right: 10%;
    background: #0a2038;
    animation: drift 25s infinite ease-in-out reverse;
}

/* --- Floating Objects (Planets and Rings) --- */
.space-background-container .space-object {
    position: absolute;
    border-radius: 50%;
    z-index: 3;
    pointer-events: none;
}

/* Estilo para los Planetas sólidos */
.space-background-container .planet {
    background: radial-gradient(circle at 30% 30%, #1c456b, #0c1f35);
    box-shadow: inset -10px -10px 20px rgba(0, 0, 0, 0.4);
}

/* Estilo para los Anillos huecos */
.space-background-container .ring {
    border: 6px solid #143754;
    box-sizing: border-box;
    background: transparent;
}

/* Posicionamiento y tamaños específicos */
.space-background-container .obj1 {
    width: 140px;
    height: 140px;
    top: 25%;
    left: -2%;
    animation: floatVertical 8s ease-in-out infinite;
}

.space-background-container .obj2 {
    width: 60px;
    height: 60px;
    bottom: 20%;
    left: 8%;
    animation: floatHorizontal 12s ease-in-out infinite;
    border-width: 8px;
}

.space-background-container .obj3 {
    width: 130px;
    height: 130px;
    bottom: -5%;
    right: 8%;
    animation: floatVertical 10s ease-in-out infinite reverse;
    opacity: 0.9;
}

.space-background-container .obj4 {
    width: 50px;
    height: 50px;
    top: 15%;
    right: 8%;
    animation: floatHorizontal 14s ease-in-out infinite;
    border-width: 6px;
}

.space-background-container .obj5 {
    width: 80px;
    height: 80px;
    top: 10%;
    right: 28%;
    animation: floatVertical 16s ease-in-out infinite;
    border: 4px solid rgba(20, 55, 84, 0.4);
}

/* --- Animaciones (Keyframes) --- */

@keyframes twinkle {
    0% {
        opacity: 0.6;
        transform: scale(1);
    }

    100% {
        opacity: 1;
        transform: scale(1.02);
    }
}

@keyframes drift {
    0% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(30px, -30px) scale(1.05);
    }

    66% {
        transform: translate(-20px, 20px) scale(0.95);
    }

    100% {
        transform: translate(0, 0) scale(1);
    }
}

@keyframes floatVertical {
    0% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-25px) rotate(5deg);
    }

    100% {
        transform: translateY(0px) rotate(0deg);
    }
}

@keyframes floatHorizontal {
    0% {
        transform: translateX(0px) translateY(0px);
    }

    50% {
        transform: translateX(20px) translateY(-10px);
    }

    100% {
        transform: translateX(0px) translateY(0px);
    }
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

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

button {
    font-family: var(--font-body);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* ========== SCROLL PROGRESS BAR ========== */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-cyan), var(--accent-cyan-light));
    z-index: 10000;
    transition: width 0.1s ease;
}

/* ========== NAVIGATION ========== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 9999;
    transition: all 0.3s ease;
    padding: 1.25rem 0;
}

.navbar.scrolled {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
    padding: 0.75rem 0;
}

.navbar .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar .logo {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar .logo .logo-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-cyan-light));
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.navbar .logo .ai {
    color: var(--accent-cyan);
}

.navbar .nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
    align-items: center;
}

.navbar .nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
}

.navbar .nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-cyan);
    transition: width 0.3s ease;
}

.navbar .nav-links a:hover {
    color: var(--text-primary);
}

.navbar .nav-links a:hover::after {
    width: 100%;
}

/* Active Nav Link */
.navbar .nav-links a.active {
    color: var(--accent-cyan);
}

.navbar .nav-links a.active::after {
    width: 100%;
}

/* ========== NAV DROPDOWNS ========== */
.nav-links li {
    position: relative;
}

.nav-dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    min-width: 260px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 0.75rem 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s, transform 0.2s;
    transform: translateX(-50%) translateY(8px);
    z-index: 1000;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
    pointer-events: none;
}

.nav-links li:hover .nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.nav-dropdown .dropdown-label {
    padding: 0.4rem 1.25rem;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-cyan);
    font-weight: 700;
}

.nav-dropdown a {
    display: block;
    padding: 0.5rem 1.25rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}

.nav-dropdown a:hover {
    background: rgba(29, 161, 242, 0.08);
    color: var(--text-primary);
}

.nav-dropdown a.active {
    color: var(--accent-cyan);
    background: rgba(29, 161, 242, 0.06);
}

.nav-dropdown a::after {
    display: none;
}

.nav-dropdown .divider {
    height: 1px;
    background: var(--border);
    margin: 0.5rem 0;
}

.navbar .nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.navbar .social-icon-header {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.navbar .social-icon-header:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* ========== BUTTONS ========== */
.btn-primary {
    background: var(--accent-cyan);
    color: white;
    padding: 0.75rem 1.75rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    border: 2px solid var(--accent-cyan);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.5s ease;
    z-index: 1;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    background: var(--accent-cyan-light);
    border-color: var(--accent-cyan-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(29, 161, 242, 0.3);
}

.btn-outline {
    background: transparent;
    color: var(--accent-cyan);
    padding: 0.75rem 1.75rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: 2px solid var(--accent-cyan);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-outline::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.5s ease;
    z-index: 1;
}

.btn-outline:hover::before {
    left: 100%;
}

.btn-outline:hover {
    background: var(--accent-cyan);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(29, 161, 242, 0.3);
}

.btn-red {
    background: var(--accent-red);
    color: white;
    padding: 0.75rem 1.75rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: 2px solid var(--accent-red);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-red::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.5s ease;
    z-index: 1;
}

.btn-red:hover::before {
    left: 100%;
}

.btn-red:hover {
    background: #d32f3e;
    border-color: #d32f3e;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(230, 57, 70, 0.3);
}

/* Mobile Menu */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    width: 28px;
    height: 3px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

.mobile-nav {
    display: none;
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
    z-index: 9998;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.mobile-nav.active {
    display: block;
    max-height: 600px;
}

.mobile-nav .nav-links {
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
}

.section {
    padding: 4rem 1.5rem;
    position: relative;
}

.section.dark {
    background: rgba(7, 13, 23, 0.5);
}

.section.darker {
    background: linear-gradient(180deg, rgba(7, 13, 23, 0.6), rgba(11, 18, 32, 0.4));
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

.section-label {
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--accent-cyan);
    margin-bottom: 1rem;
    display: block;
}

.section-title {
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
    margin-bottom: 1.5rem;
    line-height: 1.2;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    margin: 8px auto 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-cyan), var(--accent-cyan-light));
    border-radius: 2px;
    transition: width 0.8s ease;
}

.section-title.active::after {
    width: 60%;
}

.section-title.no-underline::after {
    display: none;
}

.section-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--text-secondary);
    max-width: 900px;
    line-height: 1.7;
}

/* Reveal Animation */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease;
}

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

/* CTA Buttons Container */
.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 3rem;
}

/* ========== CTA BANNER (Shared across services/pricing) ========== */
.cta-banner {
    background-image: url('https://images.unsplash.com/photo-1504384308090-c894fdcc538d?w=1200&q=60');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    padding: 6rem 0;
    margin: 4rem 0;
}

.cta-banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(11, 18, 32, 0.92), rgba(11, 18, 32, 0.88));
    z-index: 0;
}

.cta-banner .container {
    position: relative;
    z-index: 1;
}

.cta-banner h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-weight: 800;
    font-family: var(--font-heading);
}

/* ========== INDUSTRY TAGS (Shared) ========== */
.industry-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.industry-tag {
    background: rgba(29, 161, 242, 0.08);
    border: 1px solid rgba(29, 161, 242, 0.2);
    color: var(--accent-cyan-light);
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.4rem 1rem;
    border-radius: 20px;
}

/* ========== COMMUNITY COLLAGE (Shared) ========== */
.community-collage-new {
    position: relative;
    max-width: 1000px;
    margin: 4rem auto;
    padding: 2rem 0;
}

.collage-connectors {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.collage-grid-custom {
    position: relative;
    width: 100%;
    height: 600px;
    z-index: 1;
}

.collage-item {
    position: absolute;
    width: 260px;
    height: 180px;
    border-radius: 16px;
    overflow: hidden;
    border: 2px solid rgba(29, 161, 242, 0.4);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.6);
    transition: all 0.4s ease;
    cursor: pointer;
    background: #060B14;
}

.collage-item:hover {
    transform: scale(1.05);
    border-color: rgba(29, 161, 242, 1);
    box-shadow: 0 10px 30px rgba(29, 161, 242, 0.3), inset 0 0 15px rgba(29, 161, 242, 0.2);
    z-index: 10;
}

/* Positioning based on a classic 5-point layout around center */
.collage-item.box-1 {
    /* Top Center - Immigration */
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}

.collage-item.box-1:hover {
    transform: translateX(-50%) scale(1.05);
}

.collage-item.box-2 {
    /* Middle Left - Legal */
    top: 50%;
    left: 4%;
    transform: translateY(-50%);
}

.collage-item.box-2:hover {
    transform: translateY(-50%) scale(1.05);
}

.collage-item.box-3 {
    /* Middle Right - Housing */
    top: 50%;
    right: 4%;
    transform: translateY(-50%);
}

.collage-item.box-3:hover {
    transform: translateY(-50%) scale(1.05);
}

.collage-item.box-4 {
    /* Bottom Left - Employment */
    bottom: 0;
    left: 17%;
}

.collage-item.box-4:hover {
    transform: scale(1.05);
}

.collage-item.box-5 {
    /* Bottom Right - Health */
    bottom: 0;
    right: 17%;
}

.collage-item.box-5:hover {
    transform: scale(1.05);
}

.collage-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    filter: brightness(0.85);
    /* Slightly darken unused */
}

.collage-item:hover img {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.collage-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 0.8rem 1rem;
    background: linear-gradient(180deg, transparent 0%, rgba(6, 11, 20, 0.95) 80%);
    color: white;
    text-align: left;
}

.collage-label {
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.collage-center-box {
    position: absolute;
    top: 67.5%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2.2rem;
    font-weight: 700;
    color: #ffffff;
    z-index: 5;
    letter-spacing: -0.02em;
    background: rgba(6, 11, 20, 0.85);
    padding: 0.8rem 1.8rem;
    border-radius: 30px;
    border: 1px solid rgba(29, 161, 242, 0.5);
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.8), inset 0 0 15px rgba(29, 161, 242, 0.1);
    backdrop-filter: blur(8px);
    display: inline-flex;
    align-items: center;
}

/* ========== PAGE HERO (Subpages) ========== */
.page-hero {
    position: relative;
    padding: 10rem 2rem 4rem;
    text-align: center;
    background: linear-gradient(135deg, var(--bg-darker) 0%, var(--bg-primary) 100%);
    overflow: hidden;
}

.page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridScroll 20s linear infinite;
    z-index: 0;
}

@keyframes gridScroll {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(50px, 50px);
    }
}

.page-hero .container {
    position: relative;
    z-index: 1;
}

.page-hero .breadcrumb {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.page-hero .breadcrumb a {
    color: var(--accent-cyan);
}

.page-hero .breadcrumb a:hover {
    text-decoration: underline;
}

.page-hero .breadcrumb span {
    margin: 0 0.5rem;
    color: var(--text-dim);
}

.page-hero h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    font-weight: 800;
    margin-bottom: 1rem;
}

.page-hero p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Decorative circles for page hero */
.page-hero .deco-circle {
    position: absolute;
    border: 1px solid rgba(29, 161, 242, 0.15);
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}

.page-hero .deco-circle:nth-child(1) {
    width: 200px;
    height: 200px;
    top: 15%;
    left: 5%;
}

.page-hero .deco-circle:nth-child(2) {
    width: 120px;
    height: 120px;
    top: 20%;
    right: 10%;
}

.page-hero .deco-circle:nth-child(3) {
    width: 80px;
    height: 80px;
    bottom: 20%;
    right: 20%;
}

/* ========== SHARED KEYFRAMES ========== */
@keyframes radarSweep {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes ringPulse {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.6;
        border-color: rgba(29, 161, 242, 0.3);
    }

    100% {
        transform: translate(-50%, -50%) scale(7);
        opacity: 0;
        border-color: rgba(29, 161, 242, 0);
    }
}

/* ========== FOOTER ========== */

.footer {
    background: url('../images/washington-dc-monuments-at-night.jpg') center center / cover no-repeat;
    border-top: none;
    padding: 2.5rem 4rem 0;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(7, 13, 23, 0.68);
    z-index: 0;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1.6fr 1fr;
    gap: 2rem;
    padding-bottom: 2rem;
    position: relative;
    z-index: 1;
    align-items: start;
}

.footer-brand {
    padding-top: 0.25rem;
}

.footer-column h4 {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #ffffff;
    margin-top: 0;
    margin-bottom: 0.6rem;
}

.footer-column ul {
    list-style: none;
}

.footer-column li {
    margin-bottom: 0.35rem;
}

.footer-column a {
    color: #CBD5E1;
    font-size: 0.88rem;
    font-weight: 400;
    transition: color 0.2s ease;
    text-decoration: none;
}

.footer-column a:hover {
    color: #ffffff;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding: 0.9rem 0;
    text-align: center;
    color: #94A3B8;
    font-size: 0.82rem;
    font-weight: 400;
    position: relative;
    z-index: 1;
    max-width: 100%;
}

.badge-pending {
    display: inline-block;
    color: #ff3b3b;
    font-weight: 900;
    font-style: italic;
    font-size: 0.85rem;
    margin-left: 0.5rem;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.9), 0 0 15px rgba(255, 255, 255, 0.6);
    filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.8));
    animation: pendingPulse 2s infinite ease-in-out;
}

@keyframes pendingPulse {

    0%,
    100% {
        transform: scale(1);
        filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.8));
    }

    50% {
        transform: scale(1.05);
        filter: drop-shadow(0 0 5px rgba(255, 255, 255, 1));
    }
}

/* ========== RESPONSIVE — SHARED ========== */
@media (max-width: 1024px) {

    /* --- NAV: hide desktop links, show hamburger --- */
    .navbar .nav-links {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
        min-width: 44px;
        min-height: 44px;
        align-items: center;
        justify-content: center;
        padding: 0.5rem;
    }

    /* Hide desktop nav-right on tablet/mobile */
    .navbar .nav-right {
        display: none;
    }

    /* --- MOBILE NAV OVERLAY --- */
    .mobile-nav {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(7, 13, 23, 0.97);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        z-index: 9997;
        overflow-y: auto;
        overflow-x: hidden;
        max-height: none;
        padding-top: 80px;
    }

    .mobile-nav.active {
        display: flex;
        flex-direction: column;
        max-height: 100vh;
    }

    .mobile-nav .nav-links {
        display: flex;
        flex-direction: column;
        list-style: none;
        padding: 1.5rem 2rem 2rem;
        gap: 0;
        width: 100%;
    }

    .mobile-nav .nav-links li {
        width: 100%;
        border-bottom: 1px solid var(--border);
    }

    .mobile-nav .nav-links li:last-child {
        border-bottom: none;
        padding-top: 1.5rem;
    }

    .mobile-nav .nav-links a {
        display: flex;
        align-items: center;
        min-height: 56px;
        font-size: 1.1rem;
        font-weight: 600;
        color: var(--text-secondary);
        padding: 0 0.25rem;
        width: 100%;
        transition: color 0.2s ease;
    }

    .mobile-nav .nav-links a:hover,
    .mobile-nav .nav-links a.active {
        color: var(--accent-cyan);
    }

    .mobile-nav .nav-links .btn-primary {
        min-height: 44px;
        width: 100%;
        justify-content: center;
        font-size: 1rem;
    }

    /* --- FOOTER: 2-col on tablet --- */
    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 2.5rem;
    }

    /* --- SOCIAL ICONS: ensure 44px tap targets --- */
    .social-icons a {
        min-width: 44px;
        min-height: 44px;
        width: 44px;
        height: 44px;
    }

    /* --- SECTION padding reduction --- */
    .section {
        padding: 4rem 1.5rem;
    }
}

@media (max-width: 768px) {

    /* --- FOOTER: single column --- */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer {
        padding: 3rem 1.5rem 2rem;
    }

    .footer-brand .tagline {
        font-size: 0.95rem;
    }

    .footer-column h4 {
        font-size: 1rem;
        margin-bottom: 1rem;
    }

    .footer-column li {
        margin-bottom: 0.6rem;
    }

    .footer-column a {
        display: inline-block;
        min-height: 36px;
        line-height: 36px;
        font-size: 0.95rem;
    }

    .footer-bottom {
        font-size: 0.82rem;
        padding-top: 1.5rem;
        line-height: 1.8;
    }

    /* --- PAGE HERO --- */
    .page-hero {
        padding: 8rem 1.5rem 3rem;
    }

    .page-hero p {
        font-size: 1rem;
    }

    /* --- NAVBAR height/padding --- */
    .navbar {
        padding: 1rem 0;
    }

    .navbar .container {
        padding: 0 1.25rem;
    }

    /* --- CTA BUTTONS --- */
    .cta-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .cta-buttons .btn-primary,
    .cta-buttons .btn-outline,
    .cta-buttons .btn-red {
        min-height: 48px;
        width: 100%;
        max-width: 320px;
        justify-content: center;
    }

    /* --- SECTION --- */
    .section {
        padding: 3.5rem 1.25rem;
    }
}

@media (max-width: 480px) {

    /* --- PAGE HERO --- */
    .page-hero h1 {
        font-size: 2rem;
    }

    .page-hero {
        padding: 7rem 1rem 2.5rem;
    }

    /* --- NAVBAR --- */
    .navbar .container {
        padding: 0 1rem;
    }

    .navbar .logo {
        font-size: 1.4rem;
    }

    .navbar .logo .logo-icon {
        width: 30px;
        height: 30px;
        font-size: 1rem;
    }

    /* --- MOBILE NAV LINKS font size --- */
    .mobile-nav .nav-links a {
        font-size: 1rem;
        min-height: 52px;
    }

    /* --- FOOTER --- */
    .footer {
        padding: 2.5rem 1rem 1.5rem;
    }

    .footer-brand .logo {
        font-size: 1.4rem;
    }

    .footer-bottom {
        font-size: 0.78rem;
        line-height: 2;
    }

    /* --- SOCIAL ICONS --- */
    .social-icons {
        gap: 0.75rem;
    }

    .social-icons a {
        min-width: 44px;
        min-height: 44px;
        width: 44px;
        height: 44px;
    }

    /* --- BUTTONS --- */
    .btn-primary,
    .btn-outline,
    .btn-red {
        min-height: 44px;
    }

    /* --- SECTION --- */
    .section {
        padding: 3rem 1rem;
    }

    /* XBRO-02: Overflow sweep at 480px */
    html,
    body {
        overflow-x: hidden;
        max-width: 100vw;
    }

    img,
    video,
    iframe,
    embed,
    object {
        max-width: 100%;
        height: auto;
    }

    .section {
        overflow-x: hidden;
    }
}