/* =============================================
   InfinitySpace42 - Layout Styles
   Navigation, Grid, Footer, Structure
   ============================================= */

/* =============================================
   Navigation Styles
   ============================================= */

/* Essential navigation styles */
.nav-link.active {
    color: var(--page-accent, var(--primary-cyan)) !important;
    text-shadow: 0 0 10px rgba(var(--page-accent-rgb, 0, 255, 255), 0.5);
}

/* Header Dropdown Styles */
.nav-item-dropdown {
    position: relative;
}

.nav-item-dropdown .nav-parent {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    position: relative;
}

.nav-item-dropdown .nav-parent .nav-link {
    flex: 1 1 auto;
    padding-right: 0;
    text-align: center;
}

.dropdown-toggle {
    border: none;
    background: transparent;
    color: var(--page-accent, var(--primary-cyan));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border-radius: 999px;
    cursor: pointer;
    transition: color 0.3s ease, transform 0.3s ease, background 0.3s ease;
    margin-left: 0;
    flex-shrink: 0;
    font-size: 0.9rem;
    line-height: 1;
    position: static;
    width: 1.9rem;
    height: 1.9rem;
    min-width: 1.9rem;
    min-height: 1.9rem;
}

.dropdown-toggle:hover,
.dropdown-toggle:focus-visible {
    background: rgba(var(--page-accent-rgb, 0, 255, 255), 0.12);
    color: var(--banner-text-color, #ffffff);
}

.dropdown-toggle:focus-visible {
    outline: 3px solid rgba(var(--page-accent-rgb, 0, 255, 255), 0.4);
    outline-offset: 3px;
}

.dropdown-toggle-icon {
    font-size: 1rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    transition: transform 0.3s ease;
    transform: translateY(2px);
}

.nav-item-dropdown.dropdown-open .dropdown-toggle,
.nav-item-dropdown.mobile-open .dropdown-toggle {
    background: rgba(var(--page-accent-rgb, 0, 255, 255), 0.18);
    color: var(--banner-text-color, #ffffff);
}

.nav-item-dropdown.dropdown-open .nav-link,
.nav-item-dropdown.mobile-open .nav-link {
    color: var(--page-accent, var(--primary-cyan));
}

.nav-item-dropdown.dropdown-open .dropdown-toggle-icon,
.nav-item-dropdown.mobile-open .dropdown-toggle-icon {
    transform: rotate(-180deg) translateY(2px);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--darker-bg);
    border: 1px solid rgba(var(--page-accent-rgb, 0, 255, 255), 0.25);
    border-radius: 8px;
    padding: 0.5rem 0;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    z-index: 1000;
    pointer-events: none;
}

.nav-item-dropdown:hover .dropdown-menu,
.nav-item-dropdown.dropdown-open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    text-decoration: none;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    border-bottom: 1px solid rgba(var(--page-accent-rgb, 0, 255, 255), 0.12);
    width: 100%;
    box-sizing: border-box;
}

.dropdown-link .dropdown-icon {
    font-size: 1.1rem;
    line-height: 1;
    flex-shrink: 0;
}

.dropdown-link .dropdown-label {
    flex: 1;
    line-height: 1.4;
}

.dropdown-link:last-child {
    border-bottom: none;
}

.dropdown-link:hover {
    background: rgba(var(--page-accent-rgb, 0, 255, 255), 0.12);
    color: var(--page-accent, var(--primary-cyan));
}

.modern-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, rgba(var(--banner-color-rgb, 10, 10, 30), 0.92) 0%, rgba(var(--banner-color-rgb, 10, 10, 30), 0.88) 100%);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(var(--page-accent-rgb, 0, 255, 255), 0.35);
    z-index: 9999;
    will-change: transform, background;
    transition: background-color 0.3s ease, backdrop-filter 0.3s ease;
    padding: 0;
    width: 100%;
    height: auto;
    transform: translateY(0) !important;
}

.modern-navbar.scrolled,
.modern-navbar:hover {
    transform: translateY(0);
    background: linear-gradient(135deg, rgba(var(--banner-color-rgb, 10, 10, 30), 0.96) 0%, rgba(var(--banner-color-rgb, 10, 10, 30), 0.92) 100%);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    height: 70px;
    gap: 0.6rem;
}

.nav-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.nav-item-logo {
    margin-right: 0;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo {
    position: relative;
    display: flex;
    align-items: center;
}

.logo-img {
    height: 43px;
    width: 43px;
    border-radius: 4px;
    object-fit: cover;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.preloader-square-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 10;
}

.preloader-square-ring.active {
    opacity: 1;
}

.preloader-square-spinner {
    width: 100%;
    height: 100%;
    border: 3px solid rgba(0, 255, 255, 0.3);
    border-top: 3px solid #00ffff;
    border-radius: 8px;
    animation: preloader-square-spin 1.5s linear infinite;
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

body.is-spa-loading {
    cursor: progress;
}

.spa-loader-fallback {
    position: fixed;
    top: 16px;
    right: 16px;
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: rgba(10, 15, 30, 0.85);
    backdrop-filter: blur(6px);
    box-shadow: 0 10px 30px rgba(var(--surface-dark-rgb), 0.35);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 11000;
}

.spa-loader-fallback.active {
    display: flex;
}

.spa-loader-fallback__ring {
    width: 42px;
    height: 42px;
    position: relative;
}

.spa-loader-fallback__ring .preloader-square-spinner {
    width: 100%;
    height: 100%;
    border-radius: 10px;
}

@keyframes preloader-square-spin {
    0% { 
        border-top-color: #00ffff; 
        border-right-color: rgba(0, 255, 255, 0.2); 
        border-bottom-color: rgba(0, 255, 255, 0.2); 
        border-left-color: rgba(0, 255, 255, 0.2); 
    }
    25% { 
        border-top-color: rgba(0, 255, 255, 0.2); 
        border-right-color: #00ffff; 
        border-bottom-color: rgba(0, 255, 255, 0.2); 
        border-left-color: rgba(0, 255, 255, 0.2); 
    }
    50% { 
        border-top-color: rgba(0, 255, 255, 0.2); 
        border-right-color: rgba(0, 255, 255, 0.2); 
        border-bottom-color: #00ffff; 
        border-left-color: rgba(0, 255, 255, 0.2); 
    }
    75% { 
        border-top-color: rgba(0, 255, 255, 0.2); 
        border-right-color: rgba(0, 255, 255, 0.2); 
        border-bottom-color: rgba(0, 255, 255, 0.2); 
        border-left-color: #00ffff; 
    }
    100% { 
        border-top-color: #00ffff; 
        border-right-color: rgba(0, 255, 255, 0.2); 
        border-bottom-color: rgba(0, 255, 255, 0.2); 
        border-left-color: rgba(0, 255, 255, 0.2); 
    }
}

.logo-image:hover {
    transform: scale(1.05);
}

.logo-text {
    color: var(--text-primary);
}

.logo-number {
    color: var(--primary-cyan);
    text-shadow: 0 0 10px var(--primary-cyan);
}

.nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.9rem;
    flex: 1;
    justify-content: flex-end;
}

.nav-menu > li {
    position: relative;
    display: flex;
    align-items: stretch;
    justify-content: center;
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: rgba(var(--banner-color-rgb, 10, 10, 30), 0.95);
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch !important;
        padding: 40px 24px 24px;
        transition: left 0.3s ease;
        gap: 12px;
    }

    .nav-menu.active {
        left: 0;
    }
}

.nav-link {
    color: var(--banner-text-color, var(--text-secondary));
    text-decoration: none;
    font-weight: 500;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    position: relative;
    padding: 0.4rem 0.75rem;
    border-radius: 8px;
    border: 1px solid transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
    text-align: center;
    min-width: 72px;
}

@media (min-width: 769px) {
    .nav-link {
        padding-bottom: 1.4rem;
    }

    .nav-item-dropdown .nav-parent {
        height: 100%;
        justify-content: flex-start;
    }

    .nav-item-dropdown .dropdown-toggle {
        position: absolute;
        left: 50%;
        bottom: 0.35rem;
        transform: translateX(-50%);
    }
}

.nav-icon {
    font-size: 1.2rem;
    line-height: 1;
    display: block;
}

.nav-label {
    font-size: 0.85rem;
    line-height: 1.1;
    letter-spacing: 0.02em;
}

@media (max-width: 768px) {
    .nav-link {
        width: 100%;
        align-items: flex-start;
        text-align: left;
        padding: 0.8rem 1rem;
    }

    .nav-label {
        font-size: 1rem;
    }
}

.nav-link:hover {
    color: var(--page-accent, var(--primary-cyan));
    text-shadow: 0 0 5px rgba(var(--page-accent-rgb, 0, 255, 255), 0.8);
    background: rgba(var(--page-accent-rgb, 0, 255, 255), 0.12);
    border-color: rgba(var(--page-accent-rgb, 0, 255, 255), 0.35);
}


/* =============================================
   Grid Layouts
   ============================================= */

/* Essential grid layouts */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    align-items: start;
}

.section-soft-overlay {
    position: relative;
    isolation: isolate;
}

.section-soft-overlay::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: min(1180px, calc(100% - 2.5rem));
    height: 100%;
    background: linear-gradient(160deg, rgba(32, 34, 40, 0.28), rgba(22, 24, 30, 0.2));
    border-radius: 32px;
    z-index: 0;
    pointer-events: none;
}

.section-soft-overlay > * {
    position: relative;
    z-index: 1;
}

@media (max-width: 640px) {
    .section-soft-overlay::before {
        width: calc(100% - 1.5rem);
        border-radius: 24px;
    }
}

.feature-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    will-change: transform, box-shadow;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    position: relative;
    overflow: hidden;
    min-height: 200px;
    backdrop-filter: blur(10px);
    cursor: pointer;
}

.external-link-indicator {
    position: absolute;
    top: 18px;
    right: 18px;
    font-size: 1.5rem;
    color: var(--primary-cyan);
    opacity: 0.75;
    transition: transform 0.3s ease, opacity 0.3s ease;
    pointer-events: none;
}

.clickable-card:hover .external-link-indicator,
.clickable-card:focus-within .external-link-indicator {
    transform: translate(3px, -3px);
    opacity: 1;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.feature-card .role-status {
    position: absolute;
    top: 20px;
    left: 20px;
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    z-index: 11;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(12px);
}

.feature-card .role-status.status-active {
    color: #16a34a;
    background: rgba(34, 197, 94, 0.15);
    border-color: rgba(34, 197, 94, 0.45);
}

.feature-card .role-status.status-future {
    color: #dc2626;
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.45);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--page-accent-secondary, var(--primary-purple)), var(--page-accent, var(--primary-cyan)));
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.4s ease;
    z-index: 10;
    border-radius: 15px 15px 0 0;
}

.feature-card:hover::before,
.feature-card.is-proximity-hover::before {
    transform: scaleX(1);
}

.feature-card:hover,
.feature-card.is-proximity-hover {
    transform: translateY(-10px);
    border-color: var(--page-accent-secondary, var(--primary-purple));
    box-shadow: 0 20px 40px rgba(var(--page-accent-secondary-rgb, 139, 92, 246), 0.2);
}

/* Override transform for wide product cards */
.wide-product-card.feature-card:hover,
.wide-product-card.feature-card.is-proximity-hover {
    transform: none;
    border-color: var(--primary-cyan);
    box-shadow: 0 20px 40px rgba(0, 255, 255, 0.2);
}

.feature-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
    color: var(--page-accent, var(--primary-cyan));
}

.feature-card h3 {
    color: var(--page-accent-secondary, var(--primary-purple));
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 10px;
    position: relative;
    z-index: 2;
}

.feature-card h3 a {
    color: var(--page-accent-secondary, var(--primary-purple));
    text-decoration: none;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.feature-card h3 a:hover {
    text-shadow: 0 0 10px var(--page-accent-secondary, var(--primary-purple));
}

.feature-subtitle {
    color: var(--page-accent, var(--text-accent));
    font-weight: 500;
    margin-bottom: 20px;
    font-family: var(--font-heading);
    position: relative;
    z-index: 2;
}

.feature-card-hint {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--page-accent, var(--primary-cyan));
    margin-bottom: 0.75rem;
    text-transform: none;
    letter-spacing: 0.01em;
}

.feature-card ul {
    list-style: none;
    text-align: left;
}

.feature-card li {
    color: var(--text-secondary);
    margin-bottom: 10px;
    padding-left: 20px;
    position: relative;
}

.feature-card ul {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease;
    opacity: 0;
    margin-top: 1rem;
    list-style: none;
    text-align: left;
    padding: 0;
}

.feature-card:hover ul,
.feature-card:focus-within ul,
.feature-card.is-proximity-hover ul {
    max-height: 500px;
    opacity: 1;
}

.feature-card ul li {
    color: var(--text-secondary);
    margin-bottom: 8px;
    padding-left: 15px;
    position: relative;
}

.feature-card ul li::before {
    content: '•';
    color: var(--page-accent-secondary, var(--primary-purple));
    font-weight: bold;
    position: absolute;
    left: 0;
}

.whatsapp-link-list {
    list-style: none;
    margin: 0;
    padding-left: 0;
}

.whatsapp-link-list li {
    padding-left: 0;
}

.whatsapp-link-list li::before {
    content: none;
}

.whatsapp-link-list .link-arrow {
    font-size: 0.85em;
    line-height: 1;
    transition: transform 0.2s ease;
}

.whatsapp-link-list a:hover .link-arrow,
.whatsapp-link-list a:focus .link-arrow {
    transform: translateY(-1px);
}

.feature-note {
    color: var(--text-secondary);
}

.vr-form-embed {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 0;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    pointer-events: none;
    transition: max-height 0.35s ease, opacity 0.3s ease, margin-top 0.3s ease;
}

.vr-form-embed iframe {
    width: 100%;
    min-height: 520px;
    border: none;
    border-radius: 12px;
    background-color: var(--card-bg);
}

.feature-card:hover .vr-form-embed,
.feature-card:focus-within .vr-form-embed,
.feature-card.is-proximity-hover .vr-form-embed {
    margin-top: 1rem;
    max-height: 1000px;
    opacity: 1;
    pointer-events: auto;
}

.feature-card ul li a {
    color: inherit;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    transition: color 0.2s ease, text-shadow 0.2s ease;
}

.feature-card ul li a:hover,
.feature-card ul li a:focus {
    color: var(--page-accent, var(--primary-cyan));
    text-shadow: 0 0 8px rgba(var(--page-accent-rgb, 0, 255, 255), 0.4);
}

.feature-card .audio-links,
.feature-card .expandable-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding-top: 0;
    margin-top: 0;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transform: translateY(12px);
    pointer-events: none;
    transition: max-height 0.35s ease, opacity 0.3s ease, transform 0.3s ease, padding-top 0.3s ease;
}

.feature-card .audio-links .cta-button,
.feature-card .expandable-content .cta-button {
    width: 100%;
}

.feature-card:hover .audio-links,
.feature-card:focus-within .audio-links,
.feature-card.is-proximity-hover .audio-links,
.feature-card:hover .expandable-content,
.feature-card:focus-within .expandable-content,
.feature-card.is-proximity-hover .expandable-content {
    max-height: 400px;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    padding-top: 1.2rem;
}

.package-cta-wrapper {
    padding-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    position: relative;
    z-index: 2;
}

@media (hover: none) {
    body.card-animations-disabled .feature-card ul {
        max-height: none;
        opacity: 1;
    }

    body.card-animations-disabled .feature-card .audio-links,
    body.card-animations-disabled .feature-card .expandable-content {
        max-height: none;
        opacity: 1;
        transform: none;
        pointer-events: auto;
        padding-top: 1.2rem;
    }
}

.area-card ul {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease;
    opacity: 0;
    margin-top: 1rem;
    list-style: none;
    text-align: left;
}

.area-card:hover ul {
    max-height: 200px;
    opacity: 1;
}

.area-card ul li {
    color: var(--text-secondary);
    margin-bottom: 8px;
    padding-left: 15px;
    position: relative;
}

.area-card ul li::before {
    content: '•';
    color: var(--primary-purple);
    font-weight: bold;
    position: absolute;
    left: 0;
}


/* =============================================
   Global & Footer Styles
   ============================================= */

/* Global Styles */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Footer Styles */
.footer {
    background: var(--bg-secondary);
    padding: 60px 0 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Social Icons Grid Layout */
.social-icons-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

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

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    text-decoration: none;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.social-icon svg {
    width: 20px;
    height: 20px;
}

.social-icon:hover {
    background: var(--primary-cyan);
    border-color: var(--primary-cyan);
    color: var(--bg-primary);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 255, 255, 0.3);
}

.social-icon.placeholder {
    opacity: 0.5;
    cursor: not-allowed;
}

.social-icon.placeholder:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
    transform: none;
    box-shadow: none;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
    align-items: start;
    margin-bottom: 2rem;
}

