/*
Theme Name: HPDecor
Theme URI: https://hpdecor.ru
Author: iCreative
Description: Кастомная, оптимизированная тема для HPDecor, разработанная для высокой производительности и SEO.
Version: 1.0.0
Text Domain: theme-hpdecor
Tested up to: 8.4
Requires PHP: 8.3
*/

/* ========================================
   CSS Variables   #826251
======================================== */
:root {
    /* Colors - hpdecor.ru palette */
    --color-primary: #000000;
    --color-secondary: #333333;
    --color-accent: #826251;
    --color-text: #4a4a4a;
    --color-text-light: #777777;
    --color-bg: #ffffff;
    --color-light-gray: #f8f8f8;
    --color-border: #e5e5e5;
    --color-border-light: #f0f0f0;

    /* Typography */
    --font-main: 'Libre Franklin', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-heading: 'Playfair Display', Georgia, 'Times New Roman', serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;

    /* Layout */
    --container-width: 1200px;
    --container-padding: 20px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ========================================
   Reset & Base
======================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 500;
    color: var(--color-primary);
    line-height: 1.3;
    margin-bottom: var(--spacing-sm);
}

h1 {
    font-size: 42px;
}

h2 {
    font-size: 42px;
}

h3 {
    font-size: 24px;
}

h4 {
    font-size: 20px;
}

p {
    margin-bottom: var(--spacing-sm);
}

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: #826251;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul,
ol {
    list-style: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

/* ========================================
   Utility Classes
======================================== */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.skip-link {
    position: absolute;
    left: -9999px;
    z-index: 999;
    padding: 1em;
    background-color: var(--color-primary);
    color: #fff;
}

.skip-link:focus {
    left: 0;
}

/* ========================================
   Buttons
======================================== */
.btn {
    display: inline-block;
    padding: 12px 32px;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 2px solid transparent;
    transition: all var(--transition-normal);
    cursor: pointer;
}

.btn-primary {
    background-color: var(--color-primary);
    color: #fff;
    border-color: var(--color-primary);
}

.btn-primary:hover {
    background-color: var(--color-accent);
    border-color: var(--color-accent);
    color: #fff;
}

.btn-outline {
    background-color: transparent;
    color: var(--color-primary);
    border-color: var(--color-primary);
}

.btn-outline:hover {
    background-color: var(--color-primary);
    color: #fff;
}

/* ========================================
   Header - Main
======================================== */
.site-header {
    background-color: #fff;
}

.header-main {
    padding: 6px 0;
    border-bottom: 1px solid transparent;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    padding: 0 40px;
}

/* Header Left - Socials */
.header-left {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.social-icons {
    display: flex;
    gap: 17px;
}

.social-icons a {
    color: var(--color-primary);
    display: flex;
    align-items: center;
    transition: color var(--transition-fast);
    width: 15px;
}

.social-icons a:hover {
    color: var(--color-accent);
}

/* Header Right - Tools */
.header-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 22px;
}

.header-account-wrapper {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.header-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text-main);
    transition: color 0.3s;
    padding: 5px;
}

.header-icon:hover {
    color: var(--color-primary);
}

.nav-menu>li>a:hover,
.nav-menu>li.current-menu-item>a,
.nav-menu>li.current_page_item>a {
    color: #826251;
    position: relative;
    text-decoration: none;
}

.nav-menu>li.current-menu-item>a::after,
.nav-menu>li.current_page_item>a::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 40%;
    height: 1.4px;
    background-color: #826251;
}

/* Account Dropdown */
.account-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    width: 220px;
    background: #ffffff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 1000;
    padding: 10px 0;
    border: 1px solid #f0f0f0;
    border-radius: 4px;
}

.header-account-wrapper:hover .account-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.account-dropdown ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.account-dropdown li a {
    display: block;
    padding: 8px 14px;
    color: #262626;
    font-size: 12px;
    font-family: 'Libre Franklin', var(--font-main);
    font-weight: 400;
    text-transform: none;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
    border-bottom: 1px solid #f9f9f9;
}

.account-dropdown li:last-child a {
    border-bottom: none;
}

.account-dropdown li a:hover {
    background: #f9f9f9;
    color: var(--color-primary);
}

.header-tools-wrapper {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Header Search Form */
.header-search-form {
    display: flex;
    align-items: center;
    border-bottom: 1px solid #e5e5e5;
    padding-bottom: 3px;
    margin-right: 15px;
}

.header-search-input {
    border: none;
    background: transparent;
    font-family: var(--font-main);
    font-size: 13px;
    color: #777;
    width: 100px;
    padding: 0;
    outline: none;
    transition: width 0.3s ease;
}

.header-search-input:focus {
    width: 160px;
    color: #000;
}

.header-search-input::placeholder {
    color: #999;
    opacity: 1;
}

.header-search-btn {
    padding: 0;
    color: var(--color-primary);
    display: flex;
    align-items: center;
}

.header-search-btn svg {
    width: 16px;
    height: 16px;
}

/* Tools Icons */
.tool-link {
    color: var(--color-primary);
    display: flex;
    align-items: center;
    transition: color var(--transition-fast);
}

.tool-link:hover {
    color: var(--color-accent);
}

.cart-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.cart-count-bubble {
    position: absolute;
    top: -5px;
    right: -8px;
    background-color: var(--color-primary);
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    border-radius: 50%;
    width: 15px;
    height: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* Logo - Center */
.site-branding {
    flex: 0 0 auto;
    text-align: center;
}

.site-branding .custom-logo {
    max-width: 100%;
    height: auto;
    max-height: 108px;
    width: auto;
    display: block;
}

.site-title {
    font-family: var(--font-heading);
    font-size: 28px;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--color-primary);
    margin: 0;
}

.site-title a {
    color: inherit;
}

.site-description {
    display: none;
}

/* ========================================
   Main Navigation
======================================== */
.main-navigation {
    background-color: #fff;
    width: 100%;
    text-align: left;
    padding: 0 0 25px;
    padding: 0 0 25px;
}

.main-navigation .container {
    display: flex;
    justify-content: center;
}

.nav-menu {
    display: flex;
    justify-content: center;
    gap: 0;
}

.nav-menu>li {
    position: relative;
}

.nav-menu>li>a {
    display: block;
    padding: 5px 15px;
    font-family: 'Libre Franklin', var(--font-main);
    font-size: 14px;
    font-weight: 600;
    text-transform: none;
    letter-spacing: normal;
    color: #262626;
    transition: color var(--transition-fast);
}

.nav-menu>li:hover>a {
    color: var(--color-accent);
}

/* Dropdown / Mega Menu */
.nav-menu .sub-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    min-width: 220px;
    background-color: #fff;
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
    z-index: 100;
    padding: 10px 0;
}

.nav-menu>li:hover>.sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.sub-menu li {
    border-bottom: none;
}

.sub-menu a {
    display: block;
    padding: 8px 14px;
    font-size: 12px;
    color: var(--color-text);
}

.sub-menu a:hover {
    background-color: var(--color-light-gray);
    color: var(--color-accent);
}

/* Menu Toggle (Mobile Burger) */
.menu-toggle {
    display: none;
    width: 28px;
    height: 22px;
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    padding: 0;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 100;
}

.menu-icon {
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--color-primary);
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    transition: all var(--transition-fast);
}

.menu-icon::before,
.menu-icon::after {
    content: '';
    display: block;
    width: 100%;
    height: 2px;
    background-color: var(--color-primary);
    position: absolute;
    left: 0;
    transition: all var(--transition-fast);
}

.menu-icon::before {
    top: -7px;
}

.menu-icon::after {
    top: 7px;
}

/* Actions removed/integrated into Header Right */

.cart-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    font-size: 11px;
    font-weight: 600;
    background-color: var(--color-accent);
    color: #fff;
    border-radius: 50%;
}

.cart-total {
    font-size: 14px;
    font-weight: 500;
}

/* ========================================
   Search Overlay
======================================== */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: #fff;
    padding: 20px;
    box-shadow: var(--shadow-lg);
    transform: translateY(-100%);
    transition: transform var(--transition-normal);
    z-index: 1000;
}

.search-overlay.active {
    transform: translateY(0);
}

.search-form {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    max-width: 600px;
    margin: 0 auto;
}

.search-field {
    flex-grow: 1;
    padding: 15px 20px;
    font-size: 16px;
    border: 1px solid var(--color-border);
    outline: none;
    transition: border-color var(--transition-fast);
}

.search-field:focus {
    border-color: var(--color-primary);
}

.search-submit {
    padding: 15px;
    background-color: var(--color-primary);
    color: #fff;
}

.search-close {
    font-size: 28px;
    padding: 10px;
    color: var(--color-text);
}

/* ========================================
   Mobile Menu
======================================== */
.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
    z-index: 998;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 300px;
    max-width: 85vw;
    background-color: #fff;
    transform: translateX(-100%);
    transition: transform var(--transition-normal);
    z-index: 999;
    overflow-y: auto;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
}

.mobile-menu.active {
    transform: translateX(0);
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--color-border-light);
}

.mobile-menu-title {
    font-size: 18px;
    font-weight: 600;
    font-family: var(--font-heading);
}

.mobile-menu-close {
    font-size: 32px;
    color: var(--color-text);
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color var(--transition-fast);
}

.mobile-menu-close:hover {
    color: var(--color-accent);
}

.mobile-nav-menu {
    padding: 10px 20px 20px;
}

.mobile-nav-menu > li {
    border-bottom: 1px solid var(--color-border-light);
    position: relative;
}

.mobile-nav-menu > li:last-child {
    border-bottom: none;
}

.mobile-nav-menu > li > a {
    display: block;
    padding: 15px 0;
    font-size: 16px;
    font-weight: 500;
    color: var(--color-primary);
    transition: color var(--transition-fast);
}

.mobile-nav-menu > li > a:hover {
    color: var(--color-accent);
}

/* Submenu toggle button */
.mobile-nav-menu .submenu-toggle {
    position: absolute;
    right: 0;
    top: 10px;
    width: 36px;
    height: 36px;
    background: var(--color-light-gray);
    border: none;
    border-radius: 4px;
    font-size: 20px;
    font-weight: 300;
    color: var(--color-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.mobile-nav-menu .submenu-toggle:hover {
    background: var(--color-accent);
    color: #fff;
}

.mobile-nav-menu .sub-menu {
    padding-left: 15px;
    margin-bottom: 10px;
}

.mobile-nav-menu .sub-menu li {
    border-bottom: none;
}

.mobile-nav-menu .sub-menu a {
    display: block;
    padding: 10px 0;
    font-size: 14px;
    color: var(--color-text);
    transition: color var(--transition-fast);
}

.mobile-nav-menu .sub-menu a:hover {
    color: var(--color-accent);
}

.footer-bottom p {
    margin: 0;
    font-size: 12px;
    line-height: 1.2;
    color: #ffffff;
    opacity: 1;
    font-family: 'Libre Franklin', var(--font-main);
}

/* ========================================
   Hero Section
======================================== */
.hero-section {
    background-color: var(--color-bg);
    margin-bottom: 0;
}

/* For Revolution Slider */
.hero-section .rev_slider_wrapper {
    margin-bottom: 0 !important;
}

/* ========================================
   Sections
======================================== */
.section {
    padding: var(--spacing-lg) 0;
}

.section-title {
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: var(--spacing-md);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 2px;
    background-color: var(--color-accent);
    margin: var(--spacing-sm) auto 0;
}

/* ========================================
   Product Grid
======================================== */
.products-section {
    background-color: var(--color-bg);
}

.product-grid {
    display: flex;
    gap: var(--spacing-md);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: var(--spacing-sm);
    scrollbar-width: thin;
    scrollbar-color: var(--color-border) transparent;
}

.product-grid::-webkit-scrollbar {
    height: 6px;
}

.product-grid::-webkit-scrollbar-track {
    background: var(--color-light-gray);
}

.product-grid::-webkit-scrollbar-thumb {
    background-color: var(--color-border);
    border-radius: 3px;
}

.product-card {
    flex: 0 0 calc((100% - var(--spacing-md) * 3) / 4);
    min-width: 260px;
    scroll-snap-align: start;
    text-align: center;
}

.product-link {
    display: block;
    color: inherit;
}

.product-link:hover .product-title {
    color: var(--color-accent);
}

.product-image {
    position: relative;
    margin-bottom: var(--spacing-sm);
    overflow: hidden;
    background-color: var(--color-light-gray);
}

.product-image img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.placeholder-image {
    width: 100%;
    padding-top: 100%;
    background-color: var(--color-light-gray);
}

.product-title {
    font-family: var(--font-main);
    font-size: 15px;
    font-weight: 500;
    color: var(--color-primary);
    margin-bottom: var(--spacing-xs);
    transition: color var(--transition-fast);
}

.product-price {
    font-size: 15px;
    font-weight: 600;
    color: var(--color-accent);
}

.product-price del {
    color: var(--color-text-light);
    font-weight: 400;
    margin-right: 8px;
}

/* ========================================
   Welcome Section
======================================== */
.welcome-text {
    background-image: url('http://hpdecor.ru/web/wp-content/uploads/2025/12/furniture.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding-top: 190px;
    padding-bottom: 190px;
    color: #ffffff;
    position: relative;
    z-index: 1;
}

.welcome-text::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: -1;
}

.welcome-content h2 {
    font-family: "Playfair Display", "Helvetica Neue", Arial, sans-serif;
    font-size: 42px;
    font-weight: 400;
    color: #ffffff;
}

.welcome-description {
    max-width: 900px;
    margin: 0 auto;
    font-family: "Playfair Display", "Helvetica Neue", Arial, sans-serif;
    font-size: 18px;
    line-height: 1.6;
    color: #ffffff;
}

/* ========================================
   Blog Grid
======================================== */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
}

.blog-card {
    background-color: #fff;
    border: 1px solid var(--color-border-light);
    overflow: hidden;
    transition: box-shadow var(--transition-normal);
}

.blog-card:hover {
    box-shadow: var(--shadow-md);
}

.blog-link {
    display: block;
    color: inherit;
}

.blog-image {
    overflow: hidden;
    background-color: var(--color-light-gray);
}

.blog-image img {
    width: 100%;
    aspect-ratio: 3/2;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

.blog-card:hover .blog-image img {
    transform: scale(1.05);
}

.blog-content {
    padding: var(--spacing-sm);
}

.blog-meta {
    font-size: 13px;
    color: var(--color-text-light);
    margin-bottom: var(--spacing-xs);
}

.blog-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--color-primary);
    margin: var(--spacing-sm);
    transition: color var(--transition-fast);
}

.blog-card:hover .blog-title {
    color: var(--color-accent);
}

.blog-excerpt {
    font-size: 14px;
    color: var(--color-text-light);
    padding: 0 var(--spacing-sm) var(--spacing-sm);
}

/* ========================================
   Page Content (Gutenberg)
======================================== */
.page-content,
.entry-content {
    line-height: 1.8;
}

.entry-content>* {
    max-width: var(--container-width);
    margin-left: auto;
    margin-right: auto;
}

.entry-content>.alignwide {
    max-width: calc(var(--container-width) + 200px);
}

.entry-content>.alignfull {
    max-width: none;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
}

.entry-content h2 {
    margin-top: var(--spacing-lg);
}

.entry-content p,
.entry-content ul,
.entry-content ol {
    margin-bottom: var(--spacing-md);
}

/* ========================================
   Page Templates
======================================== */
.page-container {
    padding: var(--spacing-lg) 0;
}

.page-header {
    margin-bottom: var(--spacing-lg);
    text-align: center;
}

.page-title {
    font-size: 2.5rem;
}

.page-thumbnail {
    margin-bottom: var(--spacing-lg);
}

.page-thumbnail img {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
}

/* Single Post */
.single-article {
    max-width: 800px;
    margin: 0 auto;
    padding: var(--spacing-lg) 0;
}

.entry-header {
    margin-bottom: var(--spacing-lg);
    text-align: center;
}

.entry-meta {
    font-size: 14px;
    color: var(--color-text-light);
    margin-bottom: var(--spacing-sm);
}

.entry-meta span {
    margin: 0 8px;
}

.entry-categories a {
    color: var(--color-accent);
}

.entry-title {
    font-size: 2.5rem;
    line-height: 1.2;
}

.entry-thumbnail {
    margin-bottom: var(--spacing-lg);
}

.entry-thumbnail img {
    width: 100%;
    border-radius: 4px;
}

.entry-footer {
    margin-top: var(--spacing-lg);
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--color-border);
}

.entry-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.tags-label {
    font-weight: 500;
}

.tag-link {
    padding: 4px 12px;
    font-size: 13px;
    background-color: var(--color-light-gray);
    border-radius: 3px;
}

.tag-link:hover {
    background-color: var(--color-accent);
    color: #fff;
}

/* Post Navigation */
.post-navigation {
    margin-top: var(--spacing-lg);
    padding: var(--spacing-md) 0;
    border-top: 1px solid var(--color-border);
    border-top: 1px solid var(--color-border);
}

.nav-links {
    display: flex;
    justify-content: space-between;
}

.nav-previous a,
.nav-next a {
    color: var(--color-primary);
    font-weight: 500;
}

/* Archive */
.archive-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
    padding: var(--spacing-lg) 0;
    background-color: #fff;
}

.archive-title {
    font-size: 2rem;
}

.archive-description {
    max-width: 600px;
    margin: 0 auto;
    color: var(--color-text-light);
}

.archive-grid {
    margin-bottom: var(--spacing-lg);
}

.pagination-nav {
    text-align: center;
}

.pagination-nav .page-numbers {
    display: inline-flex;
    gap: 4px;
}

.pagination-nav a,
.pagination-nav span {
    display: inline-block;
    padding: 10px 16px;
    border: 1px solid var(--color-border);
    transition: all var(--transition-fast);
}

.pagination-nav a:hover,
.pagination-nav .current {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

/* No Results */
.no-results {
    text-align: center;
    padding: var(--spacing-xl) 0;
}

/* ========================================
   Footer
======================================== */
.site-footer {
    margin-top: 0px;
}

.footer-main {
    background-image: url('http://hpdecor.ru/web/wp-content/uploads/2025/12/footer-bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: var(--spacing-xl) 0 var(--spacing-lg);
}

.footer-widgets {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-lg);
}

.footer-column h4 {
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: var(--spacing-md);
    color: #ffffff;
}

.footer-description {
    font-size: 14px;
    line-height: 1.7;
    color: #ffffff;
    margin-bottom: var(--spacing-md);
}

.footer-menu {
    list-style: none;
}

.footer-menu li {
    margin-bottom: 10px;
}

.footer-menu a {
    font-size: 12px;
    color: #ffffff;
    transition: color var(--transition-fast);
}

.footer-menu a:hover {
    color: #826251;
}

.footer-menu a:hover {
    color: var(--color-accent);
}

.footer-contacts p {
    margin-bottom: 8px;
    color: #ffffff;
}

.footer-contacts a {
    font-size: 14px;
    color: #ffffff;
}

.social-links {
    display: flex;
    gap: 12px;
    margin-top: var(--spacing-md);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background-color: var(--color-primary);
    color: #fff;
    border-radius: 50%;
    transition: background-color var(--transition-fast);
}

.social-link:hover {
    background-color: var(--color-accent);
    color: #fff;
}

.social-link svg {
    width: 18px;
    height: 18px;
}

.footer-bottom {
    background-color: #1a1a1a;
    padding: 12px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.site-info {
    text-align: center;
}

.copyright {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
}


/* ========================================
   Search Results Page
======================================== */
.search-results-page {
    max-width: 1240px;
    margin: 0 auto;
    padding: 40px 20px;
}

.search-header {
    text-align: center;
    margin-bottom: 40px;
}

.search-title {
    font-family: 'Playfair Display', serif;
    font-size: 36px;
    font-weight: 400;
    color: #262626;
    margin-bottom: 15px;
}

.search-title span {
    font-style: italic;
}

.search-breadcrumbs {
    font-family: 'Libre Franklin', sans-serif;
    font-size: 14px;
    color: #777;
}

.search-breadcrumbs a {
    color: #777;
    text-decoration: none;
    transition: color 0.3s ease;
}

.search-breadcrumbs a:hover {
    color: #262626;
}

.search-breadcrumbs .separator {
    margin: 0 10px;
    color: #ccc;
}

.search-breadcrumbs .current {
    color: #262626;
}

/* Search Results Grid - same as catalog */
.search-results ul.products {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 30px !important;
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.search-results ul.products::before,
.search-results ul.products::after {
    display: none !important;
    content: none !important;
}

/* Search Pagination */
.search-pagination {
    margin-top: 50px;
    text-align: center;
}

.search-pagination .nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.search-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #ddd;
    color: #262626;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
}

.search-pagination .page-numbers:hover {
    background: #262626;
    border-color: #262626;
    color: #fff;
}

.search-pagination .page-numbers.current {
    background: #262626;
    border-color: #262626;
    color: #fff;
}

/* No Results */
.search-no-results {
    text-align: center;
    padding: 60px 20px;
}

.search-no-results h2 {
    font-family: 'Playfair Display', serif;
    font-size: 28px;
    color: #262626;
    margin-bottom: 15px;
}

.search-no-results p {
    font-size: 16px;
    color: #777;
    margin-bottom: 30px;
}

.search-form-container {
    max-width: 500px;
    margin: 0 auto;
}

.search-form-container .search-form {
    display: flex;
    gap: 10px;
}

.search-form-container .search-field {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid #ddd;
    font-size: 16px;
}

.search-form-container .search-submit {
    padding: 12px 25px;
    background: #262626;
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 14px;
    text-transform: uppercase;
    transition: background 0.3s ease;
}

.search-form-container .search-submit:hover {
    background: #826251;
}

/* Responsive */
@media (max-width: 1024px) {
    .search-results ul.products {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 768px) {
    .search-results ul.products {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 20px !important;
    }

    .search-title {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .search-results ul.products {
        grid-template-columns: 1fr !important;
    }

    .search-title {
        font-size: 24px;
    }
}

/* ========================================
   Live Search Dropdown
======================================== */
.header-search-form {
    position: relative;
}

.live-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    min-width: 320px;
    max-width: 400px;
    background: #fff;
    border: none;
    border-radius: 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    display: none;
    margin-top: 2px;
}

.live-search-loading,
.live-search-no-results {
    padding: 15px 20px;
    text-align: center;
    color: var(--color-text-light);
    font-size: 14px;
}

.live-search-results {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 400px;
    overflow-y: auto;
}

.live-search-item {
    border-bottom: 1px solid var(--color-border-light);
}

.live-search-item:last-child {
    border-bottom: none;
}

.live-search-item a {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    text-decoration: none;
    color: var(--color-text);
    transition: background-color var(--transition-fast);
}

.live-search-item a:hover,
.live-search-item.focused a {
    background-color: var(--color-light-gray);
}

.live-search-item-image {
    width: 50px;
    height: 50px;
    flex-shrink: 0;
    margin-right: 12px;
    background: var(--color-light-gray);
    border-radius: 0;
    overflow: hidden;
}

.live-search-item-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.live-search-item-info {
    flex: 1;
    min-width: 0;
}

.live-search-item-title {
    display: block;
    font-family: var(--font-heading);
    font-size: 14px;
    font-weight: 400;
    color: var(--color-primary);
    line-height: 1.3;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.live-search-item-title mark {
    background-color: rgba(130, 98, 81, 0.2);
    color: inherit;
    padding: 0 2px;
    border-radius: 2px;
}

.live-search-item-price {
    display: block;
    font-size: 13px;
    color: var(--color-text-light);
}

.live-search-item-price del {
    opacity: 0.6;
    margin-right: 5px;
}

.live-search-item-price ins {
    text-decoration: none;
    color: var(--color-accent);
}

.live-search-view-all {
    display: block;
    padding: 12px 15px;
    text-align: center;
    background: var(--color-light-gray);
    color: var(--color-accent);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    border-top: 1px solid var(--color-border);
    transition: background-color var(--transition-fast);
}

.live-search-view-all:hover {
    background: #f0f0f0;
}

/* Mobile adjustments */
@media (max-width: 768px) {
    .live-search-dropdown {
        min-width: 280px;
        left: auto;
        right: 0;
    }
}

/* ========================================
   Responsive Design
======================================== */
@media (max-width: 1199px) {

    h2,
    .h2 {
        font-size: 24px;
    }

    h4,
    .h4 {
        font-size: 18px;
    }
}

@media (max-width: 1024px) {
    .footer-widgets {
        grid-template-columns: 1fr 1fr;
    }

    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .woocommerce ul.products {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    :root {
        --spacing-lg: 3rem;
        --spacing-xl: 4rem;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    /* Header */
    .header-top {
        display: none;
    }

    .main-navigation {
        display: none;
    }

    /* Show burger menu on mobile */
    .menu-toggle {
        display: block;
    }

    .header-inner {
        padding: 15px 20px;
        justify-content: center;
        position: relative;
    }

    /* Hide social icons on mobile */
    .header-left {
        display: none;
    }

    /* Center logo on mobile */
    .site-branding {
        flex: 0 0 auto;
    }

    .site-branding .custom-logo {
        max-height: 70px;
    }

    /* Header right - adjust for mobile */
    .header-right {
        position: absolute;
        right: 15px;
        top: 50%;
        transform: translateY(-50%);
        gap: 12px;
    }

    .header-tools-wrapper {
        gap: 12px;
    }

    /* Hide search form on mobile */
    .header-search-form {
        display: none;
    }

    .site-title {
        font-size: 22px;
    }

    .cart-total {
        display: none;
    }

    /* Products */
    .product-card {
        flex: 0 0 calc((100% - var(--spacing-md)) / 2);
        min-width: 160px;
    }

    /* Blog */
    .blog-grid {
        grid-template-columns: 1fr;
    }

    /* Footer */
    .footer-widgets {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    /* Footer copyright - smaller font on mobile */
    .footer-bottom p {
        font-size: 10px;
        line-height: 1.4;
        padding: 0 15px;
    }

    .copyright {
        font-size: 10px;
    }

    /* WooCommerce */
    .woocommerce ul.products {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Page */
    .page-title,
    .entry-title {
        font-size: 1.8rem;
    }

    .single-article {
        padding: var(--spacing-md) 0;
    }
}

@media (max-width: 480px) {
    .product-card {
        flex: 0 0 100%;
        min-width: 100%;
    }

    .btn {
        display: block;
        width: 100%;
        text-align: center;
    }

    .section-title {
        font-size: 1.2rem;
        letter-spacing: 2px;
    }

    .welcome-description {
        font-size: 16px;
    }

    /* Footer copyright - even smaller on small mobile */
    .footer-bottom p {
        font-size: 9px;
        line-height: 1.5;
    }

    .copyright {
        font-size: 9px;
    }

    /* Header adjustments for very small screens */
    .site-branding .custom-logo {
        max-height: 55px;
    }

    .header-right {
        gap: 8px;
    }

    .header-tools-wrapper {
        gap: 8px;
    }
}

/* ========================================
   Cookie Consent Banner
======================================== */
.cookie-consent {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.95);
    color: #fff;
    padding: 20px;
    z-index: 9999;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
}

.cookie-consent-inner {
    max-width: var(--container-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.cookie-consent-text {
    flex: 1;
}

.cookie-consent-text p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
}

.cookie-consent-text a {
    color: var(--color-accent);
    text-decoration: underline;
}

.cookie-consent-text a:hover {
    color: #fff;
}

.cookie-consent-actions {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

.cookie-btn {
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.cookie-btn-accept {
    background-color: var(--color-accent);
    color: #000;
}

.cookie-btn-accept:hover {
    background-color: #e5c349;
}

.cookie-btn-decline {
    background-color: transparent;
    color: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.cookie-btn-decline:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.6);
}

@media (max-width: 768px) {
    .cookie-consent-inner {
        flex-direction: column;
        text-align: center;
    }

    .cookie-consent-text p {
        font-size: 13px;
    }

    .cookie-consent-actions {
        width: 100%;
        justify-content: center;
    }

    .cookie-btn {
        flex: 1;
        max-width: 150px;
    }
}