/* ==========================================================================
   CORPEX Components — Header, Footer, Cards, Buttons, Hero, CTA
   ========================================================================== */

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--sp-2);
    padding: 0.875rem 2rem;
    font-size: var(--fs-sm);
    font-weight: var(--fw-semibold);
    line-height: 1;
    border-radius: var(--radius-md);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--duration-normal) var(--ease-default);
    white-space: nowrap;
    text-decoration: none;
    min-height: 44px;
    min-width: 44px;
}

.btn:focus-visible {
    outline: 2px solid var(--cx-teal);
    outline-offset: 2px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--cx-teal) 0%, var(--cx-teal-dark) 100%);
    color: var(--cx-white);
    box-shadow: 0 4px 15px rgba(0, 165, 181, 0.2);
    position: relative;
    overflow: hidden;
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.3) 50%, rgba(255, 255, 255, 0) 100%);
    transform: skewX(-25deg);
    transition: left 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

.btn-primary:hover::after {
    left: 150%;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--cx-teal-light) 0%, var(--cx-teal) 100%);
    color: var(--cx-white);
    box-shadow: 0 8px 25px rgba(0, 165, 181, 0.3);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: var(--cx-teal);
    border-color: var(--cx-teal);
}

.btn-secondary:hover {
    background: var(--cx-teal);
    color: var(--cx-white);
}

.btn-white {
    background: var(--cx-white);
    color: var(--cx-navy);
    box-shadow: var(--shadow-md);
}

.btn-white:hover {
    background: var(--cx-gray-50);
    color: var(--cx-navy);
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.btn-ghost {
    background: rgba(255, 255, 255, 0.1);
    color: var(--cx-white);
    border-color: rgba(255, 255, 255, 0.25);
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.2);
    color: var(--cx-white);
}

.btn-sm {
    padding: 0.75rem 1.5rem;
    font-size: var(--fs-xs);
}

.btn-lg {
    padding: 1rem 2.25rem;
    font-size: var(--fs-base);
}

.btn-icon {
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: var(--radius-full);
}

/* ── Header ── */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-fixed);
    background: rgba(11, 29, 58, 0.95);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: background var(--duration-normal) var(--ease-default),
        box-shadow var(--duration-normal) var(--ease-default);
}

.site-header.scrolled {
    background: rgba(11, 29, 58, 0.98);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 95px;
    /* Increased to accommodate extra-large logo */
    gap: var(--sp-6);
}

.header-logo img {
    height: 75px;
    /* Extremely prominent */
    width: auto;
}

/* Desktop Nav */
.main-nav {
    display: none;
}

@media (min-width: 1024px) {
    .main-nav {
        display: flex;
    }
}

.main-nav ul {
    display: flex;
    align-items: center;
    gap: var(--sp-1);
}

.main-nav>ul>li {
    position: relative;
}

.main-nav a {
    display: flex;
    align-items: center;
    gap: var(--sp-1);
    padding: var(--sp-2) var(--sp-3);
    color: rgba(255, 255, 255, 0.8);
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    border-radius: var(--radius-md);
    transition: color var(--duration-fast) var(--ease-default),
        background var(--duration-fast) var(--ease-default);
    white-space: nowrap;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--cx-white);
    background: rgba(255, 255, 255, 0.08);
}

/* Dropdown Arrow */
.nav-arrow {
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 4px solid currentColor;
    margin-left: var(--sp-1);
    transition: transform var(--duration-fast) var(--ease-default);
}

.nav-dropdown:hover .nav-arrow,
.nav-dropdown:focus-within .nav-arrow {
    transform: rotate(180deg);
}

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

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    min-width: 220px;
    background: var(--cx-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    padding: var(--sp-2);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity var(--duration-fast) var(--ease-default),
        transform var(--duration-fast) var(--ease-default);
    transform: translateX(-50%) translateY(8px);
}

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

.dropdown-menu a {
    display: block;
    width: 100%;
    color: var(--cx-gray-700);
    padding: var(--sp-2) var(--sp-3);
    border-radius: var(--radius-md);
    font-size: var(--fs-sm);
    transition: background var(--duration-fast), color var(--duration-fast);
}

.dropdown-menu a:hover,
.main-nav .dropdown-menu a:hover {
    background: var(--cx-gray-50);
    color: var(--cx-teal);
}

.main-nav .dropdown-menu a.active {
    color: var(--cx-teal);
    background: rgba(0, 165, 181, 0.08);
    font-weight: var(--fw-bold);
}

/* Header CTA */
.header-cta {
    display: none;
}

@media (min-width: 1024px) {
    .header-cta {
        display: flex;
        gap: var(--sp-3);
    }
}

/* Mobile Toggle */
.mobile-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 10px;
    background: none;
    border: none;
    cursor: pointer;
}

@media (min-width: 1024px) {
    .mobile-toggle {
        display: none;
    }
}

.mobile-toggle span {
    display: block;
    height: 2px;
    background: var(--cx-white);
    border-radius: 2px;
    transition: transform var(--duration-normal) var(--ease-default),
        opacity var(--duration-normal) var(--ease-default);
}

.mobile-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

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

.mobile-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Nav */
.mobile-nav {
    position: fixed;
    top: 95px;
    /* Aligned exactly under the new 95px header */
    left: 0;
    right: 0;
    height: calc(100vh - 95px);
    /* Force it to fill the screen */
    background: var(--cx-navy);
    z-index: var(--z-overlay);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: var(--sp-4);
    transform: translateX(100%);
    transition: transform var(--duration-normal) var(--ease-default);
}

.mobile-nav.open {
    transform: translateX(0);
}

@media (min-width: 1024px) {
    .mobile-nav {
        display: none !important;
    }
}

.mobile-nav ul {
    display: flex;
    flex-direction: column;
    gap: var(--sp-1);
}

.mobile-nav a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: rgba(255, 255, 255, 0.85);
    font-size: var(--fs-base);
    padding: var(--sp-3) var(--sp-4);
    border-radius: var(--radius-md);
    min-height: 48px;
}

.mobile-nav a:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--cx-white);
}

.mobile-nav ul.mobile-subnav {
    display: none;
    padding-left: var(--sp-4);
}

.mobile-nav ul.mobile-subnav.open {
    display: flex;
    flex-direction: column;
}

/* Arrow rotation for mobile menu active state */
.mobile-dropdown-toggle.active .nav-arrow {
    transform: rotate(180deg);
}

.mobile-subnav a {
    font-size: var(--fs-sm);
    color: rgba(255, 255, 255, 0.65);
    padding: var(--sp-2) var(--sp-4);
}

.mobile-nav-cta {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
    padding: var(--sp-6) var(--sp-4) var(--sp-4);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: var(--sp-4);
}

/* ── Hero ── */
.hero {
    position: relative;
    min-height: 85vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    padding-top: calc(72px + var(--sp-12));
    padding-bottom: var(--sp-12);
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: -2;
}

.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg,
            rgba(11, 29, 58, 0.92) 0%,
            rgba(17, 43, 85, 0.85) 40%,
            rgba(11, 29, 58, 0.9) 100%);
    z-index: 1;
}

.hero-bg video,
.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 700px;
}

.hero-content .overline {
    display: inline-block;
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--ls-wider);
    text-transform: uppercase;
    color: var(--cx-teal-light);
    margin-bottom: var(--sp-4);
    padding: var(--sp-1) var(--sp-3);
    background: rgba(0, 165, 181, 0.15);
    border-radius: var(--radius-full);
}

.hero-content h1 {
    color: var(--cx-white);
    margin-bottom: var(--sp-6);
}

.hero-content h1 .text-highlight {
    background: linear-gradient(135deg, var(--cx-teal-light), var(--cx-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-content p {
    font-size: var(--fs-lg);
    color: rgba(255, 255, 255, 0.75);
    line-height: var(--lh-relaxed);
    margin-bottom: var(--sp-8);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-4);
}

/* Hero Entrance Animations */
@keyframes slideUpFade {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content .overline {
    animation: slideUpFade 0.8s cubic-bezier(0.19, 1, 0.22, 1) backwards;
    animation-delay: 0.2s;
}

.hero-content h1 {
    animation: slideUpFade 0.8s cubic-bezier(0.19, 1, 0.22, 1) backwards;
    animation-delay: 0.35s;
}

.hero-content p {
    animation: slideUpFade 0.8s cubic-bezier(0.19, 1, 0.22, 1) backwards;
    animation-delay: 0.5s;
}

.hero-actions {
    animation: slideUpFade 0.8s cubic-bezier(0.19, 1, 0.22, 1) backwards;
    animation-delay: 0.65s;
}

/* Particles decorative */
.hero-particles {
    position: absolute;
    inset: 0;
    z-index: -1;
    overflow: hidden;
}

.hero-particles .dot {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--cx-teal);
    border-radius: 50%;
    opacity: 0.3;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0) scale(1);
        opacity: 0.3;
    }

    50% {
        transform: translateY(-20px) scale(1.2);
        opacity: 0.6;
    }
}

/* ── Cards ── */
.card {
    background: var(--cx-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1), box-shadow 0.6s cubic-bezier(0.19, 1, 0.22, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
    /* Sophisticated deep shadow */
}

.card-img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: contain;
    background: var(--cx-gray-50);
    display: block;
    transition: transform 0.8s cubic-bezier(0.19, 1, 0.22, 1);
}

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

.card-body {
    padding: var(--sp-6);
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-body h3 {
    margin-bottom: var(--sp-3);
}

.card-body p {
    color: var(--cx-gray-500);
    font-size: var(--fs-sm);
    line-height: var(--lh-normal);
    flex: 1;
}

.card-tag {
    display: inline-block;
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    text-transform: uppercase;
    letter-spacing: var(--ls-wide);
    color: var(--cx-teal);
    margin-bottom: var(--sp-2);
}

.card-footer {
    padding: var(--sp-4) var(--sp-6);
    border-top: 1px solid var(--cx-gray-100);
}

.card-link {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    font-size: var(--fs-sm);
    font-weight: var(--fw-semibold);
    color: var(--cx-teal);
}

.card-link:hover {
    gap: var(--sp-3);
}

.card-link::after {
    content: '→';
    transition: transform var(--duration-fast);
}

.card-link:hover::after {
    transform: translateX(3px);
}

/* Icon Card */
.icon-card {
    background: var(--cx-white);
    padding: var(--sp-8);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    text-align: center;
    transition: transform var(--duration-normal) var(--ease-default),
        box-shadow var(--duration-normal) var(--ease-default);
}

.icon-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.icon-card .icon-wrapper {
    width: 64px;
    height: 64px;
    margin: 0 auto var(--sp-5);
    background: linear-gradient(135deg, rgba(0, 165, 181, 0.1), rgba(78, 205, 196, 0.1));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-card .icon-wrapper img {
    width: 32px;
    height: 32px;
}

.icon-card h4 {
    margin-bottom: var(--sp-3);
    font-size: var(--fs-lg);
}

.icon-card p {
    color: var(--cx-gray-500);
    font-size: var(--fs-sm);
    margin-bottom: 0;
}

/* ── Logo Carousel ── */
.logo-ticker {
    overflow: hidden;
    position: relative;
    padding: var(--sp-4) 0;
}

.logo-ticker::before,
.logo-ticker::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 80px;
    z-index: 2;
    pointer-events: none;
}

.logo-ticker::before {
    left: 0;
    background: linear-gradient(90deg, var(--cx-white), transparent);
}

.logo-ticker::after {
    right: 0;
    background: linear-gradient(90deg, transparent, var(--cx-white));
}

.bg-gray .logo-ticker::before {
    background: linear-gradient(90deg, var(--cx-gray-50), transparent);
}

.bg-gray .logo-ticker::after {
    background: linear-gradient(90deg, transparent, var(--cx-gray-50));
}

.logo-track {
    display: flex;
    gap: var(--sp-10);
    animation: scroll 40s linear infinite;
    width: max-content;
}

.logo-track img {
    height: 120px;
    width: auto;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.6;
    transition: filter var(--duration-normal), opacity var(--duration-normal);
}

.logo-track img:hover {
    filter: grayscale(0);
    opacity: 1;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* ── Feature Grid ── */
.feature-item {
    display: flex;
    gap: var(--sp-4);
    align-items: flex-start;
}

.feature-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, rgba(0, 165, 181, 0.1), rgba(78, 205, 196, 0.08));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--fs-xl);
}

.feature-text h4 {
    font-size: var(--fs-base);
    margin-bottom: var(--sp-2);
}

.feature-text p {
    font-size: var(--fs-sm);
    color: var(--cx-gray-500);
    margin-bottom: 0;
}

/* ── CTA Section ── */
.cta-section {
    padding: var(--sp-20) 0;
    background: linear-gradient(135deg, var(--cx-navy) 0%, var(--cx-navy-light) 50%, #0E2952 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(0, 165, 181, 0.12) 0%, transparent 70%);
    border-radius: 50%;
}

.cta-section h2 {
    color: var(--cx-white);
    margin-bottom: var(--sp-4);
}

.cta-section p {
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--fs-lg);
    margin-bottom: var(--sp-8);
    max-width: 600px;
    margin-inline: auto;
}

/* ── Footer ── */
.site-footer {
    background: var(--cx-navy);
    color: rgba(255, 255, 255, 0.7);
    padding-top: var(--sp-16);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--sp-8);
}

@media (min-width: 640px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr 1.5fr;
    }
}

.footer-brand p {
    font-size: var(--fs-sm);
    line-height: var(--lh-relaxed);
    margin-bottom: var(--sp-6);
    color: rgba(255, 255, 255, 0.6);
}

.footer-brand .footer-logo {
    height: 40px;
    margin-bottom: var(--sp-4);
}

.footer-heading {
    color: var(--cx-white);
    font-size: var(--fs-sm);
    font-weight: var(--fw-semibold);
    text-transform: uppercase;
    letter-spacing: var(--ls-wider);
    margin-bottom: var(--sp-5);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
}

.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    font-size: var(--fs-sm);
    transition: color var(--duration-fast);
}

.footer-links a:hover {
    color: var(--cx-teal-light);
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    margin-bottom: var(--sp-4);
    font-size: var(--fs-sm);
}

.footer-contact-item svg {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    fill: var(--cx-teal);
}

.footer-social {
    display: flex;
    gap: var(--sp-3);
    margin-top: var(--sp-5);
}

.footer-social a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    color: rgba(255, 255, 255, 0.7);
    transition: background var(--duration-fast), color var(--duration-fast);
}

.footer-social a:hover {
    background: var(--cx-teal);
    color: var(--cx-white);
}

.footer-social svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.footer-bottom {
    margin-top: var(--sp-12);
    padding: var(--sp-6) 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: var(--sp-4);
    font-size: var(--fs-xs);
    color: rgba(255, 255, 255, 0.4);
}

/* ── Breadcrumb ── */
.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--sp-2);
    font-size: var(--fs-sm);
    padding: var(--sp-4) 0;
    color: var(--cx-gray-400);
}

.breadcrumb a {
    color: var(--cx-gray-500);
}

.breadcrumb a:hover {
    color: var(--cx-teal);
}

.breadcrumb .sep {
    color: var(--cx-gray-300);
}

.breadcrumb .current {
    color: var(--cx-gray-700);
    font-weight: var(--fw-medium);
}

/* ── YouTube Lite Embed ── */
.yt-lite {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    background: var(--cx-gray-900);
}

.yt-lite img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.yt-lite .play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 68px;
    height: 48px;
    background: rgba(0, 0, 0, 0.75);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--duration-fast);
}

.yt-lite:hover .play-btn {
    background: var(--cx-teal);
}

.yt-lite .play-btn::after {
    content: '';
    border-style: solid;
    border-width: 10px 0 10px 18px;
    border-color: transparent transparent transparent white;
    margin-left: 3px;
}

.yt-lite iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* ── Page Hero (internal pages) ── */
.page-hero {
    background: linear-gradient(135deg, var(--cx-navy) 0%, var(--cx-navy-light) 100%);
    padding: calc(72px + var(--sp-12)) 0 var(--sp-12);
    text-align: center;
}

.page-hero h1 {
    color: var(--cx-white);
    margin-bottom: var(--sp-4);
}

.page-hero p {
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--fs-lg);
    max-width: 640px;
    margin-inline: auto;
}

/* ── Stats Bar ── */
.stats-bar {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--sp-6);
    text-align: center;
}

@media (min-width: 768px) {
    .stats-bar {
        grid-template-columns: repeat(4, 1fr);
    }
}

.stat-item {
    padding: var(--sp-4);
}

.stat-number {
    font-size: var(--fs-4xl);
    font-weight: var(--fw-extrabold);
    color: var(--cx-teal);
    line-height: 1;
    margin-bottom: var(--sp-2);
}

.stat-label {
    font-size: var(--fs-sm);
    color: rgba(255, 255, 255, 0.6);
    font-weight: var(--fw-medium);
}

.bg-white .stat-label {
    color: var(--cx-gray-500);
}

/* ── Tabs ── */
.tabs {
    display: block;
}

.tabs-nav,
.tabs>[role="tablist"] {
    display: flex;
    gap: var(--sp-1);
    overflow-x: auto;
    border-bottom: 2px solid var(--cx-gray-200);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.tabs-nav::-webkit-scrollbar,
.tabs>[role="tablist"]::-webkit-scrollbar {
    display: none;
}

.tab-btn {
    padding: var(--sp-3) var(--sp-5);
    font-size: var(--fs-sm);
    font-weight: var(--fw-medium);
    color: var(--cx-gray-500);
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    white-space: nowrap;
    min-height: 44px;
    transition: color var(--duration-fast), border-color var(--duration-fast);
}

.tab-btn:hover {
    color: var(--cx-navy);
}

.tab-btn.active {
    color: var(--cx-teal);
    border-bottom-color: var(--cx-teal);
}

.tab-panel {
    display: none;
    padding-top: var(--sp-8);
}

.tab-panel.active {
    display: block;
}

/* ── Animate on Scroll ── */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}

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

/* ── Word Rotator ── */
.word-rotator {
    display: inline-block;
    position: relative;
    overflow: hidden;
    vertical-align: bottom;
}

.word-rotator span {
    display: block;
    animation: wordRotate 12s ease-in-out infinite;
}

@keyframes wordRotate {

    0%,
    18% {
        transform: translateY(0);
    }

    22%,
    40% {
        transform: translateY(-100%);
    }

    44%,
    62% {
        transform: translateY(-200%);
    }

    66%,
    84% {
        transform: translateY(-300%);
    }

    88%,
    100% {
        transform: translateY(-400%);
    }
}

/* ── LIMS Venn Diagram (Pure CSS Recreation) ── */
.venn-container {
    position: relative;
    width: 100%;
    max-width: 550px;
    /* Increased from 450px to give more space */
    aspect-ratio: 1;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

/* ── Defensive Grid Mobile Stacking ── */
@media (max-width: 768px) {
    .grid-2 {
        grid-template-columns: 1fr !important;
    }

    .venn-container {
        max-width: 320px;
        /* Constrain on mobile devices */
        margin-top: var(--sp-8);
    }
}

.venn-circle {
    position: absolute;
    width: 54%;
    /* Reduced from 58% so they overlap less violently */
    height: 54%;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--cx-white);
    padding: var(--sp-2) var(--sp-3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border: 4px solid var(--cx-white);
    transition: transform var(--duration-fast), z-index 0s;
}

.venn-circle:hover {
    transform: scale(1.05);
    z-index: 10;
}

.venn-crm {
    top: 2%;
    /* Pushed to outer edges */
    left: 4%;
    background: rgba(0, 165, 181, 0.9);
}

.venn-erp {
    top: 2%;
    right: 4%;
    background: rgba(240, 138, 93, 0.9);
}

.venn-lims {
    bottom: 2%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(30, 136, 229, 0.9);
}

.venn-lims:hover {
    transform: translateX(-50%) scale(1.05);
}

.venn-icon {
    width: 36px;
    /* Scaled down slightly */
    height: 36px;
    margin-bottom: var(--sp-1);
    fill: currentColor;
    opacity: 0.9;
}

.venn-title {
    font-size: var(--fs-lg);
    /* Slightly smaller to prevent text wrapping */
    font-weight: var(--fw-bold);
    margin-bottom: 2px;
    line-height: 1;
}

.venn-desc {
    font-size: 0.65rem;
    /* Downsized for breathing room */
    opacity: 0.9;
    line-height: 1.2;
}

@media (min-width: 768px) {
    .venn-desc {
        font-size: 0.8rem;
    }
}