/* ===========================
   CLEAN MINIMALIST NAVBAR - TABBED EMAPI MENU VERSION
   =========================== */

   :root {
    --navbar-bg: rgba(255, 255, 255, 0.98);
    /*--navbar-bg: rgba(0, 0, 0, 0.04);*/
    --navbar-height: 80px;
    --navbar-scrolled-height: 70px;
    --primary-color: #0b0b0b;
    --muted-color: #6b6b6b;
    --primary-red-color: #CC0000;
    --border-color: rgba(0, 0, 0, 0.08);
    --shadow-light: 0 4px 12px rgba(0, 0, 0, 0.05);
    --shadow-medium: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-heavy: 0 15px 40px rgba(0, 0, 0, 0.15);
    --transition-fast: 0.2s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --z-overlay: 899;
    --z-navbar: 1000;
    --z-emapi: 1100;
    --z-mobile-emapi: 1200;
}

/* ===========================
   RESET AND BASE STYLES
   =========================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--primary-color);
    padding-top: var(--navbar-height);
    transition: padding-top var(--transition-base);
    overflow-x: hidden;
}

/* ===========================
   NAVBAR - ALWAYS VISIBLE
   =========================== */
#mainNavbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--navbar-height);
    background: var(--navbar-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: var(--z-navbar);
    transition: all var(--transition-base);
    box-shadow: var(--shadow-light);
}

#mainNavbar.scrolled {
    height: var(--navbar-scrolled-height);
    box-shadow: var(--shadow-medium);
}

/* ===========================
   NAV CONTAINER & LOGO
   =========================== */
.nav-container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    padding: 0 48px;
}

.navbar-brand {
    text-decoration: none;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    transition: opacity var(--transition-fast);
}

.navbar-brand:hover {
    opacity: 0.9;
}

.logo-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.logo-img {
    /*height: 38px;*/
    height: 44px;
    width: auto;
    transition: transform var(--transition-base);
}

.navbar-brand:hover .logo-img {
    transform: scale(1.02);
}

.since-text {
    font-size: 0.75rem;
    color: var(--muted-color);
    font-weight: 400;
    font-style: italic;
    letter-spacing: 0.3px;
    white-space: nowrap;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 3px 0 0 3px;
    transition: color var(--transition-fast);
}

.year-text {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-color);
}

/* ===========================
   NAVIGATION MENU - MAIN NAV ITEMS
   =========================== */
.nav-menu {
    display: flex;
    align-items: center;
    margin-left: auto;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-right: 20px;
}

.nav-links .nav-link {
    margin-right: 0;
    position: relative;
}

.nav-link {
    text-decoration: none;
    color: #515154;
    font-weight: 400;
    font-size: 0.875rem;
    letter-spacing: -0.01em;
    transition: color 0.2s ease;
    padding: 8px 10px;
    white-space: nowrap;
    display: block;
    cursor: pointer;
    position: relative;
    border-radius: 6px;
}

.nav-link:hover {
    color: #1d1d1f;
    background: rgba(0, 0, 0, 0.04);
}

/* Subtle bottom indicator — active only */
.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1.5px;
    bottom: 2px;
    left: 50%;
    background: var(--primary-red-color);
    transition: width 0.2s ease;
    transform: translateX(-50%);
    border-radius: 2px;
}

.nav-link:hover::after {
    width: 0;
}

.nav-link.active {
    color: var(--primary-red-color);
    font-weight: 500;
}

.nav-link.active::after {
    width: 60%;
}

/* Products dropdown arrow */
.dropdown-arrow {
    font-size: 0.8rem;
    margin-left: 5px;
    transition: transform var(--transition-base);
}

.nav-item.dropdown.active .dropdown-arrow {
    transform: rotate(180deg);
}


/* ===========================
   ABOUT US SELECTOR
   =========================== */
.about-selector {
    position: relative;
}

.about-toggle {
    display: flex;
    align-items: center;
    background: none;
    border: none;
    color: #515154;
    font-size: 0.875rem;
    font-weight: 400;
    letter-spacing: -0.01em;
    cursor: pointer;
    padding: 8px 10px;
    border-radius: 6px;
    transition: color 0.2s ease, background 0.2s ease;
}

.about-toggle:hover {
    color: #1d1d1f;
    background: rgba(0, 0, 0, 0.04);
}

.about-left {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.about-icon {
    font-size: 1.1rem;
    line-height: 1;
}

.about-selector .dropdown-arrow {
    font-size: 0.8rem;
    margin-left: 8px;
    transition: transform var(--transition-base);
}

.about-selector.active .dropdown-arrow {
    transform: rotate(180deg);
}

.about-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 8px;
    box-shadow: var(--shadow-medium);
    padding: 8px 0;
    min-width: 150px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition-base);
    border: 1px solid var(--border-color);
    z-index: 1001;
    overflow: hidden;
}

.about-selector.active .about-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(5px);
}

.about-option {
    display: block;
    padding: 10px 20px;
    text-decoration: none;
    color: var(--muted-color);
    font-size: 0.875rem;
    transition: all var(--transition-fast);
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    position: relative;
}

.about-option::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: var(--primary-red-color);
    transform: scaleX(0);
    transition: transform var(--transition-fast);
}

.about-option:hover {
    background: rgba(0, 0, 0, 0.04);
    color: var(--primary-color);
    padding-left: 25px;
}

.about-option:hover::before {
    transform: scaleX(1);
}

/* ===========================
   RESOURCES & TIPS MEGA-DROPDOWN
   =========================== */
.resources-selector {
    position: static;
}

.resources-toggle {
    display: flex;
    align-items: center;
    background: none;
    border: none;
    color: #515154;
    font-size: 0.875rem;
    font-weight: 400;
    letter-spacing: -0.01em;
    cursor: pointer;
    padding: 8px 10px;
    border-radius: 6px;
    gap: 4px;
    transition: color 0.2s ease, background 0.2s ease;
    white-space: nowrap;
}

.resources-toggle:hover,
.resources-selector.active .resources-toggle {
    color: #1d1d1f;
    background: rgba(0, 0, 0, 0.04);
}

.resources-selector .dropdown-arrow {
    font-size: 0.8rem;
    transition: transform var(--transition-base);
}
.resources-selector.active .dropdown-arrow {
    transform: rotate(180deg);
}

.resources-mega {
    position: fixed;
    top: var(--navbar-height);
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
    pointer-events: none;
}

.resources-selector.active .resources-mega {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.resources-mega-inner {
    max-width: 960px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    padding: 24px 20px 20px;
}

.res-col {
    padding: 0 20px 0 0;
    border-right: 1px solid #f0f0f0;
}
.res-col:last-child {
    border-right: none;
    padding-left: 20px;
    padding-right: 0;
}
.res-col:not(:first-child) {
    padding-left: 20px;
}

.res-col-heading {
    display: block;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #86868b;
    padding: 0 10px 10px;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 6px;
}

.res-item {
    display: flex;
    align-items: flex-start;
    padding: 9px 10px;
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.12s ease;
}

.res-item:hover {
    background: #f5f5f7;
}

.res-item-body {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.res-item-title {
    font-size: 0.86rem;
    font-weight: 600;
    color: #1d1d1f;
    line-height: 1.3;
}

.res-item-desc {
    font-size: 0.72rem;
    color: #86868b;
    line-height: 1.4;
}

.res-item:hover .res-item-title {
    color: #c0272d;
}

/* ===========================
   LANGUAGE SELECTOR
   =========================== */
.language-selector {
    position: relative;
}

.language-toggle {
    display: flex;
    align-items: center;
    background: none;
    border: none;
    color: #515154;
    font-size: 0.875rem;
    font-weight: 400;
    letter-spacing: -0.01em;
    cursor: pointer;
    padding: 8px 10px;
    border-radius: 6px;
    transition: color 0.2s ease, background 0.2s ease;
}

.language-toggle:hover {
    color: #1d1d1f;
    background: rgba(0, 0, 0, 0.04);
}

.language-left {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.language-icon {
    font-size: 1.1rem;
    line-height: 1;
}

.language-selector .dropdown-arrow {
    font-size: 0.8rem;
    margin-left: 8px;
    transition: transform var(--transition-base);
}

.language-selector.active .dropdown-arrow {
    transform: rotate(180deg);
}

.language-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 8px;
    box-shadow: var(--shadow-medium);
    padding: 8px 0;
    min-width: 150px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition-base);
    border: 1px solid var(--border-color);
    z-index: 1001;
    overflow: hidden;
}

.language-selector.active .language-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(5px);
}

.language-option {
    display: block;
    padding: 10px 20px;
    text-decoration: none;
    color: var(--muted-color);
    font-size: 0.875rem;
    transition: all var(--transition-fast);
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    position: relative;
}

.language-option::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: var(--primary-red-color);
    transform: scaleX(0);
    transition: transform var(--transition-fast);
}

.language-option:hover {
    background: rgba(0, 0, 0, 0.04);
    color: var(--primary-color);
    padding-left: 25px;
}

.language-option:hover::before {
    transform: scaleX(1);
}

/* ===========================
   HAMBURGER TOGGLE
   =========================== */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    margin-left: auto;
    transition: transform var(--transition-fast);
    z-index: 1001;
}

.nav-toggle:hover {
    transform: scale(1.1);
}

.hamburger {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    position: relative;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--primary-color);
    border-radius: 2px;
    transition: all var(--transition-base);
    transform-origin: center;
}

.nav-toggle.active .hamburger span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active .hamburger span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.nav-toggle.active .hamburger span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* ===========================
   DESKTOP EMAPI MENU (FIXED TO MATCH PHP STRUCTURE)
   =========================== */
.nav-item.dropdown {
    position: static;
}

.nav-item.dropdown .emapi-menu {
    position: absolute;
    top: var(--navbar-height);
    left: 0;
    width: 100%;
    background: #fff;
    box-shadow: var(--shadow-heavy);
    border-top: 3px solid var(--primary-red-color);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: var(--z-emapi);
    border-radius: 0 0 16px 16px;
    transform: translateY(-20px);
}

#mainNavbar.scrolled .nav-item.dropdown .emapi-menu {
    top: var(--navbar-scrolled-height);
}

.nav-item.dropdown.active .emapi-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.emapi-menu-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 30px;
}

/*
 * DESKTOP: flex-wrap + CSS order puts all buttons on row 1,
 * all tab-content panels on row 2 (only active panel visible).
 * MOBILE: natural DOM order = button → panel → button → panel (accordion).
 */
.emapi-tabs-accordion {
    display: flex;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 0;
    gap: 0;
}

/* All tab buttons sit on row 1 */
.emapi-tabs-accordion .tab-button {
    order: 1;
}

/* All panels sit on row 2, full width, hidden by default */
.emapi-tabs-accordion .tab-content {
    order: 2;
    width: 100%;
    display: none;
    padding-top: 25px;
}

.emapi-tabs-accordion .tab-content.active {
    display: block;
}

.tab-button {
    padding: 12px 24px 12px 28px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--muted-color);
    cursor: pointer;
    transition: all var(--transition-base);
    border-radius: 6px 6px 0 0;
    white-space: nowrap;
    position: relative;
}

.tab-button:hover {
    color: var(--primary-color);
    background: rgba(0, 0, 0, 0.02);
}

.tab-button.active {
    color: var(--primary-red-color);
    border-bottom-color: var(--primary-red-color);
    background: rgba(220, 53, 69, 0.05);
}

/* Active tab indicator dot */
.tab-button.active::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 8px;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    background: var(--primary-red-color);
    border-radius: 50%;
    animation: blink 1.5s ease-in-out infinite;
}

@keyframes blink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}

/* Legacy rule kept for safety — new structure uses .emapi-tabs-accordion */

.tab-columns {
    display: grid;
    grid-template-columns: 0.6fr 2fr 1.4fr;
    gap: 30px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 12px;
    padding: 25px;
    background: rgba(255, 255, 255, 0.5);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
}

.column-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

/* Subcategories Column */
.subcategory-list {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 500px;
    overflow-y: auto;
    padding-right: 5px;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
    transition: scrollbar-color 0.3s ease;
}

.subcategory-list:hover {
    scrollbar-color: rgba(0, 0, 0, 0.15) rgba(0, 0, 0, 0.03);
}

.subcategory-list li {
    margin-bottom: 4px;
}

.subcategory-link {
    display: block;
    padding: 10px 15px;
    color: var(--muted-color);
    text-decoration: none;
    border-radius: 6px;
    transition: all var(--transition-fast);
    font-size: 0.9rem;
    cursor: pointer;
}

.subcategory-link:hover,
.subcategory-link.active {
    background: #fff0f0;
    color: var(--primary-red-color);
    padding-left: 20px;
    border-left: 3px solid var(--primary-red-color);
}

/* Products Column */
.products-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding-right: 10px;
    max-height: 500px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
    transition: scrollbar-color 0.3s ease;
}

.products-grid:hover {
    scrollbar-color: rgba(0, 0, 0, 0.15) rgba(0, 0, 0, 0.03);
}

.product-card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 15px;
    transition: all var(--transition-base);
    cursor: pointer;
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 15px;
    align-items: start;
}

.product-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
    border-color: var(--primary-red-color);
}

.product-image {
    width: 120px;
    height: 120px;
    overflow: hidden;
    border-radius: 4px;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-base);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 6px;
    line-height: 1.3;
}

.product-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-description {
    font-size: 0.8rem;
    color: var(--muted-color);
    line-height: 1.4;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-features {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: auto;
}

.feature-tag {
    background: rgba(220, 53, 69, 0.1);
    color: var(--primary-red-color);
    font-size: 0.7rem;
    padding: 3px 8px;
    border-radius: 12px;
    white-space: nowrap;
}

/* Product Details Column */
.product-details {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    max-height: 500px;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: transparent transparent;
    transition: scrollbar-color 0.3s ease;
}

.product-details:hover {
    scrollbar-color: rgba(0, 0, 0, 0.15) rgba(0, 0, 0, 0.03);
}

.product-detail-card {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.detail-image {
    width: 100%;
    height: 160px;
    overflow: hidden;
    border-radius: 6px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.detail-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 8px;
}

.detail-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.detail-description {
    font-size: 0.9rem;
    color: var(--muted-color);
    line-height: 1.5;
    margin-bottom: 15px;
}

.detail-features {
    margin-bottom: 15px;
}

.detail-features h5 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.detail-features ul {
    list-style: none;
    padding: 0;
}

.detail-features li {
    font-size: 0.85rem;
    color: var(--muted-color);
    padding: 4px 0;
    padding-left: 16px;
    position: relative;
}

.detail-features li::before {
    content: '•';
    color: var(--primary-red-color);
    position: absolute;
    left: 0;
}

.detail-link {
    display: inline-block;
    margin-top: 15px;
    color: var(--primary-red-color);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.detail-link:hover {
    transform: translateX(5px);
}

.placeholder-message {
    text-align: center;
    color: var(--muted-color);
    padding: 40px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.placeholder-message p {
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 15px;
}

.placeholder-message.error {
    color: var(--primary-red-color);
}

.retry-btn {
    background: var(--primary-red-color);
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 4px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.retry-btn:hover {
    background: #c82333;
    transform: translateY(-2px);
}

/* ===========================
   OVERLAY
   =========================== */
.emapi-menu-overlay {
    position: fixed;
    top: var(--navbar-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--navbar-height));
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: var(--z-overlay);
}

#mainNavbar.scrolled ~ .emapi-menu-overlay,
#mainNavbar.scrolled + * .emapi-menu-overlay,
body.emapi-menu-open .emapi-menu-overlay {
    top: var(--navbar-scrolled-height);
    height: calc(100vh - var(--navbar-scrolled-height));
}

body.emapi-menu-open .emapi-menu-overlay {
    opacity: 1;
    visibility: visible;
}

/* ===========================
   MOBILE STYLES
   =========================== */

/* Tablet & Mobile (991px and below) */
@media (max-width: 991px) {
    body {
        padding-top: var(--navbar-scrolled-height);
    }
    
    #mainNavbar,
    #mainNavbar.scrolled {
        height: var(--navbar-scrolled-height);
    }
    
    .nav-container {
        padding: 0 20px;
    }
    
    .logo-img {
        /*height: 32px;*/
        height: 36px;
    }
    
    .since-text {
        font-size: 0.6rem;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-menu {
        display: none;
        position: fixed;
        top: var(--navbar-scrolled-height);
        left: 0;
        width: 100%;
        background: white;
        border-bottom: 1px solid var(--border-color);
        flex-direction: column;
        padding: 20px;
        box-shadow: var(--shadow-medium);
        max-height: calc(100vh - var(--navbar-scrolled-height));
        overflow-y: auto;
        z-index: var(--z-emapi);
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .nav-links {
        flex-direction: column;
        width: 100%;
        margin-bottom: 15px;
        margin-right: 0;
    }
    
    .nav-links .nav-link {
        margin-right: 0;
        padding: 12px 0;
        width: 100%;
        text-align: left;
        font-size: 1rem;
        border-bottom: 1px solid var(--border-color);
    }
    
    .nav-links .nav-link::after {
        display: none;
    }
    
    /* ===== MOBILE ACCORDION DROPDOWN ===== */
    .nav-item.dropdown {
        position: relative;
        width: 100%;
    }

    /* "Productos" row — arrow rotates when open */
    .nav-item.dropdown .nav-link {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .nav-item.dropdown .nav-link .dropdown-arrow {
        transition: transform 0.25s ease;
        font-style: normal;
        font-size: 1rem;
    }

    .nav-item.dropdown.active .nav-link .dropdown-arrow {
        transform: rotate(180deg);
    }

    /* Emapi-menu becomes a flat accordion panel */
    .nav-item.dropdown .emapi-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: none;
        box-shadow: none;
        border-top: none;
        border-radius: 0;
        display: none;
        padding: 0;
        margin-top: 0;
        background: transparent;
    }

    .nav-item.dropdown.active .emapi-menu {
        display: block;
    }

    /* Hide the emapi-menu container padding on mobile */
    .emapi-menu-container {
        padding: 0;
    }

    /* ===== MOBILE ACCORDION — interleaved structure ===== */
    /* Cancel the desktop flex-order trick; use natural DOM order */
    .emapi-tabs-accordion {
        display: block;
        border-bottom: none;
    }

    .emapi-tabs-accordion .tab-button {
        order: unset;
    }

    .emapi-tabs-accordion .tab-content {
        order: unset;
        width: auto;
        padding-top: 0;
        display: none;
    }

    .emapi-tabs-accordion .tab-content.active {
        display: block;
    }

    .tab-button {
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        padding: 11px 16px 11px 20px;
        font-size: 0.95rem;
        font-weight: 600;
        color: #333;
        background: #f8f8f8;
        border: none;
        border-bottom: 1px solid var(--border-color);
        border-radius: 0;
        cursor: pointer;
        text-align: left;
    }

    .tab-button::after {
        content: '›';
        font-size: 1.2rem;
        font-weight: 400;
        color: #999;
        transition: transform 0.2s ease;
        display: inline-block;
    }

    .tab-button.active {
        color: var(--primary-red-color);
        background: #fff5f5;
        border-bottom-color: var(--primary-red-color);
    }

    .tab-button.active::after {
        transform: rotate(90deg);
        color: var(--primary-red-color);
    }

    /* Strip the desktop card look from tab-columns — flat on mobile */
    .tab-columns {
        display: block;
        border: none;
        border-radius: 0;
        padding: 0;
        background: none;
        box-shadow: none;
        gap: 0;
        min-height: auto;
    }

    .products-column,
    .product-details-column {
        display: none;
    }

    .subcategories-column {
        padding: 0;
    }

    .column-title {
        display: none;
    }

    .subcategory-list {
        margin: 0;
        padding: 0;
        list-style: none;
        background: white;
        border-bottom: 1px solid var(--border-color);
    }

    .subcategory-list li {
        border-bottom: 1px solid #f0f0f0;
    }

    .subcategory-list li:last-child {
        border-bottom: none;
    }

    .subcategory-link {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 10px 16px;
        font-size: 0.9rem;
        color: #555;
        text-decoration: none;
        transition: background 0.15s, color 0.15s;
    }

    .subcategory-link::after {
        content: '›';
        font-size: 1rem;
        color: #ccc;
    }

    .subcategory-link:hover,
    .subcategory-link.active {
        background: #fff5f5;
        color: var(--primary-red-color);
    }

    .subcategory-link.active::after {
        content: '↓';
        color: var(--primary-red-color);
    }

    /* ===== MOBILE INLINE PRODUCT PANEL ===== */
    .mobile-products-panel {
        display: none;
        background: #fafafa;
        border-top: 1px solid #eee;
    }

    .mobile-products-panel.open {
        display: block;
    }

    .mob-prods-loading {
        padding: 10px 20px;
        font-size: 0.85rem;
        color: #999;
    }

    .mob-prods-empty {
        padding: 10px 20px;
        font-size: 0.85rem;
        color: #999;
        margin: 0;
    }

    .mob-prod-list {
        list-style: none;
        margin: 0;
        padding: 6px 0;
    }

    .mob-prod-item {
        border-bottom: 1px solid #f0f0f0;
    }

    .mob-prod-item:last-child {
        border-bottom: none;
    }

    .mob-prod-link {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 8px 16px 8px 16px;
        text-decoration: none;
        color: #444;
        font-size: 0.85rem;
        gap: 10px;
        transition: background 0.15s, color 0.15s;
    }

    .mob-prod-link:hover {
        background: #fff5f5;
        color: var(--primary-red-color);
    }

    .mob-prod-img {
        width: 42px;
        height: 42px;
        object-fit: contain;
        border-radius: 4px;
        background: #fff;
        flex-shrink: 0;
        border: 1px solid #f0f0f0;
    }

    .mob-prod-name {
        flex: 1;
        line-height: 1.3;
    }

    .mob-prod-arrow {
        color: #ccc;
        font-size: 1rem;
    }

    .mob-prod-view-all {
        display: block;
        padding: 8px 16px 8px 24px;
        font-size: 0.82rem;
        color: var(--primary-red-color);
        text-decoration: none;
        font-weight: 600;
        border-top: 1px solid #eee;
    }

    .tab-columns {
        grid-template-columns: 1fr;
        gap: 20px;
        min-height: auto;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        max-height: none;
        overflow-y: visible;
    }
    
    .product-details {
        min-height: auto;
    }
    /* ===========================
       ABOUT US SECTION
    =========================== */
    .about {
        max-width: 1200px;
        margin: 60px auto;
        padding: 0 20px;
        text-align: center;
        color: var(--primary-color);
    }

    .about h2 {
        font-size: 2rem;
        font-weight: 700;
        margin-bottom: 20px;
    }

    .about p {
        font-size: 1rem;
        color: var(--muted-color);
        line-height: 1.6;
        margin-bottom: 15px;
    }

    .about .highlight {
        color: var(--primary-red-color);
        font-weight: 600;
    }

    .about img {
        max-width: 200px;
        margin: 20px auto;
        border-radius: 12px;
    }

    /* Active about us */
    .about.active { display: block; }

    
    /* Resources selector mobile */
    .resources-selector {
        width: 100%;
    }

    .resources-toggle {
        width: 100%;
        justify-content: space-between;
        padding: 12px 0;
        font-size: 1rem;
        border-bottom: 1px solid var(--border-color);
        border-radius: 0;
    }

    .resources-mega {
        position: static;
        box-shadow: none;
        background: rgba(0, 0, 0, 0.02);
        border: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        pointer-events: auto;
        display: none;
        backdrop-filter: none;
    }

    .resources-selector.active .resources-mega {
        display: block;
    }

    .resources-mega-inner {
        grid-template-columns: 1fr;
        padding: 4px 0 8px;
        gap: 0;
    }

    .res-col {
        padding: 0;
        border-right: none;
        border-bottom: 1px solid #f0f0f0;
        margin-bottom: 4px;
    }
    .res-col:last-child { border-bottom: none; }
    .res-col:not(:first-child) { padding-left: 0; }

    .res-col-heading {
        padding: 8px 4px 6px;
    }

    .res-item {
        padding: 9px 4px;
        border-radius: 6px;
    }

    /* About selector mobile */
    .about-selector {
        width: 100%;
    }

    .about-toggle {
        width: 100%;
        justify-content: space-between;
        padding: 12px 0;
        font-size: 1rem;
        border-bottom: 1px solid var(--border-color);
        border-radius: 0;
    }

    .about-dropdown {
        position: static;
        box-shadow: none;
        background: rgba(0, 0, 0, 0.02);
        margin-top: 8px;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none;
        width: 100%;
        border: none;
        border-radius: 0;
        backdrop-filter: none;
    }

    .about-selector.active .about-dropdown {
        display: block;
    }

    /* Language selector mobile */
    .language-selector {
        width: 100%;
    }
    
    .language-toggle {
        width: 100%;
        justify-content: space-between;
        padding: 12px 0;
        font-size: 1rem;
        border-bottom: 1px solid var(--border-color);
        border-radius: 0;
    }
    
    .language-dropdown {
        position: static;
        box-shadow: none;
        background: rgba(0, 0, 0, 0.02);
        margin-top: 8px;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none;
        width: 100%;
        border: none;
        border-radius: 0;
        backdrop-filter: none;
    }
    
    .language-selector.active .language-dropdown {
        display: block;
    }
    
    /* Overlay adjustments */
    .emapi-menu-overlay {
        top: var(--navbar-scrolled-height);
        height: calc(100vh - var(--navbar-scrolled-height));
    }
}

/* Tablet (768px to 991px) */
@media (min-width: 768px) and (max-width: 991px) {
    .nav-container {
        padding: 0 40px;
    }
    
    .nav-menu {
        padding: 30px 40px;
    }
    
    .emapi-menu-container {
        padding: 30px 40px;
    }
}

/* Mobile (767px and below) */
@media (max-width: 767px) {
    .nav-container {
        padding: 0 15px;
    }
    
    .nav-menu {
        padding: 20px;
    }
    
    .emapi-menu-container {
        padding: 15px;
    }
    
    .tab-columns {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 10px;
    }
    
    .product-card {
        padding: 12px;
    }
    
    .product-image {
        height: 100px;
    }
    
    .product-name {
        font-size: 0.85rem;
    }
}

/* ===========================
   ANIMATIONS
   =========================== */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nav-item.dropdown.active .emapi-menu {
    animation: slideDown 0.3s ease-out;
}

/* ===========================
   SCROLLBAR STYLING
   =========================== */
/* Column 1 - Subcategories */
.subcategory-list::-webkit-scrollbar {
    width: 5px;
}

.subcategory-list::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 2px;
}

.subcategory-list::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 2px;
    transition: background 0.3s ease;
}

.subcategory-list:hover::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.03);
}

.subcategory-list:hover::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
}

.subcategory-list::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.25);
}

/* Column 2 - Products */
.products-grid::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}

.products-grid::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 2px;
}

.products-grid::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 2px;
    transition: background 0.3s ease;
}

.products-grid:hover::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.03);
}

.products-grid:hover::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
}

.products-grid::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.25);
}

/* Column 3 - Product Details */
.product-details::-webkit-scrollbar {
    width: 5px;
}

.product-details::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 2px;
}

.product-details::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 2px;
    transition: background 0.3s ease;
}

.product-details:hover::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.03);
}

.product-details:hover::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
}

.product-details::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.25);
}

/* Tabs scrollbar */
.emapi-menu-tabs::-webkit-scrollbar {
    height: 3px;
}

.emapi-menu-tabs::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.03);
}

.emapi-menu-tabs::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
}

/* ===========================
   UTILITY CLASSES
   =========================== */
.hidden {
    display: none !important;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}
