/* Google Fonts loaded via <link rel="preload"> in header.html (PERF-005) */


/* ============================================================
   Tailwind v4 Utility Overrides
   Tailwind v4 wraps everything in @layer; unlayered CSS (this
   file) takes precedence over ALL @layer blocks per CSS spec.
   We re-declare the rounded utilities here so they apply on
   ALL elements, including <button> which has a base reset of
   border-radius: 0.
   ============================================================ */
.rounded-full {
    border-radius: 9999px !important;
}

.rounded-xl {
    border-radius: 0.75rem !important;
}

.rounded-2xl {
    border-radius: 1rem !important;
}

.rounded-3xl {
    border-radius: 1.5rem !important;
}

.rounded-xl {
    border-radius: 0.75rem !important;
}

.rounded-lg {
    border-radius: 0.5rem !important;
}

.rounded-md {
    border-radius: 0.375rem !important;
}

.rounded {
    border-radius: 0.25rem !important;
}

:root {
    --bg-primary: #ffffff;
    --bg-dark: #1a2327;
    --bg-secondary: #f8f9fa;
    --text-main: #1a1a1a;
    --text-light: #ffffff;
    --text-gray: #94a3b8;
    --accent-blue: #3b82f6;
    --stc-red: #e11d48;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --input-fill: #f9fafb;
    --border-light: rgba(0, 0, 0, 0.05);
}

/* Base Styles */
html {
    scroll-behavior: auto;
    /* Handled by Lenis */
    cursor: none;
    /* Hide default cursor */
}

/* Custom Text Selection */
::selection {
    background: transparent;
    color: #1e40af;
    /* Darker Blue */
    text-shadow: none;
}

::-moz-selection {
    background: transparent;
    color: #1e40af;
    /* Darker Blue */
    text-shadow: none;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-main);
    margin: 0;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #000000;
}

::-webkit-scrollbar-thumb {
    background: #ffffff;
    border-radius: 99px;
    border: 2px solid #000000;
    /* Optional: adds padding effect around thumb */
}

::-webkit-scrollbar-thumb:hover {
    background: #e2e2e2;
}

/* --- CUSTOM CURSOR (Color Adapting) --- */
.cursor-dot {
    width: 14px;
    /* Larger filled dot */
    height: 14px;
    background-color: #ffffff;
    /* White by default */
    border-radius: 50%;
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 9999;
    /* Auto-invert color based on background */
    mix-blend-mode: difference;
    transition: width 0.3s, height 0.3s;
}

/* Cursor Outline Removed
.cursor-outline {
    width: 30px;
    height: 30px;
    border: 1px solid #ffffff;
    border-radius: 50%;
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 9998;
    mix-blend-mode: difference;
    transition: width 0.3s, height 0.3s;
    display: none; 
}
*/

/* Cursor States */
body.hover-link .cursor-dot {
    transform: translate(-50%, -50%) scale(1.5);
    /* Scale via CSS as well for smoothness */
}

/*
body.hover-link .cursor-outline {
    width: 50px;
    height: 50px;
}
*/

/* --- SCROLL REVEAL ANIMATIONS --- */
[data-reveal="up"] {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-reveal].active {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll Progress Bar */
.progress-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: transparent;
    z-index: 100;
}

.progress-bar {
    height: 100%;
    background: black;
    width: 0%;
    transition: width 0.1s ease-out;
}


/* Progress Circle White Mode Support */
.progress-wrap.white-mode {
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.2) !important;
}

.progress-wrap.white-mode svg path {
    stroke: white !important;
}

.progress-wrap.white-mode #scroll-percentage {
    color: white !important;
}

/* Navigation & Header */
header {
    background-color: #ffffff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 700;
    /* Bold navbar text */
    color: #000000;
    transition: color 0.25s ease;
    /* 0.25s transition for smooth hover */
    position: relative;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Social Dock Visible */
/* .social-sidebar, #main-sidebar { display: none !important; } */

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #6b7280;
    /* Grey underline */
    transition: width 0.25s ease;
}

.nav-link:hover,
.group:hover .nav-link {
    color: #6b7280;
    /* Hover shifts to grey */
}

.nav-link:hover::after,
.group:hover .nav-link::after {
    width: 100%;
}

/* Mega Menu & Dropdowns */
.mega-menu {
    position: fixed;
    top: 64px;
    left: 0;
    width: 100%;
    background: #ffffff;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 48;
    /* Elevated z-index for correct layering above content */
    max-height: calc(100vh - 64px);
    overflow-y: auto;
    pointer-events: none;
    /* Prevent phantom hover while invisible */
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: #ffffff;
    min-width: 260px;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 48;
    /* Elevated z-index for correct layering */
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    padding: 1rem 0;
    pointer-events: none;
    /* Prevent phantom hover while invisible */
}

.group:hover .mega-menu,
.group:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
    /* Re-enable interaction when visible */
}

/* Fix for dropdown hover gap */
.desktop-nav .group::after {
    content: '';
    position: absolute;
    bottom: -32px;
    left: 0;
    width: 100%;
    height: 32px;
    background: transparent;
}

.dropdown-item {
    display: block;
    padding: 0.75rem 1.5rem;
    font-size: 0.85rem;
    font-weight: 500;
    color: #1a1a1a;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    color: #6b7280;
}

/* Mobile Menu Styles */
.mobile-menu-overlay {
    position: fixed;
    top: 64px;
    left: 0;
    width: 100%;
    height: calc(100vh - 64px);
    background: white;
    z-index: 49;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    padding-bottom: 2rem;
}

.mobile-menu-overlay.active {
    transform: translateX(0);
}

.mobile-nav-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #f1f1f1;
    font-size: 1rem;
    font-weight: 600;
    color: #1a1a1a;
    background: transparent;
    width: 100%;
    text-align: left;
}

.mobile-submenu {
    background: #f8fafc;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out;
    /* Smooth transition for open/close */
}

.mobile-submenu.active {
    max-height: 500px;
    /* Arbitrary large height to allow content to expand */
}

.mobile-submenu a {
    display: block;
    padding: 1rem 2rem;
    font-size: 0.9rem;
    color: #64748b;
    border-bottom: 1px solid #f1f1f1;
}

/* Footer */
.footer-link {
    font-size: 0.875rem;
    color: #ffffff;
    transition: color 0.3s ease;
    display: inline-block;
}

.footer-link:hover {
    color: #ffffff;
}

/* --- PAGE SPECIFIC STYLES --- */

/* INDEX: Hero & Canvas */
.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: #070a0b;
    overflow: hidden;
}

#bg-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    filter: blur(40px);
    opacity: 0.8;
}

/* INDEX: Glass Cards */
.glass-card {
    background-color: var(--glass-bg);
    background-image:
        radial-gradient(circle, var(--accent-blue) 2px, transparent 2.5px),
        radial-gradient(circle, var(--accent-blue) 2px, transparent 2.5px),
        radial-gradient(circle, var(--accent-blue) 2px, transparent 2.5px),
        radial-gradient(circle, var(--accent-blue) 2px, transparent 2.5px);
    background-position:
        10px 10px,
        calc(100% - 10px) 10px,
        10px calc(100% - 10px),
        calc(100% - 10px) calc(100% - 10px);
    background-repeat: no-repeat;
    background-size: 20px 20px;

    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 2rem;
    position: relative;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.glass-card:hover {
    background-color: rgba(255, 255, 255, 0.08);
    transform: translateY(-5px);
}

/* INDEX: Sidebar (Static in Hero) */
.social-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: fixed;
    right: 2rem;
    top: 50%;
    transform: translateY(-50%);
    z-index: 40;

    /* Always visible in Hero */
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* Remove hidden-dock class - not needed anymore */

.social-link {
    font-size: 1.1rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

/* Sidebar States (Light/Dark Mode) */
.social-sidebar.is-dark .social-link {
    color: #ffffff;
    opacity: 0.9;
}

.social-sidebar.is-dark .social-link:hover {
    opacity: 1;
    transform: scale(1.15);
}

.social-sidebar.is-light .social-link {
    color: #000000;
    opacity: 0.8;
}

.social-sidebar.is-light .social-link:hover {
    opacity: 1;
    transform: scale(1.15);
}

/* --- GLOBAL DOCK STYLE --- */
.social-sidebar.global-dock {
    padding: 1.25rem 0.5rem;
    border-radius: 9999px;
    overflow: hidden;
    transition: background 0.6s ease, border-color 0.6s ease, box-shadow 0.6s ease, transform 0.4s ease;
}

.social-sidebar.global-dock:hover {
    transform: translateY(-50%) scale(1.02);
}

/* Dark Background Dock (Hero / Footer) */
.social-sidebar.is-dark.global-dock {
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.3), inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.social-sidebar.is-dark.global-dock .social-link {
    color: rgba(255, 255, 255, 0.9);
}

/* Light Background Dock (Products / Gallery) */
.social-sidebar.is-light.global-dock {
    background: rgba(0, 0, 0, 0.05);
    /* Soft dark glass */
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.1), inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.social-sidebar.is-light.global-dock .social-link {
    color: rgba(0, 0, 0, 0.7);
}

/* Smooth Icon Transitions */
.social-sidebar.global-dock .social-link {
    position: relative;
    z-index: 2;
    transition: color 0.4s ease, background 0.4s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

/* Hover Events */
.social-sidebar.is-dark.global-dock .social-link:hover {
    background: #ffffff;
    color: #000000;
    transform: scale(1.2);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.4);
}

.social-sidebar.is-light.global-dock .social-link:hover {
    background: #000000;
    color: #ffffff;
    transform: scale(1.2);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

/* INDEX: Marquees */
.client-marquee {
    display: flex;
    width: calc(320px * 16);
    animation: scroll-client 50s linear infinite;
}

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

    100% {
        transform: translateX(calc(-320px * 8));
    }
}

.gallery-container {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.gallery-marquee {
    display: flex;
    width: calc(350px * 8);
    animation: scroll-gallery 65s linear infinite;
}

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

    100% {
        transform: translateX(calc(-350px * 4));
    }
}

.gallery-card {
    width: 320px;
    flex-shrink: 0;
    margin-right: 30px;
}

/* Fade styles removed */

/* Post-Gallery styles */
.product-card {
    border-radius: 24px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* =============================================
   PHASE 3: GLOBAL FORM STANDARDS
   Unified across all 3 forms:
   - Contact form (index.html)
   - Resources lead modal (resources.html)
   - Quote modal (product-detail-template.html)
   ============================================= */

/* Form field wrapper — contains label + input + error msg */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0;
    position: relative;
}

/* Standardized label */
.form-label {
    display: block;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 0.45rem;
    padding-left: 0.1rem;
    line-height: 1;
}

/* Required asterisk — always red */
.form-label .required-star,
.form-label .req {
    color: #ef4444;
    margin-left: 2px;
    font-weight: 900;
}

/* Standardized input — consistent 44px height */
.form-input {
    width: 100%;
    height: 44px;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    /* Standardized 12px radius */
    padding: 0 1rem;
    font-size: 0.875rem;
    color: #1a1a1a;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: none;
    appearance: none;
    -webkit-appearance: none;
}

/* Textarea overrides — allow variable height but keep standards */
textarea.form-input {
    height: auto;
    padding: 0.75rem 1rem;
    resize: vertical;
    min-height: 120px;
    border-radius: 12px;
}

/* FOCUS STATE — black outline */
.form-input:focus {
    outline: none;
    border-color: #000000;
    /* Black border on focus */
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.07);
    /* Subtle black glow */
    background-color: #ffffff;
}

/* ERROR STATE — red border (added by JS on validation fail) */
.form-input.error,
.form-input.input-error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

/* SUCCESS STATE — subtle green when valid (added by JS) */
.form-input.success,
.form-input.input-success {
    border-color: #22c55e !important;
    box-shadow: none !important;
}

/* Inline error message — appears below invalid field */
.field-error {
    font-size: 0.7rem;
    font-weight: 600;
    color: #ef4444;
    margin-top: 0.3rem;
    padding-left: 0.1rem;
    display: none;
    /* Hidden by default; JS sets display:block */
    line-height: 1.3;
    animation: errorSlideIn 0.15s ease;
}

.field-error.visible {
    display: block;
}

@keyframes errorSlideIn {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Form group inline-error notification (non-field, e.g. network errors) */
.form-alert {
    padding: 0.75rem 1rem;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    display: none;
    animation: errorSlideIn 0.2s ease;
}

.form-alert.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
    display: block;
}

.form-alert.success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
    display: block;
}

/* Legacy rounded inputs in lead modal — keep 12px to match standard */
.form-input.rounded-2xl {
    border-radius: 12px !important;
}

/* INDEX: FAQ */
.faq-item {
    border-top: 1px solid #f1f1f1;
    padding: 1.5rem 0;
    transition: background-color 0.3s ease;
}

.faq-item:last-child {
    border-bottom: 1px solid #f1f1f1;
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    text-align: left;
    font-weight: 500;
    font-size: 1.15rem;
    color: #1a1a1a;
    cursor: pointer;
    padding: 0.5rem 0;
}

.faq-question i {
    font-size: 0.8rem;
    color: #cbd5e1;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
    color: #334155;
    /* Slate 700 - Dark Gray */
    font-weight: 400;
    /* Slightly bolder for readability if desired, or keep 300 */
    line-height: 1.6;
    font-size: 1rem;
    opacity: 0;
}

.faq-item.active .faq-answer {
    max-height: 500px;
    padding-top: 1rem;
    opacity: 1;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

/* INDEX: Products Grid */
.product-card {
    background: #fff;
    border-radius: 0;
    overflow: hidden;
    border: 1px solid #f1f1f1;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: none;
    border-color: #e2e8f0;
}

.product-image-container {
    width: 100%;
    /* Square aspect enforced by padding-top trick so height = width */
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-container img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    /* show full product, no cropping */
    transition: transform 0.8s ease;
}

/* SERVICES (Consultancy, GCMS, LCMS) */
.service-card {
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    padding: 2.5rem;
    transition: all 0.3s ease;
    background: #fff;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.05);
    border-color: #3b82f6;
}

/* =============================================
   PHASE 9: LAZY LOADING & SHIMMER EFFECTS
   ============================================= */

/* The container holding the lazy image needs this class */
.shimmer {
    position: relative;
    overflow: hidden;
    background-color: #f1f5f9;
    /* Slate 100 - light gray base */
}

/* The animated gradient overlay */
.shimmer::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    transform: translateX(-100%);
    background-image: linear-gradient(90deg,
            rgba(255, 255, 255, 0) 0,
            rgba(255, 255, 255, 0.4) 20%,
            rgba(255, 255, 255, 0.8) 60%,
            rgba(255, 255, 255, 0));
    animation: shimmer-animation 1.5s infinite;
    z-index: 10;
}

@keyframes shimmer-animation {
    100% {
        transform: translateX(100%);
    }
}

/* The actual image being lazy loaded */
.lazy-image {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

/* Added dynamically by JS once loaded */
.lazy-image.loaded {
    opacity: 1;
}

.hero-banner {
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    border-radius: 24px;
    padding: 5rem 4rem;
    margin-bottom: 4rem;
}

.training-module {
    border-left: 4px solid #f1f5f9;
    padding-left: 2rem;
    margin-bottom: 3rem;
    transition: all 0.3s ease;
}

.training-module:hover {
    border-left-color: #3b82f6;
}

/* 404 PAGE */
.error-container {
    min-height: calc(100vh - 64px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 64px;
}

.error-code {
    font-size: clamp(8rem, 20vw, 12rem);
    font-weight: 900;
    line-height: 0.8;
    letter-spacing: -0.05em;
    color: #f1f5f9;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
    user-select: none;
}

/* =============================================
   PHASE 5: CONSENT CHECKBOX
   ============================================= */

.consent-group {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    transition: border-color 0.2s ease, background 0.2s ease;
    margin-bottom: 1rem;
}

.consent-group:focus-within {
    border-color: #000;
    background: #fff;
}

.consent-group.has-error {
    border-color: #ef4444;
    background: #fef2f2;
}

.consent-checkbox {
    width: 16px;
    height: 16px;
    border: 2px solid #cbd5e1;
    border-radius: 4px;
    accent-color: #000;
    flex-shrink: 0;
    margin-top: 2px;
    cursor: pointer;
    transition: border-color 0.2s ease;
}

.consent-checkbox:focus {
    outline: 2px solid #000;
    outline-offset: 2px;
}

.consent-label {
    font-size: 0.72rem;
    color: #64748b;
    line-height: 1.5;
    cursor: pointer;
}

.consent-label a {
    color: #000;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.consent-label a:hover {
    color: #374151;
}

.consent-error {
    display: none;
    font-size: 0.65rem;
    font-weight: 700;
    color: #ef4444;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-top: 4px;
    margin-left: 26px;
}

.consent-group.has-error+.consent-error {
    display: block;
}

/* Grey-out submit when consent not ticked */
button[type="submit"][disabled],
button[type="submit"].consent-blocked {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}

/* =============================================
   GLOBAL BUTTON STANDARDS (Phase 2)
   - Default: Black bg, white text
   - Hover:   Dark blue (#1e40af)
   - Padding: 0.75rem 2rem (standardized)
   - Radius:  9999px (pill) globally
   ============================================= */

.btn-black {
    background: #000000;
    color: #ffffff;
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    transition: background-color 0.25s ease, color 0.25s ease;
    display: inline-block;
    cursor: pointer;
}

.btn-black:hover {
    background: #1e40af;
    /* Dark Blue on hover */
    color: #ffffff;
}

/* All black-bg buttons (Tailwind .bg-black) → Dark Blue on Hover */
.bg-black:not([class*="text-black"]) {
    transition: background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease;
}

/* Filled Black Buttons: Dark Blue Bg on Hover */
[data-magnetic].bg-black:hover,
a.bg-black:hover,
button.bg-black:hover {
    background-color: #1e40af !important;
    border-color: #1e40af !important;
    color: white !important;
}

/* Outlined Black Buttons: Dark Blue Border/Text on Hover */
[data-magnetic].border-black:hover {
    background-color: transparent !important;
    border-color: #1e40af !important;
    color: #1e40af !important;
    box-shadow: none !important;
}

/* Generic hover-blue target for non-magnetic buttons */
.hover-blue:hover {
    background-color: #1e40af !important;
    color: #ffffff !important;
}

/* =============================================
   GLOBAL BREADCRUMB STANDARDS (Phase 2)
   Unified across all pages: bold, text-xs,
   uppercase, slate-400 color, consistent gap
   ============================================= */

.breadcrumb-item,
.breadcrumb a,
nav[aria-label="breadcrumb"] a,
nav[aria-label="breadcrumb"] span {
    font-size: 0.7rem;
    /* Consistent xs size */
    font-weight: 700;
    /* Bold */
    color: #94a3b8;
    /* Slate-400 */
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: color 0.2s ease;
    text-decoration: none;
}

.breadcrumb-item:hover,
.breadcrumb a:hover,
nav[aria-label="breadcrumb"] a:hover {
    color: #000000;
}

/* Breadcrumb separator standardization */
.breadcrumb-separator,
nav[aria-label="breadcrumb"] .separator {
    color: #cbd5e1;
    font-size: 0.65rem;
    font-weight: 400;
}

.spec-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    display: table;
    background: white;
}

.spec-table th {
    text-align: left;
    padding: 1.25rem 1rem;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 800;
    color: #94a3b8;
    border-bottom: 2px solid #e5e7eb;
    background: #f9fafb;
}

.spec-table td {
    padding: 1.5rem 1rem;
    border-bottom: 1px solid #e5e7eb;
    font-size: 0.85rem;
    color: #1a1a1a;
}

.spec-row {
    transition: background-color 0.2s;
    display: table-row;
}

.spec-row:hover td {
    background-color: #fafafa;
}

.spec-row.selected td {
    background-color: #f8fafc;
    border-bottom-color: #000;
    font-weight: 600;
}

.action-card {
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.btn-quote {
    background: var(--stc-red);
    color: white;
    padding: 1.25rem;
    border-radius: 8px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.75rem;
    transition: all 0.3s ease;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.btn-quote:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(225, 29, 72, 0.2);
}

/* RESOURCES PAGE */
.resource-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-bottom: 1.5rem;
}

.resource-table th {
    text-align: left;
    padding: 1.5rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 800;
    color: #94a3b8;
    border-bottom: 1px solid var(--border-light);
}

.resource-table td {
    padding: 2rem 1.5rem;
    border-bottom: 1px solid var(--border-light);
    vertical-align: top;
    transition: background-color 0.2s ease;
}

.resource-row:hover td {
    background-color: #fafafa;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 0.7rem 1.4rem;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
    color: #1a1a1a;
    background: white;
    white-space: nowrap;
}

.action-btn:hover {
    border-color: #000;
    background: #f8fafc;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.category-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: #000000;
    margin-bottom: 2rem;
    margin-top: 4rem;
    letter-spacing: -0.02em;
}

.custom-dropdown-container {
    position: relative;
    user-select: none;
}

.dropdown-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: var(--input-fill);
    border: 1px solid rgba(0, 0, 0, 0.03);
    border-radius: 50px;
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
}

.dropdown-trigger:hover {
    border-color: #e2e8f0;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.dropdown-trigger.active {
    background: #fff;
    border-color: #000;
}

.dropdown-trigger i {
    font-size: 0.7rem;
    transition: transform 0.3s ease;
}

.dropdown-trigger.active i {
    transform: rotate(180deg);
}

.dropdown-content-list {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 100%;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 0.75rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
    max-height: 300px;
    overflow-y: auto;
}

.dropdown-content-list.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-option {
    padding: 0.7rem 1.5rem;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s;
    color: #64748b;
}

.dropdown-option:hover {
    background: #f8fafc;
    color: #000;
}

.dropdown-option.selected {
    color: #000;
    font-weight: 700;
    background: #f1f5f9;
}

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.modal-overlay.show {
    display: flex;
}

.modal-content {
    background: white;
    width: 100%;
    max-width: 500px;
    border-radius: 0;
    position: relative;
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.4);
    padding: 3rem;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.modal-header {
    padding-bottom: 1.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #f8fafc;
}

.btn-submit {
    width: 100%;
    background: #000;
    color: #fff;
    padding: 1.1rem;
    border-radius: 50px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: 0.7rem;
    transition: all 0.3s;
}

.btn-submit:hover {
    background: #333;
    transform: translateY(-1px);
}

.otp-input {
    letter-spacing: 0.5em;
    font-size: 1.5rem;
    font-weight: 800;
    text-align: center;
}

/* LOADING SHIMMER EFFECT */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }

    100% {
        background-position: 1000px 0;
    }
}

.shimmer {
    animation: shimmer 2s infinite linear;
    background: linear-gradient(to right, #f6f7f8 4%, #edeef1 25%, #f6f7f8 36%);
    background-size: 1000px 100%;
}

.skeleton-text {
    height: 1rem;
    margin-bottom: 0.5rem;
    border-radius: 0.25rem;
}

.skeleton-title {
    height: 1.5rem;
    margin-bottom: 1rem;
    width: 60%;
}

.skeleton-row {
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

/* Responsive adjustments */
@media (max-width: 1024px) {

    .spec-table th,
    .spec-table td {
        padding: 1rem 0.5rem;
    }
}

@media (max-width: 768px) {

    /* Custom cursor now controlled by JavaScript based on touch detection */
    /* .cursor-dot,
    .cursor-outline {
        display: none !important;
    } */


    .social-sidebar,
    .desktop-nav {
        display: none;
    }

    .client-marquee {
        width: calc(200px * 16);
    }

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

        100% {
            transform: translateX(calc(-200px * 8));
        }
    }

    .gallery-marquee {
        width: calc(350px * 8);
    }

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

        100% {
            transform: translateX(calc(-350px * 4));
        }
    }

    .category-title {
        font-size: 1.75rem;
    }

    /* Tables responsiveness */
    .resource-table,
    .resource-table thead,
    .resource-table tbody,
    .resource-table th,
    .resource-table td,
    .resource-table tr {
        display: block;
    }

    .resource-table thead {
        display: none;
    }

    .resource-table td {
        padding: 1.5rem;
        border-bottom: 1px solid #f1f1f1;
        text-align: left !important;
    }

    .spec-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    /* Layout Adjustments */
    .modal-content {
        padding: 2rem 1.5rem;
        max-height: 85vh;
        overflow-y: auto;
    }

    .action-btn {
        width: 100%;
        justify-content: center;
        margin-top: 1rem;
    }

    .controls-wrapper {
        flex-direction: column;
        width: 100%;
    }

    /* Hero adjustments */
    section.pt-48 {
        padding-top: 8rem;
    }

    /* Banner text sizes */
    .hero-banner {
        padding: 3rem 2rem;
    }
}

/* ... existing code ... */

/* --- Product Detail View (Quantum Styles) --- */
/* Segmented control tab buttons */
.tab-btn {
    padding: 0.625rem 1.25rem;
    color: #64748b;
    /* slate-500 */
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-radius: 9999px;
    transition: color 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
    white-space: nowrap;
}

.tab-btn:hover {
    color: #1e293b;
    /* slate-800 */
    background-color: rgba(148, 163, 184, 0.2);
    /* slate-200/50 */
}

.tab-btn.active {
    color: #1d4ed8;
    /* blue-700 */
    background-color: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(15, 23, 42, 0.05);
}

/* Tab Content Panes — toggled by ui-interactions.js */
.tab-content {
    display: none;
    animation: tabFadeIn 0.3s ease-in;
}

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

@keyframes tabFadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================================
   VISUAL ENHANCEMENT ADDITIONS
   ============================================================ */

/* --- 1. Sticky Tab Navigation Bar --- */
.sticky-tab-bar {
    position: sticky;
    top: 64px;
    /* sits just below the fixed header */
    z-index: 40;
    background-color: #ffffff;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

/* --- 2. Gallery Image Tray --- */
.gallery-tray {
    background-color: #ffffff;
    border-radius: 1.5rem;
    box-shadow: inset 0 2px 12px rgba(0, 0, 0, 0.04), 0 0 0 1px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    padding: 1.5rem;
}

/* --- 3. Sticky Pricing Card column --- */
.sticky-details-col {
    position: sticky;
    top: 5rem;
    align-self: start;
}

/* --- 4. Feature Highlight Pills --- */
.feature-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.75rem;
}

.feature-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #166534;
    background-color: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 9999px;
    padding: 0.3rem 0.75rem;
}

.feature-pill i {
    font-size: 0.6rem;
    color: #22c55e;
}

/* --- 5. Spec Table Polish --- */
/* Alternating row fills on prose tables inside tab content */
.tab-content .prose table tbody tr:nth-child(even),
.tab-content table tbody tr:nth-child(even) {
    background-color: rgba(249, 250, 251, 0.7);
}

/* Column header — left blue accent bar */
.tab-content .prose thead th:first-child,
.tab-content table thead th:first-child {
    border-left: 3px solid #2563eb;
}

/* Active selected row from products.js — richer blue tint */
.tab-content table tbody tr.bg-blue-50 {
    background-color: rgba(239, 246, 255, 0.9) !important;
    box-shadow: inset 3px 0 0 #2563eb;
}

/* --- 7. Hero Stagger Reveal --- */
/* data-reveal elements start invisible; ui-interactions.js adds .active */
[data-reveal] {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1),
        transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

[data-reveal].active {
    opacity: 1;
    transform: translateY(0);
}

[data-reveal-delay="100"] {
    transition-delay: 0.10s;
}

[data-reveal-delay="200"] {
    transition-delay: 0.20s;
}

[data-reveal-delay="300"] {
    transition-delay: 0.30s;
}

[data-reveal-delay="400"] {
    transition-delay: 0.40s;
}

[data-reveal-delay="500"] {
    transition-delay: 0.50s;
}

/* --- 8. Breadcrumb Chevron Style --- */
.breadcrumb-chevron {
    font-size: 0.6rem;
    opacity: 0.4;
    margin: 0 0.25rem;
}

.breadcrumb-item {
    text-decoration: none;
    transition: color 0.2s, text-decoration 0.2s;
}

.breadcrumb-item:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Minimalist Table Styles */
.quantum-table tr {
    border-bottom: 1px solid #f3f4f6;
}

.quantum-table td {
    padding: 1.5rem 0;
    font-size: 0.9rem;
    color: #1f2937;
}

.quantum-table td:first-child {
    font-weight: 600;
    color: #6b7280;
    width: 30%;
}

.status-dot {
    height: 6px;
    width: 6px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
}

/* --- Blog Article Typography --- */
.article-content p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    color: #374151;
    /* gray-700 */
}

.article-content h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 3rem;
    margin-bottom: 1rem;
    color: #000;
    letter-spacing: -0.02em;
}

.article-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: #1f2937;
    /* gray-800 */
}

.article-content ul {
    list-style-type: disc;
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
    color: #374151;
}

.article-content li {
    margin-bottom: 0.5rem;
}

/* --- PRODUCT DETAIL TEMPLATE STYLES (Extracted) --- */
/* scroll-behavior is set to 'auto' at the top of this file — Lenis owns smooth scroll */

/* Hide scrollbar for clean look in some elements */
.no-scrollbar::-webkit-scrollbar {
    display: none;
}

.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Floating button hover effect */
.float-btn {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: transform 0.2s;
}

.float-btn:hover {
    transform: translateY(-2px);
}

/* Markdown content styling (Prose) */
.prose {
    max-width: none;
}

.prose h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #111827;
    line-height: 1.2;
}

.prose h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: #111827;
    line-height: 1.3;
}

.prose h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    color: #111827;
    line-height: 1.4;
}

.prose p {
    color: #6b7280;
    margin-bottom: 1rem;
    line-height: 1.75;
}

.prose ul,
.prose ol {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
    color: #6b7280;
}

.prose ul {
    list-style-type: disc;
}

.prose ol {
    list-style-type: decimal;
}

.prose li {
    margin-bottom: 0.5rem;
    line-height: 1.75;
}

.prose a {
    color: #2563eb;
    text-decoration: none;
    transition: all 0.2s;
}

.prose a:hover {
    text-decoration: underline;
    color: #1d4ed8;
}

.prose strong {
    font-weight: 600;
    color: #111827;
}

.prose em {
    font-style: italic;
}

.prose table {
    width: 100%;
    margin-bottom: 1.5rem;
    border-collapse: collapse;
    overflow: hidden;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
}

.prose thead {
    background-color: #f3f4f6;
}

.prose th {
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6b7280;
    border-bottom: 2px solid #e5e7eb;
}

.prose td {
    padding: 1rem;
    border-bottom: 1px solid #e5e7eb;
    color: #111827;
}

.prose tbody tr:hover {
    background-color: #f9fafb;
}

.prose tbody tr:last-child td {
    border-bottom: none;
}

.prose img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1.5rem 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.prose hr {
    border: 0;
    border-top: 1px solid #e5e7eb;
    margin: 2rem 0;
}

.prose code {
    background-color: #f3f4f6;
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    font-size: 0.875em;
    font-family: 'Courier New', monospace;
    color: #111827;
}

.prose pre {
    background-color: #1f2937;
    color: #f3f4f6;
    padding: 1rem;
    border-radius: 0.5rem;
    overflow-x: auto;
    margin-bottom: 1rem;
}

.prose pre code {
    background-color: transparent;
    padding: 0;
    color: #f3f4f6;
}

.prose blockquote {
    border-left: 4px solid #2563eb;
    padding-left: 1rem;
    color: #6b7280;
    font-style: italic;
    margin: 1.5rem 0;
}

/* RIGHT-CLICK PROTECTION NOTIFICATION */
.right-click-popup {
    position: fixed;
    z-index: 9999;
    width: auto;
    height: auto;
    background: transparent;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;

    /* Animation */
    opacity: 0;
    transform: scale(0);
    pointer-events: none;
    transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);

    /* Prevent text selection */
    user-select: none;
    -webkit-user-select: none;
}

.right-click-popup.show {
    opacity: 1;
    transform: scale(1);
    animation: shake 0.5s ease-in-out;
}

.right-click-popup i {
    font-size: 24px;
    color: #ef4444;
    /* Red Icon */
    text-shadow: 0 2px 10px rgba(239, 68, 68, 0.3);
}

@keyframes shake {

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

    25% {
        transform: scale(1.1) rotate(-10deg);
    }

    50% {
        transform: scale(1.1) rotate(10deg);
    }

    75% {
        transform: scale(1.1) rotate(-10deg);
    }
}

/* Mobile adjustments */
@media (max-width: 640px) {
    .right-click-popup {
        width: 40px;
        height: 40px;
    }

    .right-click-popup i {
        font-size: 18px;
    }
}

/* COOKIE CONSENT BANNER STYLES */
#cookie-banner.show {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll Progress Circle */
.progress-wrap {
    position: fixed;
    right: auto;
    left: 2rem;
    bottom: 2rem;
    height: 46px;
    width: 46px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50px;
    box-shadow: inset 0 0 0 2px rgba(0, 0, 0, 0.1);
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: all 200ms linear;
}

.progress-wrap.active-progress {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* FontAwesome Up Arrow - Hidden by default */
.progress-wrap::after {
    position: absolute;
    content: '\f062';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    text-align: center;
    line-height: 46px;
    font-size: 14px;
    color: #1a1a1a;
    left: 0;
    top: 0;
    height: 46px;
    width: 46px;
    cursor: pointer;
    display: block;
    z-index: 1;
    transition: all 200ms linear;
    opacity: 0;
}

/* Show Arrow on Hover */
.progress-wrap:hover::after {
    opacity: 1;
}

/* Hide Text on Hover */
.progress-wrap:hover .progress-text {
    opacity: 0;
}

.progress-text {
    position: relative;
    z-index: 2;
    font-size: 10px;
    font-weight: 800;
    color: #1a1a1a;
    user-select: none;
    transition: all 200ms linear;
    opacity: 1;
    line-height: 1;
    text-align: center;
}



/* --- PROFESSIONAL UI ENHANCEMENTS --- */

/* 1. Tactile Click Feedback */
a:active,
button:active,
.clickable:active {
    transform: scale(0.98);
}

/* 2. Consistent Border Radius */
.btn,
button,
input,
textarea,
select,
.card,
.glass-card,
.gallery-card>div {
    border-radius: 12px;
}

/* --- MAIN SIDEBAR DOCK STYLES --- */
#main-sidebar {
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

#main-sidebar.hidden-dock {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Default icons are white (set in HTML utility classes).
   When .dark-mode is active (outside Hero), turn them black. */
#main-sidebar.dark-mode a {
    color: #000000 !important;
    border-color: rgba(0, 0, 0, 0.2);
}

#main-sidebar.dark-mode a:hover {
    background-color: #000000;
    color: #ffffff !important;
    border-color: #000000;
}

/* --- HOMEPAGE REFINEMENTS --- */

/* 1. Client Carousel Side Fade */
.marquee-mask {
    /* Masking for side fade effect - Applied to static parent */
    mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
    mask-size: 100% 100%;
    -webkit-mask-size: 100% 100%;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
}

/* 2. Product Cards Rounded */
.glass-card {
    border-radius: 16px;
    /* Slightly more rounded than default 12px if needed, or ensuring it applies */
}

/* Target the specific grid in Hero/Product section if they use a different class */
section .grid .glass-card {
    border-radius: 20px;
    /* "Little rounded" as requested - making it distinct */
}

footer a:visited,
nav a:visited {
    opacity: 0.7;
}

/* 4. Breadcrumbs — unified global style (Phase 2) */
.breadcrumb {
    font-size: 0.7rem;
    /* Standardised to match .breadcrumb-item */
    font-weight: 700;
    color: #94a3b8;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.breadcrumb a {
    font-size: 0.7rem;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    transition: color 0.2s ease;
    text-decoration: none;
}

.breadcrumb a:hover {
    color: #000000;
}

.breadcrumb-separator {
    color: #cbd5e1;
    font-size: 0.65rem;
    font-weight: 400;
}

/* Refined Shadows for Cards */
.glass-card {
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.05),
        /* Ambient */
        0 4px 12px rgba(0, 0, 0, 0.08);
    /* Directional */
}

.gallery-card>div {
    box-shadow: none !important;
}

/* --- PRODUCT DETAIL TABLES --- */
/* Ensure tables in tab content are styled even if not using .prose */
.tab-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
    /* text-sm */
    text-align: left;
}

.tab-content table th {
    background-color: #f8fafc;
    /* bg-gray-50 */
    color: #1a1a1a;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.tab-content table td {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    color: #475569;
    /* text-slate-600 */
}

.tab-content table tbody tr:last-child td {
    border-bottom: none;
}

.tab-content table tbody tr:hover {
    background-color: #f8fafc;
}

/* Social Dock Restored */
/* .social-sidebar,
#main-sidebar {
    display: none !important;
} */

/* =============================================
   PHASE 2: ARROW ICON FORWARD-SHIFT ANIMATION
   All fa-arrow-right icons get a uniform
   horizontal slide of +4px on hover of their
   parent element. Covers buttons, links, CTAs.
   ============================================= */

/* Keyframe for a subtle forward nudge */
@keyframes arrowShift {
    0% {
        transform: translateX(0);
    }

    50% {
        transform: translateX(4px);
    }

    100% {
        transform: translateX(4px);
    }
}

/* Apply to any element containing an arrow icon when its parent is hovered */
a:hover .fa-arrow-right,
button:hover .fa-arrow-right,
.group:hover .fa-arrow-right,
a:hover .fa-arrow-down,
button:hover .fa-arrow-down {
    transform: translateX(4px);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Default reset so transition plays correctly */
.fa-arrow-right,
.fa-arrow-down {
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-block;
}

/* =============================================
   PHASE 2: CURSOR FLICKERING FIX
   Popups and dropdowns that are hidden must
   have pointer-events: none to prevent the
   custom cursor from flickering when it passes
   over invisible/opacity-0 elements.
   ============================================= */

/* Product & Resource category popups (hidden state) */
.modal-overlay:not(.show),
#leadModal:not(.show),
#validation-modal:not([style*="opacity: 1"]) {
    pointer-events: none !important;
    cursor: none !important;
}

/* Modals using hidden class (product detail template) */
#quote-modal.hidden,
#success-popup.hidden,
#description-modal.hidden {
    pointer-events: none !important;
    cursor: none !important;
}

/* Fixed popups that are invisible should never capture mouse */
.modal-overlay {
    /* Ensure only visible overlays intercept pointer events */
    pointer-events: none;
}

.modal-overlay.show {
    pointer-events: auto;
}

/* =============================================
   PHASE 2: INLINE BREADCRUMB NAV — PRODUCT &
   LISTING PAGES
   These pages use inline nav elements without
   the .breadcrumb class; target them directly.
   ============================================= */

/* Product detail template: nav.flex + text-sm + uppercase */
main nav.flex a,
main nav.flex span:not(.separator) {
    font-size: 0.7rem !important;
    font-weight: 700 !important;
    color: #94a3b8 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.08em !important;
    text-decoration: none !important;
    transition: color 0.2s ease;
}

main nav.flex a:hover {
    color: #000000 !important;
}

main nav.flex span.text-gray-300,
main nav.flex span.text-gray-400 {
    font-size: 0.65rem !important;
    font-weight: 400 !important;
    color: #cbd5e1 !important;
}

/* Listing-page template breadcrumb nav */
main>nav.flex {
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem;
}

/* =============================================
   PHASE 4: PRODUCT IMAGES — SQUARE + CONTAIN
   ============================================= */

/* ── Product Detail Hero Image ─────────────────
   Replace the 4:3 aspect ratio with a true 1:1
   square frame.  object-fit:contain keeps full
   product visible; white bg fills letterbox gap.
   min-height prevents layout shift while loading.
   ─────────────────────────────────────────────── */
.aspect-w-4.aspect-h-3 {
    /* Override the Tailwind aspect shorthand classes */
    aspect-ratio: 1 / 1 !important;
    min-height: 320px;
    /* layout-shift guard */
    background: #f8fafc !important;
    /* crisp neutral bg */
}

/* The hero <img id="detail-img"> */
#detail-img {
    object-fit: contain !important;
    /* never crop the product photo */
    /* Keep the hover scale-up animation from the template */
}

/* ── Category Card Images (listing pages) ───────
   aspect-square is already set in the HTML;
   switch cover → contain so brand images
   show without cropping.
   ─────────────────────────────────────────────── */
#category-grid .aspect-square img,
[id^="category-grid"] .aspect-square img {
    object-fit: contain !important;
    padding: 12px;
    /* breathing room */
    background: #f8fafc;
}

/* ── Product Listing Card Images ────────────────
   The card uses .aspect-square on the container
   and object-cover on the img. Switch to contain
   so lab/instrument product shots look correct.
   ─────────────────────────────────────────────── */
#catalogGrid .aspect-square img,
.grid#catalogGrid~* .aspect-square img {
    object-fit: contain !important;
    padding: 10px;
}

/* ── Category Listing Typography ─────────────────
   Tighten up the stacked "Categories" heading
   and the product-count link inside each card.
   ─────────────────────────────────────────────── */

/* Section-level heading above the category grid */
section>h3.uppercase.tracking-widest {
    font-size: 0.65rem;
    letter-spacing: 0.15em;
    font-weight: 900;
    color: #94a3b8;
    /* slightly softer slate */
    margin-bottom: 1.25rem;
}

/* Category card heading (h3 inside .p-5) */
#category-grid a .p-5 h3 {
    font-size: 0.875rem;
    /* text-sm — was text-base (1rem) */
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.2;
    margin-bottom: 0.25rem;
}

/* Category card description paragraph */
#category-grid a .p-5 p {
    font-size: 0.7rem;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    color: #94a3b8;
}

/* Category card "N Products →" link text */
#category-grid a .p-5>div.flex {
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    gap: 6px;
}

/* ── Thumbnail Spacing Standardisation ──────────
   Enforce a uniform 4px gap between all thumbs
   in any thumbnail strip added later.
   ─────────────────────────────────────────────── */
.detail-thumbs {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.detail-thumb {
    width: 72px;
    height: 72px;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    background: #f8fafc;
    flex-shrink: 0;
    transition: border-color 0.2s ease;
}

.detail-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 4px;
}

.detail-thumb.active,
.detail-thumb:hover {
    border-color: #000;
}

/* =============================================
   PHASE 2: STABLE Z-INDEX HIERARCHY
   Header: 50 (fixed)
   Mega-menu/dropdown: 48
   Modals/overlays: 100+
   Custom cursor: 9999
   ============================================= */

/* Reaffirm header is always above content but below modals */
header#main-header {
    z-index: 50;
}

/* Mega-menu must be below header z-index would conflict, so keep at 48 */
/* Mobile menu overlay sits between header and modals */
.mobile-menu-overlay {
    z-index: 49;
}

/* Modals must sit above everything except cursor */
.modal-overlay,
#quote-modal,
#success-popup,
#description-modal,
#validation-modal {
    z-index: 100;
}

/* Cookie banner below modals but above content */
#cookie-banner {
    z-index: 95;
}

/* =============================================
   PHASE 2: CURSOR RESTORATION IN OPEN MODALS
   Since html { cursor: none } hides the OS
   cursor globally, visible modals need it
   restored so users can interact with forms.
   ============================================= */

/* Restore native cursor inside all open modals */
.modal-overlay.show *,
#quote-modal.flex *,
#success-popup.flex *,
#description-modal.flex *,
#validation-modal:not(.opacity-0) * {
    cursor: auto;
}

/* Keep pointer for clickable items inside modals */
.modal-overlay.show a,
.modal-overlay.show button,
#quote-modal.flex a,
#quote-modal.flex button,
#success-popup.flex button,
#description-modal.flex button {
    cursor: pointer;
}

/* =============================================
   PHASE 2: BUTTON HOVER OVERRIDE
   All bg-black buttons with hover:bg-gray-800
   class should go to dark blue instead.
   This uses high specificity to win over
   Tailwind's JIT hover:bg-gray-800.
   ============================================= */

/* Override hover:bg-gray-800 on buttons/anchors with bg-black */
a.bg-black.hover\:bg-gray-800:hover,
button.bg-black.hover\:bg-gray-800:hover,
.bg-black.hover\:bg-gray-800:hover {
    background-color: #1e40af !important;
    border-color: #1e40af !important;
}

/* Override hover:bg-blue-600 buttons to use our dark blue */
.bg-black.hover\:bg-blue-600:hover {
    background-color: #1e40af !important;
    border-color: #1e40af !important;
}

/* ============================================================
   PHASE 12 — GLOBAL SEARCH, QUOTE CART & INTERACTIVE UI
   ============================================================ */

/* ──────────────────────────────────────────────────────────────
   1. HEADER SEARCH BAR
   ────────────────────────────────────────────────────────────── */
.search-form-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

/* Toggle button (magnifier icon, collapsed) */
.search-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: transparent;
    border: none;
    color: #1a1a1a;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
}

.search-toggle-btn:hover {
    background: rgba(0, 0, 0, 0.06);
}

/* Input wrap — hidden by default, shown when .expanded
   Uses absolute positioning so it overlays without shifting nav links */
.search-input-wrap {
    display: none;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    padding: 0 14px;
    height: 38px;
    width: 280px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.2s, border-color 0.2s;
    position: absolute;
    top: 50%;
    right: 0;
    transform: translateY(-50%);
    z-index: 10;
}

.search-form-wrap.expanded .search-input-wrap {
    display: flex;
}

.search-form-wrap.expanded .search-toggle-btn {
    display: none;
}

.search-input-wrap:focus-within {
    border-color: rgba(0, 0, 0, 0.3);
    box-shadow: 0 6px 32px rgba(0, 0, 0, 0.13);
}

.search-icon {
    color: #94a3b8;
    font-size: 12px;
    flex-shrink: 0;
}

.search-input-wrap #search-input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    font-size: 13px;
    color: #1a1a1a;
    font-weight: 500;
    padding: 0;
    min-width: 0;
    border-radius: 0 !important;
    /* override global 12px */
}

.search-input-wrap #search-input::placeholder {
    color: #94a3b8;
    font-weight: 400;
}

.search-clear-btn {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 11px;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    flex-shrink: 0;
    transition: color 0.15s;
}

.search-clear-btn:hover {
    color: #1a1a1a;
}

/* Results Dropdown */
.search-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 380px;
    max-height: 480px;
    overflow-y: auto;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(20px) saturate(200%);
    -webkit-backdrop-filter: blur(20px) saturate(200%);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15), 0 4px 16px rgba(0, 0, 0, 0.08);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px) scale(0.98);
    transform-origin: top right;
    transition: opacity 0.18s ease, visibility 0.18s ease, transform 0.18s ease;
    z-index: 200;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.15) transparent;
}

.search-dropdown.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.search-dropdown::-webkit-scrollbar {
    width: 4px;
}

.search-dropdown::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
    border-radius: 4px;
}

/* Result items */
.search-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    text-decoration: none;
    color: inherit;
    transition: background 0.12s;
    cursor: pointer;
}

.search-result-item:last-of-type {
    border-bottom: none;
}

.search-result-item:hover,
.search-result-item.active {
    background: rgba(0, 0, 0, 0.04);
}

.search-result-item:first-child {
    border-radius: 20px 20px 0 0;
}

.search-result-thumb {
    width: 48px;
    height: 48px;
    object-fit: contain;
    border-radius: 10px;
    background: #f3f4f6;
    flex-shrink: 0;
    padding: 4px;
}

.search-result-thumb-ph {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d1d5db;
    font-size: 18px;
    flex-shrink: 0;
}

.search-result-info {
    flex: 1;
    min-width: 0;
}

.search-result-name {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #111827;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-result-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 3px;
    flex-wrap: wrap;
}

.search-result-badge {
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    background: #000;
    color: #fff;
    padding: 1px 6px;
    border-radius: 999px;
}

.search-result-cat {
    font-size: 10px;
    color: #6b7280;
    font-weight: 500;
}

.search-result-arrow {
    color: #d1d5db;
    font-size: 11px;
    transition: color 0.15s, transform 0.15s;
}

.search-result-item:hover .search-result-arrow,
.search-result-item.active .search-result-arrow {
    color: #1a1a1a;
    transform: translateX(3px);
}

mark.search-highlight {
    background: #fef08a;
    color: #1a1a1a;
    border-radius: 2px;
    padding: 0 1px;
}

.search-view-all {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 16px;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #6b7280;
    text-decoration: none;
    border-top: 1px solid rgba(0, 0, 0, 0.07);
    border-radius: 0 0 20px 20px;
    transition: background 0.12s, color 0.12s;
}

.search-view-all:hover {
    background: rgba(0, 0, 0, 0.04);
    color: #1a1a1a;
}

.search-no-results,
.search-loading {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 20px 16px;
    font-size: 13px;
    color: #6b7280;
    font-weight: 500;
}

.search-no-results {
    flex-direction: column;
    text-align: center;
    padding: 28px 16px;
    gap: 8px;
}

.search-no-results i {
    font-size: 24px;
    color: #d1d5db;
}

/* Mobile search inside mobile menu */
.mobile-search-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
    padding: 0 8px;
    background: rgba(0, 0, 0, 0.04);
    border-radius: 999px;
    height: 42px;
}

.mobile-search-wrap i {
    color: #94a3b8;
    font-size: 13px;
    padding-left: 4px;
}

.mobile-search-wrap input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    font-size: 14px;
    color: #1a1a1a;
    border-radius: 0 !important;
}

/* ──────────────────────────────────────────────────────────────
   2. HEADER CART ICON BUTTON
   ────────────────────────────────────────────────────────────── */
.header-cart-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: transparent;
    border: 1.5px solid rgba(0, 0, 0, 0.12);
    color: #1a1a1a;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, transform 0.15s;
    flex-shrink: 0;
}

.header-cart-btn:hover {
    background: rgba(0, 0, 0, 0.06);
    border-color: rgba(0, 0, 0, 0.25);
}

.header-cart-btn:active {
    transform: scale(0.95);
}

.header-cart-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    background: #ef4444;
    color: white;
    border-radius: 999px;
    font-size: 9px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid white;
    animation: badgePop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes badgePop {
    0% {
        transform: scale(0);
    }

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

/* ──────────────────────────────────────────────────────────────
   3. FLOATING CART FAB (always visible, bottom-right)
   ────────────────────────────────────────────────────────────── */
#stc-cart-fab {
    position: fixed;
    right: 1.5rem;
    bottom: 2rem;
    z-index: 95;
    transition: transform 0.2s;
}

#stc-cart-fab:hover {
    transform: translateY(-2px);
}

#stc-cart-btn {
    position: relative;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #111827;
    color: white;
    border: none;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.22), 0 2px 8px rgba(0, 0, 0, 0.14);
    transition: background 0.2s, box-shadow 0.2s;
}

#stc-cart-btn:hover {
    background: #1e40af;
}

#stc-cart-fab.has-items #stc-cart-btn {
    background: #1e40af;
}

.stc-cart-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 20px;
    height: 20px;
    background: #ef4444;
    color: white;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid white;
    animation: badgePop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ──────────────────────────────────────────────────────────────
   4. CART MODAL / DRAWER
   ────────────────────────────────────────────────────────────── */
#stc-cart-modal {
    position: fixed;
    inset: 0;
    z-index: 500;
    pointer-events: none;
    visibility: hidden;
    display: flex;
    justify-content: flex-end;
}

#stc-cart-modal.open {
    pointer-events: auto;
    visibility: visible;
}

/* Backdrop */
.stc-cart-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    transition: background 0.3s ease;
    cursor: pointer;
}

#stc-cart-modal.open .stc-cart-backdrop {
    background: rgba(0, 0, 0, 0.4);
}

/* Slide-in panel */
.stc-cart-panel {
    position: relative;
    width: 100%;
    max-width: 480px;
    height: 100%;
    background: white;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -8px 0 48px rgba(0, 0, 0, 0.18);
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.12) transparent;
}

#stc-cart-modal.open .stc-cart-panel {
    transform: translateX(0);
}

.stc-cart-panel::-webkit-scrollbar {
    width: 4px;
}

.stc-cart-panel::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.12);
    border-radius: 4px;
}

@media (max-width: 540px) {
    .stc-cart-panel {
        max-width: 100%;
    }
}

/* Panel Header */
.stc-cart-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 28px 24px 20px;
    border-bottom: 1px solid #f3f4f6;
    position: sticky;
    top: 0;
    background: white;
    z-index: 2;
}

.stc-cart-title {
    font-size: 20px;
    font-weight: 800;
    color: #111827;
    letter-spacing: -0.02em;
    margin: 0;
}

.stc-cart-subtitle {
    font-size: 12px;
    color: #6b7280;
    font-weight: 500;
    margin-top: 2px;
}

.stc-cart-close {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f3f4f6;
    border: none;
    color: #6b7280;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s, color 0.15s;
}

.stc-cart-close:hover {
    background: #e5e7eb;
    color: #111827;
}

/* Items list */
.stc-cart-items {
    padding: 8px 0;
    overflow-y: auto;
    max-height: 60vh;
    overscroll-behavior: contain;
}

.stc-cart-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 24px;
    border-bottom: 1px solid #f9fafb;
    transition: background 0.12s;
}

.stc-cart-item:hover {
    background: #fafafa;
}

.stc-cart-item-img {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.stc-cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 4px;
}

.stc-cart-item-img i {
    font-size: 20px;
    color: #d1d5db;
}

.stc-cart-item-info {
    flex: 1;
    min-width: 0;
}

.stc-cart-item-name {
    font-size: 13px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 3px;
    line-height: 1.3;
}

.stc-cart-item-meta {
    font-size: 11px;
    color: #6b7280;
    margin: 0;
}

.stc-cart-item-variant {
    display: inline-block;
    margin-top: 4px;
    font-size: 9px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #2563eb;
    background: #eff6ff;
    padding: 2px 6px;
    border-radius: 4px;
}

.stc-cart-item-remove {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: none;
    border: none;
    color: #d1d5db;
    font-size: 11px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.15s, color 0.15s;
}

.stc-cart-item-remove:hover {
    background: #fee2e2;
    color: #ef4444;
}

/* Empty state */
.stc-cart-empty {
    padding: 60px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
}

.stc-cart-empty-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: #d1d5db;
}

.stc-cart-empty-title {
    font-size: 16px;
    font-weight: 700;
    color: #111827;
    margin: 0;
}

.stc-cart-empty-sub {
    font-size: 13px;
    color: #6b7280;
    margin: 0;
    max-width: 260px;
    line-height: 1.5;
}

/* Inquiry form */
.stc-cart-form-wrap {
    padding: 0 24px 32px;
}

.stc-cart-divider {
    height: 1px;
    background: #f3f4f6;
    margin: 16px 0 20px;
}

.stc-cart-form-title {
    font-size: 14px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 16px;
}

.stc-cart-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

@media (max-width: 400px) {
    .stc-cart-form-row {
        grid-template-columns: 1fr;
    }
}

.stc-cart-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 12px;
}

.stc-cart-field label {
    font-size: 11px;
    font-weight: 700;
    color: #374151;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.stc-cart-field label span {
    color: #ef4444;
}

.stc-cart-field input,
.stc-cart-field textarea {
    border: 1px solid #e5e7eb;
    border-radius: 10px !important;
    padding: 9px 12px;
    font-size: 13px;
    color: #111827;
    background: white;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
    resize: vertical;
}

.stc-cart-field input:focus,
.stc-cart-field textarea:focus {
    border-color: #1e40af;
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

.stc-field-err {
    font-size: 11px;
    color: #ef4444;
    font-weight: 500;
}

.stc-field-err.hidden {
    display: none;
}

/* Consent */
.stc-cart-consent {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 12px;
    background: #f8fafc;
    border-radius: 10px;
    margin-bottom: 10px;
    border: 1px solid transparent;
    transition: border-color 0.2s;
}

.stc-cart-consent.has-error {
    border-color: #fca5a5;
    background: #fff1f2;
}

.stc-cart-consent input[type="checkbox"] {
    flex-shrink: 0;
    margin-top: 2px;
    accent-color: #1e40af;
}

.stc-cart-consent label {
    font-size: 12px;
    color: #374151;
    line-height: 1.5;
    cursor: pointer;
}

.stc-cart-consent label a {
    color: #2563eb;
    text-decoration: none;
}

.stc-cart-consent label a:hover {
    text-decoration: underline;
}

.stc-cart-consent label span {
    color: #ef4444;
}

.stc-consent-err {
    font-size: 11px;
    color: #ef4444;
    margin-bottom: 10px;
}

/* Cart alert */
.stc-cart-alert {
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 500;
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fca5a5;
    margin-bottom: 12px;
}

.stc-cart-alert.hidden {
    display: none;
}

/* Submit button */
.stc-cart-submit {
    width: 100%;
    background: #111827;
    color: white;
    border: none;
    border-radius: 999px !important;
    padding: 14px 24px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s, transform 0.15s;
    margin-top: 4px;
}

.stc-cart-submit:hover {
    background: #1e40af;
}

.stc-cart-submit:active {
    transform: scale(0.98);
}

.stc-cart-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Success state */
.stc-cart-success {
    padding: 60px 32px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 16px;
}

.stc-cart-success.hidden {
    display: none !important;
}

.stc-cart-success-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: #059669;
    animation: successBounce 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes successBounce {
    0% {
        transform: scale(0);
        opacity: 0;
    }

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

.stc-cart-success h3 {
    font-size: 22px;
    font-weight: 800;
    color: #111827;
    margin: 0;
}

.stc-cart-success p {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.6;
    margin: 0;
    max-width: 300px;
}

.stc-cart-success button {
    background: #111827;
    color: white;
    border: none;
    border-radius: 999px;
    padding: 12px 32px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.2s;
}

.stc-cart-success button:hover {
    background: #1e40af;
}

/* hidden utility for cart elements */
#stc-cart-empty.hidden,
#stc-cart-form-wrap.hidden,
#stc-cart-success.hidden {
    display: none !important;
}

/* ──────────────────────────────────────────────────────────────
   5. "ADD TO QUOTE CART" BUTTON  (product detail page)
   ────────────────────────────────────────────────────────────── */
#add-to-cart-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 15px 28px;
    background: #111827;
    color: white;
    border: none;
    border-radius: 999px !important;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.15);
    margin-bottom: 8px;
}

#add-to-cart-btn:hover {
    background: #1e40af;
    box-shadow: 0 8px 32px rgba(30, 64, 175, 0.3);
}

#add-to-cart-btn:active {
    transform: scale(0.98);
}

/* "In cart" state — green tint */
#add-to-cart-btn.in-cart {
    background: #059669;
    box-shadow: 0 4px 24px rgba(5, 150, 105, 0.25);
}

#add-to-cart-btn.in-cart:hover {
    background: #047857;
}

/* Bounce micro-animation on add */
#add-to-cart-btn.bounce {
    animation: cartBounce 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes cartBounce {
    0% {
        transform: scale(1);
    }

    40% {
        transform: scale(1.06);
    }

    70% {
        transform: scale(0.97);
    }

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

/* ──────────────────────────────────────────────────────────────
   6.  Z-INDEX ASSIGNMENTS (Phase 12 additions)
   ────────────────────────────────────────────────────────────── */
#stc-cart-modal {
    z-index: 500;
}

/* above everything */
#stc-cart-fab {
    z-index: 95;
}

/* above scroll progress */
.search-dropdown {
    z-index: 200;
}

/* above header content */

/* ──────────────────────────────────────────────────────────────
   7. GLOBAL COMMAND PALETTE SEARCH (Phase 16)
   ────────────────────────────────────────────────────────────── */
:root {
    --cmdk-bg-modal: #ffffff;
    --cmdk-bg-modal-hover: #f9fafb;
    --cmdk-border-color: #f3f4f6;
    --cmdk-border-highlight: #e5e7eb;
    --cmdk-accent: #3b82f6;
    --cmdk-accent-muted: #eff6ff;
    --cmdk-text-primary: #111827;
    --cmdk-text-secondary: #6b7280;
    --cmdk-text-muted: #9ca3af;
    --cmdk-font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --cmdk-font-mono: ui-monospace, SFMono-Regular, monospace;
}

.cmdk-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 10vh;
    z-index: 9000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.cmdk-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

.cmdk-modal {
    width: 100%;
    max-width: 860px;
    height: 520px;
    background: var(--cmdk-bg-modal);
    border: 1px solid var(--cmdk-border-color);
    border-radius: 12px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.15), 0 4px 16px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: scale(0.96) translateY(20px);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
    opacity: 0;
}

.cmdk-overlay.is-open .cmdk-modal {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.cmdk-header {
    padding: 16px 24px;
    border-bottom: 1px solid var(--cmdk-border-color);
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--cmdk-bg-modal);
    z-index: 2;
}

.cmdk-header svg {
    width: 20px;
    height: 20px;
    color: var(--cmdk-text-secondary);
}

.cmdk-input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--cmdk-text-primary);
    font-family: var(--cmdk-font-sans);
    font-size: 18px;
    outline: none;
    padding: 4px 0;
}

.cmdk-input::placeholder {
    color: var(--cmdk-text-muted);
}

.cmdk-body {
    display: flex;
    flex: 1;
    min-height: 0;
}

.cmdk-sidebar {
    width: 220px;
    border-right: 1px solid var(--cmdk-border-color);
    display: flex;
    flex-direction: column;
    padding: 12px 0;
    background: #fdfdfd;
    overflow-y: auto;
}

.cmdk-sidebar::-webkit-scrollbar {
    display: none;
}

.cmdk-sidebar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.filter-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 20px;
    color: var(--cmdk-text-secondary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border-left: 2px solid transparent;
    transition: all 0.2s ease;
    user-select: none;
    font-family: var(--cmdk-font-sans);
}

.filter-item:hover {
    background: var(--cmdk-bg-modal-hover);
    color: var(--cmdk-text-primary);
}

.filter-item.is-active {
    color: var(--cmdk-text-primary);
    background: var(--cmdk-bg-modal-hover);
    border-left-color: var(--cmdk-accent);
}

.filter-count {
    font-family: var(--cmdk-font-mono);
    font-size: 11px;
    color: var(--cmdk-text-muted);
    background: rgba(0, 0, 0, 0.05);
    padding: 2px 6px;
    border-radius: 4px;
}

.filter-item.is-active .filter-count {
    color: var(--cmdk-accent);
    background: var(--cmdk-accent-muted);
}

.cmdk-results {
    flex: 1;
    padding: 12px;
    overflow-y: auto;
    position: relative;
}

.cmdk-results::-webkit-scrollbar {
    width: 8px;
}

.cmdk-results::-webkit-scrollbar-track {
    background: transparent;
}

.cmdk-results::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}

.cmdk-results::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.2);
}

.result-group {
    margin-bottom: 20px;
}

.result-group-label {
    font-family: var(--cmdk-font-mono);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--cmdk-text-muted);
    padding: 8px 12px;
    margin-bottom: 4px;
    position: sticky;
    top: -12px;
    background: var(--cmdk-bg-modal);
    z-index: 1;
}

.result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.1s ease;
    position: relative;
    text-decoration: none;
}

.result-item[aria-selected="true"] {
    background: var(--cmdk-bg-modal-hover);
}

.result-item[aria-selected="true"]::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10%;
    height: 80%;
    width: 2px;
    background: var(--cmdk-accent);
    border-radius: 0 4px 4px 0;
}

.result-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.04);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--cmdk-text-secondary);
    flex-shrink: 0;
}

.result-item[aria-selected="true"] .result-icon {
    color: var(--cmdk-text-primary);
    background: rgba(0, 0, 0, 0.08);
}

.result-content {
    flex: 1;
    min-width: 0;
}

.result-title {
    font-family: var(--cmdk-font-sans);
    font-size: 14px;
    font-weight: 500;
    color: var(--cmdk-text-primary);
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.result-desc {
    font-family: var(--cmdk-font-sans);
    margin-top: 0;
    margin-bottom: 0;
    font-size: 13px;
    color: var(--cmdk-text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.result-badge {
    font-family: var(--cmdk-font-mono);
    font-size: 10px;
    padding: 3px 6px;
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.05);
    color: var(--cmdk-text-muted);
    flex-shrink: 0;
}

.result-item mark {
    background: rgba(59, 130, 246, 0.1);
    /* blue-500 tint */
    color: var(--cmdk-accent);
    font-weight: 600;
    border-radius: 2px;
    padding: 0 2px;
}

.cmdk-empty,
.cmdk-initial {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--cmdk-text-muted);
    text-align: center;
}

.cmdk-empty svg {
    width: 40px;
    height: 40px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.cmdk-initial h4 {
    font-size: 13px;
    font-weight: 500;
    color: var(--cmdk-text-secondary);
    margin-bottom: 16px;
    font-family: var(--cmdk-font-sans);
}

.hint-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 300px;
}

.hint-chip {
    background: rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(0, 0, 0, 0.05);
    color: var(--cmdk-text-secondary);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: var(--cmdk-font-sans);
}

.hint-chip:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--cmdk-text-primary);
    border-color: rgba(0, 0, 0, 0.1);
}

.cmdk-footer {
    padding: 12px 24px;
    border-top: 1px solid var(--cmdk-border-color);
    display: flex;
    align-items: center;
    gap: 16px;
    background: #fdfdfd;
}

.shortcut-group {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--cmdk-text-muted);
    font-family: var(--cmdk-font-sans);
    font-size: 12px;
}

.shortcut-key {
    font-family: var(--cmdk-font-mono);
    background: rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-bottom-width: 2px;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    color: var(--cmdk-text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
}