/* Werkking Mega-Menu CSS — ausgelagert aus mega-menu.php inline-<style> (14.07.2026)
   fuer Page-Speed / kleineres HTML. Enqueued via child_enqueue_styles. */

/* -----------------------------------------------------------------------
   RESET & BASE
   ----------------------------------------------------------------------- */
.wk-header *, .wk-header *::before, .wk-header *::after,
.wk-mega-dropdown *, .wk-mega-dropdown *::before, .wk-mega-dropdown *::after,
.wk-mobile-menu *, .wk-mobile-menu *::before, .wk-mobile-menu *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* -----------------------------------------------------------------------
   HEADER
   ----------------------------------------------------------------------- */
.wk-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
}

.wk-header__inner {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    height: 72px;
    gap: 0;
}

/* Logo */
.wk-header__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    margin-right: 8px;
    text-decoration: none;
    color: inherit;
}

.wk-header__logo img {
    height: 60px;
    width: auto;
    max-width: 280px;
    object-fit: contain;
}

.wk-header__logo-fallback {
    display: flex;
    align-items: center;
    gap: 10px;
}

.wk-header__logo-icon {
    width: 38px;
    height: 38px;
    background: #ea580c;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wk-header__logo-icon svg {
    width: 22px;
    height: 22px;
    fill: #fff;
}

.wk-header__logo-text {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #1f2937;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.wk-header__logo-text span {
    color: #ea580c;
}

/* Desktop Navigation */
.wk-mega-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 72px;
    flex: 1;
}

.wk-mega-nav__items {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 0;
    list-style: none;
    margin: 0;
    padding: 0;
}

.wk-mega-nav__item {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.wk-mega-nav__link {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 0 16px;
    height: 100%;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    transition: color 0.2s ease;
    position: relative;
    white-space: nowrap;
    user-select: none;
    text-decoration: none;
    cursor: pointer;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: none;
    border: none;
}

.wk-mega-nav__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 16px;
    right: 16px;
    height: 3px;
    background: linear-gradient(90deg, #ea580c, #f97316);
    border-radius: 3px 3px 0 0;
    transform: scaleX(0);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

.wk-mega-nav__item:hover .wk-mega-nav__link,
.wk-mega-nav__item.is-active .wk-mega-nav__link {
    color: #ea580c;
}

.wk-mega-nav__item:hover .wk-mega-nav__link::after,
.wk-mega-nav__item.is-active .wk-mega-nav__link::after {
    transform: scaleX(1);
}

.wk-mega-nav__link svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.wk-mega-nav__item:hover .wk-mega-nav__link svg,
.wk-mega-nav__item.is-active .wk-mega-nav__link svg {
    opacity: 1;
}

/* Header Right Actions */
.wk-header__actions {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
    flex-shrink: 0;
}

.wk-header__btn {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #4b5563;
    transition: all 0.2s ease;
    background: none;
    border: none;
    cursor: pointer;
    text-decoration: none;
}

.wk-header__btn:hover {
    background: #f3f4f6;
    color: #ea580c;
}

.wk-header__btn svg {
    width: 20px;
    height: 20px;
}

.wk-header__cart-btn {
    position: relative;
}

.wk-header__cart-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    background: #ea580c;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    font-family: 'Inter', sans-serif;
}

/* Hamburger */
.wk-mobile-toggle {
    display: none;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    align-items: center;
    justify-content: center;
    color: #374151;
    transition: all 0.2s ease;
    background: none;
    border: none;
    cursor: pointer;
}

.wk-mobile-toggle:hover {
    background: #f3f4f6;
}

.wk-mobile-toggle__lines {
    width: 20px;
    height: 14px;
    position: relative;
}

.wk-mobile-toggle__lines span {
    display: block;
    position: absolute;
    width: 100%;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.wk-mobile-toggle__lines span:nth-child(1) { top: 0; }
.wk-mobile-toggle__lines span:nth-child(2) { top: 6px; }
.wk-mobile-toggle__lines span:nth-child(3) { top: 12px; }

.wk-mobile-toggle.is-open .wk-mobile-toggle__lines span:nth-child(1) {
    top: 6px;
    transform: rotate(45deg);
}

.wk-mobile-toggle.is-open .wk-mobile-toggle__lines span:nth-child(2) {
    opacity: 0;
    transform: translateX(-8px);
}

.wk-mobile-toggle.is-open .wk-mobile-toggle__lines span:nth-child(3) {
    top: 6px;
    transform: rotate(-45deg);
}

/* -----------------------------------------------------------------------
   MEGA MENU DROPDOWN (Desktop)
   ----------------------------------------------------------------------- */
.wk-mega-overlay {
    position: fixed;
    inset: 0;
    top: 72px;
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(2px);
    z-index: 900;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.wk-mega-overlay.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.wk-mega-dropdown {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    width: 100vw;
    z-index: 950;
    opacity: 0;
    transform: translateY(-8px);
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.wk-mega-dropdown.is-open {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.wk-mega-dropdown__inner {
    background: #fff;
    border-top: 3px solid #ea580c;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

.wk-mega-dropdown__content {
    max-width: 1440px;
    margin: 0 auto;
    padding: 28px 32px 0;
    max-height: 70vh;
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #d1d5db transparent;
}

.wk-mega-dropdown__content::-webkit-scrollbar {
    width: 6px;
}

.wk-mega-dropdown__content::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 3px;
}

/* Grouped layout */
.wk-mega-grouped {
    display: grid;
    gap: 32px;
}

.wk-mega-group {
    padding-bottom: 20px;
}

.wk-mega-group__header {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f3f4f6;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s;
}

a.wk-mega-group__header:hover {
    border-bottom-color: #ea580c;
}

a.wk-mega-group__header:hover .wk-mega-group__title {
    color: #ea580c;
}

.wk-mega-group__title {
    font-size: 14px;
    font-weight: 700;
    color: #1f2937;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-family: 'Inter', sans-serif;
    transition: color 0.2s;
}

.wk-mega-group__count {
    font-size: 12px;
    font-weight: 500;
    color: #9ca3af;
    font-family: 'Inter', sans-serif;
}

.wk-mega-group__items {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* Subcategory link (shared by grouped & flat) */
.wk-mega-subcat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    border-radius: 8px;
    transition: all 0.15s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.wk-mega-subcat:hover {
    background: #fef3ec;
}

.wk-mega-subcat__name {
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    transition: color 0.15s ease;
    font-family: 'Inter', sans-serif;
}

.wk-mega-subcat:hover .wk-mega-subcat__name {
    color: #ea580c;
}

.wk-mega-subcat__count {
    font-size: 12px;
    color: #9ca3af;
    font-weight: 400;
    font-variant-numeric: tabular-nums;
    font-family: 'Inter', sans-serif;
}

/* Flat layout */
.wk-mega-flat {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 4px 24px;
    padding-bottom: 24px;
}

.wk-mega-flat.wk-mega-flat--cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

/* Brands layout */
.wk-mega-brands {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding-bottom: 24px;
}

.wk-brand-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #f9fafb;
    border: 1.5px solid #e5e7eb;
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: inherit;
}

.wk-brand-pill:hover {
    border-color: #ea580c;
    background: #fef3ec;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(234, 88, 12, 0.12);
}

.wk-brand-pill__name {
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
    font-family: 'Inter', sans-serif;
}

.wk-brand-pill:hover .wk-brand-pill__name {
    color: #ea580c;
}

.wk-brand-pill__count {
    font-size: 11px;
    font-weight: 500;
    color: #9ca3af;
    background: #f3f4f6;
    padding: 2px 8px;
    border-radius: 999px;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
}

.wk-brand-pill:hover .wk-brand-pill__count {
    background: #fed7c3;
    color: #ea580c;
}

/* CTA Bar */
.wk-mega-cta {
    margin-top: 0;
    padding: 14px 32px;
    background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    border-top: 1px solid #fed7aa;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: inherit;
}

.wk-mega-cta:hover {
    background: linear-gradient(135deg, #ffedd5 0%, #fed7aa 100%);
}

.wk-mega-cta__text {
    font-size: 14px;
    font-weight: 600;
    color: #ea580c;
    font-family: 'Inter', sans-serif;
}

.wk-mega-cta__arrow {
    font-size: 16px;
    color: #ea580c;
    transition: transform 0.2s ease;
}

.wk-mega-cta:hover .wk-mega-cta__arrow {
    transform: translateX(4px);
}

/* -----------------------------------------------------------------------
   MOBILE MENU
   ----------------------------------------------------------------------- */
.wk-mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(2px);
    z-index: 1100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.wk-mobile-overlay.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.wk-mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: min(380px, 85vw);
    height: 100%;
    background: #fff;
    z-index: 1200;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.wk-mobile-menu.is-open {
    transform: translateX(0);
}

.wk-mobile-menu__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
}

.wk-mobile-menu__title {
    font-size: 16px;
    font-weight: 700;
    color: #1f2937;
    font-family: 'Inter', sans-serif;
}

.wk-mobile-menu__close {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6b7280;
    transition: all 0.2s ease;
    background: none;
    border: none;
    cursor: pointer;
}

.wk-mobile-menu__close:hover {
    background: #f3f4f6;
    color: #1f2937;
}

.wk-mobile-menu__close svg {
    width: 20px;
    height: 20px;
}

.wk-mobile-menu__body {
    flex: 1;
    overflow-y: auto;
    padding: 8px 0;
    -webkit-overflow-scrolling: touch;
}

/* Accordion items */
.wk-mobile-accordion {
    border-bottom: 1px solid #f3f4f6;
}

.wk-mobile-accordion__trigger {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 14px 20px;
    gap: 10px;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
    text-align: left;
    transition: background 0.15s ease;
    background: none;
    border: none;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
}

.wk-mobile-accordion__trigger:hover {
    background: #f9fafb;
}

.wk-mobile-accordion__trigger svg.wk-mobile-nav-icon {
    width: 20px;
    height: 20px;
    opacity: 0.6;
    flex-shrink: 0;
}

.wk-mobile-accordion__trigger-text {
    flex: 1;
}

.wk-mobile-accordion__trigger-count {
    font-size: 12px;
    font-weight: 500;
    color: #9ca3af;
    margin-right: 4px;
    font-family: 'Inter', sans-serif;
}

.wk-mobile-accordion__trigger-chevron {
    width: 18px;
    height: 18px;
    color: #9ca3af;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.wk-mobile-accordion.is-open .wk-mobile-accordion__trigger-chevron {
    transform: rotate(180deg);
}

.wk-mobile-accordion__panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.wk-mobile-accordion.is-open .wk-mobile-accordion__panel {
    max-height: 1200px;
}

.wk-mobile-accordion__content {
    padding: 0 20px 12px 50px;
}

.wk-mobile-group-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #9ca3af;
    padding: 10px 0 6px;
    font-family: 'Inter', sans-serif;
}

.wk-mobile-subcat-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f9fafb;
    text-decoration: none;
    color: inherit;
}

.wk-mobile-subcat-link:last-child {
    border-bottom: none;
}

.wk-mobile-subcat-link__name {
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    font-family: 'Inter', sans-serif;
}

.wk-mobile-subcat-link__count {
    font-size: 12px;
    color: #9ca3af;
    font-family: 'Inter', sans-serif;
}

.wk-mobile-cta {
    display: block;
    margin: 8px 0 4px;
    padding: 10px 14px;
    background: #fff7ed;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #ea580c;
    text-align: center;
    transition: background 0.15s ease;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
}

.wk-mobile-cta:hover {
    background: #ffedd5;
}

/* -----------------------------------------------------------------------
   RESPONSIVE
   ----------------------------------------------------------------------- */
@media (max-width: 1023px) {
    .wk-mega-nav {
        display: none;
    }
    .wk-mobile-toggle {
        display: flex;
    }
    .wk-header__inner {
        height: 60px;
    }
    .wk-mega-overlay,
    .wk-mega-dropdown {
        display: none !important;
    }
}

@media (min-width: 1024px) {
    .wk-mobile-overlay,
    .wk-mobile-menu {
        display: none !important;
    }
}

@media (max-width: 640px) {
    .wk-header__inner {
        padding: 0 16px;
    }
}

/* Angebote-Pill: visuell akzentuiert damit's nicht in der Nav untergeht */
.wk-mega-nav__item--deals .wk-mega-nav__link {
    color: #dc2626;
    font-weight: 700;
}
.wk-mega-nav__item--deals .wk-mega-nav__link:hover {
    color: #b91c1c;
}
.wk-mega-nav__item--deals .wk-mega-nav__link svg {
    color: #dc2626;
}

/* ────────────────────────────────────────────────────────────
   SEARCH OVERLAY
   ──────────────────────────────────────────────────────────── */
.wk-search-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(15, 23, 42, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 96px 20px 40px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 180ms ease;
}
.wk-search-overlay[hidden] { display: none; }
.wk-search-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}
.wk-search-overlay__close {
    position: absolute;
    top: 24px;
    right: 24px;
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 50%;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: background 150ms ease;
}
.wk-search-overlay__close:hover { background: rgba(255, 255, 255, 0.2); }
.wk-search-overlay__close svg { width: 22px; height: 22px; }
.wk-search-overlay__inner {
    width: 100%;
    max-width: 720px;
    transform: translateY(-12px);
    transition: transform 220ms cubic-bezier(0.2, 0.7, 0.3, 1);
}
.wk-search-overlay.is-open .wk-search-overlay__inner { transform: translateY(0); }
.wk-search-overlay__label {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 12px;
}
.wk-search-overlay__field {
    display: flex;
    align-items: center;
    background: #fff;
    border-radius: 14px;
    padding: 6px 6px 6px 18px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}
.wk-search-overlay__icon {
    width: 22px;
    height: 22px;
    color: #64748b;
    flex-shrink: 0;
}
input[type="search"] {
    border: 0;
}
.wk-search-overlay__input,
input[type="search"].wk-search-overlay__input {
    flex: 1;
    border: 0 !important;
    outline: 0;
    background: transparent;
    font-size: 18px;
    line-height: 1.4;
    padding: 14px 12px;
    color: #0f172a;
    min-width: 0;
    -webkit-appearance: none;
    appearance: none;
}
.wk-search-overlay__input::placeholder { color: #94a3b8; }
.wk-search-overlay__submit {
    border: 0;
    background: #f97316;
    color: #fff;
    font-weight: 600;
    font-size: 15px;
    padding: 12px 22px;
    border-radius: 10px;
    cursor: pointer;
    transition: background 150ms ease;
}
.wk-search-overlay__submit:hover { background: #ea580c; }
.wk-search-overlay__hint {
    color: rgba(255, 255, 255, 0.55);
    font-size: 13px;
    margin: 14px 4px 0;
}
.wk-search-overlay__hint kbd {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-family: inherit;
    font-size: 12px;
}
.wk-search-overlay__results {
    margin-top: 16px;
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
    max-height: 60vh;
    overflow-y: auto;
}
.wk-search-overlay__results[hidden] { display: none; }
.wk-search-overlay__result-section {
    padding: 14px 18px 8px;
}
.wk-search-overlay__result-section + .wk-search-overlay__result-section {
    border-top: 1px solid #e2e8f0;
}
.wk-search-overlay__result-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #64748b;
    margin: 0 0 6px;
}
.wk-search-overlay__result {
    display: flex;
    gap: 12px;
    padding: 8px 4px;
    border-radius: 8px;
    text-decoration: none;
    color: #0f172a;
    transition: background 100ms ease;
}
.wk-search-overlay__result:hover,
.wk-search-overlay__result.is-active { background: #f1f5f9; }
.wk-search-overlay__result-img {
    width: 44px;
    height: 44px;
    border-radius: 6px;
    background: #f1f5f9 center/cover no-repeat;
    flex-shrink: 0;
}
.wk-search-overlay__result-name {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.35;
}
.wk-search-overlay__result-meta {
    font-size: 12px;
    color: #64748b;
}
.wk-search-overlay__result mark {
    background: #fef3c7;
    color: inherit;
    padding: 0 2px;
    border-radius: 3px;
}
@media (max-width: 640px) {
    .wk-search-overlay { padding: 64px 12px 24px; }
    .wk-search-overlay__field { flex-wrap: wrap; padding: 8px; }
    .wk-search-overlay__submit { width: 100%; margin-top: 6px; }
}
