/*
 * CurtainXpress Child Theme — custom.css
 * FIXED: Added banner, improved strip layout, larger icons/text, reduced height
 */

/* ══════════════════════════════════════════
   1. Hide Blocksy's default search trigger
   ══════════════════════════════════════════ */
.header-search-wrapper,
.ct-search-box,
[data-id="search"],
.ct-header-search,
button.ct-search-toggle,
a.ct-search-toggle {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.ct-search-modal,
.ct-search-overlay,
#search-modal,
.blocksy-search-overlay {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
}


/* ══════════════════════════════════════════
   2. Navbar inline search bar
   ══════════════════════════════════════════ */
#cx-search-wrapper {
    display: flex !important;
    align-items: center;
    flex: 1 1 auto;
    max-width: 400px;
    margin: 0 24px;
}

#cx-search-form {
    display: flex;
    align-items: center;
    width: 100%;
    background: #ede9e4;
    border-radius: 10px;
    padding: 0 16px;
    gap: 10px;
    height: 50px;
    transition: box-shadow 0.2s ease, background 0.2s ease;
}

#cx-search-form:focus-within {
    background: #e8e3dd;
    box-shadow: 0 0 0 2px rgba(0,0,0,0.08);
}

.cx-search-icon {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    color: #7a7168;
    pointer-events: none;
}

.cx-search-icon svg {
    width: 20px;
    height: 20px;
}

#cx-search-input {
    flex: 1 1 auto;
    border: none !important;
    outline: none !important;
    background: transparent !important;
    box-shadow: none !important;
    font-family: inherit;
    font-size: 15px;
    color: #3a3530;
    letter-spacing: 0.02em;
    padding: 0 !important;
    margin: 0 !important;
    height: 100%;
    -webkit-appearance: none;
       -moz-appearance: none;
            appearance: none;
}

#cx-search-input::placeholder {
    color: #a09890;
    font-weight: 400;
}

#cx-search-input::-webkit-search-decoration,
#cx-search-input::-webkit-search-cancel-button,
#cx-search-input::-webkit-search-results-button,
#cx-search-input::-webkit-search-results-decoration {
    display: none;
}

@media (max-width: 1024px) {
    #cx-search-wrapper {
        max-width: 260px;
        margin: 0 12px;
    }
}

@media (max-width: 768px) {
    #cx-search-wrapper {
        max-width: 100%;
        margin: 8px 16px;
        order: 10;
    }
    #cx-search-form {
        height: 38px;
    }
}


/* ══════════════════════════════════════════
   3. Category Banner
   FIXED: Dynamic category image rendering
   ══════════════════════════════════════════ */

.cx-category-banner {
    display: block !important;
    width: 100% !important;
    position: relative !important;

    /* IMPORTANT:
       REMOVE HARDCODED BACKGROUND IMAGE
       PHP INLINE STYLE WILL HANDLE IT
    */

    background-color: #E6DFD7 !important;
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;

    min-height: 535px !important;
    height: 535px !important;

    margin: 0 !important;
    padding: 0 !important;

    box-sizing: border-box !important;
    overflow: hidden !important;
    z-index: 5 !important;
}

/* Tablet */
@media (max-width: 1024px) {
    .cx-category-banner {
        min-height: 320px !important;
        height: 320px !important;
    }
}

/* Mobile */
@media (max-width: 640px) {
    .cx-category-banner {
        min-height: 220px !important;
        height: 220px !important;
        background-position: center center !important;
    }
}

/* ══════════════════════════════════════════
   4. Category Icon Strip - IMPROVED LAYOUT
   
   - Stretched evenly across full width
   - Larger icons (90px → 100px)
   - Larger text (16px → 18px)
   - Reduced height (141px → 110px)
   - Better spacing
   ══════════════════════════════════════════ */

.cx-category-strip {
    display: block !important;
    width: 100% !important;
    position: static !important;
    background: #E6DFD7 !important;
    border-top: 1px solid #d5ccc3 !important;
    border-bottom: 1px solid #d5ccc3 !important;
    margin: 0 0 15px 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    z-index: 10 !important;
}

.cx-category-strip__inner {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-wrap: nowrap !important;
    gap: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 14px 0 !important;
    box-sizing: border-box !important;
}

/* Individual Category Item - IMPROVED */
.cx-cat-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    text-decoration: none !important;
    color: #1c1c1c !important;
    padding: 0 20px !important;
    border-bottom: 3px solid transparent !important;
    position: relative !important;
    transition: all 0.2s ease !important;
    box-sizing: border-box !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
    text-align: center !important;
}

/* NO HOVER EFFECT */
.cx-cat-item:hover {
    border-bottom-color: transparent !important;
    opacity: 1 !important;
}

/* NO ACTIVE UNDERLINE EFFECT */
.cx-cat-item--active {
    border-bottom-color: transparent !important;
}

/* Icon Box - LARGER */
.cx-cat-icon {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100px !important;
    height: 100px !important;
    flex-shrink: 0 !important;
}

/* Icon Image - LARGER */
.cx-cat-icon img {
    width: 80px !important;
    height: 80px !important;
    object-fit: contain !important;
    filter: brightness(0) saturate(100%) opacity(0.65) !important;
    transition: none !important;
    display: block !important;
}

.cx-cat-item:hover .cx-cat-icon img,
.cx-cat-item--active .cx-cat-icon img {
    filter: brightness(0) saturate(100%) opacity(0.65) !important;
}

/* Label - LARGER TEXT */
.cx-cat-label {
    font-family: "Libre Baskerville", Montserrat, sans-serif !important;
    font-size: 18px !important;
    font-weight: 400 !important;
    line-height: 18px !important;
    color: rgb(28, 28, 28) !important;
    text-align: center !important;
    white-space: nowrap !important;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Active label - LARGER */
.cx-cat-item--active .cx-cat-label {
    font-family: Montserrat, sans-serif !important;
    font-size: 18px !important;
    font-weight: 500 !important;
    line-height: 26.4px !important;
    color: rgb(28, 28, 28) !important;
}


/* ══════════════════════════════════════════
   RESPONSIVE - Tablet (max-width: 1024px)
   ══════════════════════════════════════════ */
@media (max-width: 1024px) {
    .cx-category-strip__inner {
        padding: 12px 0 !important;
        gap: 0 !important;
    }
    
    .cx-cat-item {
        padding: 0 16px !important;
        gap: 5px !important;
    }
    
    .cx-cat-icon {
        width: 80px !important;
        height: 80px !important;
    }
    
    .cx-cat-icon img {
        width: 64px !important;
        height: 64px !important;
    }
    
    .cx-cat-label {
        font-size: 15px !important;
    }
}


/* ══════════════════════════════════════════
   RESPONSIVE - Mobile (max-width: 640px)
   
   Switch to horizontal scroll on small screens
   ══════════════════════════════════════════ */
@media (max-width: 640px) {
    .cx-category-strip {
        margin: 0 !important;
    }
    
    .cx-category-strip__inner {
        justify-content: flex-start !important;
        flex-wrap: nowrap !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        -webkit-overflow-scrolling: touch !important;
        scrollbar-width: none !important;
        padding: 10px 0 !important;
        gap: 0 !important;
    }
    
    .cx-category-strip__inner::-webkit-scrollbar {
        display: none !important;
    }
    
    .cx-cat-item {
        flex-shrink: 0 !important;
        min-width: 95px !important;
        gap: 5px !important;
        padding: 0 12px !important;
    }
    
    .cx-cat-icon {
        width: 70px !important;
        height: 70px !important;
    }
    
    .cx-cat-icon img {
        width: 56px !important;
        height: 56px !important;
    }
    
    .cx-cat-label {
        font-size: 12px !important;
        white-space: normal !important;
        line-height: 1.2 !important;
    }
}

/* ══════════════════════════════════════════════════════
   FOOTER LINK STYLING
══════════════════════════════════════════════════════ */

/* Remove underline from ALL footer links */
footer a,
.ct-footer a,
[data-footer*="type"] a {
    text-decoration: none !important;

    border-bottom: none !important;

    box-shadow: none !important;

    transition:
        color 0.25s ease,
        opacity 0.25s ease;
}

/* Default footer link color */
footer a,
.ct-footer a {
    color: #2c2420 !important;
}

/* Hover effect instead of underline */
footer a:hover,
.ct-footer a:hover,
[data-footer*="type"] a:hover {
    color: #8c6f58 !important;

    text-decoration: none !important;

    border-bottom: none !important;
}

/* Remove active/focus underline */
footer a:focus,
footer a:active,
.ct-footer a:focus,
.ct-footer a:active {
    text-decoration: none !important;

    border-bottom: none !important;

    outline: none !important;
}

/* Footer menu items */
footer .menu a,
.ct-footer .menu a {
    text-decoration: none !important;

    border: none !important;
}

/* Footer widget links */
footer .widget a,
.ct-footer .widget a {
    text-decoration: none !important;
}

/* Social icons */
footer .social-icons a,
.ct-footer .social-icons a {
    text-decoration: none !important;

    border: none !important;
}

/* Copyright links */
footer .ct-footer-copyright a {
    text-decoration: none !important;
}

/* Footer bottom links */
footer .ct-footer-secondary-section a {
    text-decoration: none !important;
}

/* Optional smoother hover */
footer a:hover {
    opacity: 0.85;
}

/* ══════════════════════════════════════════════════════
   FOOTER - SHIFT GET IN TOUCH LEFT
══════════════════════════════════════════════════════ */

.ct-footer [data-column="4"] {
    padding-left: 40px !important;
}