@import url('https://fonts.googleapis.com/css2?family=Public+Sans:wght@300;400;500;600;700;800;900&family=Noto+Sans:wght@300;400;500;600;700&family=Share+Tech+Mono&family=Black+Ops+One&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200');

body {
    font-family: "Public Sans", "Noto Sans", sans-serif;
    --h-height: 70px;
}


.sector-number {
    font-family: 'Black Ops One', cursive;
    font-weight: 400;
    color: rgba(30, 58, 138, 0.08);
    line-height: 1;
    pointer-events: none;
    user-select: none;
    letter-spacing: -0.02em;
    z-index: 0;
    font-size: 9rem;
}

@media (min-width: 768px) {
    .sector-number {
        font-size: 18rem;
    }
}

.dark .sector-number {
    color: rgba(255, 255, 255, 0.05);
}


@media (max-width: 767px) {
    body {
        --h-height: 110px;
    }
}

/* Smooth Theme Transition & View Transitions API Support */
:root {
    view-transition-name: root;
}

::view-transition-old(root),
::view-transition-new(root) {
    animation-duration: 0.5s;
    animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Fallback transitions when View Transitions API is not available */
.theme-transitioning,
.theme-transitioning *,
.theme-transitioning *:before,
.theme-transitioning *:after {
    transition: background-color 0.5s cubic-bezier(0.4, 0, 0.2, 1),
        color 0.5s cubic-bezier(0.4, 0, 0.2, 1),
        border-color 0.5s cubic-bezier(0.4, 0, 0.2, 1),
        box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Hide Default Scrollbar */
html,
body {
    scrollbar-width: none;
    /* Firefox */
    scroll-padding-top: var(--h-height);
    overflow-x: hidden;
    max-width: 100%;
}

::-webkit-scrollbar {
    display: none;
    /* Chrome, Safari, Edge */
}

/* Horizontal Scroll Progress Bar */
.scroll-progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: transparent;
    z-index: 9999;
    pointer-events: none;
}

.scroll-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #3b82f6, #0032A0, #3b82f6);
    background-size: 200% 100%;
    animation: dynamicFusion 3s linear infinite;
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.8);
    transition: width 0.1s ease-out;
}

.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Utilities */
.text-gradient {
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-image: linear-gradient(to right, #0032A0, #3b82f6);
}

.shadow-glow {
    box-shadow: 0 0 15px rgba(0, 50, 160, 0.5);
}

.shadow-glow-lg {
    box-shadow: 0 0 30px rgba(0, 50, 160, 0.6);
}

.animate-fade-in-up {
    /* Desactivado para que aparezca inmediato por pedido del usuario */
    opacity: 1 !important;
    transform: none !important;
}

@keyframes fadeInUp {
    from {
        opacity: 1;
        transform: none;
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

.material-symbols-outlined.fill {
    font-variation-settings: 'FILL' 1;
}

@keyframes breathing {
    0%, 100% {
        opacity: 0.4;
        transform: scaleX(0.95);
    }
    50% {
        opacity: 1;
        transform: scaleX(1);
    }
}

.animate-breathing {
    animation: breathing 3s ease-in-out infinite;
}

@keyframes dynamicFusion {
    0% {
        background-position: 0% 0%;
    }

    50% {
        background-position: 100% 100%;
    }

    100% {
        background-position: 0% 0%;
    }
}

/* Scroll Reveal Global Styles - Neutralizado para carga inmediata */
.reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
}

.reveal.active {
    opacity: 1 !important;
    transform: none !important;
}

.footer-fusion-tanks {
    background: linear-gradient(135deg, #0032a0 0%, #05080f 50%, #ffffff 100%);
    background-size: 200% 200%;
    animation: dynamicFusion 12s ease-in-out infinite;
    position: relative;
}

.footer-fusion-tanks::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(5, 8, 15, 0.9);
    z-index: 0;
}

.footer-fusion-tanks>div {
    position: relative;
    z-index: 10;
}

.footer-fusion-border-tanks {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #0032a0 0%, #05080f 50%, #ffffff 100%);
    background-size: 200% 100%;
    animation: dynamicFusion 12s ease-in-out infinite;
    z-index: 50;
}

.header-fusion-border-tanks {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #0032a0 0%, #05080f 50%, #ffffff 100%);
    background-size: 200% 100%;
    animation: dynamicFusion 12s ease-in-out infinite;
    z-index: 50;
}

.footer-fusion-casa {
    background: linear-gradient(135deg, #ffffff 0%, #fdfbf7 50%, #c5a065 100%);
    background-size: 200% 200%;
    animation: dynamicFusion 10s ease infinite;
    position: relative;
}

.footer-fusion-casa::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.60);
    z-index: 0;
}

.footer-fusion-casa>div {
    position: relative;
    z-index: 10;
}

.footer-fusion-border-casa {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, #c5a065 30%, #fdfcf0 50%, #c5a065 70%, transparent 100%);
    background-size: 200% 100%;
    animation: dynamicFusion 8s ease-in-out infinite;
    z-index: 50;
}

.breathing-pearl-gold {
    background: linear-gradient(90deg, transparent 0%, #c5a065 30%, #fdfcf0 50%, #c5a065 70%, transparent 100%);
    background-size: 200% 100%;
    animation: dynamicFusion 8s ease-in-out infinite;
}

.topbar-main.footer-fusion-casa .util-btn:hover {
    color: #c5a065 !important;
}

.topbar-main.footer-fusion-casa .topbar-brand:hover span {
    filter: brightness(1.2);
}

.topbar-global {
    width: 100%;
    background-color: rgba(10, 15, 24, 0.85);
    backdrop-filter: blur(12px);
    color: white;
    padding-top: 0;
    padding-bottom: 0.25rem;
    z-index: 100;
    position: sticky;
    top: 0;
    left: 0;
    right: 0;
}

.topbar-container {
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.topbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: opacity 0.2s;
}

.topbar-brand:hover {
    opacity: 0.8;
}

.topbar-logo {
    height: 2rem;
    width: auto;
    filter: invert(1) brightness(2);
}

.topbar-titles {
    display: flex;
    flex-direction: column;
    line-height: 1;
    text-align: left;
}

.topbar-subtitle {
    font-family: serif;
    font-style: italic;
    font-size: 10px;
    color: #94a3b8;
    line-height: 1.25;
}

.topbar-title {
    font-weight: 700;
    font-size: 0.875rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: white;
}

.topbar-utils {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.util-btn {
    color: #94a3b8;
    transition: color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    /* Needed for tooltip positioning */
}

.util-btn:hover {
    color: white;
}

/* ── Modal Utility Buttons Overrides ────────────────────── */
#modal-3d .util-btn:hover {
    color: #0032A0 !important;
}

.dark #modal-3d .util-btn:hover {
    color: #60a5fa !important;
}

#modal-3d .hover\:text-red-500:hover {
    color: #ef4444 !important;
}

.util-btn.active-utility {
    color: #3b82f6 !important;
    filter: drop-shadow(0 0 5px rgba(59, 130, 246, 0.5));
}

.dark .util-btn.active-utility {
    color: #60a5fa !important;
    filter: drop-shadow(0 0 8px rgba(96, 165, 250, 0.6));
}

/* ── Tooltip System ─────────────────────────────────────── */
/* Arrow pointer */
.util-btn[data-tooltip]::before {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    border: 5px solid transparent;
    border-bottom-color: rgba(15, 23, 42, 0.95);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    transition-delay: 0s;
    z-index: 9999;
}

/* Text box */
.util-btn[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: -42px;
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    background: rgba(15, 23, 42, 0.98);
    color: #e2e8f0;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.05em;
    white-space: nowrap;
    padding: 5px 10px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    transition-delay: 0s;
    z-index: 9999;
}

/* On hover: show with delay */
.util-btn[data-tooltip]:hover::before,
.util-btn[data-tooltip]:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    transition-delay: 0.6s;
}

/* ── Social Button Tooltip (points UP) ──────────────────── */
/* ── Premium Social Button Tooltips (Dynamic Hover) ────────────────── */
.social-wrapper-premium {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
}

.social-icon {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    /* Prevent becoming oval on small screens */
    background: rgba(255, 255, 255, 0.05);
    /* Dark theme base */
    border-radius: 50%;
    color: #94a3b8;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.social-icon:hover {
    color: #fff;
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
}

/* Tooltip standard implementation */
.social-icon .tooltip {
    position: absolute;
    top: -45px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background: #fff;
    color: #1e293b;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    white-space: nowrap;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
    z-index: 100;
}

.social-icon .tooltip::after {
    content: "";
    height: 8px;
    width: 8px;
    background: #fff;
    bottom: -4px;
    left: 50%;
    transform: translate(-50%) rotate(45deg);
    transition: all 0.35s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.social-icon:hover {
    transform: translateY(-5px);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.social-icon:hover .tooltip {
    top: -55px;
    opacity: 1;
    transform: translateX(-50%) translateY(0) scale(1);
    pointer-events: auto;
}







.social-icon:hover .tooltip {
    text-shadow: 0px -1px 0px rgba(0, 0, 0, 0.1);
}

.util-divider {
    width: 1px;
    height: 1rem;
    background-color: rgba(148, 163, 184, 0.4);
    margin: 0 0.25rem;
}

/* ── Mobile: compact header buttons ─────────────────────── */
@media (max-width: 767px) {
    .topbar-utils {
        gap: 0.35rem !important;
    }

    .util-divider {
        margin: 0;
    }
}

/* Language Responsive Display */
.lang-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
}

.lang-full {
    display: none;
    /* Hidden on mobile */
}

@media (min-width: 1024px) {
    .lang-full {
        display: inline;
        /* Visible on desktop */
    }
}

@media (min-width: 768px) {
    .util-divider {
        display: block;
    }
}

.topbar-cta {
    border: 1px solid #0032A0;
    color: #0032A0;
    padding: 0.375rem 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.2s;
    border-radius: 0.25rem;
    margin-left: 0.5rem;
    display: none;
}

@media (min-width: 768px) {
    .topbar-cta {
        display: block;
    }
}

.topbar-cta:hover {
    background-color: #0032A0;
    color: white;
}

/* Sidebar Menu Styles */
.menu-parent {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    color: #d1d5db;
    font-weight: 700;
    font-size: 1rem;
    text-transform: capitalize;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: color 0.2s;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    padding-right: 3rem;
}

.menu-parent:hover {
    color: #60a5fa;
}

.menu-parent .chevron {
    font-size: 1.25rem;
    transition: transform 0.3s;
}

.menu-parent.active .chevron {
    transform: rotate(180deg);
}

.menu-child {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #9ca3af;
    transition: all 0.2s;
    padding-left: 2rem;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 0.375rem;
    padding-bottom: 0.375rem;
    margin-left: 0.25rem;
}

.menu-child:hover {
    color: #60a5fa;
    border-left-color: #60a5fa;
}

/* High contrast hover for Tank Sidebar (Blue Theme) */
#left-sidebar.bg-military-dark a:hover,
#left-sidebar.bg-military-dark a:hover span,
#left-sidebar.bg-military-dark .menu-parent:hover,
#left-sidebar.bg-military-dark .menu-child:hover {
    color: #60a5fa !important;
}


.menu-content {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s;
    overflow: hidden;
}

.menu-content.open {
    grid-template-rows: 1fr;
}

.menu-inner {
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.menu-parent-right {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    color: #334155;
    font-family: serif;
    font-weight: 700;
    font-size: 1.125rem;
    text-transform: capitalize;
    letter-spacing: 0.025em;
    cursor: pointer;
    transition: color 0.2s;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.menu-parent-right:hover {
    color: #c5a065;
}

.menu-parent-right .chevron-right {
    font-size: 1.25rem;
    transition: transform 0.3s;
}

.menu-parent-right.active .chevron-right {
    transform: rotate(180deg);
}

.menu-child-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    color: #64748b;
    transition: all 0.2s;
    border-right: 2px solid #e2e8f0;
    padding-top: 0.375rem;
    padding-bottom: 0.375rem;
    padding-right: 0.75rem;
    width: 100%;
}

.menu-child-right:hover {
    color: #c5a065;
    border-right-color: #c5a065;
}

.menu-divider,
.menu-divider-right {
    display: none;
    height: 1px;
    background-color: rgba(209, 213, 219, 0.55);
    margin: 2px 0;
}

.menu-sep,
.menu-sep-right {
    flex: 1;
    height: 1px;
    background-color: rgba(209, 213, 219, 0.5);
    align-self: center;
    margin: 0 4px;
}

.menu-sep-right {
    background-color: #475569;
    margin: 0 8px;
}


/* Theme Toggle Animation */
@keyframes sun-spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.theme-toggle .material-symbols-outlined {
    animation: sun-spin 10s linear infinite;
    display: inline-block;
    transform-origin: center;
}

/* Real Sound Waves Animation (Targeting SVG paths) */
@keyframes wave-outward {
    0% {
        opacity: 0;
        transform: scale(0.8) translateX(-1px);
    }

    50% {
        opacity: 1;
        transform: scale(1) translateX(0);
    }

    100% {
        opacity: 0;
        transform: scale(1.3) translateX(3px);
    }
}

.bg-music-toggle.playing .sound-wave {
    animation: wave-outward 2.0s infinite ease-out;
    transform-origin: 10px 12px;
    /* Set origin at speaker mouth */
}

.bg-music-toggle.playing .wave-delay-1 {
    animation-delay: 0s;
}

.bg-music-toggle.playing .wave-delay-2 {
    animation-delay: 0.1s;
}

.bg-music-toggle.playing .material-symbols-outlined {
    color: white;
}

/* Search Panning Animation (No zoom, no glow) */
@keyframes search-panning {
    0% {
        transform: translate(0, 0);
    }

    25% {
        transform: translate(3px, 3px);
    }

    50% {
        transform: translate(-3px, 0);
    }

    75% {
        transform: translate(0, -3px);
    }

    100% {
        transform: translate(0, 0);
    }
}

.search-toggle .material-symbols-outlined {
    animation: search-panning 5s ease-in-out infinite;
    display: inline-block;
}

/* Custom utilities for the split effect */
.clip-diagonal-left {
    clip-path: polygon(0 0, 100% 0, 85% 100%, 0% 100%);
}

.clip-diagonal-right {
    clip-path: polygon(15% 0, 100% 0, 100% 100%, 0% 100%);
}

@media (max-width: 768px) {

    .clip-diagonal-left,
    .clip-diagonal-right {
        clip-path: none;
    }
}

.text-shadow-strong {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.bg-grain {
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
}

/* Sidebar Animations */
#left-sidebar {
    transform: translateX(-100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

#left-sidebar.open {
    transform: translateX(0);
}

#right-sidebar {
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

#right-sidebar.open {
    transform: translateX(0);
}

.overlay {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* Left overlay: cool deep blue */
#left-overlay {
    background: rgba(0, 20, 60, 0.58) !important;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

/* Right overlay: warm amber gold */
#right-overlay {
    background: rgba(90, 50, 0, 0.52) !important;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

.azimuth-indicator {
    position: absolute;
    right: 0px;
    top: 0;
    bottom: 0px;
    width: 50px;
    height: 100%;
    pointer-events: none;
    z-index: 60;
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    font-family: 'Share Tech Mono', monospace;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to bottom, transparent, black 15%, black 85%, transparent);
    mask-image: linear-gradient(to bottom, transparent, black 15%, black 85%, transparent);
}

.azimuth-scale {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
    transition: none;
    margin-right: 5px;
    padding: 0;
}

.azimuth-tick {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(0, 243, 255, 0.4);
    opacity: 0.3;
    transition: opacity 0.3s ease;
}

.azimuth-tick.major {
    color: rgba(255, 255, 255, 0.7);
    font-weight: 300;
}

.azimuth-tick .line {
    width: 8px;
    height: 1px;
    background: currentColor;
}

.azimuth-tick.major .line {
    width: 12px;
    height: 0.5px;
}

.azimuth-tick .number {
    font-size: 8px;
    color: rgba(0, 243, 255, 0.6);
}

.azimuth-tick.major .number {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.9);
}

.azimuth-pointer {
    position: absolute;
    right: 0;
    top: 0;
    width: 0;
    height: 0;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-right: 12px solid #ff0000;
    filter: drop-shadow(0 0 10px rgba(255, 0, 0, 0.8));
    z-index: 100;
    pointer-events: none;
    opacity: 1;
    transition: none;
    animation: tacticalPulse 0.8s infinite ease-in-out;
}

@keyframes tacticalPulse {
    0% {
        opacity: 1;
        filter: drop-shadow(0 0 10px rgba(255, 0, 0, 0.9));
    }

    50% {
        opacity: 0.6;
        filter: drop-shadow(0 0 4px rgba(255, 0, 0, 0.4));
    }

    100% {
        opacity: 1;
        filter: drop-shadow(0 0 10px rgba(255, 0, 0, 0.9));
    }
}

.footer-fusion {
    background: linear-gradient(135deg, #0032a0 0%, #05080f 50%, #c5a065 100%);
    background-size: 200% 200%;
    animation: dynamicFusion 12s ease infinite;
    position: relative;
}

.footer-fusion::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(5, 8, 15, 0.85);
    z-index: 0;
}

.footer-fusion>div {
    position: relative;
    z-index: 10;
}

.header-fusion-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    /* Gradiente Tricolor Ecuador (50/25/25) */
    background: linear-gradient(90deg,
            #ffcc00 0%, #ffcc00 50%,
            #0033a0 50%, #0033a0 75%,
            #e31b23 75%, #e31b23 100%);
    background-size: 200% 100%;
    animation: dynamicFusion 20s ease-in-out infinite;
    z-index: 50;
    box-shadow: 0 0 15px rgba(255, 204, 0, 0.4);
}

.footer-fusion-border {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    /* Gradiente Tricolor Ecuador (50/25/25) */
    background: linear-gradient(90deg,
            #ffcc00 0%, #ffcc00 50%,
            #0033a0 50%, #0033a0 75%,
            #e31b23 75%, #e31b23 100%);
    background-size: 200% 100%;
    animation: dynamicFusion 20s ease-in-out infinite;
    z-index: 50;
    box-shadow: 0 0 15px rgba(255, 204, 0, 0.4);
}

@keyframes text-fusion-breathing {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}


.animate-text-fusion {
    display: inline-block;
    background-size: 250% auto;
    animation: text-fusion-breathing 12s ease-in-out infinite;
}

/* Leaderboard Section Styles */
.metallic-gradient {
    background: linear-gradient(135deg, #f0f1f5 0%, #ffffff 50%, #dadee7 100%);
}

.text-glow-gradient {
    background: linear-gradient(90deg, #00329e, #2563eb, #00329e);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: shine-glow 3s linear infinite;
}


@keyframes shine-glow {
    to {
        background-position: 200% center;
    }
}

.tech-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 50, 158, 0.1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.dark .tech-card {
    background: rgba(30, 41, 59, 0.7);
    border-color: rgba(255, 255, 255, 0.05);
}

/* ── Theme Switch Smooth Transitions ── */

/* View Transitions API (Chrome/Edge/Modern) */
::view-transition-old(root),
::view-transition-new(root) {
    animation-duration: 0.6s;
    animation-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Fallback for smooth class-based transition */
html.theme-transitioning,
html.theme-transitioning *,
html.theme-transitioning *::before,
html.theme-transitioning *::after {
    transition: background-color 0.6s ease-in-out,
        color 0.6s ease-in-out,
        border-color 0.6s ease-in-out,
        box-shadow 0.6s ease-in-out,
        backdrop-filter 0.6s ease-in-out,
        filter 0.6s ease-in-out,
        opacity 0.6s ease-in-out !important;
}

/* Pulse Dot Animation */
.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: #4caf50;
    border-radius: 50%;
    position: relative;
    box-shadow: 0 0 10px rgba(76, 175, 80, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
}


.pulse-dot::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 2px solid #4caf50;
    animation: pulseActive 2s infinite;
}

@keyframes pulseActive {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    100% {
        transform: scale(2.5);
        opacity: 0;
    }
}

/* Swap Button Animation */
@keyframes swap-spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(180deg);
    }
}

.animate-swap {
    display: inline-block;
}

.util-btn:hover .animate-swap {
    animation: swap-spin 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* --- TACTICAL MUSEUM EXTENSIONS --- */

.hero-shimmer {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0) 0%, rgba(59, 130, 246, 0.1) 50%, rgba(59, 130, 246, 0) 100%);
    background-size: 200% 100%;
    animation: shimmer 3s infinite linear;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.tactical-border {
    position: relative;
}

.tactical-border::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 20px;
    height: 20px;
    border-top: 2px solid #3b82f6;
    border-left: 2px solid #3b82f6;
}

.tactical-border::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 20px;
    height: 20px;
    border-bottom: 2px solid #3b82f6;
    border-right: 2px solid #3b82f6;
}

.card-glass {
    /* Refined Defined Shadow Style */
    background: #e0e6ee;
    border: 1.5px solid rgba(0, 0, 0, 0.02);
    border-radius: 1.875rem;
    /* 30px - Standardized aesthetic */
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 15px 30px -5px rgba(0, 32, 160, 0.12);
    position: relative;
    z-index: 1;
}

.dark .card-glass {
    background: #0f172a;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.6);
}

.card-glass:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 60px -10px rgba(0, 32, 160, 0.2);
    border-color: rgba(59, 130, 246, 0.3);
    z-index: 10;
}

.dark .card-glass:hover {
    background: #1e293b;
    box-shadow: 0 40px 80px -15px rgba(0, 0, 0, 0.8);
}

.section-divider {
    position: relative;
}

.section-divider::before {
    content: '';
    position: absolute;
    bottom: 0px;
    left: 10%;
    width: 80%;
    height: 4px;
    /* Increased from 3px */
    background: linear-gradient(90deg, transparent, #1d4ed8, transparent);
    /* Stronger blue */
    z-index: 50;
    border-radius: 4px;
    opacity: 0.8;
    /* Ensure visibility */
}

.dark .section-divider::before {
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.8), transparent);
    height: 3px;
    opacity: 1;
}

.tactical-tag {
    position: absolute;
    top: 4rem;
    left: 2rem;
    font-family: 'Share Tech Mono', monospace;
    font-size: 11px;
    color: #3b82f6;
    background: rgba(59, 130, 246, 0.05);
    padding: 4px 12px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-left: 4px solid #3b82f6;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 20;
    backdrop-filter: blur(4px);
    letter-spacing: 2px;
    font-weight: 900;
}

.tactical-tag::after {
    content: '';
    width: 6px;
    height: 6px;
    background: #3b82f6;
    border-radius: 50%;
    animation: global-pulse-dot 2s infinite;
}

@keyframes global-pulse-dot {
    0% {
        transform: scale(0.95);
        opacity: 0.8;
    }

    50% {
        transform: scale(1.1);
        opacity: 1;
        box-shadow: 0 0 10px #3b82f6;
    }

    100% {
        transform: scale(0.95);
        opacity: 0.8;
    }
}

/* ─── Grid Background Pattern ─────────────────── */
.grid-bg {
    --_bg: #f8fafc;
    --_grid-heavy: rgba(0, 0, 0, 0.08);
    --_grid-light: rgba(0, 0, 0, 0.05);
    background-image:
        linear-gradient(var(--_grid-heavy) 1.5px, transparent 1.5px),
        linear-gradient(90deg, var(--_grid-heavy) 1.5px, transparent 1.5px),
        linear-gradient(var(--_grid-light) 1px, transparent 1px),
        linear-gradient(90deg, var(--_grid-light) 1px, var(--_bg) 1px);
    background-position: -2px -2px, -2px -2px, -1px -1px, -1px -1px;
    background-size: 50px 50px, 50px 50px, 10px 10px, 10px 10px;
}

.dark .grid-bg {
    background-image: none;
}

.luxury-gradient {
    background: radial-gradient(circle at center, rgba(59, 130, 246, 0.08) 0%, transparent 70%);
}

#particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    opacity: 0.8;
    transition: opacity 0.5s ease;
    display: none;
}

.dark #particles-canvas {
    display: block !important;
}

.footer-layer {
    position: relative;
    z-index: 60;
    background-color: #020617;
}

.pulse-dot-inner {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    animation: global-pulse-dot 2s infinite;
}

/* ──────── Premium Animated Theme Switch (Robust Fix) ──────── */
.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.switch .theme-checkbox {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #2196f3;
    -webkit-transition: 0.4s;
    transition: 0.4s;
    z-index: 0;
    overflow: hidden;
}

.sun-moon {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: yellow;
    -webkit-transition: 0.4s;
    transition: 0.4s;
}

.theme-checkbox:checked+.slider {
    background-color: black;
}

.theme-checkbox:focus+.slider {
    box-shadow: 0 0 1px #2196f3;
}

.theme-checkbox:checked+.slider .sun-moon {
    -webkit-transform: translateX(26px);
    -ms-transform: translateX(26px);
    transform: translateX(26px);
    background-color: white;
    -webkit-animation: rotate-center 0.6s ease-in-out both;
    animation: rotate-center 0.6s ease-in-out both;
}

.moon-dot {
    opacity: 0;
    transition: 0.4s;
    fill: gray;
}

.theme-checkbox:checked+.slider .sun-moon .moon-dot {
    opacity: 1;
}

.slider.round {
    border-radius: 34px;
}

.slider.round .sun-moon {
    border-radius: 50%;
}

#moon-dot-1 {
    left: 10px;
    top: 3px;
    position: absolute;
    width: 6px;
    height: 6px;
    z-index: 4;
}

#moon-dot-2 {
    left: 2px;
    top: 10px;
    position: absolute;
    width: 10px;
    height: 10px;
    z-index: 4;
}

#moon-dot-3 {
    left: 16px;
    top: 18px;
    position: absolute;
    width: 3px;
    height: 3px;
    z-index: 4;
}

#light-ray-1 {
    left: -8px;
    top: -8px;
    position: absolute;
    width: 43px;
    height: 43px;
    z-index: -1;
    fill: white;
    opacity: 10%;
}

#light-ray-2 {
    left: -50%;
    top: -50%;
    position: absolute;
    width: 55px;
    height: 55px;
    z-index: -1;
    fill: white;
    opacity: 10%;
}

#light-ray-3 {
    left: -18px;
    top: -18px;
    position: absolute;
    width: 60px;
    height: 60px;
    z-index: -1;
    fill: white;
    opacity: 10%;
}

.cloud-light {
    position: absolute;
    fill: #eee;
    animation-name: cloud-move;
    animation-duration: 6s;
    animation-iteration-count: infinite;
}

.cloud-dark {
    position: absolute;
    fill: #ccc;
    animation-name: cloud-move;
    animation-duration: 6s;
    animation-iteration-count: infinite;
    animation-delay: 1s;
}

#cloud-1 {
    left: 30px;
    top: 15px;
    width: 40px;
}

#cloud-2 {
    left: 44px;
    top: 10px;
    width: 20px;
}

#cloud-3 {
    left: 18px;
    top: 24px;
    width: 30px;
}

#cloud-4 {
    left: 36px;
    top: 18px;
    width: 40px;
}

#cloud-5 {
    left: 48px;
    top: 14px;
    width: 20px;
}

#cloud-6 {
    left: 22px;
    top: 26px;
    width: 30px;
}

@keyframes cloud-move {
    0% {
        transform: translateX(0px);
    }

    40% {
        transform: translateX(4px);
    }

    80% {
        transform: translateX(-4px);
    }

    100% {
        transform: translateX(0px);
    }
}

.stars {
    transform: translateY(-32px);
    opacity: 0;
    transition: 0.4s;
}

.star {
    fill: white;
    position: absolute;
    -webkit-transition: 0.4s;
    transition: 0.4s;
    animation-name: star-twinkle;
    animation-duration: 2s;
    animation-iteration-count: infinite;
}

.theme-checkbox:checked+.slider .stars {
    -webkit-transform: translateY(0);
    -ms-transform: translateY(0);
    transform: translateY(0);
    opacity: 1;
}

#star-1 {
    width: 20px;
    top: 2px;
    left: 3px;
    animation-delay: 0.3s;
}

#star-2 {
    width: 6px;
    top: 16px;
    left: 3px;
}

#star-3 {
    width: 12px;
    top: 20px;
    left: 10px;
    animation-delay: 0.6s;
}

#star-4 {
    width: 16px;
    top: 10px;
    left: 8px;
    animation-delay: 1.3s;
}

@keyframes star-twinkle {
    0% {
        opacity: 0;
        transform: scale(1);
    }

    40% {
        opacity: 1;
        transform: scale(1.2);
    }

    80% {
        opacity: 1;
        transform: scale(0.8);
    }

    100% {
        opacity: 0;
        transform: scale(1);
    }
}


/* ──────── Premium Social Icons (TAPI V4 - Absolute Clip-Path Solution) ──────── */
.tapi-social-container {
    display: flex !important;
    flex-flow: row wrap !important;
    gap: 12px 10px !important;
    /* Horiz gap 12px, Vert gap 10px */
    padding: 15px 0 !important;
    list-style: none !important;
    margin: 0 !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    /* Removed max-width to allow single row if space is available */
}

.tapi-social-item {
    position: relative !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
}

.tapi-social-item:hover {
    transform: translateY(-8px) !important;
    z-index: 10 !important;
}

.tapi-social-link {
    position: relative !important;
    width: 44px !important;
    height: 44px !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    cursor: pointer !important;
    transition: all 0.4s ease !important;
    color: #fff !important;
    overflow: hidden !important;
    text-decoration: none !important;
    z-index: 5 !important;
    /* Bulletproof clipping for Webkit */
    -webkit-mask-image: -webkit-radial-gradient(white, black);
    mask-image: radial-gradient(white, black);
    isolation: isolate !important;
}

/* Background element using position to avoid transform-clipping bugs */
.tapi-social-filled {
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    border-radius: 50% !important;
    /* Critical to prevent native square rendering */
    transform: scaleY(0) !important;
    transform-origin: bottom center !important;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    z-index: 1 !important;
}

.tapi-social-item:hover .tapi-social-filled {
    transform: scaleY(1) !important;
}

.tapi-social-item:hover .tapi-social-link {
    border-color: rgba(255, 255, 255, 0.3) !important;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5) !important;
}

.tapi-social-link svg,
.tapi-social-link i {
    position: relative !important;
    z-index: 2 !important;
    font-size: 18px !important;
    width: 20px !important;
    height: 20px !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    transition: all 0.4s ease !important;
    fill: currentColor !important;
    color: currentColor !important;
}

.tapi-social-item:hover .tapi-social-link svg,
.tapi-social-item:hover .tapi-social-link i {
    transform: scale(1.2) !important;
}

/* Tooltip */
.tapi-social-tooltip {
    position: absolute !important;
    top: -45px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    color: #fff !important;
    padding: 6px 12px !important;
    border-radius: 6px !important;
    font-size: 10px !important;
    font-weight: 800 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transition: all 0.3s ease !important;
    white-space: nowrap !important;
    z-index: 20 !important;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5) !important;
}

.tapi-social-tooltip::after {
    content: "" !important;
    position: absolute !important;
    bottom: -4px !important;
    left: 50% !important;
    transform: translateX(-50%) rotate(45deg) !important;
    width: 8px !important;
    height: 8px !important;
    background: inherit !important;
}

.tapi-social-item:hover .tapi-social-tooltip {
    opacity: 1 !important;
    visibility: visible !important;
    /* Removed extra movement since parent translates up */
}

/* Colors with perfect fill handling */
.tapi-social-item.facebook .tapi-social-filled,
.tapi-social-item.facebook .tapi-social-tooltip {
    background: #1877F2 !important;
}

.tapi-social-item.instagram .tapi-social-filled,
.tapi-social-item.instagram .tapi-social-tooltip {
    background: linear-gradient(45deg, #405de6, #5b51db, #b33ab4, #c135b4, #e1306c, #fd1f1f) !important;
}

.tapi-social-item.x .tapi-social-filled,
.tapi-social-item.x .tapi-social-tooltip {
    background: #000000 !important;
}

.tapi-social-item.youtube .tapi-social-filled,
.tapi-social-item.youtube .tapi-social-tooltip {
    background: #FF0000 !important;
}

.tapi-social-item.tiktok .tapi-social-filled,
.tapi-social-item.tiktok .tapi-social-tooltip {
    background: #010101 !important;
}

.tapi-social-item.tiktok:hover .tapi-social-link {
    border-color: #ff0050 !important;
}

.tapi-social-item.flickr .tapi-social-filled,
.tapi-social-item.flickr .tapi-social-tooltip {
    background: linear-gradient(to right, #0063dc, #ff0084) !important;
}

.tapi-social-item.whatsapp .tapi-social-filled,
.tapi-social-item.whatsapp .tapi-social-tooltip {
    background: #25D366 !important;
}

.tapi-social-item.github .tapi-social-filled,
.tapi-social-item.github .tapi-social-tooltip {
    background: #333 !important;
}

/* Animated Hamburger Menu Premium */
.hamburger-premium {
    width: 26px;
    height: 18px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-start;
}

.hamburger-premium span {
    display: block;
    height: 3px;
    background-color: currentColor;
    border-radius: 10px;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.hamburger-premium span:nth-child(1) {
    width: 100%;
}

.hamburger-premium span:nth-child(2) {
    width: 60%;
}

.hamburger-premium span:nth-child(3) {
    width: 85%;
}

.group:hover .hamburger-premium span {
    width: 100% !important;
}

.group:active .hamburger-premium span {
    transform: scaleX(0.8);
}

.hamburger-premium.align-right {
    align-items: flex-end;
}

.tanques-title:hover {
    color: #335CC0 !important;
}

.group:hover .tanques-title {
    color: #335CC0 !important;
}

/* Hamburger Colors */
.hamburger-tanques span {
    background-color: #0032A0 !important;
}

.group:hover .hamburger-tanques span {
    background-color: white !important;
}

.hamburger-casa span {
    background-color: #c5a065 !important;
}

.group:hover .hamburger-casa span {
    background-color: white !important;
}

/* Video Section Premium Styles */
.video-hud-glass {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.play-button-ripple {
    position: relative;
}

.play-button-ripple::before {
    content: '';
    position: absolute;
    inset: -15px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    animation: ripple-pulse 2s infinite;
}

@keyframes ripple-pulse {
    0% {
        transform: scale(0.8);
        opacity: 0.5;
    }

    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

.video-glow-text {
    text-shadow: 0 0 30px rgba(59, 130, 246, 0.5);
}

.util-divider {
    width: 1px;
    height: 1rem;
    background-color: rgba(148, 163, 184, 0.4);
    margin: 0 0.25rem;
}

/* Línea Vertical Tricolor Premium */
.nav-divider-tricolor {
    width: 3px;
    height: 35px;
    margin: 0 15px;
    position: relative;
    border-radius: 4px;
    overflow: hidden;
    /* Gradiente con proporciones 50/25/25 */
    background: linear-gradient(to bottom,
            #ffcc00 0%, #ffcc00 50%,
            #0033a0 50%, #0033a0 75%,
            #e31b23 75%, #e31b23 100%);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    flex-shrink: 0;
}

/* Efecto de Brillo Animado (Shimmer) */
.nav-divider-tricolor::after {
    content: '';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom,
            transparent,
            rgba(255, 255, 255, 0.6),
            transparent);
    animation: tricolor-glow 3s infinite linear;
}

@keyframes tricolor-glow {
    0% {
        top: -100%;
    }

    100% {
        top: 100%;
    }
}

/* Ajuste para móviles */
@media (max-width: 600px) {
    .nav-divider-tricolor {
        height: 25px;
        margin: 0 8px;
    }
}

/* Tailwind Polyfill: Ensures hover:text-primary-bright has priority */
.hover\:text-primary-bright:hover {
    color: #60a5fa !important;
}

/* Espaciado responsivo para el contenido debajo del topbar */
.main-content-wrapper { padding-top: 64px; }
@media (min-width: 768px) { .main-content-wrapper { padding-top: 70px; } }

/* Global Text Shimmer Animation (Breathing text gradient colors) */
@keyframes text-shimmer {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.animate-text-shimmer {
  background-size: 200% auto;
  animation: text-shimmer 5s ease-in-out infinite;
}

