/* Website design «D · Хослол» (owner chose 2026-11-29): dark premium top, catalogue as cards, day/night switch.
   Colours: Sezam orange #ff671e, near-black #0d1116 and white. Dark is the default; [data-theme="light"] is day. */
:root {
  --d-bg: #0d1116; --d-surface: #161c23; --d-line: #222b35; --d-line-strong: #2c3642;
  --d-text: #e9edf2; --d-muted: #8d99a7; --d-soft: #aab4c0; --d-accent-text: #ff8a52; --d-orange: #ff671e; --d-ink: #101419;
}
:root[data-theme="light"] {
  --d-bg: #f6f7f9; --d-surface: #ffffff; --d-line: #e4e8ee; --d-line-strong: #d5dbe2;
  --d-text: #18202a; --d-muted: #526071; --d-soft: #526071; --d-accent-text: #a7400d;
}
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Header: the approved header follows the theme; the switch sits before the quote button. */
.d-site .site-header { background: color-mix(in srgb, var(--d-bg) 94%, transparent); border-bottom: 1px solid var(--d-line); }
.d-site .site-header .brand-word strong, .d-site .site-header .nav a { color: var(--d-text); }
.d-site .site-header .brand-word small { color: var(--d-muted); }
.d-site .site-header .nav a[href$="#top"], .d-site .site-header .nav a[href="/"] { display: none; }
.d-site .header-phone { border-color: var(--d-line-strong); color: var(--d-text); }
.d-site .header-btn { border-radius: 999px; }
.d-site .mobile-toggle { color: var(--d-text); }
.d-mode { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 999px; border: 1px solid var(--d-line-strong);
  background: transparent; color: var(--d-text); cursor: pointer; padding: 0; flex: none; }
.d-mode svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.d-mode .d-moon { display: none; }
:root[data-theme="light"] .d-mode .d-sun { display: none; }
:root[data-theme="light"] .d-mode .d-moon { display: block; }

/* Home and catalogue pages take the theme background. */
.d-hero-wrap { background: var(--d-bg); }
.d-hero { display: grid; grid-template-columns: 1.1fr 1fr; gap: 32px; align-items: center; padding: 40px 0 36px; }
.d-hero h1 { font-size: clamp(32px, 4vw, 56px); line-height: 1.06; letter-spacing: -.035em; margin: 0 0 16px; font-weight: 600; color: var(--d-text); }
.d-hero h1 span { color: var(--d-orange); }
:root[data-theme="light"] .d-hero h1 span { color: #c2410c; }
.d-hero p { color: var(--d-soft); margin: 0 0 24px; max-width: 520px; font-size: 18px; line-height: 1.55; }
.d-hero .hero-media { margin: 0; }
.d-hero img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 18px; display: block; }
.d-hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.d-tiles-wrap { background: var(--d-bg); padding: 8px 0 0; }
.d-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.d-tile { display: grid; grid-template-columns: 140px minmax(0, 1fr); align-items: center; border-radius: 16px; overflow: hidden;
  background: var(--d-surface); border: 1px solid var(--d-line); color: var(--d-text); text-decoration: none; transition: border-color .15s; }
.d-tile:hover { border-color: var(--d-orange); color: var(--d-text); }
.d-tile img { width: 140px; height: 96px; object-fit: contain; background: #fff; display: block; }
.d-tile span { display: flex; flex-direction: column; padding: 0 18px; }
.d-tile b { font-size: 18px; font-weight: 600; }
.d-tile small { color: var(--d-muted); font-size: 14px; }

.home-buying { background: var(--d-bg); padding: clamp(26px, 4vw, 52px) 0 0; color: var(--d-text); }
.home-buying-inner { border-top: 1px solid var(--d-line-strong); padding-top: clamp(22px, 3vw, 38px); }
.home-buying h2 { margin: 0 0 20px; font-size: clamp(24px, 2.6vw, 36px); font-weight: 600; letter-spacing: -.025em; }
.home-buyer-links {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0; padding: 0; list-style: none;
  background: var(--d-surface); border: 1px solid var(--d-line-strong); border-radius: 14px;
}
.home-buyer-links li { display: flex; flex-direction: column; gap: 6px; padding: 18px clamp(16px, 2.5vw, 32px) 12px; }
.home-buyer-links li + li { border-inline-start: 1px solid var(--d-line-strong); }
.home-buyer-links h3 { margin: 0; color: var(--d-text); font-size: 17px; font-weight: 600; }
.home-buyer-links p { margin: 0; color: var(--d-soft); font-size: 14px; line-height: 1.55; }
.home-buyer-links a {
  display: inline-flex; align-items: center; gap: 9px; min-height: 44px; align-self: flex-start; margin-top: auto;
  color: var(--d-accent-text); font-size: 14px; font-weight: 600; text-decoration: none;
}
.home-buyer-links a:hover { text-decoration: underline; text-underline-offset: 4px; }
.home-buyer-links a:focus-visible { outline: 2px solid var(--d-accent-text); outline-offset: 3px; }
@media (max-width: 630px) {
  .home-buyer-links { grid-template-columns: 1fr; }
  .home-buyer-links li + li { border-inline-start: 0; border-top: 1px solid var(--d-line-strong); }
}

.home-storefront .workflow-section,
.home-storefront .contact-section { background: var(--d-bg); color: var(--d-text); border-top: 1px solid var(--d-line); }
.home-storefront .workflow-panel { background: var(--d-surface); border: 1px solid var(--d-line-strong); }
.home-storefront .workflow-panel p,
.home-storefront .contact-grid :is(small, p, .muted) { color: var(--d-soft); }
.home-storefront .contact-grid > div { border-color: var(--d-line-strong); }
.home-storefront .contact-grid a,
.buyer-information a { color: var(--d-accent-text); }
.buyer-information { margin: 12px 0 22px; }
.buyer-information > div { padding: 12px 0; border-top: 1px solid var(--d-line-strong); }
.buyer-information dt { font-size: 15px; font-weight: 600; }
.buyer-information dd { margin: 4px 0 0; color: var(--d-soft); font-size: 14px; line-height: 1.55; }
.buyer-information a { text-decoration: underline; text-underline-offset: 3px; }

/* Catalogue */
.d-catalog { background: var(--d-bg) !important; border: 0 !important; color: var(--d-text); padding-top: 32px !important; }
.d-catalog > .wrap { border-top: 1px solid var(--d-line); padding-top: 28px; }
.d-catalog .catalog-box { max-width: none; }
.d-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 18px; }
.d-bar-title { font-size: 28px; margin: 0 8px 0 0; letter-spacing: -.02em; font-weight: 600; color: var(--d-text); }
.d-chips { display: flex; gap: 8px; flex-wrap: wrap; }
.d-chips a { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--d-line-strong);
  font-size: 14px; color: var(--d-soft); text-decoration: none; }
.d-chips a:hover { border-color: var(--d-orange); color: var(--d-text); }
.d-chips a.selected { background: var(--d-orange); border-color: var(--d-orange); color: var(--d-ink); font-weight: 600; }
.d-search { flex: 1; min-width: 220px; display: flex; }
.d-search input { width: 100%; height: 44px; border: 1px solid var(--d-line-strong); border-radius: 999px; padding: 0 18px; font: inherit; font-size: 15px;
  background: var(--d-surface); color: var(--d-text); box-sizing: border-box; }
.d-search input::placeholder { color: var(--d-muted); }
.d-size { flex-basis: 100%; color: var(--d-muted); font-size: 14px; }
.d-size summary { cursor: pointer; }
.d-size-fields { display: flex; gap: 10px; align-items: end; flex-wrap: wrap; margin-top: 8px; }
.d-size-fields label { display: grid; gap: 4px; font-size: 13px; }
.d-size-fields input { width: 130px; height: 40px; border-radius: 10px; border: 1px solid var(--d-line-strong); background: var(--d-surface);
  color: var(--d-text); padding: 0 10px; font: inherit; }
.d-catalog .demo-banner { margin: 0 0 14px; }
.d-catalog .catalog-help { color: var(--d-muted); }
.d-catalog .empty h2 { color: var(--d-text); }

.d-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 18px; }
.d-card { display: flex; flex-direction: column; background: var(--d-surface); border: 1px solid var(--d-line); border-radius: 22px; overflow: hidden; min-width: 0; }
.d-ph { display: block; margin: 8px 8px 0; border-radius: 16px; background: #fff; aspect-ratio: 4 / 3; overflow: hidden; }
.d-ph img { width: 100%; height: 100%; object-fit: contain; display: block; }
.d-ph-empty { background: var(--d-line); }
.d-body { display: flex; flex-direction: column; gap: 5px; padding: 12px 14px 14px; flex: 1; }
.d-top { display: flex; flex-direction: column; }
.d-name { font-size: 18px; font-weight: 650; color: var(--d-text); text-decoration: none; }
.d-name:hover { color: var(--d-accent-text); }
.d-grp { color: var(--d-accent-text); font-size: 12.5px; font-weight: 600; }
.d-short { margin: 0; color: var(--d-soft); font-size: 13px; }
.d-uses-h { margin: 6px 0 0; font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--d-muted); }
.d-uses { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin: 4px 0 6px; }
.d-u { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 10px; line-height: 1.15; color: var(--d-muted); text-align: center;
  min-width: 0; white-space: nowrap; padding: 0 1px; }
.d-u svg { width: 30px; height: 30px; padding: 6px; box-sizing: border-box; border-radius: 50%; border: 1px solid var(--d-line-strong); color: var(--d-soft);
  fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.d-spec { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 2px 10px; margin: 2px 0 0; font-size: 13px; }
.d-spec dt { color: var(--d-muted); }
.d-spec dd { margin: 0; color: var(--d-text); }
.d-build { color: var(--d-muted); font-size: 12.5px; }
.d-row { display: flex; gap: 8px; padding-top: 12px; margin-top: auto; }
.d-btn { display: inline-flex; align-items: center; justify-content: center; height: 38px; padding: 0 16px; border-radius: 999px; font-weight: 600;
  font-size: 14px; text-decoration: none; border: 1px solid transparent; white-space: nowrap; cursor: pointer; font-family: inherit; }
.d-lg { height: 48px; padding: 0 24px; font-size: 15px; }
.d-brand { background: var(--d-orange); color: var(--d-ink); }
.d-brand:hover { background: #ed5913; color: var(--d-ink); }
.d-ghost { background: transparent; color: var(--d-text); border-color: var(--d-line-strong); }
.d-ghost:hover { border-color: var(--d-orange); color: var(--d-text); }
.d-fine { color: var(--d-muted); font-size: 12px; margin: 14px 0 0; }
.d-cta { margin-top: 24px; background: var(--d-surface); border: 1px solid var(--d-line); color: var(--d-text); border-radius: 16px; padding: 20px 22px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.d-cta b { font-size: 18px; font-weight: 600; }
.d-cta p { margin: 2px 0 0; color: var(--d-soft); }
.d-cta .d-btn { height: 46px; padding: 0 22px; }
@media (max-width: 1100px) { .d-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px) {
  .d-hero { grid-template-columns: 1fr; padding-top: 24px; } .d-hero .hero-media { display: none; }
  .d-tiles { grid-template-columns: 1fr; } .d-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .d-site .header-phone { display: none; }
}
@media (max-width: 600px) {
  .d-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; } .d-row .d-btn { flex: 1; } .d-hero p { font-size: 16px; }
  .d-tile { grid-template-columns: 110px minmax(0, 1fr); } .d-tile img { width: 110px; height: 80px; }
  .d-site .header-btn { padding: 0 14px; }
}
@media (min-width: 901px) { .d-site .site-header .nav a { color: var(--d-soft) !important; } .d-site .site-header .nav a:hover { color: var(--d-orange) !important; } }
/* Header as in design D (owner 2026-12-01): low, quiet bar; nav and phone as plain text; one quote pill. */
@media (min-width: 901px) {
  .d-site .header-main { height: 64px; gap: 24px; }
  .d-site .brand { gap: 8px; }
  .d-site .logo-image { width: 30px; height: 30px; }
  .d-site .brand-word strong { font-size: 17px; letter-spacing: -.02em; font-weight: 700; }
  .d-site .brand-word small { font-size: 11px; margin-top: 0; padding-left: 0; letter-spacing: 0; }
  .d-site .nav { margin-left: auto; gap: 22px; }
  .d-site .nav a { font-size: 14px; font-weight: 450; }
  .d-site .nav a.active { color: var(--d-text) !important; }
  .d-site .header-actions { gap: 14px; }
  .d-site .header-phone { border: 0; padding: 0; font-size: 14px; font-weight: 450; color: var(--d-soft); }
  .d-site .header-btn { height: 44px; padding: 0 22px; font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; }
  .d-site .header-btn .arrow { display: none; }
}
:root[data-theme="light"] .d-site .site-header { background: rgba(255, 255, 255, .96); }
.d-site .site-header .header-btn { border-radius: 999px !important; }

/* «Үнэ асуух» window on a product card (owner 2026-12-05): product filled in, metres and phone only. */
.price-ask { width: min(26rem, calc(100vw - 24px)); max-height: calc(100dvh - 24px); padding: 16px 18px 18px; border-radius: 14px;
  color: var(--d-text); background: var(--d-surface); border: 1px solid var(--d-line-strong); font-family: inherit; }
.price-ask::backdrop { background: rgb(8 12 17 / .75); }
.price-ask h2 { margin: 0 0 4px; font-size: 20px; }
.price-ask-close { display: flex; justify-content: flex-end; margin: -6px -8px 0 0; }
.price-ask-close button { min-height: 44px; padding: 0 12px; border: 0; background: none; color: var(--d-soft); font: inherit; cursor: pointer; }
.price-ask-item { margin: 0 0 12px; font-weight: 600; color: var(--d-accent-text); overflow-wrap: anywhere; }
.price-ask form[data-ask-form] { display: grid; gap: 12px; }
.price-ask label { display: grid; gap: 5px; font-size: 14px; font-weight: 600; }
.price-ask input { min-height: 46px; padding: 0 12px; border: 1px solid var(--d-line-strong); border-radius: 10px; background: var(--d-bg);
  color: var(--d-text); font: inherit; font-size: 16px; font-weight: 400; }
.price-ask input:focus-visible { outline: 2px solid var(--d-orange); outline-offset: 1px; }
.price-ask details { display: grid; gap: 10px; }
.price-ask details[open] { padding-bottom: 2px; }
.price-ask details label + label, .price-ask details summary + label { margin-top: 10px; }
.price-ask summary { min-height: 44px; display: flex; align-items: center; gap: 6px; cursor: pointer; color: var(--d-soft); }
.price-ask .optional { color: var(--d-muted); font-size: 12px; font-weight: 400; }
.price-ask button[type="submit"].d-btn { height: 48px; width: 100%; border: 0; font: inherit; font-weight: 700; cursor: pointer; }
.price-ask-consent { margin: 0; color: var(--d-muted); font-size: 12px; }
.price-ask .feedback { margin: 0; min-height: 1em; overflow-wrap: anywhere; }
.price-ask .feedback.error { color: #ff9a85; }
:root[data-theme="light"] .price-ask .feedback.error { color: var(--ui-error, #872f24); }
.price-ask .price-ask-unknown { display: flex; align-items: center; gap: 10px; min-height: 44px; font-weight: 400; cursor: pointer; }
.price-ask .price-ask-unknown input { width: 22px; height: 22px; min-height: 0; margin: 0; flex: none; accent-color: var(--d-orange); }
.price-ask input:disabled { opacity: .55; }

/* «Миний жагсаалт» window and «Жагсаалтад нэмэх» on a card (owner 2026-12-05). */
.price-list .price-list-rows { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; max-height: 42dvh; overflow: auto; }
.price-list .price-list-rows li { display: grid; gap: 8px; padding: 10px 12px; border: 1px solid var(--d-line-strong); border-radius: 10px; }
.price-list-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; overflow-wrap: anywhere; }
.price-list-remove { min-height: 44px; padding: 0 10px; border: 0; background: none; color: var(--d-soft); font: inherit; cursor: pointer; }
.price-list-fields { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.price-list-fields input { width: 100%; min-width: 0; }
.price-list .price-list-rows { overflow-x: hidden; }
.price-list-fields label { font-size: 13px; }
.price-list .price-list-empty { margin: 0; color: var(--d-muted); }
.price-list textarea { min-height: 96px; padding: 10px 12px; border: 1px solid var(--d-line-strong); border-radius: 10px; background: var(--d-bg);
  color: var(--d-text); font: inherit; font-size: 16px; font-weight: 400; resize: vertical; }
.price-list .price-list-paste .d-btn { height: 44px; width: 100%; border: 1px solid var(--d-line-strong); font: inherit; font-weight: 600; cursor: pointer; }
.price-list .price-list-paste [data-paste-result] { display: grid; gap: 8px; }
.price-list-read { margin: 0; padding: 0; list-style: none; display: grid; gap: 4px; font-size: 14px; overflow-wrap: anywhere; }
.price-list-read .read-ok { color: var(--d-text); }
.price-list-read .read-miss { color: #ff9a85; }
:root[data-theme="light"] .price-list-read .read-miss { color: var(--ui-error, #872f24); }
.price-list [hidden] { display: none !important; }
.d-row .price-list-add { flex-basis: 100%; }
.d-row { flex-wrap: wrap; }
button.price-list-add { font: inherit; font-weight: 600; cursor: pointer; }
/* A published price on a card (owner 2026-12-05), with the day it was written. */
.card-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 10px 0 0; }
.card-price b { font-size: 18px; color: inherit; }
.card-price small { font-size: 12px; color: inherit; opacity: .72; }
