:root {
  --bg: #f7f1e4;
  --panel: #fffaf0;
  --panel-2: #f0e8d6;
  --ink: #173e2d;
  --muted: #6e756e;
  --gold: #b9974c;
  --line: rgba(23, 62, 45, .18);
  --shadow: 0 14px 35px rgba(42, 48, 39, .08);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--ink);
}
a { color: inherit; }
.utilitybar {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 10px clamp(22px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
}
.topline {
  font-size: 15px;
  line-height: 1.35;
  letter-spacing: .01em;
  color: #173e2d;
  font-weight: 700;
}
.contactbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  flex-shrink: 0;
}
.phone {
  font-weight: 800;
  text-decoration: none;
  font-size: 18px;
  white-space: nowrap;
}
.socials { display: flex; align-items: center; gap: 10px; }
.social {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #fff;
  border: 1px solid rgba(23,62,45,.14);
  text-decoration: none;
  box-shadow: 0 3px 12px rgba(0,0,0,.05);
  transition: transform .15s ease, box-shadow .15s ease;
}
.social:hover { transform: translateY(-1px); box-shadow: 0 5px 15px rgba(0,0,0,.09); }
.social svg { width: 25px; height: 25px; fill: currentColor; }
.social-viber { color: #7360f2; }
.social-whatsapp { color: #25d366; }
.social-telegram { color: #229ed9; }
.hero { text-align: center; padding: 10px 20px 28px; }
.logo { width: min(520px, 72vw); max-height: 250px; object-fit: contain; display:block; margin:0 auto; }
.hero h1 { margin: 18px auto 6px; font-family: Georgia, serif; font-weight: 500; font-size: clamp(34px, 5vw, 64px); line-height: .98; max-width: 1100px; }
.hero p { margin: 0; font-size: clamp(16px, 2vw, 20px); color: #334d40; }
.divider { height: 1px; background: var(--line); max-width: 1180px; margin: 0 auto; }
.catalog { max-width: 1180px; margin: 0 auto; padding: 34px 18px 64px; }
.catalog h2 { text-align: center; font-family: Georgia, serif; font-weight: 500; font-size: clamp(38px, 5vw, 64px); margin: 0 0 28px; }
.category-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.category-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px; overflow: hidden;
  text-decoration: none; box-shadow: var(--shadow); min-width: 0;
}
.category-media { aspect-ratio: 4/3; background: linear-gradient(135deg,#ece1cc,#fff8eb); overflow: hidden; display:grid; place-items:center; }
.category-media img { width: 100%; height: 100%; object-fit: cover; display:block; }
.category-placeholder { color: #7d735f; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.category-body { padding: 15px 14px 17px; text-align: center; }
.category-body h3 { margin: 0 0 6px; font-size: 20px; line-height: 1.08; font-weight: 500; overflow-wrap: anywhere; }
.category-body p { margin: 0; font-size: 13px; line-height: 1.35; color: var(--muted); }
.products-wrap { max-width: 1180px; margin: 0 auto; padding: 32px 18px 72px; display:none; }
.products-head {
  display:flex;
  gap:14px;
  align-items:center;
  justify-content:flex-start;
  margin-bottom:22px;
}
.products-head h2 {
  flex:1;
  margin:0;
  text-align:center;
  font-family:Georgia,serif;
  font-size:clamp(25px,3vw,38px);
  line-height:1.05;
  font-weight:600;
}
.back-btn {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
  border:1px solid rgba(112,79,24,.3);
  background:linear-gradient(135deg,#cba95f,#96702d);
  color:#fff;
  border-radius:999px;
  padding:11px 17px;
  cursor:pointer;
  font:inherit;
  font-weight:800;
  box-shadow:0 8px 18px rgba(128,92,34,.22);
}
.back-icon {
  width:22px;
  height:22px;
  flex:0 0 auto;
  fill:currentColor;
  transform:translateY(-1px);
}
.product-grid { display:grid; grid-template-columns: repeat(3, 1fr); gap:18px; }
html.direct-category #catalog { display:none !important; }
html.direct-category #productsWrap { display:block !important; }
.category-help {
  grid-column:1/-1;
  display:block;
  width:min(760px,100%);
  margin:64px auto 0;
  padding:16px 20px;
  border:1px solid rgba(185,151,76,.38);
  border-radius:14px;
  background:linear-gradient(135deg,#fffaf0,#f0e4ca);
  color:#173e2d;
  text-align:center;
  text-decoration:none;
  font-size:clamp(15px,1.6vw,18px);
  line-height:1.3;
  font-weight:800;
  white-space:normal;
  box-shadow:0 8px 20px rgba(128,92,34,.10);
  transform:translateY(48px);
}
.product-card { background:var(--panel); border:1px solid var(--line); border-radius:16px; overflow:hidden; box-shadow:var(--shadow); }
.product-card .category-media { aspect-ratio: 1/1; }
.product-card .category-body { text-align:left; }
.price { font-weight:800; margin-top:8px; }
.button {
  border:1px solid rgba(112,79,24,.28);
  border-radius:12px;
  padding:12px 15px;
  background:linear-gradient(135deg,#cba95f,#96702d);
  color:#fff;
  cursor:pointer;
  font-weight:800;
  box-shadow:0 7px 16px rgba(128,92,34,.2);
  transition:transform .15s ease,box-shadow .15s ease;
}
.button:hover { transform:translateY(-1px); box-shadow:0 10px 20px rgba(128,92,34,.26); }
.button.secondary { background:#fffaf0; color:#8b6628; border:1px solid rgba(185,151,76,.5); box-shadow:none; }
.empty { grid-column:1/-1; text-align:center; padding:40px 20px; color:var(--muted); }
.modal { position:fixed; inset:0; background:rgba(20,25,21,.55); display:none; align-items:flex-end; justify-content:center; z-index:20; }
.modal.open { display:flex; }
.modal-card { width:min(680px,100%); max-height:92vh; overflow:auto; background:var(--panel); border-radius:22px 22px 0 0; padding:22px; }
.modal-close { float:right; border:0; background:transparent; font-size:28px; cursor:pointer; }
.gallery { display:grid; grid-template-columns:repeat(3,1fr); gap:8px; margin:14px 0; }
.gallery img { width:100%; aspect-ratio:1/1; object-fit:cover; border-radius:10px; }
.contact-choice {
  margin-top:18px;
  padding:16px;
  border:1px solid rgba(185,151,76,.3);
  border-radius:18px;
  background:linear-gradient(145deg,#fffdf8,#f3ead8);
  box-shadow:0 10px 26px rgba(68,54,30,.08);
}
.contact-choice h3 { margin:0 0 12px; font-size:18px; color:var(--ink); }
.messenger-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:9px; }
.messenger-btn {
  min-height:62px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:5px;
  padding:9px 5px;
  border-radius:14px;
  text-decoration:none;
  font-size:12px;
  font-weight:800;
  background:#fff;
  border:1px solid rgba(23,62,45,.12);
  box-shadow:0 4px 12px rgba(40,36,28,.07);
  transition:transform .15s ease,box-shadow .15s ease;
}
.messenger-btn:hover { transform:translateY(-1px); box-shadow:0 7px 16px rgba(40,36,28,.11); }
.messenger-icon {
  width:31px;
  height:31px;
  border-radius:50%;
  display:grid;
  place-items:center;
  color:#fff;
}
.messenger-icon svg { width:20px; height:20px; fill:currentColor; }
.messenger-viber { color:#5f4bc7; }
.messenger-viber .messenger-icon { background:#7360f2; }
.messenger-whatsapp { color:#168b47; }
.messenger-whatsapp .messenger-icon { background:#25d366; }
.messenger-telegram { color:#147ba9; }
.messenger-telegram .messenger-icon { background:#229ed9; }
.call-order {
  min-height:46px;
  margin-top:10px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  border:1px solid rgba(185,151,76,.45);
  border-radius:13px;
  background:rgba(255,255,255,.78);
  color:var(--ink);
  font-weight:800;
  text-decoration:none;
}
.call-order svg { width:21px; height:21px; fill:var(--gold); }
.order-form {
  display:grid;
  gap:11px;
  margin-top:18px;
  padding:18px;
  border:1px solid rgba(185,151,76,.3);
  border-radius:18px;
  background:linear-gradient(145deg,#fffdf8,#f1e6d1);
  box-shadow:0 10px 26px rgba(68,54,30,.08);
}
.order-form h3 { margin:0 0 5px; font-family:Georgia,serif; font-size:24px; font-weight:600; }
.order-form input,.order-form textarea {
  width:100%;
  border:1px solid rgba(185,151,76,.38);
  border-radius:13px;
  padding:14px;
  background:rgba(255,255,255,.92);
  color:var(--ink);
  font:inherit;
  outline:none;
  transition:border-color .15s ease,box-shadow .15s ease;
}
.order-form input:focus,.order-form textarea:focus {
  border-color:var(--gold);
  box-shadow:0 0 0 3px rgba(185,151,76,.14);
}
.order-form .button[type="submit"] {
  min-height:50px;
  margin-top:2px;
  color:#fff;
  background:linear-gradient(135deg,#c6a35c,#96702d);
  border:1px solid rgba(112,79,24,.25);
  box-shadow:0 8px 18px rgba(128,92,34,.2);
  font-size:16px;
}
.footer { border-top:1px solid var(--line); padding:24px 18px; text-align:center; color:var(--muted); font-size:13px; }
@media (max-width: 900px) {
  .utilitybar { flex-direction: column; justify-content:center; gap:8px; padding:10px 16px 12px; }
  .topline { text-align:center; font-size:14px; }
  .contactbar { justify-content:center; }
  .category-grid { grid-template-columns:repeat(3,1fr);}
  .product-grid{grid-template-columns:repeat(2,1fr);}
}
@media (max-width: 640px) {
  .utilitybar { gap:7px; padding:7px 9px 9px; min-height:auto; }
  .topline { font-size:10.5px; line-height:1.25; text-align:center; }
  .contactbar { width:100%; justify-content:center; gap:8px; flex-wrap:nowrap; }
  .phone { font-size:13.5px; }
  .socials { gap:6px; }
  .social { width:34px; height:34px; }
  .social svg { width:20px; height:20px; }

  .hero { padding:10px 12px 13px; }
  .logo { width:min(275px, 55vw); max-height:145px; }
  .hero h1 { margin:7px auto 3px; font-size:27px; line-height:1.02; max-width:610px; }
  .hero p { font-size:11.5px; line-height:1.2; }

  .catalog { padding:20px 9px 54px; }
  .catalog h2 { font-size:30px; line-height:1; margin:0 0 16px; }
  .category-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap:8px; }
  .category-card {
    border-radius:10px;
    box-shadow:0 3px 10px rgba(42,48,39,.045);
    border-color:rgba(23,62,45,.16);
  }
  .category-media {
    aspect-ratio: 1.6 / 1;
  }
  .category-placeholder {
    font-size:10px;
    letter-spacing:.07em;
  }
  .category-body {
    min-height:72px;
    padding:8px 7px 9px;
    display:flex;
    flex-direction:column;
    justify-content:flex-start;
  }
  .category-body h3 {
    margin:0 0 3px;
    font-size:13.5px;
    line-height:1.08;
    font-weight:750;
  }
  .category-body p {
    margin:0 auto;
    max-width:96%;
    font-size:11px;
    line-height:1.18;
    color:#756d60;
  }

  .product-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
  .category-help {
    width:100%;
    margin-top:88px;
    transform:translateY(72px);
    padding:13px 12px;
    border-radius:11px;
    font-size:13px;
    line-height:1.28;
    letter-spacing:0;
  }
  .product-card .category-body h3 { font-size:13.5px; }
  .products-wrap { padding:20px 9px 54px; }
  .products-head {
    flex-direction:column;
    align-items:stretch;
    gap:13px;
    margin-bottom:16px;
  }
  .products-head h2 {
    width:100%;
    font-family:Inter,ui-sans-serif,system-ui,sans-serif;
    font-size:clamp(18px,5.2vw,22px);
    line-height:1;
    font-weight:850;
    white-space:nowrap;
    letter-spacing:-.02em;
  }
  .back-btn {
    align-self:flex-start;
    min-height:42px;
    padding:10px 16px;
    font-size:14px;
    line-height:1;
  }
}
@media (max-width: 430px) {
  .topline { font-size:10px; }
  .phone { font-size:13px; }
  .social { width:32px; height:32px; }
  .social svg { width:19px; height:19px; }
  .logo { width:54vw; max-height:135px; }
  .hero h1 { font-size:26px; }
  .hero p { font-size:11px; }
  .catalog h2 { font-size:29px; }
  .category-grid { gap:8px; }
  .category-body { min-height:70px; }
  .category-body h3 { font-size:13px; }
  .category-body p { font-size:10.5px; }
}


/* Compact product copy: keep words intact and reduce unnecessary wrapping. */
.product-card .category-body h3 {
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
  letter-spacing: -.015em;
}
@media (max-width: 640px) {
  .product-card .category-body h3 {
    font-size: 12.5px;
    line-height: 1.12;
  }
}
