/*
Theme Name: Willow Tax & Legal v2
Theme URI: https://willowtaxlegal.com
Author: Senior WordPress Developer
Description: A minimalistic, corporate legal WordPress theme based on brand guidebook.
Version: 2.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: willow-theme
*/

/* ============================================================================
   CSS VARIABLES (Design Tokens)
   ============================================================================ */

:root {
    --willow-purple: #322242;
    --willow-coffee: #E0BA95;
    --willow-white: #FFFFFF;
    --willow-lavender: #C7B6D8;
    --willow-astronomist: #52366E;
    --willow-dark: #151515;
    --willow-light-gray: #E7E7E7;
    --max-width: 1400px;
    --spacing-unit: 1rem;
}

/* ============================================================================
   BASE RESET & TYPOGRAPHY
   ============================================================================ */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    font-size: 1rem;
    line-height: 1.7;
    color: var(--willow-astronomist);
    background-color: var(--willow-white);
    letter-spacing: 0.02em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 400;
    margin-bottom: 1rem;
    color: var(--willow-purple);
    letter-spacing: 0.02em;
}

h1 {
    font-size: 3rem;
    line-height: 1.1;
}

h2 {
    font-size: 2rem;
    font-weight: 300;
    line-height: 1.2;
}

h3 {
    font-size: 1.5rem;
    font-weight: 400;
}

a {
    color: inherit;
    transition: color 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

p {
    margin-bottom: 1rem;
}

.hidden {
    display: none !important;
}

ul.style-none {
    list-style: none;
}

/* ============================================================================
   CONTAINER & LAYOUT
   ============================================================================ */

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

body.menu-open {
    overflow: hidden;
}


/* ============================================================================
   BUTTON COMPONENT
   ============================================================================ */

.btn {
    display: inline-block;
    padding: 14px 28px;
    border: 1px solid transparent;
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    border-radius: 0;
    text-decoration: none;
}

.btn-primary {
    background-color: var(--willow-coffee);
    color: var(--willow-purple);
}

.btn-primary:hover {
    background-color: var(--willow-white);
    color: var(--willow-purple);
    border: 1px solid var(--willow-purple);
}

.btn-contact {
    height: 48px;
    line-height: 18px;
    background-color: var(--willow-coffee);
    color: var(--willow-purple);
}

.btn-contact:hover {
    background-color: var(--willow-white);
    color: var(--willow-purple);
    border: 1px solid var(--willow-purple);
}

/* ============================================================================
   TOP BAR
   ============================================================================ */

.top-bar {
    background-color: var(--willow-white);
    border-bottom: 1px solid var(--willow-light-gray);
    padding: 12px 0;
    font-size: 1rem;
    font-weight: 200;
    letter-spacing: 0.02em;
}

.top-bar-content {
    display: flex;
    justify-content: space-between; /* Разносим поиск и ссылки по краям */
    align-items: center;
}

.top-bar-links {
    display: flex;
    gap: 24px;
    align-items: center;
}

.top-bar-links a {
    text-decoration: none;
    color: var(--willow-purple);
}

.top-bar-links a:hover {
    color: var(--willow-coffee);
}

/* Контейнер поиска */
.top-bar-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Кнопка-иконка поиска */
.search-toggle {
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: var(--willow-purple);
    transition: color 0.2s ease, transform 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
}

.search-toggle:hover {
    color: var(--willow-coffee);
    background-color: rgba(50, 34, 66, 0.05);
}

.search-toggle:focus {
    outline: 2px solid var(--willow-purple);
    outline-offset: 2px;
}

.search-icon {
    width: 18px;
    height: 18px;
}

/* Форма поиска (скрыта по умолчанию) */
.search-form {
    display: flex;
    align-items: center;
    gap: 4px;
    background-color: var(--willow-white);
    border: 1px solid var(--willow-purple);
    border-radius: 20px;
    padding: 4px 12px;
    transition: all 0.3s ease;
}

/* Поле ввода */
.search-form input[type="search"] {
    border: none;
    background: transparent;
    font-size: 0.9rem;
    font-weight: 300;
    color: var(--willow-purple);
    padding: 4px 0;
    width: 90px;
    outline: none;
}

.search-form input[type="search"]::placeholder {
    color: var(--willow-purple);
    opacity: 0.6;
}

/* Кнопка отправки */
.search-submit {
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: var(--willow-purple);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.search-submit:hover {
    color: var(--willow-coffee);
}

.search-submit svg {
    width: 14px;
    height: 14px;
}

/* Адаптив */
@media (max-width: 768px) {
    .search-form input[type="search"] {
        min-width: 80px;
    }
}


/* ============================================================================
   HEADER & NAVIGATION
   ============================================================================ */

.site-header {
    background-color: var(--willow-purple);
    padding: 15px 0;
    position: sticky;
    top: 32px;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.site-header a {
    text-decoration: none;
}

.menu-toggle {
    display: none;
}

.header-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}


/* Main Navigation */
.main-navigation {
    display: flex;
}

.main-navigation ul {
    display: flex;
    gap: 75px;
    list-style: none;
}

.main-navigation li {
    white-space: nowrap;
}

.main-navigation a {
    color: var(--willow-white);
    font-size: 0.9rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: color 0.3s ease;
}

.main-navigation a:hover {
    color: var(--willow-coffee);
}

/* Header CTA Group */
.header-cta-group {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
}

/* === DROPDOWN MENU === */

/* Пункты меню с подменю */
.main-navigation li.menu-item-has-children {
    position: relative;
}

/* Стрелочка для пунктов с подменю */
.main-navigation li.menu-item-has-children > a::after {
    content: '▼';
    font-size: 6px;
    margin-left: 6px;
    color: var(--willow-coffee);
    display: inline-block;
    transition: transform 0.3s ease;
    vertical-align: middle;
}

/* Выпадающий список (скрыт по умолчанию) */
.main-navigation .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--willow-white);
    min-width: 220px;
    box-shadow: 0 4px 12px rgba(50, 34, 66, 0.15);
    border-top: 2px solid var(--willow-coffee);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 1000;
    list-style: none;
    padding: 0;
    margin: 0;
    flex-direction: column;
    gap: 0;
}

/* Показываем dropdown при hover */
.main-navigation li.menu-item-has-children:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Пункты подменю */
.main-navigation .sub-menu li {
    border-bottom: 1px solid var(--willow-light-gray);
    width: 100%;
}

.main-navigation .sub-menu li:last-child {
    border-bottom: none;
}

.main-navigation .sub-menu a {
    display: block;
    padding: 12px 20px;
    font-size: 0.85rem;
    color: var(--willow-purple);
    text-transform: none;
    letter-spacing: 0.02em;
    background-color: var(--willow-white);
    border-left: 3px solid transparent;
}

.main-navigation .sub-menu a:hover {
    background-color: var(--willow-lavender);
    color: var(--willow-purple);
    border-left-color: var(--willow-coffee);
}

/* Поворот стрелочки при открытии */
.main-navigation li.menu-item-has-children:hover > a::after {
    transform: rotate(180deg);
}

.home-icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  transition: all 0.3s ease;
  color: var(--willow-purple);
}

.home-icon-link:hover {
  background-color: var(--willow-astronomist);
  color: var(--willow-astronomist);
}

.home-icon-link svg {
  width: 20px;
  height: 20px;
}



.rss-icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: transparent;
  transition: all 0.3s ease;
  color: #FFFFFF; /* Белый контур иконки */
  text-decoration: none;
  padding: 0;
  border: 1px solid transparent;
}

.rss-icon-link:hover {
  background-color: var(--willow-astronomist, #52366E);
}

.rss-icon-link svg {
    margin-right: -3px;
    margin-top: -3px;
    width: 20px;
    height: 20px;
    transition: stroke 0.3s ease;
}


/* ============================================================================
   HERO SECTION
   ============================================================================ */

.hero-section {
    background-color: var(--willow-purple);
    color: var(--willow-white);
    padding: 120px 0;
    text-align: left;
}

.hero-content {
    position: relative;
    margin: 0 auto;
    max-width: 900px;
    text-align: center;
}

.hero-logo {
    margin: 0 auto 24px;
}

.hero-subtitle {
    position: relative;
    margin-bottom: 40px;
    color: var(--willow-lavender);
    font-size: 1.2rem;
    font-weight: 300;
    line-height: 1.6;
    letter-spacing: 0.02em;
    z-index: 1;
}

.hero-subtitle/* ============================================================================
   SECTIONS
   ============================================================================ */

.page-section,
.blog-section,
.single-post-section {
    padding: 100px 0;
}

.show_more-link {
    margin-top: 24px;
    text-align: center;
}

.ecosystem-section,
.featured-cases,
.press-center-section {
    padding: 100px 0;
}

.ecosystem-section h2,
.featured-cases h2,
.press-center-section h2 {
    text-align: center;
    margin-bottom: 60px;
}

/* Ecosystem Grid */
.ecosystem-section {
    background-color: var(--willow-light-gray);
}


.ecosystem-section h2 {
    color: var(--willow-astronomist);
}

.ecosystem-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

@media (max-width: 768px) {
    .ecosystem-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}

.ecosystem-card {
    padding: 40px;
    border: 1px solid var(--willow-light-gray);
    background-color: var(--willow-white);
    text-decoration: none;
    transition: transform 0.3s ease;
}

.ecosystem-card:hover {
    transform: translateY(-5px);
}

.ecosystem-card h3 {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

/* Обертка для иконки */
.ecosystem-card .card-icon {
  display: inline-flex;
  margin-right: 6px;
  height: 24px;
  color: var(--willow-coffee);
}

/* Настройки SVG внутри */
.card-icon svg {
  width: 100%;
  height: 100%;
  /* stroke-width можно подправить здесь, если линии слишком тонкие/толстые */
}

.ecosystem-card p {
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--willow-astronomist);
}

/* Cases Grid */
.featured-cases {
    padding-top: 0;
}

.cases-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

@media (max-width: 768px) {
    .cases-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}

.case-card {
    border: 1px solid var(--willow-light-gray);
    background-color: var(--willow-white);
}

.case-card:hover {
    box-shadow: 0 4px 12px rgba(50, 34, 66, 0.15);
}

.case-card-link {
    display: block;
}

.case-card__image {
    filter: grayscale(100%);
}

.case-card__image:hover {
    filter: none
}

.case-card__text {
    padding: 40px;
    text-decoration: none;
}

.case-card h3 {
    margin-bottom: 15px;
}

/* Press Center - Front-page */
.press-tabs {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
    justify-content: center;
}

.press-tab {
    background: none;
    border: none;
    color: var(--willow-purple);
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    cursor: pointer;
    padding: 10px 20px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.press-tab.active {
    border-bottom-color: var(--willow-coffee);
    color: var(--willow-coffee);
}

.press-tab-content .content-posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin: 32px 0;
}

/* Адаптив */
@media (max-width: 768px) {
    .press-tabs {
        gap: 10px
    }
    .press-tab {
        padding: 5px 10px;
    }
    .press-tab-content .content-posts-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}

/* === CARD POST STYLES === */
.content-item {
    background: var(--willow-white);
    border: 1px solid var(--willow-light-gray);
    padding: 24px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.content-item:hover {
    border-color: var(--willow-purple);
    box-shadow: 0 4px 12px rgba(50, 34, 66, 0.08);
}

.content-item-link {
    display: flex;
    flex-direction: column;
    height: 100%;
    text-decoration: none;
    color: var(--willow-purple);
}

/* === DATE === */
.content-date {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300; /* Light */
    font-size: 14px;
    color: var(--willow-purple);
    opacity: 0.7;
    display: block;
    margin-bottom: 12px;
}

/* === TITLE === */
.content-item-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400; /* Regular */
    font-size: 20px;
    line-height: 1.4;
    color: var(--willow-purple);
    margin: 0 0 12px 0;
}

/* === EXCERPT === */
.content-item-excerpt {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300; /* Light */
    font-size: 15px;
    line-height: 1.6;
    color: var(--willow-purple);
    margin: 0 0 16px 0;
}

/* === CATEGORY LABELS === */
.content-item-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--willow-light-gray);
}

.content-category-label {
    font-family: 'Montserrat', sans-serif;
    font-weight: 200; /* ExtraLight */
    font-size: 12px; /* 0.85X по гайдбуку */
    letter-spacing: 0.5px;
    color: var(--willow-purple);
    background: #F8F9FA;
    padding: 4px 10px;
    border-radius: 2px;
    text-transform: uppercase;
    opacity: 0.8;
}

/* === GRID LAYOUT === */
.content-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    margin: 32px 0;
}

/* === PAGINATION === */
.content-pagination a,
.content-pagination span {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    font-size: 14px;
    color: var(--willow-purple);
    padding: 8px 16px;
    border: 1px solid var(--willow-light-gray);
    text-decoration: none;
    transition: all 0.3s ease;
}

.content-pagination a:hover,
.content-pagination .current {
    background: var(--willow-purple);
    color: #FFFFFF;
    border-color: var(--willow-purple);
}

/* ============================================================================
PRESS CENTER  - CATEGORY BAR
============================================================================ */
.content-categories-bar {
    margin: 32px 0;
}

.content-categories-list {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.content-category-item {
    margin: 0;
}

.content-category-link {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300; /* Light */
    font-size: 15px;
    letter-spacing: 0.5px;
    color: #322242; /* Abstract Purple */
    background: transparent;
    border: none;
    padding: 8px 0;
    cursor: pointer;
    opacity: 0.7;
    transition: all 0.3s ease;
    border-bottom: 2px solid transparent;
    margin-bottom: -9px;
}

.content-category-link:hover {
    opacity: 1;
    border-bottom-color: #C7B6D8; /* Lavender */
}

.content-category-link.active {
    opacity: 1;
    font-weight: 400; /* Regular */
    border-bottom-color: #322242; /* Abstract Purple */
}

/* === TAB CONTENT === */
.content-tab-content {
    position: relative;
}

.content-feed {
    display: block;
}

.content-feed.hidden {
    display: none;
}

/* === GRID & PAGINATION === */
.content-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin: 32px 0;
}

.content-pagination a,
.content-pagination span {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    font-size: 14px;
    color: #322242;
    padding: 8px 16px;
    border: 1px solid #E7E7E7;
    text-decoration: none;
    transition: all 0.3s ease;
}

.content-pagination a:hover,
.content-pagination .current {
    background: #322242;
    color: #FFFFFF;
    border-color: #322242;
}

.content-no-results {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    font-size: 16px;
    color: #322242;
    opacity: 0.7;
    text-align: center;
    padding: 40px 0;
}

/* === Posts Grid === */

/**/

/*.press-card:hover {*/
/*    border-color: var(--willow-purple);*/
/*}*/

/**/

/**/

/**/

/**/

/**/

/* === Pagination === */
/**/

/*.press-pagination a,*/
/*.press-pagination span {*/
/*    font-family: 'Montserrat', sans-serif;*/
/*    font-weight: 300;*/
/*    padding: 0.5rem 1rem;*/
/*    border: 1px solid var(--willow-light-gray);*/
/*    color: var(--willow-purple);*/
/*    text-decoration: none;*/
/*    border-radius: 4px;*/
/*    transition: all 0.3s ease;*/
/*}*/

/*.press-pagination a:hover {*/
/*    background: var(--willow-purple);*/
/*    color: #FFFFFF;*/
/*    border-color: var(--willow-purple);*/
/*}*/

/**/

/* === SINGLE POST WITH BACKGROUND === */
.press-single-post {
    position: relative;
    overflow: hidden;
}

/* Фоновое изображение по правому краю */
.press-single-bg {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

/*.press-single-bg::before {*/
/*  content: '';*/
/*  position: absolute;*/
/*  top: 0;*/
/*  left: 0;*/
/*  right: 0;*/
/*  bottom: 0;*/
/*  background-image: url('images/post-bg.png');*/
/*  background-repeat: repeat-y;*/
/*  background-position: 0 0;*/
/*  transform: rotate(90deg);*/
/*  z-index: -1;*/
/*  opacity: 0.15;*/
/*}*/

.press-bg-image {
    /*display: none;*/
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: right center;
    opacity: 0.15;
}

/* Контент поверх фона */
.press-single-content {
    position: relative;
    z-index: 1;
    padding: 80px 20px;
    margin: 0 auto;
}

.wp-block-column:empty {
    flex-basis: 0 !important;
}

/* === META INFORMATION === */
.press-single-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    margin-bottom: 24px;
}

.press-single-meta time {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300; /* Light */
    font-size: 14px;
    color: var(--willow-purple); /* Abstract Purple */
    opacity: 0.7;
}

.press-single-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.press-category-label {
    font-family: 'Montserrat', sans-serif;
    font-weight: 200; /* ExtraLight */
    font-size: 12px; /* 0.85X по гайдбуку */
    letter-spacing: 0.5px;
    color: var(--willow-purple);
    background: #F8F9FA;
    padding: 4px 10px;
    border-radius: 2px;
    text-transform: uppercase;
    opacity: 0.8;
}

/* === TITLE === */
.press-single-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400; /* Regular */
    font-size: 48px; /* 4X по гайдбуку */
    letter-spacing: 2%;
    line-height: 1.2;
    color: var(--willow-purple); /* Abstract Purple */
    margin: 0 0 40px 0;
}

/* === BODY CONTENT === */
.press-single-body {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300; /* Light */
    font-size: 16px; /* 1X */
    line-height: 1.8;
    color: var(--willow-purple);
}

.press-single-body p {
    margin-bottom: 24px;
}

.press-single-body h2,
.press-single-body h3 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400; /* Regular */
    color: var(--willow-purple);
    margin: 40px 0 20px 0;
}

.press-single-body h2 {
    font-size: 32px; /* 3X */
}

.press-single-body h3 {
    font-size: 24px; /* 2X */
}

/* === Cases-Page === */
.cases-page .hero-section {
    background-color: var(--willow-purple);
    color: var(--willow-white);
    padding: 20px 0;
    text-align: left;
    overflow-x: hidden;
}

.cases-page .hero-content {
    position: relative;
    margin: 0 auto;
    padding: 100px 0;
    max-width: 900px;
    text-align: center;
}

.cases-page .hero-content::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(0, -50%);
  
   /*Размеры буквы */
  width: 100%;
  height: 100%;
  
   /*Фоновая картинка */
  background-image: url('images/W-coffee.png');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  
  opacity: 0.05;
  pointer-events: none;
  z-index: 0;
}

.cases-page .hero-title {
    position: relative;
    margin-bottom: 25px;
    color: var(--willow-white);
    font-size: 4rem;
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: 0.02em;
    z-index: 1;
}

.cases-page .services-content {
    padding: 20px 0;
    text-align: left;
}

/* === Industries-Page === */
.industries-page .hero-content::before {
  top: 50%;
  left: 50%;
  transform: translate(-100%,-50%);
}

/* ============================================================================
   BLOG & PAGES
   ============================================================================ */
.page-header {
    margin: 60px 0 40px;
}

.post-header {
    margin-bottom: 40px;
}


/* Заголовок страницы */
.page-title {
    text-align: center;
    font-size: 4rem;
    font-weight: 400;
    color: var(--willow-coffee);
    margin-bottom: 60px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.blog-card:hover {
    transform: translateY(-3px);
}

.blog-title a {
    color: var(--willow-purple);
}

.blog-title a:hover {
    color: var(--willow-coffee);
}

.read-more:hover {
    color: var(--willow-coffee);
}

.post-date {
    font-size: 0.8rem;
    font-weight: 200;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--willow-coffee);
    margin-bottom: 15px;
}

.post-content {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--willow-astronomist);
}

/* ============================================================================
   FOOTER
   ============================================================================ */

.site-footer {
    background-color: var(--willow-purple);
    color: var(--willow-white);
    padding: 80px 0 30px;
    font-weight: 200;
    font-size: 0.85rem;
    letter-spacing: 0.02em;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 60px;
}

.footer-col h4 {
    color: var(--willow-coffee);
    margin-bottom: 25px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.9rem;
    font-weight: 400;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 12px;
}

.footer-col a {
    color: var(--willow-white);
    transition: color 0.3s ease;
    text-decoration: none;
}

.footer-col a:hover {
    color: var(--willow-coffee);
}

/* Logo */
.footer-logo {
    margin-bottom: 16px;
}

.footer-logo .logo-link {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    height: 42px;
    color: var(--willow-coffee);
    transition: opacity 0.3s ease;
}

.footer-logo .logo-link:hover {
    opacity: 0.8;
}

.footer-logo .logo-img {
    height: 100%;
}

.footer-col.main-col {
    display: flex;
    flex-direction: column;
}

.policy-terms {
    margin-top: auto;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    text-align: center;
    opacity: 0.7;
}

/* ============================================================================
   CUSTOM DEFAULT PAGES
   ============================================================================ */
/* COMPANY */
.page-id-475 .page-section,
.page-id-633 .page-section,
.page-id-477 .page-section,
.page-id-479 .page-section,
.page-id-123 .page-section {
    position: relative;
    overflow-x: hidden;
}

.page-id-475 .page-section .container::before,
.page-id-633 .page-section .container::before,
.page-id-477 .page-section .container::before,
.page-id-479 .page-section .container::before,
.page-id-123 .page-section .container::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-25%, -50%);
  
   /*Размеры буквы */
  width: 100%;
  height: 100%;
  
   /*Фоновая картинка */
  background-image: url('images/W-coffee.png');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  
  opacity: 0.1;
  pointer-events: none;
  z-index: 0;
}


/* =========================================
   POPUP & FORM STYLES (v2 - CF7 Compatible)
   Scope: #contact-popup
   ========================================= */

/* --- Overlay & Centering --- */
#contact-popup {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(50, 34, 66, 0.9); /* Abstract Purple @ 90% */
  backdrop-filter: blur(4px);
  z-index: 9999;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  box-sizing: border-box;
}

/* --- Content Box --- */
#contact-popup .popup-content {
  background: #FFFFFF;
  padding: 2.5rem;
  border-radius: 12px;
  max-width: 480px;
  width: 100%;
  position: relative;
  box-shadow: 0 20px 60px rgba(50, 34, 66, 0.3);
  box-sizing: border-box;
}

/* --- Close Button --- */
#contact-popup .popup-close {
  position: absolute;
  top: 1rem; right: 1rem;
  background: none; border: none;
  font-size: 1.75rem; line-height: 1;
  color: #322242; cursor: pointer;
  padding: 0.25rem; transition: opacity 0.2s;
}
#contact-popup .popup-close:hover { opacity: 0.7; }

/* --- Typography --- */
#contact-popup h3 {
  color: #322242; /* Abstract Purple */
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 1.5rem;
  margin: 0 0 1.5rem 0;
  line-height: 1.3;
}

/* --- Form Layout Reset (Fixes CF7 <p> & <br> clustering) --- */
#contact-popup form p {
  margin: 0; padding: 0;
}
#contact-popup form p br {
  display: none; /* Скрываем переносы строк CF7 */
}
#contact-popup form p > .wpcf7-form-control-wrap,
#contact-popup form p > input[type="submit"] {
  display: block;
  width: 100%;
  margin-bottom: 1.25rem;
  box-sizing: border-box;
}
#contact-popup form p > input[type="submit"] {
  margin-bottom: 0; /* Убираем отступ после кнопки */
}
#contact-popup .wpcf7-spinner { display: none; } /* Скрываем лоадер CF7 */

/* --- Inputs --- */
#contact-popup input[type="text"],
#contact-popup input[type="email"],
#contact-popup input[type="tel"],
#contact-popup textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 1px solid #C7B6D8; /* Lavander */
  border-radius: 6px;
  background: #FFFFFF;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95rem;
  color: #322242;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
}
#contact-popup input:focus,
#contact-popup textarea:focus {
  outline: none;
  border-color: #322242;
  box-shadow: 0 0 0 3px rgba(50, 34, 66, 0.1);
}
#contact-popup textarea { min-height: 110px; resize: vertical; }
#contact-popup input::placeholder,
#contact-popup textarea::placeholder { color: #C7B6D8; font-weight: 400; }

/* --- Checkbox & Label --- */
#contact-popup .wpcf7-acceptance {
  display: flex; align-items: center; width: 100%;
}
#contact-popup .wpcf7-acceptance label {
  display: flex; align-items: center; gap: 0.6rem;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem; color: #322242;
  cursor: pointer; line-height: 1.4;
}
#contact-popup .wpcf7-acceptance input[type="checkbox"] {
  width: 1.1rem; height: 1.1rem; margin: 0;
  accent-color: #322242; flex-shrink: 0; cursor: pointer;
}

/* --- Submit Button (CF7 использует <input>, а не <button>) --- */
#contact-popup input[type="submit"] {
  width: 100%;
  background: #322242; /* Abstract Purple */
  color: #FFFFFF;
  border: none;
  padding: 0.875rem 1.5rem;
  border-radius: 6px;
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  box-sizing: border-box;
}
#contact-popup input[type="submit"]:hover { background: #52366E; /* Astronomist */ }
#contact-popup input[type="submit"]:active { transform: scale(0.98); }
/* Состояние disabled (CF7 блокирует кнопку, пока не отмечен чекбокс) */
#contact-popup input[type="submit"]:disabled {
  background: #C7B6D8;
  cursor: not-allowed;
  opacity: 0.6;
}

/* --- Responsive --- */
@media (max-width: 480px) {
  #contact-popup .popup-content { padding: 1.5rem; max-width: 95%; }
  #contact-popup h3 { font-size: 1.35rem; margin-bottom: 1.25rem; }
}

/* ============================================================================
   SEARCH RESULTS PAGE
   ============================================================================ */

.search-results-page {
    padding: 64px 0;
    min-height: 60vh;
    background-color: var(--willow-white, #FFFFFF);
}

/* Заголовок поиска */
.search-header {
    margin-bottom: 48px;
    text-align: center;
}

.search-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400; /* Regular */
    font-size: 2rem; /* 2X from guidebook */
    color: var(--willow-purple, #322242);
    letter-spacing: 0.02em;
    margin-bottom: 12px;
}

.search-title span {
    font-weight: 600;
    color: var(--willow-purple, #322242);
}

.search-subtitle {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300; /* Light */
    font-size: 1rem;
    color: var(--willow-grey, #52366E);
    opacity: 0.8;
}

/* Карточка результата */
.search-result-item {
    padding: 24px 0;
    border-bottom: 1px solid var(--willow-light-gray, #E7E7E7);
    transition: background-color 0.2s ease;
}

.search-result-item:hover {
    background-color: rgba(50, 34, 66, 0.03);
}

.search-result-item:last-child {
    border-bottom: none;
}

.result-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 1.25rem;
    margin: 0 0 8px 0;
}

.result-title a {
    text-decoration: none;
    color: var(--willow-purple, #322242);
    transition: color 0.2s ease;
}

.result-title a:hover {
    color: var(--willow-coffee, #E0BA95);
}

.result-excerpt {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300; /* Light */
    font-size: 1rem;
    color: var(--willow-grey, #52366E);
    line-height: 1.6;
    margin: 0 0 12px 0;
    opacity: 0.9;
}

.result-meta {
    display: flex;
    gap: 16px;
    align-items: center;
    font-family: 'Montserrat', sans-serif;
    font-weight: 200; /* ExtraLight */
    font-size: 0.85rem;
    color: var(--willow-grey, #52366E);
    opacity: 0.7;
}

.result-category {
    position: relative;
    padding-left: 16px;
}

.result-category::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background-color: var(--willow-coffee, #E0BA95);
}

/* Пагинация */
.search-pagination {
    margin-top: 48px;
    display: flex;
    justify-content: center;
    gap: 8px;
}

.search-pagination .search-pagination .page-numbers:hover,
.search-pagination .page-numbers.current {
    background-color: var(--willow-purple, #322242);
    color: var(--willow-white, #FFFFFF);
    border-color: var(--willow-purple, #322242);
}

.search-pagination .page-numbers.prev,
.search-pagination .page-numbers.next {
    font-size: 1.1rem;
}

/* Нет результатов */
.search-no-results {
    text-align: center;
    padding: 64px 24px;
    background-color: rgba(199, 182, 216, 0.1); /* Lavender 10% */
    border-radius: 8px;
    border: 1px dashed var(--willow-lavender, #C7B6D8);
}

.no-results-text {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 1.1rem;
    color: var(--willow-purple, #322242);
    margin-bottom: 8px;
}

.no-results-suggestion {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    font-size: 0.95rem;
    color: var(--willow-grey, #52366E);
    margin-bottom: 24px;
    opacity: 0.9;
}

.search-no-results .search-form {
    max-width: 400px;
    margin: 0 auto;
    display: flex;
    gap: 8px;
}

.search-no-results input[type="search"] {
    flex: 1;
    padding: 10px 16px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    border: 1px solid var(--willow-light-gray, #E7E7E7);
    border-radius: 4px;
    background: var(--willow-white, #FFFFFF);
    color: var(--willow-purple, #322242);
}

.search-no-results button[type="submit"] {
    padding: 10px 20px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 0.95rem;
    background-color: var(--willow-purple, #322242);
    color: var(--willow-white, #FFFFFF);
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.search-no-results button[type="submit"]:hover {
    background-color: var(--willow-coffee, #E0BA95);
}

/* Адаптив */
@media (max-width: 768px) {
    .search-results-page {
        padding: 40px 0;
    }
    
    .search-title {
        font-size: 1.5rem;
    }
    
    .result-title {
        font-size: 1.1rem;
    }
    
    .result-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .result-category {
        padding-left: 0;
    }
    
    .result-category::before {
        display: none;
    }
}
/* ============================================================================
   MOBILE RESPONSIVE STYLES
   ============================================================================ */

@media (max-width: 1024px) {
    .main-navigation ul {
        gap: 30px;
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }
}

@media (max-width: 992px) {
    .site-header {
        top: 0;
    }

    .menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 21px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 1001;
    }

    .hamburger-line {
        width: 100%;
        height: 2px;
        background-color: var(--willow-white);
        transition: all 0.3s ease;
    }

    .menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(1) {
        transform: translateY(9.5px) rotate(45deg);
    }

    .menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(3) {
        transform: translateY(-9.5px) rotate(-45deg);
    }

    .main-navigation {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background-color: var(--willow-purple);
        padding: 100px 40px 40px;
        transition: right 0.4s ease;
        box-shadow: -5px 0 15px rgba(0,0,0,0.3);
        z-index: 1000;
        display: block;
    }

    .main-navigation.is-active {
        right: 0;
    }

    .main-navigation ul {
        flex-direction: column;
        gap: 20px;
    }

    .main-navigation a {
        font-size: 1.2rem;
    }

    .main-navigation .sub-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        background: rgba(255,255,255,0.05);
        box-shadow: none;
        border-top: none;
        display: none;
        margin-top: 10px;
    }

    .main-navigation li.menu-item-has-children.is-open > .sub-menu {
        display: block;
    }

    .main-navigation .sub-menu a {
        color: var(--willow-lavender);
        padding: 10px 20px;
    }

    .header-cta-group {
        display: none; /* Скрываем на мобильных, можно перенести в меню */
    }
}

@media (max-width: 768px) {
    h1 { font-size: 2.2rem; }
    h2 { font-size: 1.7rem; }
    
    .top-bar-links {
        display: none;
    }

    .hero-section {
        padding: 80px 0;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-logo .logo-link {
        align-items: center;
    }

    .team-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .profile-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .team-profile .profile-photo {
        position: relative;
        top: 0;
        max-width: 300px;
        margin: 0 auto;
    }

    .team-profile .profile-content h1 {
        font-size: 2rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .team-grid {
        grid-template-columns: 1fr;
    }
    
    .container {
        padding: 0 15px;
    }
}
