/*
 * Desktop D1 experience layer
 * Scope: Home → Designer → Desktop IM → OTP → Delivered/Failed
 * The shared Mock Store and business interactions remain in app.js.
 */

body.desktop-d1 {
  --d1-ink: #111214;
  --d1-ink-soft: #1c1e22;
  --d1-surface: #f3f2ee;
  --d1-card: #ffffff;
  --d1-muted: #6c6e72;
  --d1-line: #dcdcd8;
  --d1-accent: #ff5a2a;
  --d1-accent-dark: #d73e13;
  --d1-lime: #d8ff4f;
  background: var(--d1-surface);
  color: var(--d1-ink);
}

body.desktop-d1 .wrap {
  width: min(100%, 1800px);
  max-width: none;
  padding-inline: clamp(32px, 2.5vw, 48px);
}

body.desktop-d1 .topbar {
  background: #0b0c0e;
  color: #d6d6d2;
  border-bottom: 1px solid #2c2d30;
}

body.desktop-d1 .topbar .wrap {
  height: 40px;
}

body.desktop-d1 .topbar .left,
body.desktop-d1 .topbar .right {
  gap: 24px;
  font-size: 12px;
  letter-spacing: .02em;
}

body.desktop-d1 .topbar a,
body.desktop-d1 .topbar span {
  color: #a8a9ad;
}

body.desktop-d1 .topbar strong {
  color: #fff;
  font-size: 12px;
}

body.desktop-d1 header.site {
  background: rgba(255, 255, 255, .97);
  border-bottom-color: #d8d8d4;
  backdrop-filter: blur(14px);
}

body.desktop-d1 header.site .wrap {
  height: 82px;
  gap: 30px;
}

body.desktop-d1 .logo {
  flex: 0 0 auto;
  font-size: 27px;
}

body.desktop-d1 .logo .mark {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: var(--d1-ink);
}

body.desktop-d1 nav.main {
  justify-content: center;
  gap: 25px;
}

body.desktop-d1 nav.main a {
  padding: 28px 0 25px;
  border-bottom-width: 3px;
  color: #35363a;
  font-size: 13.5px;
  white-space: nowrap;
}

body.desktop-d1 nav.main a:hover,
body.desktop-d1 nav.main a.active {
  color: var(--d1-ink);
  border-bottom-color: var(--d1-accent);
}

body.desktop-d1 .head-actions {
  flex: 0 0 auto;
  gap: 8px;
}

body.desktop-d1 .desktop-search,
body.desktop-d1 .icon-btn {
  width: 40px;
  height: 40px;
  border: 1px solid var(--d1-line);
  border-radius: 10px;
  background: #fff;
  display: grid;
  place-items: center;
  color: var(--d1-ink);
  font-size: 18px;
}

body.desktop-d1 .desktop-search:hover,
body.desktop-d1 .icon-btn:hover {
  border-color: #9d9da0;
  background: #f4f4f1;
}

body.desktop-d1 .lang-switch {
  height: 40px;
  min-width: 72px;
  border-color: var(--d1-line);
  border-radius: 10px;
  font-size: 12px;
}

body.desktop-d1 .desktop-quote-btn {
  min-height: 42px;
  padding: 0 17px;
  border: 1px solid var(--d1-ink);
  border-radius: 10px;
  background: var(--d1-ink);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

body.desktop-d1 .desktop-quote-btn:hover {
  background: var(--d1-accent);
  border-color: var(--d1-accent);
}

.d1-hero {
  position: relative;
  overflow: hidden;
  padding: 76px 0 70px;
  background:
    radial-gradient(circle at 83% 14%, rgba(255, 90, 42, .17), transparent 29%),
    linear-gradient(124deg, #0c0d0f 0%, #17191c 58%, #24262a 100%);
  color: #fff;
}

.d1-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,.032) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.032) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: linear-gradient(to right, transparent, #000 45%, #000);
}

.d1-hero .wrap {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(520px, .96fr);
  gap: clamp(48px, 3.5vw, 68px);
  align-items: center;
}

.d1-hero-copy {
  max-width: 760px;
}

.d1-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 20px;
  color: var(--d1-lime);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.d1-eyebrow::before {
  content: "";
  width: 26px;
  height: 2px;
  background: var(--d1-lime);
}

.d1-hero h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(58px, 5vw, 78px);
  line-height: .93;
  letter-spacing: -.02em;
  text-transform: uppercase;
}

.d1-hero h1 span {
  display: block;
  color: #a9aaad;
}

.d1-lead {
  max-width: 720px;
  margin: 28px 0 30px;
  color: #c0c1c4;
  font-size: 17px;
  line-height: 1.72;
}

.d1-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.d1-button {
  min-height: 54px;
  padding: 0 22px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  font-size: 14px;
  font-weight: 800;
}

.d1-button.primary {
  background: var(--d1-accent);
  color: #fff;
}

.d1-button.primary:hover {
  background: var(--d1-accent-dark);
}

.d1-button.secondary {
  border: 1px solid #55575b;
  background: rgba(255,255,255,.03);
  color: #fff;
}

.d1-button.secondary:hover {
  border-color: #fff;
  background: rgba(255,255,255,.08);
}

.d1-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin-top: 42px;
  border-top: 1px solid #36383c;
}

.d1-metrics > div {
  padding: 20px 18px 0 0;
}

.d1-metrics > div + div {
  padding-left: 22px;
  border-left: 1px solid #36383c;
}

.d1-metrics strong,
.d1-metrics span {
  display: block;
}

.d1-metrics strong {
  font-family: var(--font-display);
  font-size: 25px;
  text-transform: uppercase;
}

.d1-metrics span {
  margin-top: 2px;
  color: #929398;
  font-size: 11.5px;
}

.d1-hero-visual {
  position: relative;
  min-height: 500px;
  border: 1px solid #424448;
  border-radius: 24px;
  overflow: hidden;
  background: #25272b;
  box-shadow: 0 38px 90px rgba(0,0,0,.34);
}

.d1-hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10,11,13,.78), transparent 55%);
  pointer-events: none;
}

.d1-hero-visual > img {
  width: 100%;
  height: 100%;
  min-height: 500px;
  object-fit: cover;
  object-position: center;
  filter: saturate(.72) contrast(1.08);
}

.d1-visual-topline,
.d1-price-card,
.d1-material-card {
  position: absolute;
  z-index: 2;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(17,18,20,.82);
  backdrop-filter: blur(14px);
}

.d1-visual-topline {
  top: 18px;
  left: 18px;
  right: 18px;
  padding: 12px 14px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.d1-visual-topline span {
  color: #a9aaad;
}

.d1-visual-topline strong {
  color: var(--d1-lime);
}

.d1-price-card {
  right: 18px;
  bottom: 18px;
  width: 188px;
  padding: 16px;
  border-radius: 14px;
}

.d1-price-card span,
.d1-price-card small,
.d1-price-card strong {
  display: block;
}

.d1-price-card span {
  color: #a9aaad;
  font-size: 10px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.d1-price-card strong {
  margin: 2px 0;
  font: 800 38px var(--font-display);
}

.d1-price-card small {
  color: #bfc0c3;
  font-size: 10px;
}

.d1-material-card {
  left: 18px;
  bottom: 18px;
  padding: 12px 14px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 11px;
}

.d1-material-card .sample {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background:
    repeating-linear-gradient(45deg, #3b3d42 0 5px, #222429 5px 10px);
  border: 1px solid #606268;
}

.d1-material-card strong,
.d1-material-card small {
  display: block;
}

.d1-material-card strong {
  font-size: 11.5px;
}

.d1-material-card small {
  margin-top: 2px;
  color: #a9aaad;
  font-size: 9.5px;
}

.d1-proofbar {
  border-bottom: 1px solid var(--d1-line);
  background: #fff;
}

.d1-proofbar .wrap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.d1-proofbar .wrap > div {
  min-height: 110px;
  padding: 24px 22px;
  display: flex;
  align-items: flex-start;
  gap: 15px;
}

.d1-proofbar .wrap > div + div {
  border-left: 1px solid var(--d1-line);
}

.d1-proofbar span {
  color: var(--d1-accent);
  font: 800 16px var(--font-display);
}

.d1-proofbar strong,
.d1-proofbar small {
  display: block;
}

.d1-proofbar strong {
  font-size: 13px;
}

.d1-proofbar small {
  margin-top: 4px;
  color: var(--d1-muted);
  font-size: 11px;
  line-height: 1.45;
}

/* Designer workspace */
.designer-intro {
  padding: 44px 0 38px;
  border-bottom: 1px solid #303237;
  background:
    radial-gradient(circle at 88% 10%, rgba(255,90,42,.16), transparent 25%),
    #141518;
  color: #fff;
}

.designer-intro .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 50px;
  align-items: end;
}

.designer-back {
  color: #9b9ca0;
  font-size: 12px;
  font-weight: 700;
}

.designer-kicker {
  display: block;
  margin: 18px 0 8px;
  color: var(--d1-lime);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.designer-intro h1 {
  max-width: 940px;
  font-size: clamp(48px, 4vw, 64px);
  line-height: .98;
}

.designer-intro h1 span {
  display: block;
  color: #98999d;
}

.designer-intro p {
  max-width: 880px;
  margin-top: 16px;
  color: #b9babe;
  font-size: 14px;
  line-height: 1.65;
}

.designer-status {
  padding: 17px 18px;
  border: 1px solid #3c3e43;
  border-radius: 13px;
  background: rgba(255,255,255,.035);
}

.designer-status span,
.designer-status strong,
.designer-status small {
  display: block;
}

.designer-status span {
  color: #85868b;
  font-size: 9.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.designer-status strong {
  margin: 5px 0 3px;
  color: var(--d1-lime);
  font-size: 14px;
}

.designer-status small {
  color: #aaa;
  font-size: 10px;
}

body.designer-d1 .cfg-layout {
  grid-template-columns: minmax(0, 1fr) 460px;
  gap: 30px;
  padding-top: 34px;
}

body.designer-d1 .cfg-steps-nav {
  position: sticky;
  top: 94px;
  z-index: 20;
  margin-bottom: 18px;
  padding: 8px;
  border: 1px solid var(--d1-line);
  border-radius: 13px;
  background: rgba(255,255,255,.95);
  box-shadow: 0 8px 25px rgba(20,20,20,.06);
  backdrop-filter: blur(12px);
  flex-wrap: nowrap;
}

body.designer-d1 .cfg-steps-nav .s {
  min-width: 0;
  padding: 10px 7px;
  border-color: transparent;
  background: transparent;
  font-size: 11px;
}

body.designer-d1 .cfg-steps-nav .s.done {
  border-color: #c9d6cf;
  background: #eef4f0;
}

body.designer-d1 .cfg-steps-nav .s.now {
  border-color: var(--d1-ink);
  background: var(--d1-ink);
}

body.designer-d1 .cfg-panel {
  margin-bottom: 16px;
  padding: 28px;
  border-color: #d8d8d4;
  border-radius: 15px;
  box-shadow: 0 8px 22px rgba(20,20,20,.035);
}

body.designer-d1 .cfg-panel h3 {
  font-size: 23px;
  letter-spacing: .01em;
}

body.designer-d1 .cfg-panel .desc {
  max-width: 760px;
  margin-top: 4px;
  margin-bottom: 20px;
  font-size: 13px;
  line-height: 1.6;
}

body.designer-d1 .opt-card {
  min-height: 112px;
  padding: 15px;
  border-width: 1px;
  border-color: #d7d7d3;
  border-radius: 11px;
}

body.designer-d1 .opt-card:hover {
  border-color: #77797d;
  box-shadow: 0 7px 18px rgba(20,20,20,.06);
}

body.designer-d1 .opt-card.sel {
  border: 2px solid var(--d1-ink);
  background: #f0efea;
  box-shadow: inset 4px 0 0 var(--d1-accent);
}

body.designer-d1 .opt-card b {
  font-size: 13px;
}

body.designer-d1 .opt-card span {
  font-size: 11.5px;
  line-height: 1.45;
}

body.designer-d1 .field input {
  min-height: 48px;
  border-color: #cfcfca;
  border-radius: 10px;
}

body.designer-d1 .cfg-summary {
  top: 96px;
  border-color: #c9c9c5;
  border-radius: 17px;
  box-shadow: 0 26px 60px rgba(22,23,25,.16);
}

body.designer-d1 .cfg-summary .preview {
  padding: 20px 24px;
  background:
    linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px),
    #1a1c20;
  background-size: 24px 24px;
}

body.designer-d1 .cfg-preview-case {
  width: 88%;
  aspect-ratio: 16 / 9;
  border-color: #777980;
  box-shadow: 0 24px 40px rgba(0,0,0,.25);
}

body.designer-d1 .sum-body {
  padding: 18px 24px 22px;
}

body.designer-d1 .sum-total .val {
  color: var(--d1-accent);
  font-size: 46px;
}

body.designer-d1 .cfg-summary .btn {
  min-height: 48px;
  border-radius: 10px;
}

body.designer-d1 .cfg-summary .btn-primary {
  background: var(--d1-ink);
}

body.designer-d1 .cfg-summary .btn-primary:hover {
  background: var(--d1-accent);
}

body.designer-d1 .inline-cta {
  border-radius: 15px;
  background: var(--d1-ink);
}

/* Desktop IM */
body.desktop-d1 .im-launcher {
  display: none;
}

body.desktop-d1 .im-launcher b {
  font-size: 13.5px;
}

body.desktop-d1 .im-launcher small {
  font-size: 10px;
}

body.desktop-d1 .im-panel {
  right: 28px;
  bottom: 24px;
  width: min(420px, calc(100vw - 40px));
  height: min(720px, calc(100vh - 56px));
  max-height: calc(100vh - 56px);
  border-radius: 18px;
  box-shadow: 0 30px 90px rgba(0,0,0,.32);
}

body.desktop-d1 .im-header {
  padding: 17px 18px;
}

body.desktop-d1 .im-avatar {
  width: 42px;
  height: 42px;
}

body.desktop-d1 .im-header strong {
  font-size: 13.5px;
}

body.desktop-d1 .im-context {
  padding: 12px 16px;
}

body.desktop-d1 .im-body {
  padding: 18px;
}

body.desktop-d1 .im-welcome {
  padding: 18px 7px;
}

body.desktop-d1 .im-welcome h3 {
  font-size: 22px;
}

body.desktop-d1 .im-welcome p {
  font-size: 13px;
}

body.desktop-d1 .im-auth {
  padding: 22px 20px;
}

body.desktop-d1 .im-auth h3 {
  font-size: 21px;
}

body.desktop-d1 .im-auth p {
  font-size: 13px;
  line-height: 1.55;
}

body.desktop-d1 .im-auth input,
body.desktop-d1 .im-auth form button {
  min-height: 46px;
}

body.desktop-d1 .im-composer {
  padding: 13px 14px 11px;
}

body.desktop-d1 .im-composer textarea {
  min-height: 46px;
  font-size: 13px;
}

body.desktop-d1 .im-footer.auth-active .im-footer-controls {
  display: none;
}

body.desktop-d1 .im-footer.auth-active {
  justify-content: flex-end;
}

body.desktop-d1 :focus-visible {
  outline: 3px solid rgba(255,90,42,.35);
  outline-offset: 3px;
}

body.desktop-d1 .proto-nav {
  display: none;
}

body.desktop-d1[data-review-locale="zh-CN"] .d1-hero h1,
body.desktop-d1[data-review-locale="zh-CN"] .designer-intro h1 {
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 52px;
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -.045em;
}

@media (min-width: 1025px) and (max-width: 1300px) {
  body.desktop-d1 .wrap {
    padding-inline: 28px;
  }

  body.desktop-d1 header.site .wrap {
    gap: 20px;
  }

  body.desktop-d1 nav.main {
    gap: 17px;
  }

  body.desktop-d1 nav.main a {
    font-size: 12.5px;
  }

  body.desktop-d1 .desktop-search,
  body.desktop-d1 .icon-btn {
    display: none;
  }

  .d1-hero .wrap {
    grid-template-columns: minmax(0, 1.03fr) minmax(430px, .97fr);
    gap: 42px;
  }

  .d1-hero h1 {
    font-size: 60px;
  }

  body.desktop-d1[data-review-locale="zh-CN"] .d1-hero h1,
  body.desktop-d1[data-review-locale="zh-CN"] .designer-intro h1 {
    font-size: 48px;
  }

  body.designer-d1 .cfg-layout {
    grid-template-columns: minmax(0, 1fr) 420px;
  }
}

@media (max-width: 1024px) {
  body.desktop-d1 .wrap {
    padding-inline: 22px;
  }

  body.desktop-d1 .topbar .left span,
  body.desktop-d1 .topbar .right span,
  body.desktop-d1 .topbar .right strong,
  body.desktop-d1 .desktop-search,
  body.desktop-d1 .desktop-quote-btn {
    display: none;
  }

  body.desktop-d1 .head-actions {
    margin-left: auto;
  }

  .d1-hero {
    padding: 54px 0;
  }

  .d1-hero .wrap,
  .designer-intro .wrap {
    grid-template-columns: 1fr;
  }

  .d1-hero-visual {
    min-height: 360px;
  }

  .d1-hero-visual > img {
    min-height: 360px;
  }

  .d1-proofbar .wrap {
    grid-template-columns: repeat(2, 1fr);
  }

  .d1-proofbar .wrap > div:nth-child(3) {
    border-left: 0;
    border-top: 1px solid var(--d1-line);
  }

  .d1-proofbar .wrap > div:nth-child(4) {
    border-top: 1px solid var(--d1-line);
  }

  .designer-status {
    max-width: 260px;
  }

  body.designer-d1 .cfg-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  body.designer-d1 .cfg-summary {
    position: static;
    width: 100%;
  }

  body.designer-d1 .cfg-steps-nav {
    position: static;
    overflow-x: auto;
  }

  body.designer-d1 .cfg-steps-nav .s {
    min-width: 92px;
  }
}

@media (max-width: 720px) {
  body.desktop-d1 .sec-head {
    flex-direction: column;
    align-items: flex-start;
  }

  body.desktop-d1 .sec-head a.more {
    white-space: normal;
  }
}

@media (max-width: 640px) {
  .d1-hero h1,
  .designer-intro h1 {
    font-size: 42px;
  }

  .d1-lead {
    font-size: 14px;
  }

  .d1-metrics {
    grid-template-columns: 1fr;
  }

  .d1-metrics > div + div {
    padding-left: 0;
    border-left: 0;
  }

  .d1-proofbar .wrap {
    grid-template-columns: 1fr;
  }

  .d1-proofbar .wrap > div + div {
    border-left: 0;
    border-top: 1px solid var(--d1-line);
  }

  .d1-material-card {
    display: none;
  }
}
