/* Existing homepage palette, applied only to internal pages.
 * Keep the ms-interior scope on every rule: shared markup also occurs on home.
 * Important declarations override legacy ACF <style> blocks after wp_head(). */
body.ms-interior {
  --ms-page: #181822;
  --ms-surface: #15171c;
  --ms-text: #eef0f6;
  --ms-muted: #c8c8d2;
  --ms-accent: #a99aff;
  --ms-line: rgba(255, 255, 255, .12);
  --ms-gutter: 20px;
  --ac-bg: var(--ms-page);
  --ac-muted: var(--ms-muted);
  background-color: var(--ms-page);
  color: var(--ms-text);
  font-family: VelaSans, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Keep outer widths fluid, including pages with a fixed 1600px ACF override. */
body.ms-interior .wrap {
  box-sizing: border-box;
  width: 100% !important;
  max-width: 1600px !important;
  margin-inline: auto;
  padding-inline: var(--ms-gutter) !important;
}
body.ms-interior .uni-main { padding-bottom: 64px; }
body.ms-interior .uni-wrap { max-width: 1240px !important; }
body.ms-interior .uni-main .uni-head { margin-bottom: 32px !important; }
body.ms-interior .uni-title,
body.ms-interior .site-main > article > .entry-header .entry-title {
  font-size: clamp(30px, 3.5vw, 48px);
  line-height: 1.16;
  font-weight: 600;
  letter-spacing: -.6px;
  overflow-wrap: break-word;
}
body.ms-interior .site-main.wrap { padding-block: 40px 64px; }
body.ms-interior .site-main > article > .entry-header {
  position: static;
  height: auto;
  min-height: 0;
  padding: 0;
  margin: 0 0 24px;
  background: none;
  border: 0;
  backdrop-filter: none;
}
body.ms-interior main :is(.uni-breadcrumbs, .woocommerce-breadcrumb) {
  line-height: 1.6;
  margin-bottom: 24px;
}

/* Full-width existing hero and calculator sections retain their composition. */
body.ms-interior .uni-main:has(:is(.wr-hero, [class*="-hero-full"], .us-hero, .pt-hero, .dz-hero, .mo-hero, .zs-hero, #calc, .calculator-section)) .uni-wrap {
  max-width: 1600px !important;
  padding-inline: var(--ms-gutter) !important;
}
body.ms-interior .wr-full > .wr-in {
  box-sizing: border-box;
  width: 100%;
  max-width: 1600px;
  padding-inline: var(--ms-gutter);
}
body.ms-interior .uni-wrap .calculator-section > .wrap,
body.ms-interior .uni-main:has(.wr-hero) .section > .wrap {
  padding-inline: 0 !important;
}
body.ms-interior :is(.ld-hero-in, .ok-hero-in, .au-hero-in, .os-hero-in, .em-hero-in, .va-hero-in, .kk-hero-in, .mr-hero-in, .bz-hero-in, .sz-hero-in, .bw-hero-in, .dp-hero-in, .md-hero-in, .pr-hero-in, .us-slide-in, .pt-in, .dz-in, .mo-in, .zs-in) {
  box-sizing: border-box;
  width: 100%;
  max-width: 1600px;
  margin-inline: auto;
  padding-inline: var(--ms-gutter);
}
body.ms-interior :is(.pt-tier, .zs-tier) { min-width: 0; border-radius: 24px; }
body.ms-interior :is(.pt-tiers, .zs-tiers) { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
body.ms-interior :is(.bw-sec, .pr-sec, .md-sec, .dp-sec, .ok-sec, .au-sec, .os-sec, .em-sec, .va-sec, .kk-sec, .mr-sec, .bz-sec, .sz-sec) {
  padding-block: clamp(32px, 4vw, 56px);
}
body.ms-interior .cost { width: 100%; max-width: 100%; gap: 24px; flex-direction: row; }
body.ms-interior .cost .left { flex: 1 1 0; width: auto; min-width: 0; }
body.ms-interior .cost .right11 { flex: 0 1 380px; width: 100%; min-width: 0; height: auto; align-self: flex-start; }
body.ms-interior .cost :is(.top, .bot, .left3, .left4, .wrapp2) { min-width: 0; max-width: 100%; }
body.ms-interior :is(.cn-pack, .cn-rates, .cn-why-grid) { gap: 24px; }
body.ms-interior :is(.cn-p, .cn-rate, .cn-w) { min-width: 0; border-radius: 24px; }
body.ms-interior .cn-p-price { flex-wrap: wrap; }

/* Existing project/blog cards use the same surface family as homepage cards. */
body.ms-interior :is(.ms-project-card, .ms-blog-card) {
  background-color: var(--ms-surface);
  border-color: var(--ms-line);
  border-radius: 24px;
}
body.ms-interior :is(.ms-projects-grid, .ms-blog-grid) { gap: 24px; }
body.ms-interior .ms-project-card__body { padding: 24px; }
body.ms-interior :is(.ms-project-card__title, .ms-blog-card__title) { line-height: 1.35; }
body.ms-interior :is(.ms-project-card__desc, .ms-blog-card__excerpt) { color: var(--ms-muted); line-height: 1.6; }

/* Preserve archive entries and article layout; only normalize their framing. */
body.ms-interior:is(.archive, .search, .blog) .site-main.wrap { max-width: 1240px !important; }
body.ms-interior:is(.archive, .search, .blog) .site-main > article {
  padding-block: 32px;
  border-bottom: 1px solid var(--ms-line);
}
body.ms-interior:is(.archive, .search, .blog) .site-main > article:first-child { padding-top: 0; }
body.ms-interior:is(.archive, .search, .blog) .site-main > article > .entry-header .entry-title {
  max-width: 980px;
  font-size: clamp(24px, 2.4vw, 34px);
  margin: 0;
}
body.ms-interior:is(.archive, .search, .blog) .entry-content { max-width: 900px; }
body.ms-interior:is(.archive, .search, .blog) .entry-title a { color: var(--ms-text); text-decoration: none; }
body.ms-interior:is(.archive, .search, .blog) .entry-title a:hover { color: var(--ms-accent); }
body.ms-interior .ms-blog-main--hero { padding-top: 0; }
body.ms-interior .ms-blog-main--hero #post-1911 { max-width: none; margin: 0; padding: 0; }

/* WooCommerce keeps its fields, navigation, endpoints and purchase behavior. */
body.ms-interior.woocommerce-account .site-main.wrap { max-width: 1240px !important; }
body.ms-interior.woocommerce-account .woocommerce-MyAccount-navigation {
  position: static;
  height: auto;
  padding: 20px;
  background: var(--ms-surface);
  border: 1px solid var(--ms-line);
  border-radius: 24px;
}
body.ms-interior.woocommerce-account .woocommerce-MyAccount-navigation ul { margin: 0; padding: 0; list-style: none; }
body.ms-interior.woocommerce-account .woocommerce-MyAccount-navigation li a {
  display: block;
  padding: 12px 16px;
  color: var(--ms-muted);
  border-radius: 12px;
  text-decoration: none;
}
body.ms-interior.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a {
  color: var(--ms-text);
  background: rgba(127, 107, 255, .18);
}
body.ms-interior.woocommerce-account .woocommerce-MyAccount-content { min-width: 0; line-height: 1.7; }
body.ms-interior .woocommerce :is(form.login, form.register, form.lost_reset_password) {
  max-width: 680px;
  padding: clamp(20px, 3vw, 32px);
  margin-block: 24px;
  background: var(--ms-surface);
  border: 1px solid var(--ms-line);
  border-radius: 24px;
}
body.ms-interior .woocommerce .form-row { display: block; }
body.ms-interior .woocommerce form .form-row label { line-height: 1.5; margin-bottom: 8px; }
body.ms-interior .woocommerce form .input-text,
body.ms-interior .woocommerce form select {
  box-sizing: border-box;
  width: 100%;
  min-height: 48px;
  padding: 12px 16px;
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 12px;
  background: #20212c;
  color: var(--ms-text);
  font: inherit;
}
body.ms-interior .woocommerce form .input-text:focus-visible {
  outline: 2px solid var(--ms-accent);
  outline-offset: 2px;
}
body.ms-interior .woocommerce :is(button.button, a.button, input.button),
body.ms-interior.woocommerce div.product form.cart .button {
  min-height: 48px;
  padding: 14px 24px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #7f6bff, #5548aa);
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  line-height: 1.4;
  text-align: center;
  white-space: normal;
}
body.ms-interior .woocommerce :is(button.button, a.button):hover { filter: brightness(1.08); }
body.ms-interior .woocommerce .lost_reset_password .form-row-first { float: none; width: 100%; }
body.ms-interior.woocommerce div.product form.cart .quantity .qty {
  min-height: 48px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 12px;
  background: #20212c;
  color: var(--ms-text);
}

/* Only the shared site chrome: never target article headers or app navigation. */
body.ms-interior .ms-site-header .primary-menu > li > a { white-space: nowrap; }
body.ms-interior .ms-site-header .nav-right { min-width: 0; }
body.ms-interior .footer { box-sizing: border-box; max-width: 1600px; width: 100%; margin-inline: auto; }

@media (max-width: 1600px) {
  body.ms-interior .uni-wrap > :is(.wr-full, [class*="-hero-full"], .us-hero, .pt-full, .dz-full, .mo-full, .zs-full) {
    left: auto;
    right: auto;
    width: calc(100% + 2 * var(--ms-gutter));
    max-width: none !important;
    margin-inline: calc(-1 * var(--ms-gutter));
  }
}

@media (min-width: 769px) {
  body.ms-interior.woocommerce-account .woocommerce:has(> .woocommerce-MyAccount-navigation) {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    align-items: start;
    gap: 32px;
  }
  body.ms-interior.woocommerce-account .woocommerce > .woocommerce-notices-wrapper { grid-column: 1 / -1; }
  body.ms-interior.woocommerce-account :is(.woocommerce-MyAccount-navigation, .woocommerce-MyAccount-content) { float: none; width: 100%; }
}
@media (max-width: 1399px) and (min-width: 1024px) {
  body.ms-interior .ms-site-header .nav { gap: 16px; }
  body.ms-interior .ms-site-header .primary-menu { gap: 12px; }
  body.ms-interior .ms-site-header .nav-right { flex-wrap: wrap; justify-content: flex-end; row-gap: 4px; }
  body.ms-interior .ms-site-header .region { margin-left: 0 !important; font-size: 12px !important; }
}
@media (max-width: 1199px) {
  body.ms-interior .cost { flex-direction: column; }
  body.ms-interior .cost :is(.left, .right11) { width: 100%; max-width: 100%; flex: auto; }
  body.ms-interior .footer { height: auto; display: flex; flex-direction: column; gap: 32px; padding: 40px var(--ms-gutter); }
  body.ms-interior .footer :is(.footer-caption, .footer-columns, .footer-start) { position: static; width: 100%; max-width: none; height: auto; }
  body.ms-interior .footer-start { margin-top: 0; }
}
@media (max-width: 767px) {
  body.ms-interior .uni-main { padding-bottom: 40px; }
  body.ms-interior .uni-main .uni-head { margin-bottom: 24px !important; }
  body.ms-interior :is(.pt-tiers, .zs-tiers) { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  body.ms-interior .site-main.wrap { padding-block: 24px 40px; }
  body.ms-interior .ms-blog-main--hero { padding-top: 0; }
  body.ms-interior :is(.cn-pack, .cn-rates, .cn-why-grid, .ms-projects-grid, .ms-blog-grid) { gap: 20px; }
  body.ms-interior .cost .left { padding: 20px; gap: 24px; border-radius: 24px; }
  body.ms-interior .cost .wrapp2 { flex-direction: column !important; }
  body.ms-interior .cost :is(.left3, .left4) { width: 100%; flex: auto !important; }
  body.ms-interior.woocommerce-account .woocommerce-MyAccount-navigation { margin-bottom: 24px; }
  body.ms-interior.woocommerce-account :is(.woocommerce-MyAccount-navigation, .woocommerce-MyAccount-content) { float: none; width: 100%; }
  body.ms-interior .ms-site-header .region { white-space: normal; line-height: 1.3; }
  body.ms-interior .footer-columns { gap: 24px; }
}


/* Brand alignment, second pass.
 * Values come from the unchanged homepage. Map the existing page components to
 * shared visual roles; keep their markup, media, ordering and JS states intact.
 * !important is limited to presentation values with competing legacy ACF rules.
 */
body.ms-interior {
  --ms-h1: 48px;
  --ms-h2: 40px;
  --ms-card-title: 24px;
  --ms-lead-size: 24px;
  --ms-section-space: 140px;
  --ms-card-radius: 28px;
  --ms-card-pad: 28px;
  --ms-button-size: 20px;
  --ms-button-height: 56px;
  --ms-panel-fill: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01));
  --ms-panel-shadow: 0 14px 40px rgba(0,0,0,.45);
  --radius: var(--ms-card-radius);
  --radius-sm: 16px;
  --shadow: var(--ms-panel-shadow);
  background-image: none;
}

/* Content edges match across the hub, universal pages and standalone landings. */
body.ms-interior .uni-main:not(:has(.ms-blog)) .uni-wrap,
body.ms-interior:is(.landing-apartment, .landing-cottage) main .container {
  box-sizing: border-box;
  width: 100% !important;
  max-width: 1600px !important;
  margin-inline: auto;
  padding-inline: var(--ms-gutter) !important;
}
body.ms-interior .uni-main:has(:is(.sol-hero, .kr-hero, .os-hero)) { padding-top: 0; }
body.ms-interior :is(.sol-page, .kr-page) { gap: var(--ms-section-space); }
body.ms-interior .os-page { gap: 48px; }

/* Heading levels and supporting copy, including the apartment/cottage templates. */
body.ms-interior .uni-main h1,
body.ms-interior:is(.landing-apartment, .landing-cottage) main h1,
body.ms-interior .uni-main :is(.us-slide h2, .ab-intro h2) {
  font-family: VelaSans, system-ui, sans-serif !important;
  font-size: var(--ms-h1) !important;
  font-weight: 600 !important;
  line-height: 1.167 !important;
  letter-spacing: -.6px;
  color: var(--ms-text);
  text-wrap: pretty;
}
body.ms-interior .uni-main h2,
body.ms-interior:is(.landing-apartment, .landing-cottage) main h2 {
  font-family: VelaSans, system-ui, sans-serif !important;
  font-size: var(--ms-h2) !important;
  font-weight: 500 !important;
  line-height: 1.2 !important;
  letter-spacing: -.4px;
  color: var(--ms-text);
}
/* H2 is the existing hero heading on the services and about index pages. */
body.ms-interior .uni-main :is(.us-slide, .ab-intro) h2 { font-size: var(--ms-h1) !important; line-height: 1.167 !important; font-weight: 600 !important; }
body.ms-interior :is(.au-hero-lead, .bw-hero-lead, .bz-hero-lead, .dp-hero-lead, .em-hero-lead, .kk-hero-lead, .ld-hero-lead, .md-hero-lead, .mr-hero-lead, .ok-hero-lead, .os-hero-lead, .pr-hero-lead, .sz-hero-lead, .va-hero-lead, .sol-lead, .kr-hero-lead, .pt-hero p, .dz-hero p, .mo-hero p, .zs-hero p, .wr-hero p, .us-slide p, .apartment-hero-copy .hero-sub, .cottage-hero-copy .hero-sub) {
  font-size: var(--ms-lead-size) !important;
  line-height: 1.35 !important;
  font-weight: 400 !important;
  color: var(--ms-muted);
  max-width: 760px;
}
body.ms-interior :is(.au-sub, .bw-sub, .bz-sub, .dp-sub, .em-sub, .kk-sub, .ld-sub, .md-sub, .mr-sub, .ok-sub, .os-sub, .pr-sub, .sz-sub, .va-sub, .pt-sub, .dz-sub, .mo-sub, .zs-sub, .wr-sub, .ab-sub, .sol2-sub, .kr-sub, .cn-why-sub, .section-head .subtext) {
  font-size: 20px !important;
  line-height: 1.4 !important;
  font-weight: 400;
  color: var(--ms-muted) !important;
}

/* Preserve different hero compositions while aligning height, text and actions. */
body.ms-interior :is(.au-hero-full, .bw-hero-full, .bz-hero-full, .dp-hero-full, .em-hero-full, .kk-hero-full, .ld-hero-full, .md-hero-full, .mr-hero-full, .ok-hero-full, .os-hero-full, .pr-hero-full, .sz-hero-full, .va-hero-full, .us-hero, .pt-hero, .dz-hero, .mo-hero, .zs-hero, .wr-hero, .apartment-hero, .cottage-hero) {
  box-sizing: border-box;
  min-height: 680px !important;
  height: auto !important;
  border-radius: 0 !important;
}
body.ms-interior :is(.sol-hero, .kr-hero, .os-hero) {
  min-height: 680px;
  padding-block: 64px;
  align-items: center;
}
body.ms-interior :is(.au-hero-in, .bw-hero-in, .bz-hero-in, .dp-hero-in, .em-hero-in, .kk-hero-in, .ld-hero-in, .md-hero-in, .mr-hero-in, .ok-hero-in, .os-hero-in, .pr-hero-in, .sz-hero-in, .va-hero-in, .us-slide-in, .wr-hero-content, .apartment-hero-grid, .cottage-hero-grid) { padding-block: 64px !important; }
body.ms-interior :is(.apartment-hero-copy, .cottage-hero-copy) { gap: 24px; }
body.ms-interior :is(.apartment-hero-copy, .cottage-hero-copy) :is(h1, .hero-sub) { margin: 0; }
body.ms-interior :is(.apartment-hero, .cottage-hero) .hero-actions { margin-block: 8px 0; }
body.ms-interior :is(.sol-lead, .ld-hero-lead, .wr-hero p) { margin-bottom: 32px; }

/* One treatment for calls to action; segmented controls, gallery arrows and
 * interactive demo controls retain their purpose-specific sizes and behavior. */
body.ms-interior main :is(.btn.hero-primary, .btn.hero-outline, .au-btn, .bw-btn, .bz-btn, .dp-btn, .em-btn, .kk-btn, .ld-btn, .md-btn, .mr-btn, .ok-btn, .os-btn, .pr-btn, .sz-btn, .va-btn, .pt-btn, .dz-btn, .mo-btn, .zs-btn, .wr-btn, .sol-btn, .kr-btn) {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--ms-button-height) !important;
  height: auto;
  padding: 15px 28px !important;
  border-radius: 16px !important;
  font-family: VelaSans, system-ui, sans-serif !important;
  font-size: var(--ms-button-size) !important;
  line-height: 1.2 !important;
  font-weight: 600 !important;
  text-align: center;
  text-decoration: none;
  white-space: normal;
  color: #fff !important;
  background: linear-gradient(90deg, #7f6bff, #5548aa) !important;
  border: 1px solid transparent !important;
  box-shadow: none !important;
}
body.ms-interior main :is(.btn.hero-outline, .au-btn--ghost, .bw-btn--ghost, .bz-btn--ghost, .dp-btn--ghost, .em-btn--ghost, .kk-btn--ghost, .ld-btn--ghost, .md-btn--ghost, .mr-btn--ghost, .ok-btn--ghost, .os-btn--ghost, .pr-btn--ghost, .sz-btn--ghost, .va-btn--ghost, .pt-btn--ghost, .dz-btn--ghost, .mo-btn--ghost, .zs-btn--ghost, .wr-btn--ghost, .sol-btn--ghost, .kr-btn--ghost) {
  background: rgba(255,255,255,.02) !important;
  border-color: rgba(255,255,255,.9) !important;
}
body.ms-interior main :is(.btn.hero-primary, .btn.hero-outline, .au-btn, .bw-btn, .bz-btn, .dp-btn, .em-btn, .kk-btn, .ld-btn, .md-btn, .mr-btn, .ok-btn, .os-btn, .pr-btn, .sz-btn, .va-btn, .pt-btn, .dz-btn, .mo-btn, .zs-btn, .wr-btn, .sol-btn, .kr-btn):hover { filter: brightness(1.08); }
body.ms-interior main :is(.btn.hero-primary, .btn.hero-outline, .au-btn, .bw-btn, .bz-btn, .dp-btn, .em-btn, .kk-btn, .ld-btn, .md-btn, .mr-btn, .ok-btn, .os-btn, .pr-btn, .sz-btn, .va-btn, .pt-btn, .dz-btn, .mo-btn, .zs-btn, .wr-btn, .sol-btn, .kr-btn):focus-visible {
  outline: 2px solid var(--ms-accent);
  outline-offset: 4px;
}
body.ms-interior :is(.hero-actions, .sol-hero__cta, .ld-hero-actions, .wr-hero-actions, .pt-actions, .us-actions) { gap: 20px; }

/* Reuse the homepage card finish without overwriting photographic backgrounds. */
body.ms-interior main :is(.sol2-card, .sol-kit__stage, .sol-step, .os-why-grid > .os-why, .path-card, .format-card, .sets-card, .kit-card, .life-tab, .day-item, .ms-project-card, .ms-blog-card, .cn-p, .cn-rate, .cn-w, .kont-card, .dz-card, .mo-card, .zs-card, .pt-tier, .zs-tier, .au-step, .bw-step, .bz-step, .dp-step, .em-step, .kk-step, .ld-step, .md-step, .mr-step, .ok-step, .os-step, .pr-step, .sz-step, .va-step, .pt-step, .dz-step, .mo-step, .zs-step, .wr-step, .os-card, .life-panel, .project-card, .ld-pane, .ld-gal, .wr-gal, .wr-sys-card, .pt-adv, .ld-adv, .ab-intro-photo) {
  border-radius: var(--ms-card-radius) !important;
  border-color: var(--ms-line) !important;
  box-shadow: var(--ms-panel-shadow);
}
body.ms-interior main :is(.sol2-card, .sol-kit__stage, .sol-step, .os-why-grid > .os-why, .path-card, .format-card, .sets-card, .kit-card, .life-tab, .day-item, .ms-project-card, .ms-blog-card, .cn-p, .cn-rate, .cn-w, .kont-card, .dz-card, .mo-card, .zs-card, .pt-tier, .zs-tier, .au-step, .bw-step, .bz-step, .dp-step, .em-step, .kk-step, .ld-step, .md-step, .mr-step, .ok-step, .os-step, .pr-step, .sz-step, .va-step, .pt-step, .dz-step, .mo-step, .zs-step, .wr-step) {
  background-color: var(--ms-surface) !important;
  background-image: var(--ms-panel-fill) !important;
}
body.ms-interior main :is(.sol2-body, .path-card-body, .format-card-body, .ms-project-card__body, .ms-blog-card__body, .cn-p, .cn-w, .pt-tier, .zs-tier, .sol-step, .os-why-grid > .os-why, .kont-card) { padding: var(--ms-card-pad); }
body.ms-interior main :is(.sol2-card, .sol-kit__stage, .sol-step, .path-card, .format-card, .sets-card, .kit-card, .life-tab, .day-item, .ms-project-card, .ms-blog-card, .cn-p, .cn-rate, .cn-w, .kont-card, .dz-card, .mo-card, .zs-card, .pt-tier, .zs-tier, .au-step, .bw-step, .bz-step, .dp-step, .em-step, .kk-step, .ld-step, .md-step, .mr-step, .ok-step, .os-step, .pr-step, .sz-step, .va-step, .pt-step, .dz-step, .mo-step, .zs-step, .wr-step, .os-card, .life-panel, .project-card, .ld-pane, .ld-gal, .wr-gal, .wr-sys-card, .pt-adv, .ld-adv, .ab-intro-photo) h3 {
  font-size: var(--ms-card-title) !important;
  font-weight: 600;
  line-height: 1.3 !important;
  letter-spacing: -.2px;
}
body.ms-interior main :is(.sol2-body, .path-card-body, .format-card-body, .cn-w, .sol-step, .os-why-grid > .os-why) p {
  font-size: 16px;
  line-height: 1.55;
  color: var(--ms-muted);
}
body.ms-interior :is(.life-tab, .path-tab, .pt-tab-btn, .dz-tab-btn, .mo-tab-btn) { border-radius: 16px; }
body.ms-interior :is(.life-tab.is-active, .path-tab.is-active, .pt-tab-btn.is-active, .dz-tab-btn.is-active, .mo-tab-btn.is-active) {
  background: linear-gradient(110deg, rgba(127,107,255,.2), rgba(127,107,255,.06)) !important;
  border-color: rgba(169,154,255,.55) !important;
}

/* Statistics are the same quiet surface; their existing columns stay intact. */
body.ms-interior :is(.au-stats, .bw-stats, .bz-stats, .dp-stats, .em-stats, .kk-stats, .ld-stats, .md-stats, .mr-stats, .ok-stats, .os-stats, .pr-stats, .sz-stats, .va-stats, .dz-stats, .mo-stats, .zs-stats, .wr-stats) {
  background-color: var(--ms-surface) !important;
  background-image: var(--ms-panel-fill) !important;
  border: 1px solid var(--ms-line) !important;
  border-radius: var(--ms-card-radius) !important;
  box-shadow: var(--ms-panel-shadow) !important;
  padding: 32px !important;
}
body.ms-interior :is(.ld-stats, .wr-stats, .dz-stats, .mo-stats, .zs-stats)::before,
body.ms-interior :is(.ld-stats, .wr-stats, .dz-stats, .mo-stats, .zs-stats)::after { background: none !important; }
body.ms-interior :is(.au-stat-num, .bw-stat-num, .bz-stat-num, .dp-stat-num, .em-stat-num, .kk-stat-num, .ld-stat-num, .md-stat-num, .mr-stat-num, .ok-stat-num, .os-stat-num, .pr-stat-num, .sz-stat-num, .va-stat-num, .ab-stat-num, .dz-stat-num, .mo-stat-num, .zs-stat-num, .wr-stat-num, .hero-proof dt) {
  font-size: 40px !important;
  line-height: 1.2 !important;
  font-weight: 500 !important;
  color: var(--ms-accent) !important;
}
body.ms-interior :is(.au-stat-label, .bw-stat-label, .bz-stat-label, .dp-stat-label, .em-stat-label, .kk-stat-label, .ld-stat-label, .md-stat-label, .mr-stat-label, .ok-stat-label, .os-stat-label, .pr-stat-label, .sz-stat-label, .va-stat-label, .ab-stat-label, .dz-stat-label, .mo-stat-label, .zs-stat-label, .wr-stat-label, .hero-proof dd) {
  margin-top: 8px;
  font-size: 14px !important;
  line-height: 1.4 !important;
  color: var(--ms-muted) !important;
}

/* Vertical rhythm. Half spacing on adjoining sections avoids doubled gaps.
 * Stats retain their existing overlap at the bottom of the hero. */
body.ms-interior .uni-main :is(.au-sec, .bw-sec, .bz-sec, .dp-sec, .em-sec, .kk-sec, .ld-sec, .md-sec, .mr-sec, .ok-sec, .os-sec, .pr-sec, .sz-sec, .va-sec, .pt-sec, .dz-sec, .mo-sec, .zs-sec, .wr-sec):not([class*="--stats"]) {
  padding-block: calc(var(--ms-section-space) / 2) !important;
  margin-block: 0;
}
body.ms-interior:is(.landing-apartment, .landing-cottage) main > .section {
  padding-block: calc(var(--ms-section-space) / 2) !important;
}
body.ms-interior :is(.section-head, .sol2-head) { margin-bottom: 32px; }
body.ms-interior .uni-main :is(.cn-prices, .cn-why) { padding-block: calc(var(--ms-section-space) / 2); }
body.ms-interior .uni-main .cn-prices { padding-top: 0; }
body.ms-interior .sol-page > :is(.sol-kit, .sol2-part, .sol-steps) { margin-block: 0; }
body.ms-interior :is(.au-cta, .bw-cta, .bz-cta, .dp-cta, .em-cta, .kk-cta, .ld-cta, .md-cta, .mr-cta, .ok-cta, .os-cta, .pr-cta, .sz-cta, .va-cta, .pt-cta, .dz-cta, .mo-cta, .zs-cta, .wr-cta, .sol-cta, .kr-cta, .ab-cta, .uslugi-cta):not([class*="-full"]) { border-radius: var(--ms-card-radius); }

@media (max-width: 1450px) {
  body.ms-interior { --ms-section-space: 96px; }
}
@media (max-width: 1023px) {
  body.ms-interior { --ms-h1: 40px; --ms-h2: 32px; --ms-lead-size: 20px; --ms-section-space: 80px; --ms-button-size: 18px; }
  body.ms-interior :is(.au-hero-full, .bw-hero-full, .bz-hero-full, .dp-hero-full, .em-hero-full, .kk-hero-full, .ld-hero-full, .md-hero-full, .mr-hero-full, .ok-hero-full, .os-hero-full, .pr-hero-full, .sz-hero-full, .va-hero-full, .us-hero, .pt-hero, .dz-hero, .mo-hero, .zs-hero, .wr-hero, .apartment-hero, .cottage-hero) { min-height: 560px !important; }
  body.ms-interior :is(.sol-hero, .kr-hero, .os-hero) { min-height: 0; padding-block: 48px; }
}
@media (max-width: 600px) {
  body.ms-interior { --ms-h1: 32px; --ms-h2: 28px; --ms-card-title: 20px; --ms-lead-size: 18px; --ms-section-space: 48px; --ms-card-radius: 24px; --ms-card-pad: 20px; --ms-button-size: 17px; --ms-button-height: 52px; }
  body.ms-interior :is(.au-hero-full, .bw-hero-full, .bz-hero-full, .dp-hero-full, .em-hero-full, .kk-hero-full, .ld-hero-full, .md-hero-full, .mr-hero-full, .ok-hero-full, .os-hero-full, .pr-hero-full, .sz-hero-full, .va-hero-full, .us-hero, .pt-hero, .dz-hero, .mo-hero, .zs-hero, .wr-hero, .apartment-hero, .cottage-hero) { min-height: 0 !important; }
  body.ms-interior :is(.au-hero-in, .bw-hero-in, .bz-hero-in, .dp-hero-in, .em-hero-in, .kk-hero-in, .ld-hero-in, .md-hero-in, .mr-hero-in, .ok-hero-in, .os-hero-in, .pr-hero-in, .sz-hero-in, .va-hero-in, .us-slide-in, .wr-hero-content, .apartment-hero-grid, .cottage-hero-grid) { padding-block: 40px !important; }
  body.ms-interior :is(.sol-hero, .kr-hero, .os-hero) { padding-block: 40px; }
  body.ms-interior :is(.sol-hero__cta, .ld-hero-actions, .wr-hero-actions, .pt-actions, .us-actions) { gap: 12px; }
  body.ms-interior :is(.au-sub, .bw-sub, .bz-sub, .dp-sub, .em-sub, .kk-sub, .ld-sub, .md-sub, .mr-sub, .ok-sub, .os-sub, .pr-sub, .sz-sub, .va-sub, .pt-sub, .dz-sub, .mo-sub, .zs-sub, .wr-sub, .ab-sub, .sol2-sub, .kr-sub, .cn-why-sub, .section-head .subtext) { font-size: 17px !important; }
  body.ms-interior :is(.au-stats, .bw-stats, .bz-stats, .dp-stats, .em-stats, .kk-stats, .ld-stats, .md-stats, .mr-stats, .ok-stats, .os-stats, .pr-stats, .sz-stats, .va-stats, .dz-stats, .mo-stats, .zs-stats, .wr-stats) { padding: 24px 20px !important; }
  body.ms-interior :is(.au-stat-num, .bw-stat-num, .bz-stat-num, .dp-stat-num, .em-stat-num, .kk-stat-num, .ld-stat-num, .md-stat-num, .mr-stat-num, .ok-stat-num, .os-stat-num, .pr-stat-num, .sz-stat-num, .va-stat-num, .ab-stat-num, .dz-stat-num, .mo-stat-num, .zs-stat-num, .wr-stat-num, .hero-proof dt) { font-size: 28px !important; }
  body.ms-interior :is(.section-head, .sol2-head) { margin-bottom: 24px; }
}

/* Standalone landing headers use the same navigation markup without a class. */
body.ms-interior .sol-mosaic__glow { right: 0; }
body.ms-interior :is(.ab-intro, .ab-stats, .ab-path > article, .ab-team > article, .pt-track, .pt-panel-card, .pt-panel-aside) {
  border-radius: var(--ms-card-radius);
  border-color: var(--ms-line);
  background-color: var(--ms-surface);
  background-image: var(--ms-panel-fill);
  box-shadow: var(--ms-panel-shadow);
}
body.ms-interior .os-page > .os-hero-full {
  border-radius: 0 !important;
  min-height: 600px;
  padding: 0 !important;
}
body.ms-interior .os-page > .os-hero-full > .os-hero-in {
  box-sizing: border-box;
  width: 100% !important;
  max-width: 1600px !important;
  padding: 64px var(--ms-gutter) !important;
}
body.ms-interior .woocommerce-products-header {
  position: static;
  height: auto;
  min-height: 0;
  padding-block: 32px 24px;
  background: none;
  border: 0;
  backdrop-filter: none;
}
body.ms-interior.woocommerce ul.products li.product {
  min-width: 0;
  border-radius: var(--ms-card-radius);
  background-color: var(--ms-surface);
  border-color: var(--ms-line);
}
body.ms-interior.woocommerce ul.products { grid-template-columns: repeat(4, minmax(0, 1fr)); }
body.ms-interior.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
body.ms-interior.woocommerce ul.products li.product .button,
body.ms-interior.woocommerce div.product form.cart .button,
body.ms-interior .woocommerce form .button { border-radius: 16px; }
@media (max-width: 1600px) {
  body.ms-interior .uni-wrap .os-page > .os-hero-full {
    width: calc(100% + 2 * var(--ms-gutter)) !important;
    max-width: none !important;
    left: auto !important;
    right: auto !important;
    margin-inline: calc(-1 * var(--ms-gutter)) !important;
  }
}
body.ms-interior header:has(> .wrap > .nav) .primary-menu > li > a { white-space: nowrap; }
@media (max-width: 1023px) {
  body.ms-interior.woocommerce ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body.ms-interior header:has(> .wrap > .nav) .nav { gap: 16px !important; }
  body.ms-interior header:has(> .wrap > .nav) .nav-right { min-width: 0; flex-shrink: 1; }
  body.ms-interior header:has(> .wrap > .nav) .region {
    white-space: normal !important;
    font-size: 14px !important;
    line-height: 1.3 !important;
    margin-left: 0 !important;
  }
}
@media (max-width: 600px) {
  body.ms-interior.woocommerce ul.products li.product .woocommerce-loop-product__title { font-size: 17px; }
  body.ms-interior .os-page > .os-hero-full { min-height: 0; }
  body.ms-interior .os-page > .os-hero-full > .os-hero-in { padding-block: 40px !important; }
  body.ms-interior .ab-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 20px; gap: 16px; }
  body.ms-interior .ab-stat { min-width: 0; padding: 0; }
  body.ms-interior .ab-stat-label { overflow-wrap: anywhere; }
  body.ms-interior .mr-plan { padding: 16px; }
  body.ms-interior .mr-plan-grid { grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 1fr)); gap: 8px; }
  body.ms-interior .mr-room { min-width: 0; padding: 8px; }
  body.ms-interior .mr-room-top { flex-direction: column; align-items: flex-start; gap: 8px; }
  body.ms-interior .mr-room-name { font-size: 12px; overflow-wrap: anywhere; }
  body.ms-interior .mr-room-track { max-width: 100%; white-space: normal; font-size: 11px; }
}
@media (max-width: 360px) {
  body.ms-interior { --ms-h1: 28px; --ms-h2: 26px; }
  body.ms-interior .ab-stat-num { font-size: 24px !important; }
}

/* Отдельные системы: как «Комплексные решения». Эти правила сильнее кэшированного otdelnye-page.css. */
body.ms-interior section.os-why {
  background: none;
  background-image: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
}
body.ms-interior .os-hero-full {
  min-height: 600px !important;
  height: 600px !important;
}
body.ms-interior .os-why-grid > .os-why {
  border-radius: 16px;
  padding: 22px;
}
@media (max-width: 768px) {
  body.ms-interior .os-page { gap: 24px; }
}
body.ms-interior .os-page > .os-plank {
  height: 2px;
  display: block;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}
body.ms-interior .os-page > .benefits {
  padding-block: 14px;
}
