/* Эко Пол Анапа — дизайн-система Organic, кастомизированная под зелёную/изумрудную палитру.
   См. хендофф D:\claude\esm23\README.md — токены и структура секций взяты оттуда 1:1. */
@import url('https://fonts.googleapis.com/css2?family=Figtree:wght@400;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:wght@600;700&display=swap');

:root {
  --color-bg: #f9faf8;
  --color-surface: #f2f4f0;
  --color-text: #201e1d;
  --color-accent: #146b4a;
  --color-accent-2: #7fba49;
  --color-divider: color-mix(in srgb, #201e1d 16%, transparent);

  --color-accent-100: #e6f4ec;
  --color-accent-200: #c7e9d4;
  --color-accent-300: #9ed9b7;
  --color-accent-400: #6cc295;
  --color-accent-500: #2f9d6b;
  --color-accent-600: #1f8159;
  --color-accent-700: #146b4a;
  --color-accent-800: #0f5038;
  --color-accent-900: #0a3a29;

  --color-accent-2-100: #eff8e4;
  --color-accent-2-200: #dcefc4;
  --color-accent-2-300: #c0e39a;
  --color-accent-2-400: #9ed169;
  --color-accent-2-500: #7fba49;
  --color-accent-2-600: #639a37;
  --color-accent-2-700: #4c7a2a;
  --color-accent-2-800: #375b1f;
  --color-accent-2-900: #243d14;

  --sea-100: #e2f1f0;
  --sea-150: #d2ebe8;
  --sea-200: #c3e4e1;
  --sea-300: #98d0cb;
  --sea-600: #2f8a82;
  --sea-700: #226b64;
  --sea-800: #174e49;

  --forest-900: #0a3024;

  --grey-50:  #f9faf8;
  --grey-100: #f2f4f0;
  --grey-150: #eaede8;
  --grey-200: #e1e5de;

  --color-neutral-100: #f9f4ed;
  --color-neutral-900: #2e2b25;

  --font-heading: "Source Serif 4", serif;
  --font-body: "Figtree", system-ui, sans-serif;

  --space-1: 4.4px;
  --space-2: 8.8px;
  --space-3: 13.2px;
  --space-4: 17.6px;
  --space-6: 26.4px;
  --space-8: 35.2px;

  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 25px;

  --shadow-sm: 0 1px 2px color-mix(in srgb, #2e2b25 14%, transparent);
  --shadow-md: 0 3px 10px color-mix(in srgb, #2e2b25 16%, transparent);
  --shadow-lg: 0 12px 32px color-mix(in srgb, #2e2b25 22%, transparent);
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; background: var(--color-bg); color: var(--color-text); font-family: var(--font-body); font-size: 17px; line-height: 1.55; font-weight: 400; }
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading); font-weight: 700; text-transform: uppercase; letter-spacing: .015em;
  line-height: 1.15; margin: 0 0 var(--space-2);
}
h1 { font-size: clamp(30px, 4vw, 48px); }
h2 { font-size: clamp(24px, 3vw, 32px); }
h3 { font-size: 22px; }
h4 { font-size: 18px; }
p { margin: 0 0 var(--space-3); }
a { color: var(--color-accent); text-underline-offset: 3px; }
img { display: block; max-width: 100%; }
figure { margin: 0; }
.text-muted { color: color-mix(in srgb, var(--color-text) 72%, transparent); }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
.washed { filter: saturate(0.6) contrast(0.85) brightness(1.1) opacity(0.94); }

/* — layout — */
.container { max-width: 1300px; margin: 0 auto; padding: 0 clamp(20px, 5vw, 64px); }
.plate { max-width: 1300px; margin: 0 auto var(--space-8); border-radius: var(--radius-lg); padding: 35px; position: relative; overflow: hidden; }
.plate-sm { border-radius: var(--radius-lg); padding: 40px clamp(20px, 5vw, 64px); }
/* .plate уже задаёт и общую ширину 1300px, и свой горизонтальный отступ —
   вложенный .container внутри него не должен добавлять ВТОРОЙ слой
   отступа/ограничения ширины поверх первого (из-за этого текст внутри
   плашек оказывался отцентрирован у́же, чем в хиро/шапке, где .container
   ровно один слой). */
.plate > .container { max-width: none; padding-left: 0; padding-right: 0; }
.bg-100 { background: var(--grey-100); }
.bg-150 { background: var(--grey-150); }
.kicker { display: block; font-size: 15px; letter-spacing: .08em; text-transform: uppercase; font-weight: 700; color: var(--color-accent-700); margin-bottom: 10px; position: relative; z-index: 1; }

/* — buttons — */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer; text-decoration: none;
  font-family: var(--font-heading); font-weight: 600; text-transform: none; letter-spacing: 0;
  font-size: 15px; line-height: 1.2; color: var(--color-text);
  background: transparent; border: 1px solid transparent;
  padding: 13px 24px; border-radius: 999px;
}
.btn svg { display: block; }
.btn-primary { background: var(--color-accent); color: #fff; }
.btn-primary:hover { background: var(--color-accent-600); }
.btn-secondary { border-color: var(--color-divider); background: var(--color-surface); }
.btn-secondary:hover { background: color-mix(in srgb, var(--color-text) 7%, transparent); }
.btn-outline { border-color: color-mix(in srgb, var(--color-text) 20%, transparent); background: transparent; color: var(--color-text); }
.btn-outline:hover { background: color-mix(in srgb, var(--color-text) 5%, transparent); }
.btn-lime { background: var(--color-accent-2-400); color: var(--forest-900); }
.btn-lime:hover { background: var(--color-accent-2-300); }

/* — конверсионные действия WooCommerce (добавить в корзину и т.п.) — светло-зелёные, как btn-lime */
.single_add_to_cart_button.button,
.woocommerce a.button.product_type_simple,
.added_to_cart.wc-forward {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font-family: var(--font-heading); font-weight: 600; font-size: 15px; line-height: 1.2;
  padding: 13px 24px; border-radius: 999px; border: none;
  background: var(--color-accent-2-400) !important; color: var(--forest-900) !important;
  text-transform: none; text-decoration: none; cursor: pointer;
}
.single_add_to_cart_button.button:hover,
.woocommerce a.button.product_type_simple:hover,
.added_to_cart.wc-forward:hover {
  background: var(--color-accent-2-300) !important;
}
.btn-ghost { color: var(--color-accent-700); padding: 0; text-transform: none; font-family: var(--font-body); font-weight: 600; }
.btn-ghost:hover { opacity: .75; }
.btn-block { width: 100%; }

/* — forms — */
.field > label { display: block; font-size: 12px; margin-bottom: 5px; color: color-mix(in srgb, var(--color-text) 70%, transparent); }
.input {
  width: 100%; min-height: 40px; padding: 8px 14px; font: inherit; font-size: 14px; color: var(--color-text);
  background: var(--color-surface); border: 1px solid var(--color-divider); border-radius: 999px;
}
.input:focus-visible { border-color: var(--color-accent); }

/* — cards — */
.card { display: flex; flex-direction: column; gap: var(--space-2); padding: var(--space-4); border-radius: var(--radius-lg); background: var(--color-surface); }
.card-title { font-family: var(--font-heading); font-weight: 700; font-size: 17px; line-height: 1.25; text-transform: none; letter-spacing: 0; }
.card-body { margin: 0; font-size: 15.5px; opacity: .8; flex: 1; }
.elev-sm { box-shadow: var(--shadow-sm); }
.tag { display: inline-flex; align-items: center; font-size: 11px; letter-spacing: .02em; padding: 3px 10px; border-radius: 999px; }

/* — nav — */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--color-bg); border-bottom: 1px solid var(--color-divider); }
.nav { display: flex; align-items: center; gap: var(--space-4); max-width: 1300px; margin: 0 auto; padding: 14px 0; flex-wrap: wrap; row-gap: 10px; }
.nav-brand { display: flex; align-items: center; gap: 10px; margin-right: auto; font-family: var(--font-heading); font-weight: 600; font-size: 19px; text-transform: none; letter-spacing: 0; text-decoration: none; color: var(--color-text); }
.logo-tile { width: 40px; height: 40px; border-radius: 14px; background: var(--color-accent-2-200); display: grid; place-items: center; color: var(--color-accent-700); flex: none; }
.nav a.nav-link { color: var(--color-text); text-decoration: none; font-size: 15px; font-family: var(--font-heading); font-weight: 500; }
.nav a.nav-link:hover { color: var(--color-accent-700); }
.nav-phone { display: flex; align-items: center; gap: 7px; color: inherit; text-decoration: none; font-size: 18px; white-space: nowrap; }
.nav-phone .m-tile { width: 22px; height: 22px; border-radius: 50%; flex: none; display: block; object-fit: contain; }
.nav-cart { display: flex; align-items: center; gap: 6px; color: inherit; text-decoration: none; font-size: 13px; }

/* — brand grid tiles — */
.brand-tile { border-radius: var(--radius-lg); min-height: 84px; display: flex; align-items: center; justify-content: center; text-decoration: none; color: var(--sea-800); font-family: var(--font-heading); font-weight: 700; text-transform: uppercase; letter-spacing: .01em; font-size: 13px; text-align: center; padding: 10px; }

/* — brand cards (каталог брендов, как на eco-pol.com) — */
.brand-card { background: #fff; border-radius: var(--radius-lg); padding: var(--space-4); display: flex; flex-direction: column; gap: var(--space-2); text-decoration: none; color: var(--color-text); }
.brand-card .photo { width: 100%; aspect-ratio: 1/1; border-radius: var(--radius-lg); overflow: hidden; background: var(--grey-150); }
.brand-card .photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.brand-card-name { font-family: var(--font-heading); font-weight: 700; font-size: 16px; margin: 2px 0 0; }
.brand-card-row { display: flex; align-items: center; }
.brand-card-row > span { width: 50%; font-size: 15px; }
.brand-card-price { color: var(--color-accent-700); font-weight: 600; }
.brand-card-count { color: color-mix(in srgb, var(--color-text) 60%, transparent); }

/* — product grid (shop) — */
.product-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: var(--space-6); }
.product-card { position: relative; display: block; text-decoration: none; color: inherit; background: #fff; border-radius: var(--radius-lg); overflow: hidden; }
.product-card .thumb { position: relative; aspect-ratio: 1; overflow: hidden; background: var(--grey-150); }
.product-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.product-card .body { padding: var(--space-4); }
.product-card .name { font-family: var(--font-heading); font-weight: 700; font-size: 15px; text-transform: none; letter-spacing: 0; margin: 0 0 6px; line-height: 1.3; }
.product-card .card-attrs { font-size: 12.5px; color: color-mix(in srgb, var(--color-text) 60%, transparent); margin-bottom: 10px; }
.product-card .card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.product-card .card-plank-size { font-size: 11.5px; color: color-mix(in srgb, var(--color-text) 55%, transparent); white-space: nowrap; }
.product-card .price { font-size: 15px; font-weight: 700; color: var(--color-accent-700); }
.product-card-badge { position: absolute; top: 10px; left: 10px; background: var(--color-accent-2-400); color: var(--forest-900); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; padding: 4px 10px; border-radius: 999px; z-index: 1; }

/* — каталог: сайдбар фильтров + сетка — */
.catalog-layout { display: grid; grid-template-columns: 260px 1fr; gap: var(--space-8); align-items: start; }
.catalog-sidebar { background: #fff; border-radius: var(--radius-lg); padding: var(--space-4); position: sticky; top: 90px; }
.catalog-sidebar-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--space-2); padding: 0 4px; }
.catalog-sidebar-head h3 { margin: 0; font-size: 16px; }
.catalog-sidebar-head a { font-size: 13px; color: var(--color-accent-700); text-decoration: none; }
.filter-group { border-top: 1px solid var(--color-divider); padding: 12px 4px; }
.filter-group:first-of-type { border-top: none; }
.filter-group-summary { cursor: pointer; font-weight: 600; font-size: 14.5px; list-style: none; display: flex; align-items: center; justify-content: space-between; }
.filter-group-summary::-webkit-details-marker { display: none; }
.filter-group-summary::after { content: '+'; font-size: 16px; color: color-mix(in srgb, var(--color-text) 50%, transparent); }
.filter-group[open] > .filter-group-summary::after { content: '−'; }
.filter-group-body { margin-top: 10px; display: flex; flex-direction: column; gap: 9px; max-height: 260px; overflow-y: auto; }
.chk { display: flex; align-items: center; gap: 9px; font-size: 14px; cursor: pointer; }
.chk input { flex: none; width: 16px; height: 16px; accent-color: var(--color-accent-700); }
.price-range { display: flex; gap: 10px; margin-top: 10px; }
.catalog-sort { display: flex; align-items: center; gap: 10px; }
.catalog-sort label { font-size: 13px; color: color-mix(in srgb, var(--color-text) 60%, transparent); white-space: nowrap; }

/* — характеристики/иконки преимуществ — */
.feature-icons { display: flex; gap: 14px; margin: var(--space-3) 0; }
.feature-icon { width: 36px; height: 36px; border-radius: 10px; background: var(--color-accent-100); color: var(--color-accent-700); display: grid; place-items: center; }
.feature-icon svg { width: 18px; height: 18px; }

/* — слайдер товаров (связанные/апселл) — */
.product-slider { position: relative; min-width: 0; }
.product-slider-track { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.product-slider-track::-webkit-scrollbar { display: none; }
.product-slide { flex: 0 0 230px; scroll-snap-align: start; }

/* — калькулятор площади — */
.area-calc { margin-top: var(--space-4); border-top: 1px solid var(--color-divider); padding-top: var(--space-3); }
.area-calc-summary { cursor: pointer; font-weight: 600; font-size: 14.5px; list-style: none; }
.area-calc-summary::-webkit-details-marker { display: none; }
.area-calc-body { padding-top: var(--space-3); }
.area-calc-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.area-calc-x { color: color-mix(in srgb, var(--color-text) 50%, transparent); }
.area-calc-remove { flex: none; width: 28px; height: 28px; border-radius: 50%; border: none; background: var(--grey-150); cursor: pointer; font-size: 16px; }
.area-calc-field { margin: 10px 0; }
.area-calc-result { margin-top: 12px; background: var(--color-accent-100); border-radius: var(--radius-md); padding: 14px; }
.area-calc-headline { margin: 0 0 4px; font-size: 14.5px; }
.area-calc-fine { margin: 0 0 10px; font-size: 12.5px; color: color-mix(in srgb, var(--color-text) 65%, transparent); }

/* — степпер количества на странице товара — */
.qty-stepper { display: inline-flex; align-items: center; border: 1.5px solid var(--color-divider); border-radius: 999px; overflow: hidden; }
.qty-stepper button { width: 38px; height: 38px; border: none; background: transparent; font-size: 18px; cursor: pointer; }
.qty-stepper .qty-value { width: 48px; text-align: center; border: none; font: inherit; font-size: 15px; -moz-appearance: textfield; }
.qty-stepper .qty-value::-webkit-outer-spin-button, .qty-stepper .qty-value::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-unit { font-size: 12px; color: color-mix(in srgb, var(--color-text) 55%, transparent); padding-right: 6px; }

/* — миниатюры галереи — */
.gallery-thumbs button { border: 2px solid transparent; border-radius: var(--radius-sm); padding: 0; cursor: pointer; background: none; overflow: hidden; }
.gallery-thumbs button.is-active { border-color: var(--color-accent-700); }

/* — breadcrumbs — */
.breadcrumbs { font-size: 13px; color: color-mix(in srgb, var(--color-text) 60%, transparent); margin: 24px 0; }
.breadcrumbs a { color: inherit; text-decoration: none; }
.breadcrumbs a:hover { color: var(--color-accent-700); }

/* — product page — */
.product-single { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: var(--space-8); margin-bottom: var(--space-8); }
.product-gallery { border-radius: var(--radius-lg); overflow: hidden; background: var(--grey-150); min-height: 360px; }
.product-gallery img { width: 100%; height: 100%; object-fit: cover; }
.product-price-row { font-size: 28px; font-weight: 700; color: var(--color-accent-700); font-family: var(--font-heading); margin: 10px 0 18px; }
.spec-table { width: 100%; border-collapse: collapse; font-size: 14px; margin: 16px 0; }
.spec-table td { padding: 10px 0; border-bottom: 1px solid var(--color-divider); }
.spec-table td:first-child { color: color-mix(in srgb, var(--color-text) 60%, transparent); width: 50%; }

/* — articles — */
.article-card { display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-2); text-decoration: none; color: inherit; padding: 26px; border-radius: var(--radius-lg); }
.article-tag { display: inline-block; background: var(--sea-300); color: var(--sea-800); font-size: 12.5px; font-weight: 600; padding: 7px 16px; border-radius: 999px; margin-bottom: 4px; }
.article-related-list a { display: block; padding: 10px 0; border-bottom: 1px solid var(--color-divider); color: inherit; text-decoration: none; font-size: 14px; }
.article-body h2 { font-size: 22px; margin-top: var(--space-6); }
.article-body h3 { font-size: 18px; margin-top: var(--space-4); }
.article-body p { font-size: 17.5px; line-height: 1.65; }
.article-body table { width: 100%; border-collapse: collapse; margin: var(--space-4) 0; font-size: 15px; background: #fff; border-radius: var(--radius-md); overflow: hidden; }
.article-body table th, .article-body table td { padding: 11px 16px; border-bottom: 1px solid var(--color-divider); text-align: left; }
.article-body table th { background: var(--grey-100); font-weight: 700; font-family: var(--font-heading); }
.article-body table tr:last-child td { border-bottom: none; }
.article-body ul, .article-body ol { font-size: 17.5px; line-height: 1.65; padding-left: 1.3em; }

/* — footer — */
.site-footer { border-top: 1px solid var(--color-divider); padding: 36px 0; }
.site-footer-inner { display: flex; flex-wrap: wrap; gap: 24px; justify-content: space-between; align-items: center; max-width: 1300px; margin: 0 auto; }

/* — hero (plain bg, no plate) — */
.hero-wrap { position: relative; overflow: hidden; padding: 56px 0; }
/* Видимый контент хиро (текст/фото) должен доходить до тех же 1300px
   границ, что и цветной фон плашек — у plain .container есть свой
   внутренний паддинг, в хиро он не нужен (фон тут не закрашен, инсет
   создавала бы только сама .container, а не секция). */
.hero-wrap > .container { padding-left: 0; padding-right: 0; }
.hero-blob { position: absolute; border-radius: 50%; background: var(--color-accent-2-200); opacity: .55; z-index: 0; }

/* — promo: asymmetric bento (1 tall + 2 stacked) — */
.promo-grid { display: grid; grid-template-columns: 40% 1fr; grid-template-rows: repeat(2, 1fr); gap: var(--space-6); }
.promo-tall { grid-row: 1 / 3; }
.icon-badge { width: 52px; height: 52px; border-radius: 16px; background: var(--color-accent-2-200); color: var(--color-accent-800); display: grid; place-items: center; font-size: 22px; font-weight: 700; margin-bottom: var(--space-4); }
.promo-link { display: inline-flex; align-items: center; gap: 10px; color: var(--color-accent-700); font-weight: 600; text-decoration: none; margin-top: auto; }

/* — filter pills (outline, inline price, flows to content width) — */
.pill-grid { display: flex; flex-wrap: wrap; gap: 14px; }
.pill-outline { border: 2.5px solid color-mix(in srgb, var(--color-text) 26%, transparent); border-radius: 999px; padding: 16px 22px; font-size: 14.5px; color: var(--color-text); text-decoration: none; display: block; white-space: nowrap; }
.pill-outline b { font-weight: 700; }
.pill-outline:hover { border-color: var(--color-accent-600); color: var(--color-accent-700); }

/* — showroom capsule photos — */
.showroom-slider { position: relative; min-width: 0; }
.showroom-slider-track { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; height: 320px; }
.showroom-slider-track::-webkit-scrollbar { display: none; }
.showroom-slide { flex: 0 0 260px; scroll-snap-align: start; height: 100%; border-radius: var(--radius-lg); overflow: hidden; }
.showroom-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.slider-arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; border: none; background: #fff; box-shadow: var(--shadow-md); display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 20px; line-height: 1; z-index: 2; color: var(--color-text); }
.slider-arrow-prev { left: -10px; }
.slider-arrow-next { right: -10px; }
.slider-arrow:hover { background: var(--color-accent-100); }

/* — portfolio bento grid (1 tall left + 2 small + 1 wide) — */
.portfolio-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; grid-template-rows: repeat(2, 230px); gap: var(--space-4); }
.portfolio-card { position: relative; border-radius: var(--radius-lg); overflow: hidden; text-decoration: none; display: flex; flex-direction: column; justify-content: flex-end; padding: 22px; color: #fff; }
.portfolio-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.portfolio-card::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,48,36,.05), rgba(10,48,36,.82)); z-index: 1; }
.portfolio-card > * { position: relative; z-index: 2; }
.portfolio-big { grid-column: 1; grid-row: 1 / 3; }
.portfolio-small { grid-column: span 1; grid-row: 1; }
.portfolio-wide { grid-column: 2 / 4; grid-row: 2; }

/* — contacts icon rows — */
.contact-row { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; color: #fff; }
.contact-row svg { flex: none; color: var(--color-accent-2-400); }

@media (max-width: 860px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .product-single { grid-template-columns: 1fr; }
  .nav .nav-link { display: none; }
  .promo-grid { grid-template-columns: 1fr; grid-template-rows: none; }
  .promo-tall { grid-row: auto; }
  .pill-outline { width: 100%; }
  .portfolio-grid { grid-template-columns: 1fr; grid-template-rows: none; }
  .portfolio-big, .portfolio-small, .portfolio-wide { grid-column: 1; grid-row: auto; height: 220px; }
  .catalog-layout { grid-template-columns: 1fr; }
  .catalog-sidebar { position: static; }
}
