/* ============================================================================
   QA REMEDIATION LAYER  —  newditai.com
   Loaded last, after every other stylesheet. Purpose: resolve visual defects
   left behind by stacked theme layers (premium / inner / redesign / decor).
   Nothing here adds decoration; it only removes breakage and re-unifies colour.
   ========================================================================== */

/* ---------------------------------------------------------------------------
   1. TOKENS — one palette for the whole site.
   premium.css re-declared :root with a navy / blue-grey / coral set that leaked
   into every component (footer links became #687181 on near-black, filter chips
   turned navy, indices turned coral). Re-assert the warm editorial palette.
   ------------------------------------------------------------------------- */
:root {
  --ink: #24231e;
  --muted: #514e45;
  --paper: #f3f2ed;
  --line: #dedcd2;
  --night: #25251f;
  --lavender: #e6e4db;
  --orange: #7d620a; /* was #f16c4d coral — now a readable gold for small text */
}
body.studio-v18 {
  background: var(--studio-paper);
}

/* ---------------------------------------------------------------------------
   2. FOOTER — every link was #687181 on #25251f (3.13:1). Unreadable.
   ------------------------------------------------------------------------- */
.studio-v18 footer,
.studio-v18 footer .footergrid a,
.studio-v18 footer .footergrid a:not(.brand),
.studio-v18 footer .footer-knowledge a,
.studio-v18 footer .textlink,
.studio-v18 footer .brand,
.studio-v18 footer .xdt-wordmark {
  color: #e2dfd3;
}
.studio-v18 footer .footergrid p {
  color: #bdb9ac;
}
.studio-v18 footer .footergrid h4 {
  color: #d5d2c6;
}
/* the little brand dot must stay legible on the dark footer */
.studio-v18 footer .xdt-wordmark > span {
  color: var(--studio-accent);
}
.studio-v18 footer .xdt-brand small {
  color: #bdb9ac;
}
.studio-v18 footer .footer-knowledge a {
  color: #a9a598;
}
.studio-v18 footer .bottom,
.studio-v18 footer .bottom span {
  color: #a9a598;
}
.studio-v18 footer .entity-line {
  color: #bdb9ac;
  border-color: #3d3c34;
}
.studio-v18 footer .footergrid a:hover,
.studio-v18 footer .footer-knowledge a:hover {
  color: #fff;
}

/* contact strip sits outside .wrap, was flush against the viewport edge and
   jammed on the last line of the page */
footer > .business-contacts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  padding: 18px 65px 26px;
  margin: 0;
  font-size: 12px;
  color: #bdb9ac;
  border-top: 1px solid #3d3c34;
  margin-top: 6px;
}
footer > .business-contacts a {
  color: #dcd9cc;
  text-decoration-color: #6c695e;
}
@media (max-width: 1250px) {
  footer > .business-contacts { padding-left: 38px; padding-right: 38px; }
}
@media (max-width: 720px) {
  footer > .business-contacts { padding-left: 23px; padding-right: 23px; }
}

/* back-to-top button was completely hidden underneath the WhatsApp bubble */
.back-top {
  bottom: 86px;
  right: 24px;
}
@media (max-width: 720px) {
  .back-top { bottom: 74px; right: 14px; }
}

/* ---------------------------------------------------------------------------
   3. KICKERS / META — yellow #e0ce58 on #f3f2ed is 1.43:1, i.e. invisible.
   ------------------------------------------------------------------------- */
.smp-hero .smp-kicker {
  color: #7d620a;
}
.smp-meta span,
.smp-meta small {
  color: #6b675c;
}
.smp-hero figcaption,
.smp-hero-lead,
.smp-meta {
  color: var(--studio-dim);
}
.studio-v18 .inner-ribbon {
  font-size: 10px;
  letter-spacing: .04em;
}
.studio-v18 .inner-ribbon span {
  color: #6b675c;
}
.article-body .editorial-note,
.article-meta,
.article-deck {
  color: #6b675c;
}

/* ---------------------------------------------------------------------------
   4. EMPTY IMAGE FRAMES — 34 article pages ship an empty .article-lead-image
   and /about ships .about-photo with no <img>. Both left huge blank panels.
   ------------------------------------------------------------------------- */
.inner-article-cover:has(.article-lead-image:empty) {
  grid-template-columns: 1fr;
  background: var(--studio-paper);
  border-radius: 0;
  min-height: 0;
}
.inner-article-cover:has(.article-lead-image:empty) .article-lead-image {
  display: none;
}
.inner-article-cover:has(.article-lead-image:empty) .article-header {
  align-self: stretch;
  max-width: none;
  padding: clamp(40px, 6vw, 84px) 0 clamp(30px, 4vw, 52px);
}
/* the cover copy was styled for a navy background; on paper it was ghost text */
.inner-article-cover .article-header h1,
.inner-article-cover .article-header .article-deck,
.inner-article-cover .article-header .article-meta,
.inner-article-cover .article-header .eyebrow {
  color: var(--studio-ink);
}
.inner-article-cover .article-header .article-deck { color: var(--studio-dim); }
.inner-article-cover .article-header .article-meta,
.inner-article-cover .article-header .eyebrow { color: #6b675c; }

/* /about hero block: no photograph, so don't reserve a 480px photo stage */
.about-photo:not(:has(> img)) {
  min-height: 0;
  background: transparent;
  border-radius: 0;
  overflow: visible;
  padding: clamp(40px, 6vw, 84px) 0 clamp(30px, 4vw, 60px);
}
.about-photo:not(:has(> img)) > div {
  position: static;
  width: auto;
  max-width: 74ch;
  padding: 0;
  background: transparent;
  backdrop-filter: none;
  border-radius: 0;
}
.about-photo:not(:has(> img)) h2 {
  font-size: clamp(30px, 3.6vw, 50px);
  line-height: 1.06;
  letter-spacing: -.03em;
  max-width: 20ch;
}
.about-photo:not(:has(> img)) p {
  font-size: var(--studio-body);
  line-height: 1.6;
  color: var(--studio-dim);
  max-width: 62ch;
  margin-top: 20px;
}
.about-photo:not(:has(> img)) small {
  display: block;
  font-size: 11px;
  color: #6b675c;
  margin-top: 22px;
  max-width: 62ch;
}
.factory-grid:empty,
.archive-photos:empty,
.article-inline-photo:empty,
.article-lead-image:empty {
  display: none;
}
/* placeholder panels that never received their photograph */
.article-inline-photo {
  background: #e7e5db;
  border-radius: 3px;
}
.article-inline-photo img { mix-blend-mode: normal; }

/* ---------------------------------------------------------------------------
   5. HOME / "Choose a way to listen" — the sticky character plate is 720px
   tall while the copy column is ~1470px, so the left half of the screen turns
   into an empty grey panel for the last ~750px of the section.
   ------------------------------------------------------------------------- */
/* fix-img.css forces position:relative on .studio-plate, so the sticky
   top:80px still shifted the whole plate down and opened an 80px hole at the
   top of the duet — reset it and let the plate fill the row instead. */
.studio-v18 .studio-plate {
  top: 0;
}
@media (min-width: 621px) {
  .studio-v18 .studio-duet { align-items: stretch; }
  .studio-v18 .studio-plate {
    height: auto;
    max-height: none;
    min-height: 0;
    align-self: stretch;
  }
}

/* ---------------------------------------------------------------------------
   6. /about BUYER STRIP — the "01 /" indices are absolutely positioned on top
   of the headings; on a 4-up row the headings run into them.
   ------------------------------------------------------------------------- */
.redesign .buyer h3 {
  padding-right: 46px;
  overflow-wrap: break-word;
  min-width: 0;
}
.redesign .buyer .count {
  right: 0;
  top: 33px;
  color: #7d7360;
}
@media (min-width: 1151px) {
  .redesign .buyer h3 { font-size: 18px; }
}

/* ---------------------------------------------------------------------------
   7. COLOUR LEAKS FROM THE OLD "premium / inner" THEME
   ------------------------------------------------------------------------- */
/* lavender + tan route cards (OEM / ODM) */
.inner-premium .route-cards article,
.inner-premium .route-cards article:first-child,
.inner-premium .route-cards article:last-child {
  background: #e7e5db;
  border: 0;
  border-radius: 3px;
}
/* tan CTA slab */
.premium .cta,
.redesign .cta {
  background: #e7e5db;
  border-radius: 3px;
}
.premium .cta p,
.redesign .cta p { color: var(--studio-dim); }
/* purple answer box + practice box on guide pages */
.answer-box {
  background: #e7e5db;
  border-left-color: var(--studio-accent);
  border-radius: 0;
}
.answer-box p { color: #3d3a33; }
.article-practice {
  background: #efece4;
  border-radius: 3px;
}
.article-practice strong {
  border-left-color: var(--studio-accent);
  color: #3d3a33;
}
.article-practice li:before { color: #7d620a; }
.article-toc {
  background: #e7e5db;
  border-radius: 3px;
}
.article-toc a:last-child { color: #7d620a; }
/* navy slabs */
.inner-archive,
.inner-dossier,
.usecase-grid article:nth-child(2),
.quality-split {
  background: var(--studio-dark) !important;
  border-radius: 3px;
}
.inner-archive .eyebrow,
.inner-dossier .eyebrow,
.inner-archive p,
.inner-dossier > div > p,
.dossier-points p { color: #b9b6ab; }
/* blue-ish catalogue surfaces — product-transparency.css forced #e7ecf5 on
   every .v15-product-frame and catalog.css painted a mint/pink 3n checkerboard */
body.studio-v18 main .catalog-photo.v15-product-frame,
body.studio-v18 main .product-image.v15-product-frame,
body.studio-v18 main .gallery-main.v15-product-frame,
body.studio-v18 main .article-lead-image.v15-product-frame,
body.studio-v18 main .article-inline-photo.v15-product-frame,
body.studio-v18 main .editorial-card > div.v15-product-frame {
  background: #e6e4db !important;
  border: 0 !important;
}
body.studio-v18 main .catalog-card .catalog-photo.v15-product-frame,
body.studio-v18 main .catalog-card:nth-child(3n) .catalog-photo.v15-product-frame,
body.studio-v18 main .catalog-card:nth-child(3n+1) .catalog-photo.v15-product-frame,
body.studio-v18 main .catalog-card:nth-child(3n+2) .catalog-photo.v15-product-frame,
body.studio-v18 main .catalog-photo,
body.studio-v18 main .catalog-card .catalog-photo,
body.studio-v18 main .catalog-card:nth-child(3n) .catalog-photo,
body.studio-v18 main .catalog-card:nth-child(3n+1) .catalog-photo,
body.studio-v18 main .catalog-card:nth-child(3n+2) .catalog-photo {
  background: #e6e4db !important;
  border-radius: 3px;
}
body.studio-v18 .catalog-sidebar {
  background: #e7e5db;
  border-radius: 3px;
}
.cat-choice > span { color: #6b675c; }
.cat-choice.active span { color: #7d620a; }

/* chapter tints (lavender / blue / mint) drove the contact form panel, the
   article panels and several figure plates */
.inner-premium,
.inner-premium[data-inner-tone="mint"],
.inner-premium[data-inner-tone="sun"],
.inner-premium[data-inner-tone="blue"],
.inner-premium[data-inner-tone] {
  --chapter: #e7e5db;
  --chapter-soft: #efece4;
}
.inner-premium #project-form {
  background: #efece4;
  border-radius: 3px;
}
.v10-steps > div {
  background: #e7e5db;
  border-radius: 3px;
}
.v10-steps span { color: #7d620a; }
.v10-format-art {
  background: #e7e5db;
  color: var(--studio-ink);
}
.v10-orbits i { border-color: #cbc7b8; }
.v10-context th { background: var(--studio-dark); }
.editorial-card > div {
  background: #e7e5db;
  border-radius: 3px;
}
.editorial-card small { color: #6b675c; }
.editorial-card > div > span { color: #6b675c; }
.premium .configurator {
  background: #e7e5db;
  border-radius: 3px;
}
/* pale-blue / lavender cards and notices that survived the theme layers */
.v12-practical-grid article {
  background: #e7e5db;
  border-radius: 3px;
}
.v10-form-note {
  background: #e7e5db;
  border-left-color: var(--studio-accent);
}
.redesign .contactgrid aside,
.premium .photo-gallery {
  background: #e9e7dd;
  border-radius: 3px;
}
.premium .company-film,
.redesign .company-film,
.premium-factory {
  background: var(--studio-dark);
  border-radius: 3px;
}
.premium .company-film p,
.premium-factory .premium-heading p { color: #b9b6ab; }
/* safety: the navy page-header background must never peek through */
.studio-v18 > header,
.premium.inner-premium > header {
  background: var(--studio-paper);
}

/* ---------------------------------------------------------------------------
   8. LINE LENGTH — several templates run body copy the full 1085–1370px.
   ------------------------------------------------------------------------- */
.studio-v18 main .section > p,
.studio-v18 main .sectionhead + p {
  max-width: 74ch;
}
.article-body > section > p,
.article-body p {
  max-width: 70ch;
}
.item-copy p,
.detail-copy p,
.product-detail p {
  max-width: 68ch;
}
.studio-v18 .studio-proof p,
.studio-v18 .studio-faq details p { max-width: 70ch; }

/* ---------------------------------------------------------------------------
   8b. FINAL CONTRAST PASS — copy and metadata that were still under 4.5:1.
   ------------------------------------------------------------------------- */
/* blue-grey body copy inside the v12 panels (#637087 -> 3.9:1) */
.studio-v18 .v12-section-title p,
.studio-v18 .v12-practical p,
.studio-v18 .v12-format-notes p,
.studio-v18 .v12-family-guide p {
  color: var(--studio-dim);
}
/* uppercase metadata labels (#8a877d -> 2.7–3.6:1 on warm panels) */
.studio-v18 .smp-meta span,
.studio-v18 .smp-meta small,
.studio-v18 .srow-idx,
.studio-v18 .srow-tag,
.studio-v18 .srow-draw figcaption,
.studio-v18 .pm-kicker,
.studio-v18 .pm-noimg span,
.studio-v18 .pm-body small,
body.studio-v18 main .v12-reference small,
body.studio-v18 main .ref-wide .v12-reference small,
body.studio-v18 main .ref-tiles .v12-reference small,
body.studio-v18 main .ref-rows .v12-reference small,
body.studio-v18 main .ref-wide-r .v12-reference small,
body.studio-v18 main .ref-duo .v12-reference small {
  color: #635f54;
}
/* SKU line under catalogue cards (#84907c -> 2.7:1) */
.studio-v18 .catalog-card > a > p {
  color: #6b675c;
}
/* the dark "stage" reference card keeps its light metadata */
.studio-v18 .ref-stage .v12-reference small,
.studio-v18 .ref-stage .v12-reference > small {
  color: #c9c6ba;
}
.cat-choice > span { color: #5f5b50; }
.editorial-card small { color: #5f5b50; }
.redesign .buyer .count {
  color: #6b6050;
}
/* workshop plates: align the mount colour with the site panel and make the
   caption gradient actually carry the white label */
.factory-grid figure {
  background: #e9e7dd !important;
}
.factory-grid figure figcaption {
  background: linear-gradient(0deg, rgba(20, 19, 16, .92) 30%, rgba(20, 19, 16, .55) 70%, transparent) !important;
  padding-top: 22px !important;
}

/* ---------------------------------------------------------------------------
   9. NAVIGATION — a bare "+" floats between menu items and reads as a stray
   glyph. Give it an affordance instead of hiding the panel.
   ------------------------------------------------------------------------- */
@media (min-width: 1251px) {
  .studio-v18 header .mega-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    padding: 0 0 1px;
    margin-left: 1px;
    border: 1px solid #c6c2b3;
    border-radius: 3px;
    font-size: 14px;
    line-height: 1;
    color: #4a473e;
    background: transparent;
    transition: background .18s ease, border-color .18s ease;
  }
  .studio-v18 header .mega-toggle:hover,
  .studio-v18 header .mega-toggle[aria-expanded="true"] {
    background: var(--studio-accent);
    border-color: var(--studio-accent);
    color: #20201a;
  }
}

/* ---------------------------------------------------------------------------
   10. (reserved)
   ------------------------------------------------------------------------- */
