/* ==========================================================================
   pages.css - FAQ, контакт, за нас, отзиви, търсене, 404, страница от редактора
   Префикси: .mg-page .mg-faq .mg-contact .mg-za .mg-otz .mg-search-results .mg-404
   Източник на вида: claude-design 05 (за нас, 404), 07 (faq), 08 (390),
   09 (контакт, търсене, отзиви). Тъмните тонове на пастелите (#4A1230,
   #6B2545, #0E2F2D, #14514D, #7A1E49, #6B4400, #5A3B00, #4A2E85, #2E1D57)
   не са токени - пишат се литерално.
   Копие 1:1 на magia/makets/final/assets/pages.css без правилата за
   .mg-maket-note (.mg-za__values .mg-maket-note, .mg-otz__note) - те са само
   за макета (И8). Елементни селектори тук няма - те живеят само в base.css.
   ========================================================================== */

/* ---------- Общ розов блок в началото (страница от редактора, index) ---------- */
.mg-page__head{ background:var(--mg-powder); padding-block:clamp(28px,3.5vw,48px); }
.mg-page__head h1{ margin-bottom:10px; }
.mg-page__head p{ max-width:66ch; margin:0; font-size:clamp(16px,0.9rem + 0.3vw,19px); }
/* B6.4: `page.php` слага `--center` на „Моят акаунт" (B5.11); в макета `akaunt.html`
   заглавието е центрирано и на 1440, и на 390. */
.mg-page__head--center{ text-align:center; }
body.mg .mg-page__head--center p{ margin-inline:auto; }
.mg-page__body{ padding-block:clamp(28px,3.5vw,48px); }

/* ---------- Заглавна карта в контейнера (FAQ, отзиви) - дизайн 07, 09 ---------- */
.mg-page__top{ padding-block:24px 40px; }
.mg-page__box{
  display:flex; flex-direction:column; gap:16px;
  padding:36px 40px; border-radius:20px; background:var(--mg-p-pink-bg);
}
.mg-page__box--rose{ background:var(--mg-p-pink); }
body.mg .mg-page__title{ font-size:44px; line-height:1.1; margin:0; color:#4A1230; }
body.mg .mg-page__lead{ max-width:70ch; margin:0; font-size:18px; line-height:1.6; color:#6B2545; }
body.mg .mg-page__box--rose .mg-page__lead{ color:#4A1230; }

/* ---------- Поле за търсене в страница (FAQ, 404): бяло хапче с лупа ---------- */
.mg-page__search{
  display:flex; align-items:center; gap:10px;
  max-width:520px; padding:0 22px;
  background:var(--mg-white); border:1px solid var(--mg-line); border-radius:var(--mg-r-pill);
}
.mg-page__search:focus-within{ border-color:var(--mg-pink); }
.mg-page__box .mg-page__search{ border-color:transparent; margin-top:4px; }
.mg-page__box .mg-page__search:focus-within{ border-color:var(--mg-pink); }
.mg-page__search button{
  display:flex; align-items:center; justify-content:center; flex:0 0 auto;
  padding:0; background:none; border:0; color:#A8929A; cursor:pointer;
}
body.mg .mg-page__search input[type=search]{
  flex:1 1 auto; min-width:0; min-height:50px; padding:0;
  font-size:16px; color:var(--mg-ink); background:transparent; border:0; border-radius:0;
}
body.mg .mg-page__search input[type=search]:focus-visible{ outline:none; }
body.mg .mg-page__search input[type=search]::placeholder{ color:var(--mg-meta); }

/* ---------- Две колони: сайдбар + съдържание (FAQ) ---------- */
.mg-page__layout{ display:grid; grid-template-columns:268px 1fr; gap:36px; align-items:start; }
.mg-page__layout > *{ min-width:0; }
.mg-page__side{ position:sticky; top:20px; display:flex; flex-direction:column; gap:14px; min-width:0; }

/* Списък теми (котви към H2-тата) */
body.mg .mg-page__topics{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:6px; max-width:100%; }
body.mg .mg-page__topics a{
  display:flex; align-items:center; min-height:44px; padding:11px 16px; border-radius:var(--mg-r-pill);
  font-size:16px; line-height:1.3; color:var(--mg-text); text-decoration:none;
}
body.mg .mg-page__topics a:hover{ background:var(--mg-powder); color:var(--mg-ink); text-decoration:none; }
body.mg .mg-page__topics a.is-active{ font-weight:700; color:var(--mg-pink-text); background:var(--mg-p-pink-bg); }

/* ---------- Розов CTA блок (FAQ отдолу, За нас отдолу) ---------- */
.mg-page__cta{
  display:flex; flex-direction:column; align-items:center; gap:14px; text-align:center;
  padding:36px; border-radius:20px; background:var(--mg-pink);
}
body.mg .mg-page__cta-title{ font-size:30px; line-height:1.15; margin:0; color:var(--mg-white); }
body.mg .mg-page__cta-text{ max-width:52ch; margin:0; font-size:17px; line-height:1.6; color:var(--mg-white); }
body.mg .mg-page__cta-text a.mg-text-link{ color:inherit; text-decoration:underline; text-underline-offset:3px; }
body.mg .mg-page__cta-text a.mg-text-link:hover{ text-decoration-thickness:2px; }
body.mg .mg-faq__help a.mg-text-link{ color:inherit; text-decoration:underline; text-underline-offset:3px; }
body.mg a.mg-page__cta-btn{
  display:inline-flex; align-items:center; justify-content:center; min-height:50px; margin-top:4px;
  padding:14px 30px; border-radius:var(--mg-r-pill);
  font-size:16px; font-weight:700; line-height:1.2; color:var(--mg-pink); background:var(--mg-white); text-decoration:none;
}
body.mg a.mg-page__cta-btn:hover{ background:var(--mg-p-pink-bg); color:var(--mg-pink-text); text-decoration:none; }
.mg-page__cta--lg{ padding:44px; gap:16px; }
body.mg .mg-page__cta--lg .mg-page__cta-title{ font-size:36px; }
body.mg .mg-page__cta--lg .mg-page__cta-text{ max-width:60ch; font-size:18px; }
body.mg .mg-page__cta--lg a.mg-page__cta-btn{ font-size:17px; padding:16px 32px; min-height:52px; margin-top:6px; }

/* ==========================================================================
   FAQ - 07-faq-1440 / 07-faq-390
   ========================================================================== */
.mg-faq{ padding-block:0 72px; }
.mg-faq__topics{
  display:flex; flex-direction:column; gap:6px;
  padding:22px; border-radius:var(--mg-r-lg); background:var(--mg-white); box-shadow:var(--mg-sh-sm);
}
.mg-faq__topics .mg-eyebrow{ margin:0 0 6px; }
.mg-faq__help{
  display:flex; flex-direction:column; gap:10px;
  padding:22px; border-radius:var(--mg-r-lg); background:var(--mg-p-teal-bg);
}
body.mg .mg-faq__help-title{ font-size:20px; line-height:1.3; margin:0; color:#0E2F2D; }
body.mg .mg-faq__help p{ margin:0; font-size:15px; line-height:1.55; color:#14514D; }
.mg-faq__help .mg-btn{ margin-top:4px; font-size:15px; font-weight:700; }

/* Групите: H2 от съдържанието + details.mg-acc (работи и без обвивка) */
.mg-faq__list{ display:flex; flex-direction:column; }
.mg-faq__group{ display:flex; flex-direction:column; gap:12px; margin-bottom:28px; }
body.mg .mg-faq__list h2{ font-size:30px; line-height:1.2; margin:0; }
body.mg .mg-faq__list > h2{ margin-top:28px; margin-bottom:12px; }
body.mg .mg-faq__list > h2:first-child{ margin-top:0; }
.mg-faq__list > .mg-acc + .mg-acc{ margin-top:12px; }
.mg-faq .mg-acc{ border-bottom:0; border-radius:var(--mg-r-lg); background:var(--mg-white); box-shadow:var(--mg-sh-sm); }
.mg-faq .mg-acc > summary{ min-height:60px; padding:18px 24px; font-size:20px; line-height:1.3; }
.mg-faq .mg-acc > summary::after{ font-size:22px; color:var(--mg-meta); }
.mg-faq .mg-acc[open] > summary{ border-bottom:1px solid var(--mg-powder); }
.mg-faq .mg-acc[open] > summary::after{ color:var(--mg-pink); }
/* отговорът: div.mg-acc__body или голи <p> след summary (както ги даде импортът) */
.mg-faq .mg-acc > :not(summary){ padding-inline:24px; font-size:17px; line-height:1.75; color:var(--mg-text); }
.mg-faq .mg-acc > summary + *{ padding-top:18px; }
.mg-faq .mg-acc > :last-child:not(summary){ padding-bottom:22px; margin-bottom:0; }

/* ==========================================================================
   Контакт - 09-kontakt-1440 / 09-kontakt-390
   ========================================================================== */
.mg-contact{ padding-block:36px 72px; }
.mg-contact__layout{ display:grid; grid-template-columns:1fr 420px; gap:44px; align-items:start; }
.mg-contact__layout > *{ min-width:0; }
.mg-contact__main{ display:flex; flex-direction:column; gap:20px; }
.mg-contact__head{ display:flex; flex-direction:column; gap:20px; }
.mg-contact__head .mg-eyebrow{ margin:0; }
body.mg .mg-contact__title{ font-size:46px; line-height:1.1; margin:0; }
body.mg .mg-contact__lead{ max-width:60ch; margin:0; font-size:19px; line-height:1.6; color:var(--mg-text); }

/* Формата */
.mg-contact__form{
  display:flex; flex-direction:column; gap:18px;
  padding:30px; border-radius:20px; background:var(--mg-white); box-shadow:var(--mg-sh-sm);
}
.mg-contact__row{ display:grid; grid-template-columns:1fr 1fr; gap:16px; }
.mg-contact__row > *{ min-width:0; }
.mg-contact__form .mg-field{ margin:0; }
.mg-contact__form .mg-field__label{ margin-bottom:7px; }
body.mg .mg-contact__form input[type=text],
body.mg .mg-contact__form input[type=email],
body.mg .mg-contact__form select,
body.mg .mg-contact__form textarea{ min-height:52px; padding:14px 16px; background-color:var(--mg-cream); }
body.mg .mg-contact__form select{ padding-right:40px; font-weight:500; }
body.mg .mg-contact__form input:focus,
body.mg .mg-contact__form select:focus,
body.mg .mg-contact__form textarea:focus{ outline:none; border-color:var(--mg-pink); box-shadow:0 0 0 3px rgba(193,59,118,.18); }
body.mg .mg-contact__form .mg-field--error input{ background-color:var(--mg-p-pink-bg); }
.mg-contact__form .mg-check{ color:var(--mg-text); line-height:1.55; }
body.mg .mg-contact__form .mg-check a{ font-weight:600; text-decoration:underline; text-underline-offset:3px; }
.mg-contact__submit{ align-self:flex-start; min-height:58px; padding:16px 44px; font-size:18px; font-weight:700; }

/* Успех: лента под формата */
.mg-contact__ok{
  display:flex; gap:12px; align-items:center;
  padding:20px 24px; border-radius:var(--mg-r-lg); background:var(--mg-p-teal-bg);
  font-size:16px; line-height:1.55; color:#0E2F2D;
}
.mg-contact__ok svg{ flex:0 0 auto; color:var(--mg-teal); }

/* Дясната колона */
.mg-contact__side{ display:flex; flex-direction:column; gap:16px; }
.mg-contact__card{ display:flex; flex-direction:column; gap:12px; padding:24px; border-radius:var(--mg-r-lg); }
body.mg .mg-contact__card-title{ font-size:22px; line-height:1.3; margin:0; }
body.mg .mg-contact__card--social p,body.mg .mg-contact__card--hours p{ margin:0; font-size:16px; line-height:1.6; }
.mg-contact__card--social{ background:var(--mg-p-pink-bg); }
.mg-contact__card--social .mg-contact__card-title{ color:#4A1230; }
body.mg .mg-contact__card--social p{ color:#6B2545; }
.mg-contact__socials{ display:flex; gap:10px; margin-top:4px; }
body.mg a.mg-contact__social{
  display:flex; align-items:center; justify-content:center; gap:8px;
  width:44px; height:44px; border-radius:50%; background:var(--mg-white); color:var(--mg-ink); text-decoration:none;
}
body.mg a.mg-contact__social:hover{ color:var(--mg-pink); text-decoration:none; }
.mg-contact__social svg{ opacity:.8; }
.mg-contact__social-label{ display:none; }
/* имейлът под иконите (Р37); body.mg - да бие `--social p` и `a:any-link` */
body.mg .mg-contact__mail{ margin:6px 0 0; font-size:16px; line-height:1.5; }
body.mg .mg-contact__mail a{ color:#4A1230; font-weight:600; text-decoration:underline; text-underline-offset:3px; }
body.mg .mg-contact__mail a:hover{ color:var(--mg-pink); }

.mg-contact__card--pre{ gap:14px; background:var(--mg-white); box-shadow:var(--mg-sh-sm); }
.mg-contact__card--pre .mg-eyebrow{ margin:0; }
body.mg .mg-contact__pre{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:14px; }
body.mg .mg-contact__pre a{
  display:flex; align-items:center; justify-content:space-between; gap:12px; min-height:44px;
  font-size:16px; line-height:1.4; color:var(--mg-ink);
}
body.mg .mg-contact__pre a:hover{ color:var(--mg-pink); text-decoration:none; }
body.mg .mg-contact__pre a span{ flex:0 0 auto; color:var(--mg-meta); }
body.mg a.mg-contact__all{ display:flex; align-items:center; min-height:44px; font-size:16px; font-weight:700; color:var(--mg-pink); }

.mg-contact__card--hours{ gap:8px; background:var(--mg-p-purple-bg); }
body.mg .mg-contact__card--hours .mg-contact__card-title{ font-size:20px; color:#4A2E85; }
body.mg .mg-contact__card--hours p{ line-height:1.7; color:#4A2E85; }

/* Състояние „грешка" (демо под страницата) */
/* рамката на демото е inline в kontakt.html */

/* ==========================================================================
   За нас - 05-za-nas-1440 / 08-za-nas-390
   ========================================================================== */
.mg-za__hero,.mg-za__story,.mg-za__values{ padding-block:56px; }
.mg-za__story{ background:var(--mg-powder); }
.mg-za__cta{ padding-block:0 72px; }
.mg-za__grid{ display:grid; grid-template-columns:1fr 1fr; gap:56px; align-items:center; }
.mg-za__grid > *{ min-width:0; }
.mg-za__text{ display:flex; flex-direction:column; gap:20px; font-size:19px; line-height:1.7; }
body.mg .mg-za__text p{ margin:0; }
.mg-za__text .mg-eyebrow{ margin:0; }
body.mg .mg-za__title{ font-size:50px; line-height:1.1; margin:0; }
body.mg .mg-za__h2{ font-size:36px; line-height:1.15; margin:0; }
.mg-za__shop{ padding-block:0 56px; }
.mg-za__actions{ margin:0; display:flex; justify-content:center; }
.mg-za__actions .mg-btn{ min-height:52px; padding:14px 30px; font-size:17px; font-weight:700; }
.mg-za__photo{ margin:0; border:6px solid var(--mg-p-pink-bg); border-radius:20px; overflow:hidden; aspect-ratio:1024/977; background:var(--mg-p-pink-bg); }
.mg-za__photo img{ width:100%; height:100%; object-fit:cover; }
.mg-za__story-media img{ display:block; width:100%; height:auto; }
.mg-za__story .mg-za__text{ gap:18px; }
.mg-za__story .mg-za__text{ font-size:18px; line-height:1.8; }
.mg-za__story-media{ margin:0; aspect-ratio:auto; border-radius:20px; overflow:hidden; background:var(--mg-p-teal-bg); }

/* „В какво вярваме": H2 + ul от съдържанието, всяко li = карта, strong = заглавие */
body.mg .mg-za__values .mg-za__h2{ text-align:center; margin-bottom:26px; }
body.mg .mg-za__cards{ list-style:none; margin:0; padding:0; display:grid; grid-template-columns:repeat(3,1fr); gap:22px; }
.mg-za__cards > li{
  display:flex; flex-direction:column; gap:10px; margin:0;
  padding:28px; border-radius:var(--mg-r-lg); font-size:16px; line-height:1.6;
}
.mg-za__cards strong{ display:block; font-family:var(--mg-font-head); font-size:24px; line-height:1.25; font-weight:700; }
.mg-za__cards > li:nth-child(3n+1){ background:var(--mg-p-pink-bg); color:#6B2545; }
.mg-za__cards > li:nth-child(3n+1) strong{ color:#7A1E49; }
.mg-za__cards > li:nth-child(3n+2){ background:var(--mg-p-yellow-bg); color:#6B4400; }
.mg-za__cards > li:nth-child(3n){ background:var(--mg-p-purple-bg); color:#4A2E85; }

/* ==========================================================================
   Отзиви - 09-otzivi-1440 (карта на отзив = .mg-review от B1.1)
   ========================================================================== */
.mg-otz__top{ padding-block:32px; }
.mg-otz__head{ flex-direction:row; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:32px; }
.mg-otz__intro{ display:flex; flex-direction:column; gap:12px; }
body.mg .mg-otz__head .mg-page__title{ font-size:42px; line-height:1.12; }
body.mg .mg-otz__head .mg-page__lead{ max-width:56ch; }
.mg-otz__score{
  display:flex; flex-direction:column; align-items:center; gap:6px;
  padding:24px 32px; border-radius:var(--mg-r-lg); background:var(--mg-white);
}
.mg-otz__num{ font-family:var(--mg-font-head); font-size:46px; font-weight:700; line-height:1; color:var(--mg-pink); }
.mg-otz__score .mg-stars{ font-size:18px; letter-spacing:2px; }
.mg-otz__count{ font-size:15px; color:var(--mg-text); }
.mg-otz{ padding-block:0 72px; }
.mg-otz__chips{ display:flex; gap:10px; flex-wrap:wrap; margin-bottom:22px; }
/* чиповете тук са <a> (филтърът ?grupa= е на сървъра), затова и вариантът
   body.mg …a.mg-chip - както е за табовете на търсенето по-долу */
.mg-otz__chips .mg-chip,body.mg .mg-otz__chips a.mg-chip{ min-height:44px; padding:11px 20px; border-color:transparent; }
.mg-otz__grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:var(--mg-gap); align-items:start; }
.mg-otz__cta{
  display:flex; flex-direction:column; gap:12px;
  padding:26px; border-radius:var(--mg-r-lg); background:var(--mg-p-teal-bg);
}
body.mg .mg-otz__cta-title{ font-size:21px; line-height:1.3; margin:0; color:#0E2F2D; }
body.mg .mg-otz__cta p{ margin:0; font-size:16px; line-height:1.6; color:#14514D; }
.mg-otz__cta .mg-btn{ margin-top:4px; font-size:15px; font-weight:700; }
.mg-otz__pager{ margin-top:30px; }
body.mg .mg-otz__pager a,.mg-otz__pager span{ min-width:46px; min-height:46px; border-color:transparent; background:var(--mg-white); color:var(--mg-text); }
body.mg .mg-otz__pager a:hover{ background:var(--mg-p-pink-bg); color:var(--mg-pink-text); }
body.mg .mg-otz__pager .is-current{ background:var(--mg-pink); color:var(--mg-white); }

/* ==========================================================================
   Резултати от търсене - 09-tarsene-1440 / 09-prazni-sastoyaniya
   (заявката стои в полето на хедъра - data-search в chrome.js)
   ========================================================================== */
.mg-search-results{ padding-block:32px 72px; }
body.mg .mg-search-results__title{ font-size:38px; line-height:1.15; margin:0 0 12px; }
body.mg .mg-search-results__count{ margin:0 0 16px; font-size:17px; color:var(--mg-text); }
.mg-search-results__tabs{ display:flex; gap:10px; flex-wrap:wrap; margin-bottom:24px; max-width:100%; }
.mg-search-results__tabs .mg-chip,body.mg .mg-search-results__tabs a.mg-chip{ min-height:44px; padding:11px 20px; border-color:transparent; }
.mg-search-results__block{ display:flex; flex-direction:column; gap:18px; margin-top:40px; scroll-margin-top:20px; }
body.mg .mg-search-results__h2{ font-size:28px; line-height:1.2; margin:0; }
.mg-search-results mark{ background:var(--mg-p-yellow-bg); color:var(--mg-ink); padding:0 2px; border-radius:3px; }

/* Ред-карта на статия/страница */
body.mg a.mg-search-results__post{
  display:grid; grid-template-columns:120px 1fr auto; grid-template-areas:"media body more";
  gap:18px; align-items:center; padding:20px;
  border-radius:var(--mg-r-lg); background:var(--mg-white); box-shadow:var(--mg-sh-sm);
  color:var(--mg-ink); text-decoration:none;
}
body.mg a.mg-search-results__post:hover{ box-shadow:var(--mg-sh-md); text-decoration:none; }
body.mg a.mg-search-results__post--page{ grid-template-columns:1fr auto; grid-template-areas:"body more"; }
.mg-search-results__media{ grid-area:media; aspect-ratio:16/10; border-radius:var(--mg-r-sm); overflow:hidden; background:var(--mg-p-purple-bg); }
.mg-search-results__media img{ width:100%; height:100%; object-fit:cover; }
.mg-search-results__body{ grid-area:body; display:flex; flex-direction:column; gap:6px; min-width:0; }
.mg-search-results__meta{ font-size:13px; line-height:1.4; color:var(--mg-meta); }
body.mg .mg-search-results__post-title{ font-size:21px; line-height:1.25; margin:0; color:var(--mg-ink); }
.mg-search-results__more{ grid-area:more; font-size:15px; font-weight:700; color:var(--mg-pink); white-space:nowrap; }

/* Празно търсене */
.mg-search-results__empty{ margin-inline:auto;
  display:flex; flex-direction:column; gap:18px;
  max-width:820px; padding:28px; border-radius:var(--mg-r-lg); background:var(--mg-white); box-shadow:var(--mg-sh-md);
}
.mg-search-results__empty .mg-eyebrow{ margin:0; }
.mg-search-results__field{
  display:flex; align-items:center; gap:10px; padding:13px 20px;
  border:2px solid var(--mg-pink); border-radius:var(--mg-r-pill); background:var(--mg-cream);
  font-size:17px; color:var(--mg-ink);
}
.mg-search-results__field svg{ flex:0 0 auto; color:var(--mg-meta); }
.mg-search-results__field span{ flex:1 1 auto; min-width:0; }
.mg-search-results__field b{
  display:flex; align-items:center; justify-content:center; flex:0 0 auto;
  width:28px; height:28px; border-radius:50%; background:var(--mg-p-pink-bg); color:var(--mg-pink-text); font-weight:400;
}
.mg-search-results__empty .mg-empty{ display:flex; flex-direction:column; align-items:center; gap:14px; padding-block:16px; }
.mg-search-results__empty .mg-empty__icon{ width:64px; height:64px; margin:0; }
body.mg .mg-search-results__empty-title{ font-size:28px; line-height:1.2; margin:0; }
.mg-search-results__empty .mg-empty p{ max-width:52ch; margin:0; font-size:17px; line-height:1.6; color:var(--mg-text); }
.mg-search-results__empty .mg-empty__chips{ margin:0; gap:10px; }
.mg-search-results__empty .mg-empty__chips .mg-chip,
body.mg .mg-search-results__empty .mg-empty__chips a.mg-chip{ min-height:46px; padding:12px 20px; font-weight:700; border-color:transparent; }
body.mg a.mg-search-results__sugg--pink{ background:var(--mg-p-pink-bg); color:var(--mg-pink-text); }
body.mg a.mg-search-results__sugg--yellow{ background:var(--mg-p-yellow-bg); color:#6B4400; }
body.mg a.mg-search-results__sugg--teal{ background:var(--mg-p-teal-bg); color:var(--mg-teal-text); }
body.mg a.mg-search-results__sugg--purple{ background:var(--mg-p-purple-bg); color:#4A2E85; }

/* ==========================================================================
   404 - 05-404-1440 / 08-404-390
   ========================================================================== */
.mg-404{ padding-block:72px; }
.mg-404__inner{ display:flex; flex-direction:column; align-items:center; gap:22px; text-align:center; }
body.mg .mg-404__num{ margin:0; font-family:var(--mg-font-head); font-size:120px; font-weight:700; line-height:1; color:var(--mg-pink); }
body.mg .mg-404__title{ font-size:42px; line-height:1.15; margin:0; }
body.mg .mg-404__text{ max-width:56ch; margin:0; font-size:19px; line-height:1.65; color:var(--mg-text); }
.mg-404 .mg-page__search{ width:420px; max-width:100%; margin-top:6px; }
.mg-404__actions{ display:flex; gap:14px; justify-content:center; flex-wrap:wrap; margin-top:6px; }
.mg-404__actions .mg-btn{ min-height:52px; padding:14px 30px; font-size:17px; font-weight:700; }

.mg-404__more{ padding-block:0 72px; }
body.mg .mg-404__h2{ font-size:30px; line-height:1.15; margin:0 0 22px; text-align:center; }
.mg-404__tiles{ display:grid; grid-template-columns:repeat(4,1fr); gap:22px; }
body.mg a.mg-404__tile{
  display:flex; flex-direction:column; justify-content:space-between; gap:40px;
  padding:26px; border-radius:var(--mg-r-lg); text-decoration:none;
  transition:box-shadow .15s;
}
body.mg a.mg-404__tile:hover{ box-shadow:0 18px 40px rgba(51,38,43,.16); text-decoration:none; }
.mg-404__tile-name{ font-family:var(--mg-font-head); font-size:22px; font-weight:700; line-height:1.25; }
.mg-404__tile-count{ font-size:15px; font-weight:700; line-height:1.3; }
body.mg a.mg-404__tile--pink{ background:var(--mg-p-pink-bg); color:#4A1230; }
.mg-404__tile--pink .mg-404__tile-count{ color:var(--mg-pink-text); }
body.mg a.mg-404__tile--yellow{ background:var(--mg-p-yellow-bg); color:#5A3B00; }
.mg-404__tile--yellow .mg-404__tile-count{ color:#6B4400; }
body.mg a.mg-404__tile--teal{ background:var(--mg-p-teal-bg); color:#0E2F2D; }
.mg-404__tile--teal .mg-404__tile-count{ color:var(--mg-teal-text); }
body.mg a.mg-404__tile--purple{ background:var(--mg-p-purple-bg); color:#2E1D57; }
.mg-404__tile--purple .mg-404__tile-count{ color:#4A2E85; }

/* ==========================================================================
   Таблет
   ========================================================================== */
@media (max-width:1023px){
  .mg-page__layout{ grid-template-columns:220px 1fr; gap:24px; }
  .mg-contact__layout{ grid-template-columns:1fr 320px; gap:28px; }
  .mg-za__grid{ gap:32px; }
  body.mg .mg-za__title{ font-size:40px; }
  .mg-otz__grid{ grid-template-columns:repeat(2,1fr); }
  .mg-404__tiles{ grid-template-columns:repeat(2,1fr); }
}

/* ==========================================================================
   Мобилно (390) - правило R8
   ========================================================================== */
@media (max-width:767px){
  /* заглавна карта */
  .mg-page__top{ padding-block:16px; }
  .mg-page__box{ gap:12px; padding:20px; border-radius:var(--mg-r-md); }
  body.mg .mg-page__title{ font-size:27px; line-height:1.15; }
  body.mg .mg-page__lead{ font-size:15px; line-height:1.55; }
  body.mg .mg-page__search input[type=search]{ min-height:46px; font-size:15px; }
  .mg-page__search{ padding:0 18px; }
  .mg-page__cta{ gap:12px; padding:22px; border-radius:var(--mg-r-md); }
  body.mg .mg-page__cta-title,body.mg .mg-page__cta--lg .mg-page__cta-title{ font-size:22px; line-height:1.2; }
  body.mg .mg-page__cta-text,body.mg .mg-page__cta--lg .mg-page__cta-text{ font-size:15px; line-height:1.55; }
  body.mg a.mg-page__cta-btn,body.mg .mg-page__cta--lg a.mg-page__cta-btn{ min-height:48px; padding:14px 24px; font-size:15px; margin-top:0; }

  /* FAQ: темите стават хоризонтален ред чипове, помощната карта се скрива (дизайн 07-faq-390) */
  .mg-page__layout{ grid-template-columns:1fr; gap:12px; }
  .mg-page__side{ position:static; }
  .mg-faq__topics{ padding:0; background:transparent; box-shadow:none; border-radius:0; }
  .mg-faq__topics .mg-eyebrow{ display:none; }
  body.mg .mg-page__topics{ flex-direction:row; gap:8px; overflow-x:auto; padding-bottom:6px; }
  .mg-page__topics li{ flex:0 0 auto; }
  body.mg .mg-page__topics a{ min-height:44px; padding:10px 16px; font-size:14px; font-weight:600; color:var(--mg-ink); background:var(--mg-white); white-space:nowrap; }
  body.mg .mg-page__topics a.is-active{ color:var(--mg-white); background:var(--mg-pink); }
  .mg-faq__help{ display:none; }
  .mg-faq{ padding-block:0 24px; }
  .mg-faq__group{ gap:10px; margin-bottom:18px; }
  body.mg .mg-faq__list h2{ font-size:22px; }
  body.mg .mg-faq__list > h2{ margin-top:18px; margin-bottom:10px; }
  .mg-faq__list > .mg-acc + .mg-acc{ margin-top:10px; }
  .mg-faq .mg-acc{ border-radius:14px; }
  .mg-faq .mg-acc > summary{ min-height:52px; padding:14px 16px; font-size:17px; gap:12px; }
  .mg-faq .mg-acc > summary::after{ font-size:20px; }
  .mg-faq .mg-acc[open] > summary{ border-bottom:0; }
  .mg-faq .mg-acc > :not(summary){ padding-inline:16px; font-size:15px; line-height:1.7; }
  .mg-faq .mg-acc > summary + *{ padding-top:0; }
  .mg-faq .mg-acc > :last-child:not(summary){ padding-bottom:16px; }

  /* Контакт: една колона; соц. картата става два бутона над формата (09-kontakt-390) */
  .mg-contact{ padding-block:16px 24px; }
  .mg-contact__layout{ display:flex; flex-direction:column; align-items:stretch; gap:14px; }
  .mg-contact__main,.mg-contact__side{ display:contents; }
  .mg-contact__head{ order:1; gap:14px; }
  .mg-contact__card--social{ order:2; }
  .mg-contact__form{ order:3; }
  .mg-contact__ok{ order:4; }
  .mg-contact__card--hours{ order:5; }
  .mg-contact__card--pre{ order:6; }
  .mg-contact__head .mg-eyebrow{ display:none; }
  body.mg .mg-contact__title{ font-size:27px; line-height:1.15; }
  body.mg .mg-contact__lead{ font-size:16px; }
  .mg-contact__form{ gap:14px; padding:16px; border-radius:var(--mg-r-md); }
  .mg-contact__row{ grid-template-columns:1fr; gap:14px; }
  .mg-contact__form .mg-field__label{ margin-bottom:6px; }
  .mg-contact__form .mg-check{ font-size:14px; line-height:1.5; }
  .mg-contact__submit{ align-self:stretch; min-height:52px; padding:14px; font-size:16px; }
  .mg-contact__ok{ padding:16px; border-radius:14px; font-size:15px; }
  .mg-contact__card--social{ padding:0; background:transparent; border-radius:0; }
  .mg-contact__card--social .mg-contact__card-title,
  body.mg .mg-contact__card--social p{ display:none; }
  body.mg .mg-contact__card--social .mg-contact__mail{ display:block; width:100%; margin:8px 0 0; font-size:15px; }
  .mg-contact__socials{ margin:0; }
  body.mg a.mg-contact__social{ flex:1 1 0; width:auto; height:auto; min-height:48px; border-radius:var(--mg-r-pill); font-size:15px; font-weight:700; }
  body.mg a.mg-contact__social--ig{ order:-1; background:var(--mg-p-pink-bg); color:var(--mg-pink-text); }
  body.mg a.mg-contact__social--fb{ background:var(--mg-p-teal-bg); color:var(--mg-teal-text); }
  body.mg a.mg-contact__social--tt{ display:none; }
  .mg-contact__social-label{ display:inline; }
  .mg-contact__card--hours{ padding:16px; border-radius:14px; }
  .mg-contact__card--hours .mg-contact__card-title{ display:none; }
  body.mg .mg-contact__card--hours p{ font-size:15px; line-height:1.65; }
  .mg-contact__card--pre{ padding:16px; border-radius:14px; }

  /* За нас: снимката е първа, една колона (08-za-nas-390) */
  .mg-za__hero{ padding-block:16px 20px; }
  .mg-za__story{ padding-block:0 20px; background:transparent; }
  .mg-za__values{ padding-block:0 20px; }
  .mg-za__cta{ padding-block:0 24px; }
  .mg-za__shop{ padding-block:0 24px; }
  .mg-za__grid{ grid-template-columns:1fr; gap:14px; }
  .mg-za__photo{ order:-1; border-width:4px; border-radius:var(--mg-r-md); }
  .mg-za__story-media{ border-radius:var(--mg-r-md); }
  .mg-za__text{ gap:14px; }
  .mg-za__text,.mg-za__story .mg-za__text{ font-size:16px; line-height:1.75; }
  body.mg .mg-za__title{ font-size:28px; line-height:1.15; }
  body.mg .mg-za__h2{ font-size:24px; line-height:1.2; }
  .mg-za__actions .mg-btn{ width:100%; }
  body.mg .mg-za__values .mg-za__h2{ margin-bottom:14px; }
  body.mg .mg-za__cards{ grid-template-columns:1fr; gap:10px; }
  .mg-za__cards > li{ gap:6px; padding:18px; border-radius:14px; font-size:15px; line-height:1.55; }
  .mg-za__cards strong{ font-size:19px; }

  /* Отзиви */
  .mg-otz__top{ padding-block:16px; }
  .mg-otz__head{ gap:16px; }
  body.mg .mg-otz__head .mg-page__title{ font-size:27px; line-height:1.15; }
  .mg-otz__score{ flex-direction:row; flex-wrap:wrap; gap:10px; padding:14px 18px; border-radius:14px; }
  .mg-otz__num{ font-size:32px; }
  .mg-otz{ padding-block:0 32px; }
  .mg-otz__chips{ flex-wrap:nowrap; overflow-x:auto; padding-bottom:6px; margin-bottom:14px; }
  .mg-otz__chips .mg-chip{ flex:0 0 auto; white-space:nowrap; }
  .mg-otz__grid{ grid-template-columns:1fr; }

  /* Търсене */
  .mg-search-results{ padding-block:16px 32px; }
  body.mg .mg-search-results__title{ font-size:26px; }
  body.mg .mg-search-results__count{ font-size:15px; }
  .mg-search-results__tabs{ gap:8px; margin-bottom:18px; }
  .mg-search-results__tabs .mg-chip,body.mg .mg-search-results__tabs a.mg-chip{ padding:10px 14px; font-size:14px; }
  .mg-search-results__block{ margin-top:28px; gap:12px; }
  body.mg .mg-search-results__h2{ font-size:22px; }
  body.mg a.mg-search-results__post{ grid-template-columns:96px 1fr; grid-template-areas:"media body" "media more"; gap:6px 14px; padding:14px; border-radius:14px; }
  body.mg a.mg-search-results__post--page{ grid-template-columns:1fr; grid-template-areas:"body" "more"; }
  body.mg .mg-search-results__post-title{ font-size:17px; }
  .mg-search-results__more{ font-size:14px; }
  .mg-search-results__empty{ padding:18px; gap:14px; }
  body.mg .mg-search-results__empty-title{ font-size:22px; }
  .mg-search-results__empty .mg-empty p{ font-size:15px; }
  .mg-search-results__empty .mg-empty__actions .mg-btn{ width:100%; }

  /* 404 (08-404-390) */
  .mg-404{ padding-block:28px; }
  .mg-404__inner{ gap:14px; }
  body.mg .mg-404__num{ font-size:76px; }
  body.mg .mg-404__title{ font-size:26px; }
  body.mg .mg-404__text{ font-size:16px; line-height:1.6; }
  .mg-404 .mg-page__search{ width:100%; margin-top:0; }
  .mg-404__actions{ flex-direction:column; align-self:stretch; gap:14px; margin-top:0; }
  .mg-404__actions .mg-btn{ width:100%; min-height:50px; font-size:16px; }
  .mg-404__more{ padding-block:0 28px; }
  body.mg .mg-404__h2{ font-size:22px; line-height:1.2; margin-bottom:12px; }
  .mg-404__tiles{ grid-template-columns:1fr 1fr; gap:12px; }
  body.mg a.mg-404__tile{ gap:24px; padding:18px; border-radius:14px; }
  .mg-404__tile-name{ font-size:18px; }
  .mg-404__tile-count{ font-size:14px; }
  .mg-404__tile-unit{ display:none; }
}

/* E9: дълги линкове (URL) в текста на страниците се пренасят - без хоризонтален скрол на телефон */
body.mg .mg-page__body .mg-entry a{ overflow-wrap:anywhere; }
