/*
 Theme Name:   Storefront Child
 Theme URI:    https://www.high-furniture.com/
 Description:  Bespoke custom styling and micro-animations for High Furniture, built on Storefront.
 Author:       Antigravity
 Template:     storefront
 Version:      1.0.0
 Text Domain:  storefront-child
*/

/* ==========================================================================
   Google Fonts Import & Global Design Tokens
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&display=swap');

:root {
    --hf-primary: hsl(42, 60%, 45%);        /* Luxurious Custom Gold */
    --hf-primary-hover: hsl(42, 60%, 35%);
    --hf-dark: #121110;                     /* Warm Charcoal */
    --hf-light: #faf9f6;                    /* Soft Warm Alabaster */
    --hf-white: #ffffff;
    --hf-text: #3c3835;                     /* Warm Slate Text */
    --hf-text-light: #8e8780;
    --hf-border: #f0edea;
    --hf-border-dark: #d2c9c0;
    --hf-shadow-subtle: 0 4px 24px rgba(18, 17, 16, 0.03);
    --hf-shadow-hover: 0 16px 40px rgba(18, 17, 16, 0.08);
    
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Outfit', sans-serif;
    
    --transition-smooth: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-fast: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   Base Overrides & Cleanups (Removing Boxed Layout)
   ========================================================================== */
body, button, input, select, textarea, .site-title, .main-navigation a {
    font-family: var(--font-body);
    color: var(--hf-text);
    background-color: var(--hf-light);
    -webkit-font-smoothing: antialiased;
}

body {
    background-color: var(--hf-light) !important;
    overflow-x: hidden;
}

body.hf-panel-open {
    overflow: hidden !important;
}

h1, h2, h3, h4, h5, h6, .site-title a {
    font-family: var(--font-heading);
    color: var(--hf-dark);
    font-weight: 700;
}

/* Force page and site wrappers to stretch 100% full-width, eliminating Storefront's default boxed style */
#page,
.site,
.site-content {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
    border: none !important;
}

/* Make Container Full-Width (Fluid Layout) instead of Storefront's tiny Boxed layout */
.col-full {
    max-width: 1440px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 40px !important;
    padding-right: 40px !important;
}

/* On the homepage, force the main content wrapper of Storefront to be 100% wide, allowing edge-to-edge sections */
.home #content > .col-full {
    max-width: 100% !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin: 0 !important;
}

/* Force the content area (#primary) to stretch 100% on the homepage, breaking out of standard sidebar grids */
.home .content-area,
.home #primary {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Hide the sidebar completely on the homepage to avoid empty grid slots */
.home #secondary {
    display: none !important;
}

/* Center and box the specific homepage sections at 1440px to keep content perfectly aligned */
.home .hf-categories,
.home .hf-featured-products,
.home .hf-values {
    max-width: 1440px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 40px !important;
    padding-right: 40px !important;
    box-sizing: border-box;
}

/* Ensure the full-bleed Hero banner stretches edge-to-edge without margins */
.home .hf-hero {
    margin-left: 0 !important;
    margin-right: 0 !important;
    width: 100% !important;
    box-sizing: border-box;
}

/* Reset Default Storefront Container Borders and Backgrounds */
.storefront-primary-navigation,
#content,
.site-footer {
    background: transparent !important;
    border: none !important;
}

/* ==========================================================================
   Header & Navigation Overhaul (Flexbox & Horizontal Layout)
   ========================================================================== */
.site-header {
    background-color: var(--hf-white) !important;
    border-bottom: 1px solid var(--hf-border) !important;
    padding-top: 1.5em !important;
    padding-bottom: 1.5em !important;
    position: sticky;
    top: 0;
    z-index: 999;
    backdrop-filter: blur(12px);
    background: rgba(255, 255, 255, 0.96) !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.02);
}

/* Force Header to Flexbox to align elements horizontally */
.site-header .col-full {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 30px !important;
}

/* Hide Default Bulky Elements */
.site-search, 
.site-header-cart .widget_shopping_cart,
.handheld-navigation, 
.menu-toggle {
    display: none !important;
}

/* Reset Logo (Site Branding) */
.site-header .site-branding {
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
    width: auto !important;
    max-width: 250px;
}

.site-branding .site-title {
    font-size: 26px !important;
    margin: 0 !important;
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: -0.02em;
}

.site-branding .site-title a {
    color: var(--hf-dark) !important;
}

/* Reset Navigation wrapper */
.site-header .main-navigation {
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
    width: auto !important;
    flex-grow: 1;
    display: flex !important;
    justify-content: flex-end !important;
}

.main-navigation ul.nav-menu,
.main-navigation ul.menu {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 10px !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
    float: none !important;
}

/* Remove default Storefront menu block items and paddings */
.main-navigation ul.nav-menu li,
.main-navigation ul.menu li {
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
    display: inline-block !important;
    background: transparent !important;
    border: none !important;
}

.main-navigation ul.nav-menu li a,
.main-navigation ul.menu li a {
    background: transparent !important;
    border: none !important;
    padding: 8px 16px !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.15em !important;
    color: var(--hf-dark) !important;
    transition: var(--transition-fast) !important;
    display: block !important;
    line-height: 1.5 !important;
}

.main-navigation ul.nav-menu li a:hover,
.main-navigation ul.menu li a:hover {
    color: var(--hf-primary) !important;
    background: transparent !important;
}

/* Search and Cart Triggers Icon container */
.main-navigation ul.nav-menu li.hf-menu-icons-li,
.main-navigation ul.menu li.hf-menu-icons-li,
.hf-menu-icons-li {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 15px !important;
    padding-left: 20px !important;
    border-left: 1px solid var(--hf-border) !important;
    margin-left: 15px !important;
    float: none !important;
}

.main-navigation ul.nav-menu li.hf-menu-icons-li a,
.main-navigation ul.menu li.hf-menu-icons-li a,
.hf-menu-icons-li a {
    padding: 6px !important;
    display: inline-flex !important;
    vertical-align: middle !important;
    align-items: center !important;
    justify-content: center !important;
    background: transparent !important;
    color: var(--hf-dark) !important;
    transition: var(--transition-fast) !important;
    float: none !important;
}

.main-navigation ul.nav-menu li.hf-menu-icons-li a:hover,
.main-navigation ul.menu li.hf-menu-icons-li a:hover,
.hf-menu-icons-li a:hover {
    color: var(--hf-primary) !important;
    transform: translateY(-1px);
    background: transparent !important;
}

.hf-menu-icons-li a svg {
    transition: var(--transition-fast);
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.hf-btn {
    display: inline-block;
    padding: 14px 36px;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    border-radius: 2px;
    transition: var(--transition-smooth);
    text-align: center;
    cursor: pointer;
    border: none;
}

.hf-btn-primary {
    background-color: var(--hf-primary);
    color: var(--hf-white) !important;
    border: 1px solid var(--hf-primary);
}

.hf-btn-primary:hover {
    background-color: var(--hf-primary-hover);
    border-color: var(--hf-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(191, 155, 48, 0.2);
}

.hf-btn-secondary {
    background-color: transparent;
    color: var(--hf-white) !important;
    border: 1px solid var(--hf-white);
}

.hf-btn-secondary:hover {
    background-color: var(--hf-white);
    color: var(--hf-dark) !important;
    transform: translateY(-2px);
}

/* ==========================================================================
   Hero Section (Fluid Design)
   ========================================================================== */
.hf-hero {
    position: relative;
    height: 80vh;
    min-height: 550px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--hf-white);
    padding: 0 20px;
    overflow: hidden;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
}

.hf-hero-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hf-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(18, 17, 16, 0.3) 0%, rgba(18, 17, 16, 0.6) 100%);
    z-index: 1;
}

.hf-hero-content {
    position: relative;
    z-index: 2;
    max-width: 850px;
    animation: fadeInUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.hf-hero-subtitle {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.3em;
    font-weight: 600;
    color: var(--hf-primary);
    margin-bottom: 20px;
    display: block;
}

.hf-hero-title {
    font-size: clamp(36px, 5.5vw, 68px);
    color: var(--hf-white);
    margin-bottom: 25px;
    line-height: 1.1;
    font-weight: 700;
}

.hf-hero-text {
    font-size: clamp(16px, 2vw, 19px);
    font-weight: 300;
    line-height: 1.65;
    margin-bottom: 40px;
    color: rgba(255, 255, 255, 0.95);
}

.hf-hero-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ==========================================================================
   Section Headers
   ========================================================================== */
.hf-section-header {
    text-align: center;
    margin-bottom: 60px;
}

.hf-section-tag {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    font-weight: 600;
    color: var(--hf-primary);
    display: block;
    margin-bottom: 12px;
}

.hf-section-title {
    font-size: clamp(28px, 4vw, 36px);
    position: relative;
    margin-bottom: 18px;
    font-weight: 700;
}

.hf-section-divider {
    width: 50px;
    height: 2px;
    background-color: var(--hf-primary);
    margin: 0 auto;
}

/* ==========================================================================
   Categories Section
   ========================================================================== */
.hf-categories {
    padding: 100px 0;
    max-width: 1240px;
    margin: 0 auto;
}

.hf-categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 30px;
    padding: 0 20px;
}

.hf-cat-card {
    position: relative;
    display: block;
    height: 320px;
    overflow: hidden;
    border-radius: 4px;
    box-shadow: var(--hf-shadow-subtle);
    transition: var(--transition-smooth);
    background-color: var(--hf-dark);
}

.hf-cat-image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

.hf-cat-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.hf-cat-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(18, 17, 16, 0.1) 0%, rgba(18, 17, 16, 0.6) 100%);
    transition: var(--transition-smooth);
}

.hf-cat-info {
    position: absolute;
    bottom: 30px;
    left: 30px;
    z-index: 2;
    color: var(--hf-white);
}

.hf-cat-name {
    color: var(--hf-white);
    font-size: 26px;
    margin-bottom: 8px;
    transition: var(--transition-smooth);
    font-weight: 600;
}

.hf-cat-count {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 600;
}

/* Category Hover */
.hf-cat-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--hf-shadow-hover);
}

.hf-cat-card:hover img {
    transform: scale(1.08);
}

.hf-cat-card:hover .hf-cat-overlay {
    background: linear-gradient(180deg, rgba(18, 17, 16, 0.25) 0%, rgba(18, 17, 16, 0.75) 100%);
}

/* ==========================================================================
   Featured Products Section
   ========================================================================== */
.hf-featured-products {
    padding: 100px 0;
    background-color: var(--hf-white);
    border-top: 1px solid var(--hf-border);
    border-bottom: 1px solid var(--hf-border);
}

.hf-products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 45px;
    max-width: 1360px;
    margin: 0 auto;
    padding: 0 40px;
}

@media (max-width: 992px) {
    .hf-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
        padding: 0 20px;
    }
}

@media (max-width: 568px) {
    .hf-products-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
}

.hf-product-card {
    background-color: var(--hf-white) !important;
    border-radius: 4px !important;
    border: 1px solid var(--hf-border) !important;
    box-shadow: 0 4px 15px rgba(18, 17, 16, 0.02) !important;
    transition: var(--transition-smooth) !important;
    display: flex;
    flex-direction: column;
    overflow: hidden !important;
}

.hf-product-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1 !important;
    background-color: var(--hf-light) !important;
    overflow: hidden;
    border-radius: 0 !important;
}

.hf-product-image-wrapper img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    padding: 0 !important;
    background-color: var(--hf-light) !important;
    transition: var(--transition-smooth);
}

.hf-product-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 3;
    padding: 5px 12px;
    font-size: 10px;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.12em;
    border-radius: 0 !important;
}

.hf-badge-sale {
    background-color: var(--hf-primary);
    color: var(--hf-white);
}

.hf-product-actions {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: rgba(247, 246, 243, 0.45) !important;
    backdrop-filter: blur(10px) !important;
    opacity: 0;
    z-index: 2;
    transition: var(--transition-smooth);
}

.hf-action-btn {
    width: 46px;
    height: 46px;
    background-color: var(--hf-white) !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: var(--hf-dark) !important;
    transition: var(--transition-smooth) !important;
    box-shadow: 0 4px 15px rgba(18, 17, 16, 0.08) !important;
    border: 1px solid var(--hf-border) !important;
    cursor: pointer;
}

.hf-action-btn svg {
    width: 18px;
    height: 18px;
}

.hf-action-btn:hover {
    background-color: var(--hf-primary) !important;
    color: var(--hf-white) !important;
    border-color: var(--hf-primary) !important;
    transform: translateY(-2px) scale(1.05) !important;
    box-shadow: 0 8px 24px rgba(191, 155, 48, 0.25) !important;
}

/* Product Details */
.hf-product-details {
    padding: 20px !important;
    text-align: left !important;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.hf-product-cats {
    font-family: var(--font-body);
    font-size: 10px !important;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--hf-text-light);
    margin-bottom: 6px;
}

.hf-cat-link a {
    color: var(--hf-text-light);
    text-decoration: none;
}

.hf-cat-link a:hover {
    color: var(--hf-primary);
}

.hf-product-title {
    font-family: var(--font-body) !important;
    font-weight: 500 !important;
    font-size: 16px !important;
    line-height: 1.35 !important;
    margin-bottom: 8px !important;
    letter-spacing: 0.01em !important;
}

.hf-product-title a {
    color: var(--hf-dark) !important;
    text-decoration: none !important;
}

.hf-product-title a:hover {
    color: var(--hf-primary);
}

.hf-product-price {
    font-family: var(--font-body) !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    color: var(--hf-primary) !important;
    margin-bottom: 0 !important;
}

.hf-product-price del {
    color: var(--hf-text-light);
    font-weight: 400;
    margin-right: 6px;
    font-size: 13px;
}

.hf-product-price ins {
    text-decoration: none;
}

/* Product Hover */
.hf-product-card:hover {
    box-shadow: 0 16px 30px rgba(18, 17, 16, 0.06) !important;
    transform: translateY(-6px) !important;
    border-color: var(--hf-primary) !important;
}

.hf-product-card:hover .hf-product-image-wrapper img {
    transform: scale(1.05) !important;
}

.hf-product-card:hover .hf-product-actions {
    opacity: 1;
}

/* ==========================================================================
   Brand Values Section
   ========================================================================== */
.hf-values {
    padding: 100px 20px;
    max-width: 1240px;
    margin: 0 auto;
}

.hf-values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.hf-value-item {
    text-align: center;
    padding: 30px;
    background-color: var(--hf-white);
    border-radius: 4px;
    transition: var(--transition-smooth);
    border: 1px solid var(--hf-border);
}

.hf-value-icon {
    width: 72px;
    height: 72px;
    background-color: rgba(191, 155, 48, 0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    color: var(--hf-primary);
}

.hf-value-icon svg {
    width: 36px;
    height: 36px;
}

.hf-value-title {
    font-size: 22px;
    margin-bottom: 14px;
    font-weight: 600;
}

.hf-value-desc {
    font-size: 14px;
    line-height: 1.65;
    color: var(--hf-text-light);
}

.hf-value-item:hover {
    box-shadow: var(--hf-shadow-hover);
    border-color: var(--hf-primary);
    transform: translateY(-4px);
}

/* ==========================================================================
   Sliding Mini-Cart Drawer
   ========================================================================== */
.hf-cart-drawer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    visibility: hidden;
    transition: visibility 0.4s;
}

.hf-cart-drawer.active {
    visibility: visible;
}

.hf-cart-drawer-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(18, 17, 16, 0.5);
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.hf-cart-drawer.active .hf-cart-drawer-overlay {
    opacity: 1;
}

.hf-cart-drawer-panel {
    position: absolute;
    top: 0;
    right: -420px;
    width: 420px;
    max-width: 100%;
    height: 100%;
    background-color: var(--hf-white);
    box-shadow: -10px 0 40px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    transform: translate3d(0, 0, 0);
}

.hf-cart-drawer.active .hf-cart-drawer-panel {
    transform: translate3d(-420px, 0, 0);
}

.hf-cart-drawer-header {
    padding: 24px;
    border-bottom: 1px solid var(--hf-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hf-cart-drawer-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
}

.hf-cart-drawer-close {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--hf-dark);
    padding: 5px;
    transition: var(--transition-fast);
}

.hf-cart-drawer-close svg {
    width: 20px;
    height: 20px;
}

.hf-cart-drawer-close:hover {
    color: var(--hf-primary);
    transform: rotate(90deg);
}

.hf-cart-drawer-content {
    flex-grow: 1;
    overflow-y: auto;
    padding: 24px;
}

/* Custom mini-cart stylings inside drawer */
.hf-cart-drawer .woocommerce-mini-cart {
    padding: 0;
    margin: 0;
    list-style: none;
}

.hf-cart-drawer .woocommerce-mini-cart-item {
    display: flex;
    gap: 15px;
    padding-bottom: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--hf-border);
    position: relative;
}

.hf-cart-drawer .woocommerce-mini-cart-item img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 2px;
}

.hf-cart-drawer .woocommerce-mini-cart-item a.remove {
    position: absolute;
    top: 0;
    right: 0;
    font-size: 20px;
    color: var(--hf-text-light) !important;
}

.hf-cart-drawer .woocommerce-mini-cart-item a.remove:hover {
    color: #cc0000 !important;
    background: none !important;
}

.hf-cart-drawer .woocommerce-mini-cart__total {
    padding: 15px 0;
    font-size: 18px;
    font-weight: 600;
    border-top: 1px solid var(--hf-border);
    display: flex;
    justify-content: space-between;
}

.hf-cart-drawer .woocommerce-mini-cart__buttons {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.hf-cart-drawer .woocommerce-mini-cart__buttons a.button {
    flex: 1;
    text-align: center;
    padding: 14px 0;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 600;
    border-radius: 2px;
}

.hf-cart-drawer .woocommerce-mini-cart__buttons a.button.checkout {
    background-color: var(--hf-primary) !important;
    color: var(--hf-white) !important;
}

.hf-cart-drawer .woocommerce-mini-cart__buttons a.button.checkout:hover {
    background-color: var(--hf-primary-hover) !important;
}

/* ==========================================================================
   AJAX Search Modal (Overlay)
   ========================================================================== */
.hf-search-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    visibility: hidden;
    transition: visibility 0.4s;
}

.hf-search-modal.active {
    visibility: visible;
}

.hf-search-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(18, 17, 16, 0.95);
    backdrop-filter: blur(8px);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.hf-search-modal.active .hf-search-modal-overlay {
    opacity: 1;
}

.hf-search-modal-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -60%);
    width: 90%;
    max-width: 700px;
    z-index: 2;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    opacity: 0;
}

.hf-search-modal.active .hf-search-modal-container {
    transform: translate(-50%, -50%);
    opacity: 1;
}

.hf-search-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    color: var(--hf-white);
}

.hf-search-modal-header h3 {
    margin: 0;
    color: var(--hf-white);
    font-size: 24px;
}

.hf-search-modal-close {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--hf-white);
    padding: 5px;
    transition: var(--transition-fast);
}

.hf-search-modal-close svg {
    width: 24px;
    height: 24px;
}

.hf-search-modal-close:hover {
    color: var(--hf-primary);
    transform: rotate(90deg);
}

.hf-search-field-wrapper {
    position: relative;
    margin-bottom: 40px;
}

#hf-search-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 2px solid var(--hf-text-light);
    color: var(--hf-white);
    font-size: 28px;
    font-family: var(--font-heading);
    padding: 10px 0;
    outline: none;
    transition: var(--transition-fast);
}

#hf-search-input:focus {
    border-color: var(--hf-primary);
}

.hf-search-loader {
    position: absolute;
    right: 10px;
    top: 20px;
    width: 24px;
    height: 24px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-top: 2px solid var(--hf-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.hf-search-results {
    max-height: 380px;
    overflow-y: auto;
}

.hf-search-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 12px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: var(--transition-fast);
    background-color: rgba(255,255,255,0.02);
    margin-bottom: 10px;
    border-radius: 2px;
}

.hf-search-item:hover {
    background-color: rgba(255,255,255,0.06);
}

.hf-search-item-thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 2px;
}

.hf-search-item-info {
    display: flex;
    flex-direction: column;
}

.hf-search-item-title {
    color: var(--hf-white);
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 5px;
}

.hf-search-item-price {
    color: var(--hf-primary);
    font-size: 14px;
    font-weight: 600;
}

.hf-search-no-results {
    color: var(--hf-text-light);
    text-align: center;
    font-size: 16px;
}

/* ==========================================================================
   Product Quick View Modal
   ========================================================================== */
.hf-qv-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    visibility: hidden;
    transition: visibility 0.4s;
}

.hf-qv-modal.active {
    visibility: visible;
}

.hf-qv-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(18, 17, 16, 0.5);
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.hf-qv-modal.active .hf-qv-modal-overlay {
    opacity: 1;
}

.hf-qv-modal-container {
    position: relative;
    background-color: var(--hf-white);
    width: 90%;
    max-width: 960px;
    max-height: 90vh;
    border-radius: 4px;
    z-index: 2;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    transform: scale(0.9) translateY(20px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 40px;
}

.hf-qv-modal.active .hf-qv-modal-container {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.hf-qv-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--hf-dark);
    padding: 5px;
    z-index: 10;
    transition: var(--transition-fast);
}

.hf-qv-modal-close svg {
    width: 24px;
    height: 24px;
}

.hf-qv-modal-close:hover {
    color: var(--hf-primary);
    transform: rotate(90deg);
}

.hf-qv-loader-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 300px;
}

.hf-qv-loader {
    width: 40px;
    height: 40px;
    border: 3px solid var(--hf-border);
    border-top: 3px solid var(--hf-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* Quick View layout inside container */
.hf-qv-modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.hf-qv-featured-image img {
    width: 100% !important;
    aspect-ratio: 1 / 1 !important;
    object-fit: contain !important;
    background-color: #f7f6f3 !important;
    padding: 20px !important;
    border-radius: 0 !important;
}

.hf-qv-title {
    font-size: 28px;
    margin-top: 0;
    margin-bottom: 15px;
}

.hf-qv-price-wrapper {
    font-size: 20px;
    color: var(--hf-primary);
    font-weight: 600;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--hf-border);
    padding-bottom: 15px;
}

.hf-qv-description {
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 25px;
}

/* ==========================================================================
   Custom Swatches Styling
   ========================================================================== */
.hf-swatches-wrapper {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 10px;
    margin-bottom: 20px;
}

.hf-swatch-btn {
    border: 1px solid var(--hf-border-dark);
    background-color: var(--hf-white);
    color: var(--hf-dark);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 2px;
    cursor: pointer;
    transition: var(--transition-fast);
}

.hf-swatch-btn:hover {
    border-color: var(--hf-primary);
    color: var(--hf-primary);
}

.hf-swatch-btn.active {
    background-color: var(--hf-primary);
    border-color: var(--hf-primary);
    color: var(--hf-white);
}

/* ==========================================================================
   General Animations & Keyframes
   ========================================================================== */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   Responsive Overrides
   ========================================================================== */
@media (max-width: 768px) {
    .hf-hero {
        height: 65vh;
    }
    
    .hf-categories-grid {
        grid-template-columns: 1fr;
    }
    
    .hf-products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .hf-product-card {
        border-radius: 2px;
    }
    
    .hf-product-details {
        padding: 15px;
    }
    
    .hf-product-title {
        font-size: 15px;
        margin-bottom: 5px;
    }
    
    .hf-qv-modal-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .hf-qv-modal-container {
        padding: 20px;
        width: 95%;
    }
}

@media (max-width: 480px) {
    .hf-products-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Header Utilities Bar (Search, Cart & Hamburger Consolidated)
   ========================================================================== */
.hf-header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-left: auto;
}

.hf-header-actions a {
    color: var(--hf-dark) !important;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
    padding: 5px;
}

.hf-header-actions a:hover {
    color: var(--hf-primary) !important;
    transform: translateY(-2px);
}

.hf-header-actions a svg {
    width: 20px;
    height: 20px;
}

/* Hamburger Toggle Button */
.hf-mobile-menu-toggle {
    display: none !important;
    background: none !important;
    border: none !important;
    padding: 10px 5px !important;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    z-index: 100;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.hf-mobile-menu-toggle .hamburger-bar {
    display: block;
    width: 20px;
    height: 2px;
    background-color: var(--hf-dark);
    transition: var(--transition-fast);
    border-radius: 1px;
}

/* Sliding Mobile Menu Drawer */
.hf-mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    visibility: hidden;
    transition: var(--transition-smooth);
}

.hf-mobile-menu.active {
    visibility: visible;
}

.hf-mobile-menu-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(18, 17, 16, 0.4);
    backdrop-filter: blur(4px);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.hf-mobile-menu.active .hf-mobile-menu-overlay {
    opacity: 1;
}

.hf-mobile-menu-panel {
    position: absolute;
    top: 0;
    left: -320px;
    width: 320px;
    height: 100%;
    background: var(--hf-light);
    box-shadow: 10px 0 40px rgba(18, 17, 16, 0.15);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: left 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 40px 30px;
    box-sizing: border-box;
    z-index: 100000;
}

.hf-mobile-menu.active .hf-mobile-menu-panel {
    left: 0;
}


.hf-mobile-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--hf-border);
    padding-bottom: 20px;
}

.hf-mobile-menu-brand {
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 700;
    color: var(--hf-dark);
}

.hf-mobile-menu-close {
    background: none !important;
    border: none !important;
    padding: 5px !important;
    cursor: pointer;
    color: var(--hf-dark);
    display: flex;
    align-items: center;
    justify-content: center;
}

.hf-mobile-menu-close svg {
    width: 22px;
    height: 22px;
}

.hf-mobile-menu-content {
    flex-grow: 1;
    overflow-y: auto;
    padding: 30px 0;
}

.hf-mobile-nav-list {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.hf-mobile-nav-list li {
    margin-bottom: 20px !important;
}

.hf-mobile-nav-list li a {
    font-family: var(--font-body);
    font-size: 18px;
    font-weight: 500;
    color: var(--hf-dark) !important;
    text-decoration: none;
    letter-spacing: -0.01em;
    display: block;
    transition: var(--transition-fast);
}

.hf-mobile-nav-list li a:hover {
    color: var(--hf-primary) !important;
    transform: translateX(5px);
}

/* Accordion submenu support */
.hf-mobile-nav-list li.menu-item-has-children > a {
    position: relative;
    padding-right: 30px;
}

.hf-mobile-nav-list li.menu-item-has-children > a::after {
    content: '';
    position: absolute;
    right: 5px;
    top: 50%;
    width: 6px;
    height: 6px;
    border-right: 2px solid var(--hf-dark);
    border-bottom: 2px solid var(--hf-dark);
    transform: translateY(-70%) rotate(45deg);
    transition: var(--transition-fast);
}

.hf-mobile-nav-list li.menu-item-has-children.submenu-open > a::after {
    transform: translateY(-30%) rotate(-135deg);
}

.hf-mobile-nav-list li.menu-item-has-children ul.sub-menu {
    list-style: none !important;
    padding: 10px 0 0 15px !important;
    margin: 0 !important;
    display: none;
}

.hf-mobile-nav-list li.menu-item-has-children ul.sub-menu li {
    margin-bottom: 10px !important;
}

.hf-mobile-nav-list li.menu-item-has-children ul.sub-menu li a {
    font-size: 16px;
    color: var(--hf-text) !important;
}

.hf-mobile-menu-footer {
    border-top: 1px solid var(--hf-border);
    padding-top: 20px;
}

.hf-mobile-menu-desc {
    font-size: 13px;
    color: var(--hf-text-light);
    margin-bottom: 10px;
}

.hf-mobile-menu-contact a {
    font-size: 14px;
    font-weight: 500;
    color: var(--hf-primary) !important;
    text-decoration: none;
}

/* Responsive Header & Navigation Toggles */
@media (max-width: 992px) {
    .site-header .col-full {
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 15px 20px !important;
        gap: 15px !important;
    }
    
    .hf-mobile-menu-toggle {
        display: flex !important;
    }
    
    .site-header .main-navigation {
        display: none !important;
    }
    
    .site-header .site-branding {
        max-width: 180px;
    }
    
    .site-branding .site-title {
        font-size: 20px !important;
    }
}

/* ==========================================================================
   Product Catalog Grid — Clean & Reliable
   ========================================================================== */
ul.products {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 30px !important;
    padding: 0 !important;
    list-style: none !important;
    margin: 0 !important;
}

/* Remove clearfix pseudo-elements from grid calculations */
ul.products::before,
ul.products::after {
    content: none !important;
    display: none !important;
}

@media (max-width: 992px) {
    ul.products {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }
}

@media (max-width: 568px) {
    ul.products {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
}

ul.products li.product {
    background-color: var(--hf-white) !important;
    border-radius: 6px !important;
    border: 1px solid var(--hf-border) !important;
    box-shadow: 0 2px 12px rgba(18, 17, 16, 0.04) !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    float: none !important;
    width: auto !important;
}

ul.products li.product:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 12px 28px rgba(18, 17, 16, 0.08) !important;
    border-color: var(--hf-primary) !important;
}

/* Image wrapper — only target the main product link, not buttons */
ul.products li.product a.woocommerce-loop-product__link {
    display: block !important;
    width: 100% !important;
    aspect-ratio: unset !important;
    background: none !important;
    overflow: visible !important;
    float: none !important;
}

/* Product thumbnail image — square crop, fills width */
ul.products li.product img.attachment-woocommerce_thumbnail,
ul.products li.product img.wp-post-image {
    width: 100% !important;
    height: 280px !important;
    object-fit: cover !important;
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
    transition: transform 0.4s ease !important;
    background-color: var(--hf-light) !important;
}

ul.products li.product:hover img.attachment-woocommerce_thumbnail,
ul.products li.product:hover img.wp-post-image {
    transform: scale(1.04) !important;
}

/* Product title */
ul.products li.product .woocommerce-loop-product__title {
    font-family: var(--font-body) !important;
    font-size: 15px !important;
    color: var(--hf-dark) !important;
    margin: 14px 16px 6px !important;
    line-height: 1.4 !important;
    font-weight: 500 !important;
    text-align: left !important;
    letter-spacing: 0.01em !important;
}

/* Product price */
ul.products li.product .price {
    color: var(--hf-primary) !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    margin: 0 16px 16px !important;
    text-align: left !important;
    display: block !important;
}

/* Add to cart / Read more button */
ul.products li.product .button,
ul.products li.product .add_to_cart_button {
    display: block !important;
    width: auto !important;
    aspect-ratio: unset !important;
    background: none !important;
    overflow: visible !important;
    margin: 0 16px 16px !important;
    padding: 10px 20px !important;
    font-size: 13px !important;
    text-align: center !important;
}

/* ==========================================================================
   Single Product Page — 2-Column Layout (Gallery | Details)
   ========================================================================== */

/* Step 1: Kill Storefront's float clearfix */
.single-product div.product::before,
.single-product div.product::after {
    content: '' !important;
    display: table !important;
    clear: both !important;
}

/* Step 2: Force 2-column grid */
.single-product div.product {
    display: grid !important;
    grid-template-columns: minmax(0, 55fr) minmax(0, 45fr) !important;
    column-gap: 50px !important;
    row-gap: 40px !important;
    margin-top: 40px !important;
    align-items: start !important;
    width: 100% !important;
    box-sizing: border-box !important;
    float: none !important;
}

/* Step 3: Gallery — column 1, row 1 */
.single-product div.product .woocommerce-product-gallery,
.single-product div.product .images {
    grid-column: 1 / 2 !important;
    grid-row: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: none !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
}

/* Step 4: Summary — column 2, row 1, sticky */
.single-product div.product .summary.entry-summary {
    grid-column: 2 / 3 !important;
    grid-row: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: none !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    position: sticky !important;
    top: 100px !important;
    align-self: start !important;
}

/* Step 5: Tabs — row 2, full width (both class combos) */
.single-product div.product .woocommerce-tabs,
.single-product .woocommerce-tabs {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: both !important;
    box-sizing: border-box !important;
    margin-top: 20px !important;
}

/* Step 6: Fix Storefront's floated tab nav and panel */
.single-product .woocommerce-tabs ul.tabs {
    float: none !important;
    width: 100% !important;
    display: flex !important;
    flex-wrap: wrap !important;
    padding: 0 !important;
    margin: 0 0 30px 0 !important;
    border: none !important;
    border-bottom: 2px solid #ede9e4 !important;
    background: none !important;
}

.single-product .woocommerce-tabs ul.tabs li {
    float: none !important;
    display: inline-block !important;
}

.single-product .woocommerce-tabs ul.tabs li a {
    float: none !important;
    display: inline-block !important;
    padding: 12px 24px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    color: var(--hf-text-light) !important;
    text-decoration: none !important;
    border: none !important;
    background: none !important;
}

.single-product .woocommerce-tabs ul.tabs li.active a {
    color: var(--hf-primary) !important;
    border-bottom: 2px solid var(--hf-primary) !important;
    margin-bottom: -2px !important;
}

.single-product .woocommerce-tabs .panel {
    float: none !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Step 7: Related and upsells — full width below everything */
.single-product .related.products,
.single-product .up-sells.products,
.single-product section.related,
.single-product section.up-sells {
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: both !important;
    margin-top: 60px !important;
    box-sizing: border-box !important;
}

/* Step 8: Catch-all for any other children of div.product */
.single-product div.product > *:not(.woocommerce-product-gallery):not(.images):not(.summary):not(.entry-summary) {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    max-width: 100% !important;
    float: none !important;
    clear: both !important;
    box-sizing: border-box !important;
}

/* Mobile: everything stacks */
@media (max-width: 992px) {
    .single-product div.product {
        grid-template-columns: 1fr !important;
        column-gap: 0 !important;
        row-gap: 20px !important;
    }

    .single-product div.product .woocommerce-product-gallery,
    .single-product div.product .images,
    .single-product div.product .summary.entry-summary,
    .single-product div.product > * {
        grid-column: 1 / -1 !important;
        position: static !important;
        width: 100% !important;
    }
}

/* ==========================================================================
   Single Product Gallery — Main Image
   ========================================================================== */

/* Keep gallery as default block layout — flex fights Flexslider JS */
.woocommerce-product-gallery {
    position: relative !important;
}

/* Main image: show full product, no crop, light gallery background */
.woocommerce-product-gallery .woocommerce-product-gallery__image,
.woocommerce-product-gallery .woocommerce-product-gallery__wrapper > div {
    background-color: #f7f6f3 !important;
}

.woocommerce-product-gallery .woocommerce-product-gallery__image img,
.woocommerce-product-gallery figure img {
    width: 100% !important;
    height: auto !important;
    max-height: 620px !important;
    object-fit: contain !important;
    display: block !important;
    background-color: #f7f6f3 !important;
}

/* Constrain Flexslider viewport — prevents full-screen height bug */
.woocommerce-product-gallery .flex-viewport {
    max-height: 620px !important;
    overflow: hidden !important;
}

/* Thumbnail strip — horizontal row below main image */
.woocommerce-product-gallery .flex-control-thumbs {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    margin: 10px 0 0 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

.woocommerce-product-gallery .flex-control-thumbs li {
    width: calc(16.666% - 7px) !important;
    min-width: 60px !important;
    max-width: 90px !important;
    float: none !important;
    margin: 0 !important;
    flex-shrink: 0 !important;
}

.woocommerce-product-gallery .flex-control-thumbs li img {
    width: 100% !important;
    aspect-ratio: 1 / 1 !important;
    object-fit: cover !important;
    display: block !important;
    border: 2px solid #ede9e4 !important;
    opacity: 0.7 !important;
    transition: opacity 0.2s, border-color 0.2s !important;
    cursor: pointer !important;
    border-radius: 3px !important;
}

.woocommerce-product-gallery .flex-control-thumbs li img.flex-active,
.woocommerce-product-gallery .flex-control-thumbs li img:hover {
    border-color: var(--hf-primary) !important;
    opacity: 1 !important;
}
