/* Easy-Going — «дом под оранжевой крышей»: крем, пудровая лазурь, жёлто-зелёный градиент бренда, орех.
   Namespace eg-. Шрифты Lora (заголовки) + Figtree (текст), локальные variable woff2. */

@font-face {
  font-family: 'Lora';
  font-style: normal;
  font-weight: 500 700;
  font-display: swap;
  src: url('../fonts/lora.woff2') format('woff2');
}
@font-face {
  font-family: 'Lora';
  font-style: italic;
  font-weight: 500 600;
  font-display: swap;
  src: url('../fonts/lora-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('../fonts/figtree.woff2') format('woff2');
}

:root {
  --eg-cream: #f8f3e9;
  --eg-paper: #fffdf7;
  --eg-ink: #33291f;
  --eg-ink2: #6a5e4e;
  --eg-roof: #d96f2b;
  --eg-roof-deep: #b1541a;
  --eg-green: #4f7a33;
  --eg-green-deep: #3f6229;
  --eg-yellow: #e9b93c;
  --eg-blue: #cfe0e9;
  --eg-blue-deep: #33586d;
  --eg-walnut: #453424;
  --eg-line: #e5dac6;
  --eg-grad: linear-gradient(90deg, #e9b93c, #7aa13f);
  --eg-serif: 'Lora', Georgia, serif;
  --eg-sans: 'Figtree', 'Segoe UI', Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--eg-sans);
  font-size: 16.5px;
  line-height: 1.62;
  color: var(--eg-ink);
  background: var(--eg-cream);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--eg-green-deep); text-decoration: none; }
a:hover { color: var(--eg-roof-deep); }
h1, h2, h3 { font-family: var(--eg-serif); font-weight: 600; line-height: 1.22; color: var(--eg-ink); }

.eg-wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }

/* ---------- шапка ---------- */
.eg-header {
  background: var(--eg-paper);
  border-bottom: 1px solid var(--eg-line);
  position: sticky; top: 0; z-index: 50;
}
.eg-header-in { display: flex; align-items: center; gap: 28px; min-height: 74px; }
.eg-logo img { width: 124px; height: 56px; object-fit: contain; display: block; }
.eg-nav { display: flex; flex-wrap: wrap; gap: 4px 18px; margin-left: auto; }
.eg-nav a {
  font-weight: 600; font-size: 15px; color: var(--eg-ink2);
  padding: 6px 2px; border-bottom: 2px solid transparent;
}
.eg-nav a:hover { color: var(--eg-ink); }
.eg-nav a.on { color: var(--eg-ink); border-image: var(--eg-grad) 1; border-bottom: 2px solid; }
.eg-burger { display: none; background: none; border: 1px solid var(--eg-line); border-radius: 8px; padding: 9px 10px; cursor: pointer; margin-left: auto; }
.eg-burger span { display: block; width: 20px; height: 2px; background: var(--eg-ink); margin: 4px 0; border-radius: 2px; }

/* ---------- герой ---------- */
.eg-hero { background: var(--eg-paper); border-bottom: 1px solid var(--eg-line); }
.eg-hero-in { display: grid; grid-template-columns: 5fr 6fr; align-items: center; gap: 36px; padding: 44px 20px 48px; max-width: 1160px; margin: 0 auto; }
.eg-eyebrow {
  display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: var(--eg-roof-deep); margin-bottom: 14px;
}
.eg-hero h1 { font-size: clamp(30px, 4.2vw, 44px); margin-bottom: 16px; }
.eg-hero-sub { color: var(--eg-ink2); font-size: 18px; max-width: 34em; margin-bottom: 24px; }
.eg-hero-photo { border-radius: 16px; overflow: hidden; box-shadow: 0 10px 30px rgba(69, 47, 36, .16); }
.eg-hero-photo img { width: 100%; height: auto; }
.eg-hero-note { margin-top: 18px; font-size: 14.5px; color: var(--eg-ink2); font-style: italic; font-family: var(--eg-serif); }

/* кнопки */
.eg-btn {
  display: inline-block; background: var(--eg-green); color: #fff;
  font-weight: 700; font-size: 16px; padding: 12px 26px; border-radius: 999px;
  border: none; cursor: pointer; transition: background .15s;
}
.eg-btn:hover { background: var(--eg-green-deep); color: #fff; }
.eg-btn-buy { background: var(--eg-roof); }
.eg-btn-buy:hover { background: var(--eg-roof-deep); }
.eg-btn-ghost { background: none; color: var(--eg-green-deep); border: 2px solid var(--eg-green); padding: 10px 24px; }
.eg-btn-ghost:hover { background: var(--eg-green); color: #fff; }

/* ---------- секции ---------- */
.eg-section { padding: 52px 0; }
.eg-section-head { max-width: 640px; margin-bottom: 30px; }
.eg-section-head h2 { font-size: clamp(24px, 3vw, 32px); margin-bottom: 10px; padding-bottom: 12px; position: relative; }
.eg-section-head h2::after {
  content: ''; position: absolute; left: 0; bottom: 0;
  width: 74px; height: 4px; border-radius: 2px; background: var(--eg-grad);
}
.eg-section-head p { color: var(--eg-ink2); }

/* ---------- плитки категорий ---------- */
.eg-cats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.eg-cat {
  position: relative; display: block; border-radius: 14px; overflow: hidden;
  background: var(--eg-paper); border: 1px solid var(--eg-line);
  transition: transform .15s, box-shadow .15s;
}
.eg-cat:hover { transform: translateY(-3px); box-shadow: 0 12px 26px rgba(69, 47, 36, .14); }
.eg-cat-ph { height: 170px; background: #fff; display: flex; align-items: center; justify-content: center; padding: 12px; overflow: hidden; }
.eg-cat-ph picture { display: flex; align-items: center; justify-content: center; height: 100%; width: 100%; }
.eg-cat-ph img { max-height: 146px; width: auto; max-width: 100%; object-fit: contain; }
.eg-cat-cap { padding: 14px 18px 16px; border-top: 3px solid; border-image: var(--eg-grad) 1; }
.eg-cat-cap h3 { font-size: 18px; margin-bottom: 2px; }
.eg-cat-cap p { font-size: 14px; color: var(--eg-ink2); }

/* ---------- карточка товара: «стёжка» ---------- */
.eg-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.eg-card {
  position: relative; display: flex; flex-direction: column;
  background: var(--eg-paper); border: 1px solid var(--eg-line); border-radius: 14px;
  padding: 7px; transition: transform .15s, box-shadow .15s;
}
.eg-card::before {
  content: ''; position: absolute; inset: 7px; pointer-events: none;
  border: 1.5px dashed #dcc292; border-radius: 9px;
}
.eg-card:hover { transform: translateY(-3px); box-shadow: 0 12px 26px rgba(69, 47, 36, .13); }
.eg-card-link { display: flex; flex-direction: column; flex: 1; color: inherit; padding: 10px 12px 4px; }
.eg-card-link:hover { color: inherit; }
.eg-card-ph { height: 190px; background: #fff; border-radius: 8px; display: flex; align-items: center; justify-content: center; margin-bottom: 12px; }
.eg-card-ph picture { display: flex; align-items: center; justify-content: center; height: 100%; width: 100%; }
.eg-card-ph img { max-height: 170px; width: auto; max-width: 100%; object-fit: contain; }
.eg-card-cat { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--eg-roof-deep); }
.eg-card h3 { font-size: 16.5px; margin: 4px 0 6px; font-weight: 600; }
.eg-card-short { font-size: 13.5px; color: var(--eg-ink2); line-height: 1.5; }
.eg-card-meta { margin-top: auto; padding: 10px 12px 6px; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.eg-price { font-family: var(--eg-serif); font-weight: 700; font-size: 20px; color: var(--eg-ink); }
.eg-rate { font-size: 13px; color: var(--eg-ink2); }
.eg-stars { color: #d9a51d; letter-spacing: 1px; }
.eg-card .eg-btn-buy { margin: 6px 12px 10px; text-align: center; position: relative; z-index: 1; }

/* ---------- размерный стол ---------- */
.eg-sizes { background: var(--eg-paper); border-top: 1px solid var(--eg-line); border-bottom: 1px solid var(--eg-line); }
.eg-size-scroll { overflow-x: auto; }
.eg-size-table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 640px; }
.eg-size-table th {
  text-align: left; font-family: var(--eg-serif); font-size: 15.5px;
  padding: 12px 14px; border-bottom: 2px solid var(--eg-ink); white-space: nowrap;
}
.eg-size-table td { padding: 11px 14px; border-bottom: 1px solid var(--eg-line); vertical-align: top; }
.eg-size-table tr:hover td { background: #fdf8ec; }
.eg-size-note { margin-top: 14px; font-size: 14.5px; color: var(--eg-ink2); }
/* мерная лента сверху таблицы */
.eg-tape {
  height: 16px; border-radius: 4px 4px 0 0; margin-bottom: -1px;
  background-color: var(--eg-yellow);
  background-image: repeating-linear-gradient(90deg, #7a5c14 0 2px, transparent 2px 20px);
  background-size: 20px 100%;
  border: 1px solid #c99e2b; border-bottom: none;
}

/* ---------- полоса «двусторонний» ---------- */
.eg-flip { background: var(--eg-blue); }
.eg-flip-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 18px; margin-top: 28px; }
.eg-flip .eg-section-head h2, .eg-flip .eg-section-head p { color: var(--eg-blue-deep); }
.eg-flip .eg-section-head h2::after { background: var(--eg-blue-deep); }
.eg-flip-step { background: rgba(255, 255, 255, .82); border-radius: 12px; padding: 20px 22px; }
.eg-flip-step .eg-flip-n {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%; background: var(--eg-blue-deep);
  color: #fff; font-weight: 700; font-size: 16px; margin-bottom: 10px;
}
.eg-flip-step h3 { font-size: 17px; margin-bottom: 6px; color: var(--eg-blue-deep); }
.eg-flip-step p { font-size: 14.5px; color: #3d5568; }

/* ---------- рейтинги ---------- */
.eg-rating-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.eg-rating-card { background: var(--eg-paper); border: 1px solid var(--eg-line); border-radius: 14px; padding: 22px 24px; }
.eg-rating-figure { font-family: var(--eg-serif); font-size: 19px; font-weight: 700; margin: 6px 0 8px; }
.eg-rating-card p { font-size: 14.5px; color: var(--eg-ink2); }
.eg-rating-card .eg-rating-name { margin-top: 12px; font-weight: 600; font-size: 15px; }

/* ---------- эссе ---------- */
.eg-essay h2 { font-size: clamp(24px, 3vw, 30px); margin-bottom: 16px; }
.eg-essay h3 { font-size: 20px; margin: 28px 0 10px; }
.eg-essay p { margin-bottom: 14px; max-width: 46em; color: var(--eg-ink); }
.eg-essay ul { margin: 0 0 14px 22px; max-width: 44em; }
.eg-essay li { margin-bottom: 7px; }
.eg-essay table { width: 100%; border-collapse: collapse; margin: 16px 0 22px; font-size: 15px; }
.eg-essay th { text-align: left; padding: 10px 12px; border-bottom: 2px solid var(--eg-ink); font-family: var(--eg-serif); }
.eg-essay td { padding: 10px 12px; border-bottom: 1px solid var(--eg-line); vertical-align: top; }

/* ---------- страницы разделов и сервисные ---------- */
.eg-pagehero { background: var(--eg-paper); border-bottom: 1px solid var(--eg-line); padding: 40px 0 34px; }
.eg-pagehero h1 { font-size: clamp(26px, 3.6vw, 38px); margin-bottom: 10px; }
.eg-pagehero-sub { color: var(--eg-ink2); max-width: 46em; }
.eg-doc { padding: 44px 0 60px; }
.eg-doc h2 { font-size: 22px; margin: 26px 0 10px; }
.eg-doc h3 { font-size: 18px; margin: 20px 0 8px; }
.eg-doc p, .eg-doc li { max-width: 46em; color: var(--eg-ink); }
.eg-doc p { margin-bottom: 12px; }
.eg-doc ul, .eg-doc ol { margin: 0 0 14px 22px; }
.eg-doc li { margin-bottom: 7px; }
.eg-doc table { border-collapse: collapse; margin: 14px 0 20px; font-size: 15px; }
.eg-doc th { text-align: left; padding: 9px 12px; border-bottom: 2px solid var(--eg-ink); font-family: var(--eg-serif); }
.eg-doc td { padding: 9px 12px; border-bottom: 1px solid var(--eg-line); }

/* ---------- хлебные крошки ---------- */
.eg-crumbs { font-size: 13.5px; color: var(--eg-ink2); padding: 16px 0 0; }
.eg-crumbs a { color: var(--eg-ink2); }
.eg-crumbs a:hover { color: var(--eg-roof-deep); }

/* ---------- PDP ---------- */
.eg-product { display: grid; grid-template-columns: 6fr 5fr; gap: 40px; padding: 28px 0 12px; align-items: start; }
.eg-product-media {
  background: #fff; border: 1px solid var(--eg-line); border-radius: 16px;
  padding: 24px; display: flex; align-items: center; justify-content: center;
  position: sticky; top: 94px;
}
.eg-product-media img { max-height: 460px; width: auto; max-width: 100%; object-fit: contain; }
.eg-product-info h1 { font-size: clamp(22px, 2.6vw, 30px); margin: 6px 0 12px; }
.eg-product-meta { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.eg-product-price { font-family: var(--eg-serif); font-size: 32px; font-weight: 700; }
.eg-stock { font-size: 14px; font-weight: 600; color: var(--eg-green-deep); }
.eg-stock.low { color: var(--eg-roof-deep); }
.eg-price-note { font-size: 13px; color: var(--eg-ink2); margin-top: 8px; }
.eg-product-info .eg-btn-buy { font-size: 17px; padding: 14px 34px; }
.eg-product-short { margin: 18px 0 0; font-size: 16.5px; color: var(--eg-ink2); font-style: italic; font-family: var(--eg-serif); }

/* авторский текст */
.eg-story { padding: 34px 0 8px; }
.eg-story p { max-width: 46em; margin-bottom: 14px; font-size: 17px; }
.eg-story p:first-of-type::first-letter {
  font-family: var(--eg-serif); font-size: 3.1em; font-weight: 700; float: left;
  line-height: .85; padding: 4px 8px 0 0; color: var(--eg-roof);
}

/* fit-бокс — мерная лента */
.eg-fitcare { display: grid; grid-template-columns: 3fr 2fr; gap: 22px; padding: 20px 0 40px; align-items: start; }
.eg-fit { background: var(--eg-paper); border: 1px solid var(--eg-line); border-radius: 0 0 12px 12px; padding: 20px 24px; }
.eg-fit h2, .eg-care h2 { font-size: 18px; margin-bottom: 8px; }
.eg-fit p { color: var(--eg-ink); font-size: 15.5px; }
.eg-fit-note { margin-top: 10px; font-size: 13.5px; color: var(--eg-ink2); }

/* care-бокс — бирка на ткани */
.eg-care {
  position: relative; background: #fff; border: 1px solid var(--eg-line);
  border-radius: 10px; padding: 20px 24px 20px 34px;
}
.eg-care::before {
  content: ''; position: absolute; left: 12px; top: 14px; bottom: 14px;
  border-left: 2px dashed #cbbfa8;
}
.eg-care::after {
  content: ''; position: absolute; top: 14px; right: 16px; width: 12px; height: 12px;
  border-radius: 50%; background: var(--eg-cream); border: 2px solid #cbbfa8;
}
.eg-care p { font-size: 15px; color: var(--eg-ink); }
.eg-care-icons { display: flex; gap: 10px; margin-top: 12px; color: var(--eg-ink2); }
.eg-care-icons svg { width: 30px; height: 30px; }

/* ---------- 404 ---------- */
.eg-404 { text-align: center; padding: 70px 20px; }
.eg-404 h1 { font-size: 40px; margin-bottom: 12px; }
.eg-404 p { color: var(--eg-ink2); margin-bottom: 22px; }

/* ---------- подвал ---------- */
.eg-footer { background: #453424; color: #e9decd; margin-top: 56px; }
.eg-footer a { color: #f0e3cd; }
.eg-footer a:hover { color: var(--eg-yellow); }
.eg-foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 34px; padding: 44px 0 30px; }
.eg-foot-logo { display: inline-block; background: var(--eg-paper); border-radius: 10px; padding: 8px 14px; }
.eg-foot-logo img { width: 150px; height: 68px; object-fit: contain; display: block; }
.eg-foot-brand .eg-foot-tag { font-style: italic; font-family: var(--eg-serif); color: var(--eg-yellow); margin: 6px 0 12px; }
.eg-foot-brand p { font-size: 14px; color: #cfc2ab; max-width: 30em; }
.eg-foot-mail { margin-top: 12px; font-size: 14px; }
.eg-footer h3 { color: #fff; font-size: 15px; letter-spacing: .06em; text-transform: uppercase; font-family: var(--eg-sans); font-weight: 700; margin-bottom: 12px; }
.eg-footer ul { list-style: none; }
.eg-footer li { margin-bottom: 8px; font-size: 14.5px; }
.eg-foot-bottom { border-top: 1px solid rgba(255, 253, 247, .15); padding: 16px 0 22px; font-size: 13.5px; color: #b6a88f; }

/* ---------- адаптив ---------- */
@media (max-width: 980px) {
  .eg-grid { grid-template-columns: repeat(3, 1fr); }
  .eg-cats { grid-template-columns: repeat(2, 1fr); }
  .eg-hero-in { grid-template-columns: 1fr; padding-top: 32px; }
  .eg-product { grid-template-columns: 1fr; }
  .eg-product-media { position: static; }
  .eg-foot-grid { grid-template-columns: 1fr 1fr; }
  .eg-rating-grid, .eg-flip-grid { grid-template-columns: 1fr; }
  .eg-fitcare { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .eg-grid { grid-template-columns: repeat(2, 1fr); }
  .eg-burger { display: block; }
  .eg-nav {
    display: none; position: absolute; left: 0; right: 0; top: 74px;
    background: var(--eg-paper); border-bottom: 1px solid var(--eg-line);
    flex-direction: column; gap: 0; padding: 8px 20px 14px;
  }
  .eg-nav.open { display: flex; }
  .eg-nav a { padding: 10px 2px; border-bottom: 1px solid var(--eg-line); }
  .eg-card-ph { height: 150px; }
  .eg-card-ph img { max-height: 135px; }
}
@media (max-width: 460px) {
  .eg-grid { grid-template-columns: 1fr; }
  .eg-cats { grid-template-columns: 1fr; }
}
