/* Insight Upgrade District | 20261128ud1
   Load last on index.html only. Category cards are owned by a separate patch.
   ud-* classes are additive adapters; retain original IDs/classes/attributes. */
body.page-home main.ud-home {
  --ud-bg:#fbf8f0; --ud-yellow:#ffd200; --ud-soft:#fff4c2;
  --ud-ink:#111; --ud-muted:#5f5f5f; --ud-line:#ece6d6;
  --ud-shadow:0 6px 18px rgba(40,32,0,.07),0 1px 3px rgba(40,32,0,.06);
  --ud-gutter:12px; --ud-max:1440px;
  background:var(--ud-bg); color:var(--ud-ink);
  font-family:Inter,"Noto Sans Sinhala","Noto Sans Tamil",system-ui,sans-serif;
}
body.page-home .ud-home .ud-shell {
  box-sizing:border-box; width:100%; max-width:var(--ud-max); margin-inline:auto;
  padding-inline:var(--ud-gutter); min-width:0;
}
body.page-home .ud-home .ud-section { margin-block:24px; min-width:0; }
body.page-home .ud-home .ud-heading {
  margin:0 0 12px; font-size:clamp(1.45rem,3vw,2.15rem); line-height:1.13;
  letter-spacing:-.035em; font-weight:700; color:var(--ud-ink);
}
body.page-home .ud-home .ud-eyebrow {
  margin:0 0 8px; font-size:.7rem; line-height:1.4; font-weight:700;
  letter-spacing:.12em; text-transform:uppercase; color:#7a6a2a;
}
/* HERO: the existing rotator stays intact; annotate its actual visible nodes. */
body.page-home .ud-home .ud-hero {
  position:relative; isolation:isolate; background:var(--ud-bg);
  padding-block:16px 12px; min-width:0;
}
body.page-home .ud-home .ud-hero-inner { position:relative; min-width:0; }
body.page-home .ud-home .ud-hero-copy { position:relative; z-index:1; min-width:0; }
body.page-home .ud-home .ud-badge {
  display:inline-flex; align-items:center; max-width:100%; box-sizing:border-box;
  padding:6px 10px; border-radius:999px; background:var(--ud-yellow);
  color:var(--ud-ink); font-size:.67rem; line-height:1.3; font-weight:700; letter-spacing:.075em;
}
/* Existing H1 text and semantic level remain unchanged. */
body.page-home .ud-home .ud-hero-copy h1 {
  margin:12px 0 6px; font-size:clamp(1.95rem,8.3vw,3.2rem);
  line-height:1.04; letter-spacing:-.05em; font-weight:700; overflow-wrap:anywhere;
}
body.page-home .ud-home .ud-tagline { margin:0 0 12px; font-size:.95rem; font-weight:600; }
body.page-home .ud-home .ud-hero-media {
  position:relative; isolation:isolate; display:grid; place-items:center;
  min-width:0; min-height:160px; padding:12px; box-sizing:border-box;
  background:transparent !important; border:0 !important; box-shadow:none !important;
}
/* A flat geometric backdrop, contained within the media region. */
body.page-home .ud-home .ud-hero-media::before {
  content:""; position:absolute; inset:0; z-index:-1; pointer-events:none;
  background:var(--ud-yellow); border-radius:18px;
  clip-path:polygon(0 18%,100% 0,100% 100%,0 100%);
}
body.page-home .ud-home .ud-hero-photo {
  display:block; width:100%; max-width:420px; height:auto; max-height:245px;
  object-fit:contain; background:transparent !important; border:0 !important;
  border-radius:0 !important; padding:0 !important; box-shadow:none !important;
  filter:none; margin-inline:auto;
}
/* Opt in ONLY for verified white-background assets; do not tint transparent products. */
body.page-home .ud-home .ud-hero-photo.ud-white-photo { mix-blend-mode:multiply; }
body.page-home .ud-home .ud-product-name { font-size:1rem; font-weight:700; line-height:1.3; overflow-wrap:anywhere; }
body.page-home .ud-home .ud-product-price { font-size:clamp(1.4rem,5vw,2rem); font-weight:700; letter-spacing:-.035em; line-height:1.15; }
body.page-home .ud-home :is(.ud-cta,.ud-repair-cta) {
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  box-sizing:border-box; min-height:44px; padding:10px 20px; border:1px solid transparent;
  border-radius:999px; background:var(--ud-ink); color:#fff; font-weight:700;
  font-size:.9rem; line-height:1.3; text-decoration:none;
  transition:background-color .18s,transform .18s;
}
body.page-home .ud-home .ud-hero-controls { min-width:0; margin-block:8px; }
/* Existing quick links and computer strip: preserve markup/handlers. */
body.page-home .ud-home :is(.ud-quick,.ud-mobile-computers) { margin-block:12px; min-width:0; }
body.page-home .ud-home .ud-desktop-computers { display:none; }
/* Trust strip: exactly four supplied facts. */
body.page-home .ud-home .ud-trust { margin-block:24px; }
body.page-home .ud-home .ud-trust-list {
  display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:1px;
  list-style:none; margin:0; padding:1px; border-radius:16px; background:var(--ud-line);
  overflow:hidden; box-shadow:var(--ud-shadow);
}
body.page-home .ud-home .ud-trust-list li {
  display:flex; flex-direction:column; justify-content:center; gap:4px;
  min-width:0; padding:14px 12px; background:#fff; font-size:.78rem; line-height:1.35;
}
body.page-home .ud-home .ud-trust-list strong { font-size:1rem; font-weight:700; }
body.page-home .ud-home .ud-trust-list span { color:var(--ud-muted); }
/* Repair feature. Contact links are existing anchors, not new destinations. */
body.page-home .ud-home .ud-repair-panel {
  position:relative; isolation:isolate; overflow:hidden; border-radius:20px;
  padding:24px 20px; background:var(--ud-ink); color:#fff;
}
body.page-home .ud-home .ud-repair-panel::after {
  content:""; position:absolute; z-index:-1; width:150px; height:150px;
  right:-75px; bottom:-80px; border:16px solid var(--ud-yellow); border-radius:50%;
  opacity:.25; pointer-events:none;
}
body.page-home .ud-home .ud-repair-panel h2 {
  margin:0 0 12px; font-size:clamp(1.75rem,6vw,3rem); font-weight:700;
  line-height:1.08; letter-spacing:-.045em; color:#fff;
}
body.page-home .ud-home .ud-repair-panel h2 span { color:var(--ud-yellow); }
body.page-home .ud-home .ud-repair-panel p { margin:0 0 16px; font-size:.95rem; color:#fff; }
body.page-home .ud-home .ud-repair-actions { display:flex; flex-wrap:wrap; gap:10px; }
body.page-home .ud-home .ud-repair-cta { background:var(--ud-yellow); color:var(--ud-ink); }
body.page-home .ud-home .ud-repair-cta.ud-secondary { background:transparent; border-color:#fff; color:#fff; }
/* Existing product, brand and editorial mounts: no changes to data or card hooks. */
body.page-home .ud-home :is(.ud-products,.ud-deals,.ud-brands,.ud-discover) { min-width:0; margin-block:24px; }
body.page-home .ud-home :is(.ud-cta,.ud-repair-cta,.ud-hero-controls a,.ud-hero-controls button):focus-visible {
  outline:3px solid var(--ud-ink); outline-offset:2px; box-shadow:0 0 0 6px var(--ud-yellow);
}
body.page-home .ud-home .ud-repair-panel :focus-visible { outline-color:#fff; box-shadow:0 0 0 6px var(--ud-yellow); }
@media (hover:hover) and (pointer:fine) {
  body.page-home .ud-home .ud-cta:hover { background:#2a2a2a; transform:translateY(-1px); }
  body.page-home .ud-home .ud-repair-cta:not(.ud-secondary):hover { background:#f0c400; transform:translateY(-1px); }
  body.page-home .ud-home .ud-repair-cta.ud-secondary:hover { background:#2a2a2a; }
}
@media (min-width:768px) {
  body.page-home main.ud-home { --ud-gutter:24px; }
  body.page-home .ud-home .ud-section { margin-block:32px; }
  body.page-home .ud-home .ud-hero { padding-block:28px 20px; }
  /* Apply to an existing slide/layout element containing copy and media as children. */
  body.page-home .ud-home .ud-hero-layout { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); align-items:center; gap:24px; }
  body.page-home .ud-home .ud-hero-copy h1 { font-size:clamp(2.4rem,4.5vw,4rem); }
  body.page-home .ud-home .ud-hero-media { min-height:280px; padding:20px; }
  body.page-home .ud-home .ud-hero-photo { max-height:330px; }
  body.page-home .ud-home .ud-trust-list { grid-template-columns:repeat(4,minmax(0,1fr)); }
  body.page-home .ud-home .ud-trust-list li { padding:20px 16px; }
  /* proofread: do not hide/show .ud-quick/.ud-mobile-computers/.ud-desktop-computers at 768px; existing .m45/.mt-only/.dt-only (767/901) stay in charge */
  body.page-home .ud-home .ud-repair-panel { padding:36px; }
}
@media (min-width:1280px) {
  body.page-home main.ud-home { --ud-gutter:36px; --ud-shadow:0 10px 30px rgba(40,32,0,.07),0 2px 6px rgba(40,32,0,.05); }
  body.page-home .ud-home .ud-hero { padding-block:36px 24px; }
  body.page-home .ud-home .ud-hero-layout { grid-template-columns:minmax(0, .95fr) minmax(0,1.05fr); gap:48px; }
  body.page-home .ud-home .ud-hero-copy h1 { font-size:clamp(3.5rem,4.3vw,4.8rem); }
  body.page-home .ud-home .ud-hero-media { min-height:380px; padding:28px; }
  body.page-home .ud-home .ud-hero-media::before { border-radius:26px; }
  body.page-home .ud-home .ud-hero-photo { max-width:560px; max-height:365px; }
  body.page-home .ud-home .ud-section { margin-block:40px; }
  body.page-home .ud-home .ud-repair-panel { padding:48px; }
}
@media (prefers-reduced-motion:reduce) {
  body.page-home .ud-home :is(.ud-hero,.ud-repair-panel),
  body.page-home .ud-home :is(.ud-hero,.ud-repair-panel) * {
    animation:none !important; transition:none !important; scroll-behavior:auto !important;
  }
  body.page-home .ud-home :is(.ud-cta,.ud-repair-cta):hover { transform:none !important; }
}


/* ---- 20261128ud1 proofread additions (do not touch category cards) ---- */

/* After Insight Discover leaves the hero, the desktop hero is a 2-column copy + product layout. */
@media (min-width:901px) {
  body.page-home.dt-theme .ud-home .dt-hero {
    grid-template-columns: minmax(0,1.08fr) minmax(0,1fr) !important;
  }
  /* Replace the decorative hero waves with the yellow geometric media backdrop. */
  body.page-home.dt-theme .ud-home .pv-hero.disc-hero::after { display:none !important; }
}
@media (min-width:901px) and (max-width:1439px) {
  body.page-home.dt-theme .ud-home .dt-hero {
    grid-template-columns: minmax(0,1.1fr) minmax(0,.9fr) !important;
  }
}

/* Keep Discover editorial in the hero visually hidden; H1 in .hero3__text stays. */
body.page-home .ud-home .disc-hero > .disc-figwrap,
body.page-home .ud-home .disc-hero .hero3__text .disc-text {
  display: none !important;
}

/* Tablet (768-900): full-width product rotator, no Discover overlay. */
@media (min-width:768px) and (max-width:900px) {
  body.page-home .ud-home .disc-hero > .hero-stage {
    width: 100%;
    max-width: var(--preview-max, 1440px);
    margin-inline: auto;
    position: relative;
  }
}

/* Relocated desktop/tablet Discover: full-width editorial, not a hero column. */
body.page-home .ud-home > aside.dt-disc {
  display: none !important;
  grid-column: auto !important;
  grid-row: auto !important;
  width: 100%;
  max-width: var(--ud-max, 1440px);
  margin: 24px auto;
  box-sizing: border-box;
  padding-inline: var(--ud-gutter, 24px);
  min-height: 0;
}
@media (min-width:768px) {
  body.page-home .ud-home > aside.dt-disc {
    display: flex !important;
    flex-direction: column;
  }
}

/* Mobile reading order (overrides .mt-theme main > … order). */
@media (max-width:767px) {
  body.page-home.mt-theme .ud-home > * { order: 50; }
  body.page-home.mt-theme .ud-home > #m45-hero { order: 1; }
  body.page-home.mt-theme .ud-home > .mt-deals { order: 2; }
  body.page-home.mt-theme .ud-home > .mt-pcs { order: 3; }
  body.page-home.mt-theme .ud-home > .mt-aio { order: 4; }
  body.page-home.mt-theme .ud-home > .mt-cats { order: 5; }
  body.page-home.mt-theme .ud-home > .ud-trust { order: 6; }
  body.page-home.mt-theme .ud-home > .ud-repair { order: 7; }
  body.page-home.mt-theme .ud-home > .m45-disc { order: 8; }
  body.page-home.mt-theme .ud-home > .mt-care { order: 9; }
}

/* Give the last homepage blocks room above the sticky WhatsApp/Call bar and chat. */
@media (max-width:767px) {
  body.page-home .ud-home { padding-bottom: 8px; }
}
