:root {
  --ink: #20201e;
  --paper: #f8f5f1;
  --white: #fff;
  --green: #496451;
  --green-soft: #f3f6f3;
  --green-soft-hover: #edf1ed;
  --sand: #dacec4;
  --line: #ded8d1;
  --muted: #6e6b67;
  --rose: #947061;
  --font: Manrope, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --display: "Iowan Old Style", Baskerville, Georgia, serif;
  --mono: var(--font);
  --action-height: 52px;
  --icon-size: 36px;
  --section-rhythm: 24px;
  --control-radius: 6px;
  --card-radius: 8px;
  --label-size: 10px;
  --meta-size: 12px;
  --body-size: 13px;
  --label-tracking: .06em;
  --motion-ease: cubic-bezier(.22, 1, .36, 1);
  --motion-accordion: .42s var(--motion-ease);
  --motion-sheet: .4s var(--motion-ease);
  --motion-screen: .42s var(--motion-ease);
  --motion-fade: .28s ease;
  --nav-bg: #1a1d1b;
  --nav-bg-soft: #222623;
  --nav-ink: #f1eee8;
  --nav-muted: #9b9891;
  --nav-line: rgba(241, 238, 232, .12);
  --nav-accent: #8aa58f;
  --nav-accent-soft: rgba(138, 165, 143, .16);
  --nav-accent-strong: rgba(138, 165, 143, .28);
  interpolate-size: allow-keywords;
}

.deal-modal[hidden] { display: none; }
.deal-modal {
  position: fixed;
  z-index: 50;
  inset: 0;
  bottom: var(--keyboard-inset, 0px);
  display: grid;
  align-items: end;
  background: rgba(32, 32, 30, .3);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity var(--motion-fade), visibility var(--motion-fade);
}
.deal-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.deal-modal.is-closing {
  opacity: 0;
  visibility: visible;
  pointer-events: none;
}
.deal-modal__backdrop { position: absolute; inset: 0; }
.deal-modal__panel {
  position: relative;
  display: grid;
  gap: 22px;
  width: 100%;
  max-width: none;
  max-height: min(92dvh, 100%);
  margin: 0;
  padding: 22px 18px max(22px, env(safe-area-inset-bottom));
  overflow: auto;
  -webkit-overflow-scrolling: touch;
  background: var(--paper);
  box-shadow: 0 -12px 36px rgba(32, 32, 30, .16);
  box-sizing: border-box;
  transform: translate3d(0, 108%, 0);
  transition: transform var(--motion-sheet);
  will-change: transform;
}
.deal-modal.is-open .deal-modal__panel {
  transform: translate3d(0, 0, 0);
}
.deal-modal.is-closing .deal-modal__panel {
  transform: translate3d(0, 108%, 0);
}
html.is-keyboard-open .deal-modal__panel {
  padding-bottom: 16px;
  max-height: 100%;
}
.deal-modal__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.deal-modal__head .eyebrow { margin-bottom: 5px; }
.deal-modal__head h2 {
  margin: 0;
  color: var(--ink);
  font-family: var(--display, Georgia, serif);
  font-size: clamp(22px, 5vw, 28px);
  font-weight: 500;
  letter-spacing: -.035em;
  line-height: 1.1;
}
.deal-modal__head .icon-button { flex: 0 0 36px; }
.existing-client-state { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 4px; background: var(--cream); }
.existing-client-state > i { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--green); color: #fff; font-size: 20px; }
.existing-client-state strong { display: block; margin-bottom: 3px; }
.existing-client-state p, .muted { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.45; }
.deal-form { display: grid; gap: 16px; }
.deal-form label.field-label { display: block; }
.deal-form .field-label + .text-input,
.deal-form .field-label + .phone-input { margin-top: -10px; }
.deal-form .step-footer--stack {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: 8px;
  padding-top: 16px;
  border-top: .5px solid var(--line);
}
.deal-form .step-footer--stack > .button {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 0;
  grid-column: 1 / -1;
}

* { box-sizing: border-box; }
html {
  width: 100%;
  max-width: 100%;
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
  touch-action: manipulation;
  -ms-touch-action: manipulation;
}
body {
  margin: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
  background: #ebe5df;
  color: var(--ink);
  font: 16px/1.35 var(--font);
}
.app-shell {
  position: relative;
  left: 0;
  width: 100%;
  height: 100dvh;
  max-height: 100dvh;
  max-width: 540px;
  margin: 0 auto;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  background: var(--paper);
}
.app-shell.admin-shell {
  height: 100dvh;
  max-height: 100dvh;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.screen {
  --screen-pad-x: 18px;
  --screen-pad-top: 20px;
  --bottom-nav-pad: 10px;
  --bottom-nav-gap: 8px;
  --bottom-nav-action: 48px;
  --bottom-nav-height: calc(var(--bottom-nav-pad) + var(--bottom-nav-action) + max(10px, env(safe-area-inset-bottom)));
  display: none;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 100%;
  padding: var(--screen-pad-top) var(--screen-pad-x) 0;
}
.screen.is-active {
  display: flex;
  flex-direction: column;
  transform: none;
  animation: screen-enter-fade .28s var(--motion-ease, ease-out) both;
}
.screen.is-active > * {
  max-width: 100%;
  min-width: 0;
}
@keyframes screen-enter-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .screen.is-active {
    animation: none !important;
  }
}

.screen[data-screen="unlock"] {
  justify-content: flex-start;
  gap: 0;
  padding: 42px 20px 34px;
  background: var(--paper);
  overflow-x: hidden;
}
.success-screen {
  justify-content: flex-start;
  gap: 0;
  background: var(--paper);
}
.brand { margin: 0; color: var(--green); font-size: 19px; font-weight: 800; letter-spacing: .28em; }
.brand--small { font-size: 14px; }
.eyebrow { margin: 0 0 8px; color: var(--green); font-family: var(--mono); font-size: var(--label-size); font-weight: 700; letter-spacing: var(--label-tracking); text-transform: uppercase; }
.lockup { margin-top: 4dvh; }
.lockup .brand { margin-bottom: 84px; }
.lockup h1, .screen-heading h1, .screen-heading h2, .success-screen h1 { margin: 0; font-size: 48px; font-weight: 650; letter-spacing: -.06em; line-height: .94; }
.intro, .screen-heading p { max-width: 34ch; margin: 22px 0 0; color: var(--muted); }
.screen-heading { margin: 36px 0 28px; }
.screen-heading--compact { margin: 28px 0 22px; }
.screen-heading--compact h1, .screen-heading--compact h2 { font-size: 34px; }

label { display: block; font-size: 13px; font-weight: 800; }
.pin-form, .search-form { display: grid; gap: 10px; width: 100%; max-width: 100%; min-width: 0; }
input, select { width: 100%; border: 1px solid var(--line); border-radius: 0; background: var(--white); color: var(--ink); font: inherit; }
input { padding: 16px; }
.pin-form {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  gap: 16px;
  margin-top: 36px;
}
.pin-form__field { display: grid; gap: 6px; min-width: 0; }
.pin-form__field label { font-size: 12px; font-weight: 700; letter-spacing: .02em; color: var(--muted); }
.pin-form input {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 10px 12px;
  font-size: 16px;
  letter-spacing: normal;
  text-align: left;
}
.pin-form input:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 1px #496451;
}
.pin-form .field-error { margin-top: -4px; }
.pin-form .button { margin-top: 4px; width: 100%; max-width: 100%; }
.search-form .field-label + .phone-input { margin-top: -4px; }
.field-note { margin: 0; color: var(--muted); font-size: 12px; }
.field-error { margin: 0; color: #a73b33; font-size: 12px; font-weight: 600; }
.field-error--banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid #e0b4b0;
  border-radius: 6px;
  background: #faf0ee;
  color: #8f2a28;
  font-size: 13px;
  line-height: 1.4;
}
.field-error--banner[hidden] { display: none !important; }
.field-error--banner > i { flex: 0 0 auto; margin-top: 1px; font-size: 18px; line-height: 1; color: #b33a35; }
.field-error__body { display: grid; gap: 2px; min-width: 0; }
.field-error__body strong { font-size: 13px; font-weight: 700; letter-spacing: -.01em; }
.field-error__body p { margin: 0; color: #9a4a46; font-size: 12px; font-weight: 500; line-height: 1.45; }
.phone-input.is-invalid { border-color: #c75a54; }
.phone-input.is-invalid:focus-within { box-shadow: inset 0 0 0 1px #c75a54; }
.text-input.is-invalid { border-color: #c75a54; }
.text-input.is-invalid:focus-within { box-shadow: inset 0 0 0 1px #c75a54; }
.field-label .req,
.passport-form--table .req { color: #b33a35; font-weight: 700; }

.app-busy {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  min-height: 100dvh;
  padding: 24px;
  background: rgba(32, 32, 30, .38);
  backdrop-filter: blur(2px);
}
.app-shell.is-busy {
  overflow: hidden;
  touch-action: none;
}
.app-busy[hidden] { display: none !important; }
.app-busy__card {
  display: grid;
  justify-items: center;
  gap: 14px;
  min-width: min(240px, 100%);
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: 0 16px 40px rgba(32, 32, 30, .18);
}
.app-busy__spinner {
  width: 28px;
  height: 28px;
  border: 2px solid color-mix(in srgb, var(--green) 25%, transparent);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: app-busy-spin .7s linear infinite;
}
.app-busy__label {
  margin: 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .01em;
  text-align: center;
}
.app-notice {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 45;
  display: flex;
  align-items: center;
  gap: 10px;
  width: min(430px, calc(100vw - 32px));
  padding: 12px 12px 12px 14px;
  border: .5px solid #d7aaa4;
  border-radius: 12px;
  background: #fffaf9;
  box-shadow: 0 12px 32px rgba(32, 32, 30, .16);
  color: #8f413c;
}
.app-notice[hidden] { display: none !important; }
.app-notice > i { flex: 0 0 auto; font-size: 19px; }
.app-notice p { flex: 1 1 auto; margin: 0; font-size: 13px; font-weight: 600; line-height: 1.4; }
.app-notice__action { min-height: 34px; padding: 0 10px; border: .5px solid currentColor; border-radius: 8px; background: transparent; color: inherit; font: 700 12px/1 var(--font); cursor: pointer; }
.app-notice__dismiss { display: inline-grid; flex: 0 0 auto; place-items: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 8px; background: transparent; color: inherit; cursor: pointer; }
.app-notice__dismiss:hover, .app-notice__action:hover { background: rgba(143, 65, 60, .08); }
.app-notice[data-tone="info"] { border-color: color-mix(in srgb, var(--green) 35%, var(--line)); background: var(--green-soft); color: var(--green); }
@keyframes app-busy-spin {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .app-busy__spinner { animation: none; border-top-color: var(--green); opacity: .85; }
}

.field-label {
  display: block;
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .02em;
}
.search-form .field-label { margin-bottom: 0; }
.search-form .field-note { margin-top: -2px; }
.deal-form .field-label { margin: 0; }
.deal-form .text-input,
.deal-form .phone-input { margin-top: 0; }
.text-input {
  display: flex;
  align-items: stretch;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 48px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--control-radius, 6px);
  background: var(--white);
}
.text-input input {
  flex: 1 1 auto;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 0;
  border: 0;
  border-radius: 0;
  padding: 12px 14px;
  background: transparent;
  font-size: 16px;
  outline: none;
}
.text-input input:focus-visible { outline: none; }
.text-input:focus-within {
  outline: none;
  box-shadow: inset 0 0 0 1px #496451;
}

.button { min-height: var(--action-height); border: .5px solid var(--line); padding: 0 16px; border-radius: var(--control-radius); font: 600 var(--body-size)/1.2 var(--font); letter-spacing: .01em; cursor: pointer; }
.button--primary { background: var(--green); color: #fff; border-color: var(--green); }
.button--quiet { margin-top: 12px; background: var(--white); color: var(--green); }
.text-button { margin-top: 18px; border: 0; padding: 0; background: none; color: var(--rose); font: 800 13px var(--font); text-align: left; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }
button:active { transform: scale(.985); }
button:focus-visible, input:focus-visible { outline: 1px solid #496451; outline-offset: 1px; }

.topbar { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; min-height: 36px; max-width: 100%; min-width: 0; padding-bottom: 10px; gap: 8px; }
.topbar--admin { grid-template-columns: 36px 1fr auto 36px; column-gap: 10px; }
.topbar--shell { grid-template-columns: 36px minmax(0, 1fr) auto; column-gap: 8px; }
.topbar-actions { display: inline-flex; align-items: center; gap: 4px; justify-self: end; }
.shell-drawer {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}
.shell-drawer[hidden] { display: none !important; }
.shell-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(18, 20, 19, .55);
  opacity: 0;
  transition: opacity var(--motion-fade);
}
.shell-drawer:not([hidden]) .shell-drawer__backdrop { opacity: 1; }
.app-nav-panel {
  --nav-local-line: var(--nav-line);
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(300px, 86vw);
  height: 100%;
  padding: max(14px, env(safe-area-inset-top)) 12px max(18px, env(safe-area-inset-bottom));
  border-right: 1px solid var(--nav-local-line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .03), transparent 28%),
    var(--nav-bg);
  color: var(--nav-ink);
  box-shadow:
    inset 1px 0 0 rgba(255, 255, 255, .04),
    12px 0 36px rgba(12, 14, 13, .28);
}
.shell-drawer__panel.app-nav-panel {
  transform: translateX(-12px);
  opacity: .92;
  transition: transform var(--motion-sheet), opacity var(--motion-fade);
}
.shell-drawer:not([hidden]) .shell-drawer__panel.app-nav-panel {
  transform: translateX(0);
  opacity: 1;
}
.app-nav-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 40px;
  margin-bottom: 8px;
  padding: 0 6px 12px;
  border-bottom: 1px solid var(--nav-local-line);
}
.app-nav-panel__logo {
  margin: 0;
  filter: brightness(0) invert(1);
  opacity: .92;
}
.app-nav-panel__close {
  border-color: var(--nav-local-line);
  background: var(--nav-bg-soft);
  color: var(--nav-ink);
}
.app-nav-panel__close:hover,
.app-nav-panel__close:focus-visible {
  border-color: color-mix(in srgb, var(--nav-accent) 45%, var(--nav-local-line));
  background: var(--nav-accent-soft);
  color: var(--nav-ink);
  outline: 1px solid color-mix(in srgb, var(--nav-accent) 40%, transparent);
  outline-offset: 0;
}
.app-nav-panel__nav {
  display: grid;
  gap: 4px;
}
.app-nav-panel__group {
  margin: 14px 0 4px;
  padding: 0 12px;
  color: var(--nav-muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.app-nav-panel__group:first-child { margin-top: 2px; }
.app-nav-panel__link {
  display: grid;
  grid-template-columns: 22px 1fr;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--nav-ink);
  font: 650 14px/1.2 var(--font);
  text-decoration: none;
  text-align: left;
  cursor: pointer;
  transition:
    background .22s var(--motion-ease),
    border-color .22s var(--motion-ease),
    color .22s var(--motion-ease),
    transform .18s var(--motion-ease);
}
.app-nav-panel__link i {
  font-size: 17px;
  color: var(--nav-accent);
  transition: color .22s var(--motion-ease);
}
.app-nav-panel__link:hover,
.app-nav-panel__link:focus-visible {
  border-color: color-mix(in srgb, var(--nav-accent) 35%, transparent);
  background: var(--nav-accent-soft);
  outline: 1px solid color-mix(in srgb, var(--nav-accent) 28%, transparent);
  outline-offset: 0;
}
.app-nav-panel__link:active {
  transform: scale(.985);
}
.app-nav-panel__link.is-current,
.app-nav-panel__link[aria-current="page"] {
  border-color: color-mix(in srgb, var(--nav-accent) 42%, transparent);
  background: var(--nav-accent-strong);
}
.app-nav-panel__link.is-current i,
.app-nav-panel__link[aria-current="page"] i,
.app-nav-panel__link:hover i,
.app-nav-panel__link:focus-visible i {
  color: color-mix(in srgb, var(--nav-accent) 70%, #fff);
}
.app-nav-panel__link[hidden] { display: none !important; }
.shell-drawer__link-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.shell-drawer__link-title {
  font: inherit;
}
.shell-drawer__link-meta {
  color: var(--nav-muted);
  font: 550 12px/1.25 var(--font);
}
.shell-order-timeline {
  margin: 6px 0 4px;
  padding: 8px 0;
  border-top: 1px solid var(--nav-line);
  border-bottom: 1px solid var(--nav-line);
}
.shell-order-timeline[hidden] { display: none !important; }
.shell-order-timeline .order-timeline__shell {
  margin: 0;
  padding: 4px 0;
}
.shell-order-timeline .order-timeline__track--vertical .order-timeline__step::before {
  background: color-mix(in srgb, var(--nav-muted) 40%, transparent);
}
.shell-order-timeline .order-timeline__track--vertical .order-timeline__step.is-done::before,
.shell-order-timeline .order-timeline__track--vertical .order-timeline__step.is-current::before {
  background: var(--nav-accent);
}
.shell-order-timeline .order-timeline__marker {
  border-color: color-mix(in srgb, var(--nav-accent) 35%, var(--nav-muted));
  background: var(--nav-accent-soft, var(--nav-bg-soft));
  color: var(--nav-accent);
  box-shadow: none;
}
.shell-order-timeline .order-timeline__step.is-done .order-timeline__marker {
  border-color: color-mix(in srgb, var(--nav-accent) 35%, var(--nav-muted));
  background: var(--nav-accent-soft, var(--nav-bg-soft));
  color: var(--nav-accent);
}
.shell-order-timeline .order-timeline__step.is-current .order-timeline__marker {
  border-color: var(--nav-accent);
  background: var(--nav-accent-soft, var(--nav-bg-soft));
  color: var(--nav-accent);
  box-shadow: none;
}
.shell-order-timeline .order-timeline__label {
  background: transparent;
  color: var(--nav-muted);
}
.shell-order-timeline .order-timeline__step.is-done .order-timeline__label {
  color: color-mix(in srgb, var(--nav-accent) 55%, var(--nav-ink));
}
.shell-order-timeline .order-timeline__step.is-current .order-timeline__label {
  color: var(--nav-ink);
  background: var(--nav-accent-soft);
  font-weight: 700;
}
.shell-order-timeline button.order-timeline__label:hover,
.shell-order-timeline button.order-timeline__label:focus-visible,
.shell-order-timeline button.order-timeline__marker:hover,
.shell-order-timeline button.order-timeline__marker:focus-visible {
  color: var(--nav-ink);
}
.shell-menu-icon {
  display: grid;
  gap: 3px;
  width: 16px;
  pointer-events: none;
}
.shell-menu-icon i {
  display: block;
  height: 1.5px;
  border-radius: 1px;
  background: currentColor;
}
.icon-button {
  display: grid;
  place-items: center;
  width: var(--icon-size);
  height: var(--icon-size);
  border: .5px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--green);
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
}
.icon-button--solid { background: var(--green); color: #fff; }
.icon-button--solid i { color: #fff; }
.step-count { color: var(--muted); font-size: 11px; letter-spacing: .08em; }
.phone-input {
  display: flex;
  align-items: stretch;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 48px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--control-radius, 6px);
  background: var(--white);
}
.phone-input span {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  padding: 0 0 0 14px;
  color: var(--ink);
  font-size: 16px;
  font-weight: 400;
  line-height: 1;
}
.phone-input input {
  flex: 1 1 auto;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 0;
  border: 0;
  border-radius: 0;
  padding: 12px 14px 12px 8px;
  background: transparent;
  font-size: 16px;
  outline: none;
}
.phone-input input:focus-visible { outline: none; }
.phone-input:focus-within {
  outline: none;
  box-shadow: inset 0 0 0 1px #496451;
}

.person-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  margin: 0 0 var(--section-rhythm);
  padding: 14px;
  border: .5px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--white);
}
.person-card:has(.crm-link) {
  grid-template-columns: auto minmax(0, 1fr) auto;
}
.person-card:not(:has(.person-card__monogram)):has(.crm-link) {
  grid-template-columns: minmax(0, 1fr) auto;
}
.person-card__monogram, .success-mark { display: grid; place-items: center; background: var(--green); color: #fff; }
.person-card__monogram {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  border-radius: 50%;
  font-family: var(--display);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1;
}
.person-card__details { display: grid; min-width: 0; gap: 4px; }
.person-card h2 {
  margin: 0;
  overflow: hidden;
  color: var(--ink);
  font-family: var(--display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.person-card__contacts {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 2px 10px;
  min-width: 0;
}
.person-card__contacts > p {
  margin: 0;
  color: var(--muted);
  font-size: var(--meta-size);
  font-weight: 500;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.person-card__contacts > p[hidden] { display: none; }
.deal-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
  margin: -8px 0 var(--section-rhythm);
  padding: 16px 18px;
  border: .5px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--white);
}
.deal-card[hidden] { display: none; }
.deal-card__details { display: grid; gap: 6px; min-width: 0; justify-items: start; }
.deal-card__title {
  min-width: 0;
  max-width: 100%;
  margin: 0;
  overflow: hidden;
  color: var(--ink);
  font-family: var(--display);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.deal-card .deal__manager {
  line-height: 1.45;
  white-space: normal;
}
.deal-card__meta {
  display: grid;
  margin-top: 2px;
  gap: 4px;
}
.deal-card > .crm-link {
  align-self: start;
}
.deal-card .deal__manager[hidden],
.deal-card .deal__created[hidden],
.deal-card .deal__status[hidden],
.deal-card .deal__badge[hidden] { display: none; }
.deal-card .deal__top:not(:has(:not([hidden]))) { display: none; }
.deal-list { display: grid; gap: 9px; width: 100%; max-width: 100%; min-width: 0; }
.deal-item {
  position: relative;
  display: grid;
  width: 100%;
  min-width: 0;
}
.deal-item > .deal {
  width: 100%;
  padding-right: 56px;
}
.deal-item > .crm-link {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
}
.deal-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  margin-top: 18px;
  margin-bottom: 18px;
}
.deal-pager[hidden] { display: none; }
.deal-pager__pages {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.deal-pager__link,
.deal-pager__step {
  display: grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 10px;
  border: .5px solid color-mix(in srgb, var(--green) 35%, var(--line));
  border-radius: var(--control-radius);
  background: var(--green-soft);
  color: var(--green);
  font: 800 12px var(--font);
  text-decoration: none;
  cursor: pointer;
}
.deal-pager__link.is-current {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
  cursor: default;
}
.deal-pager__link:hover:not(.is-current),
.deal-pager__step:hover:not(.is-disabled) {
  border-color: var(--green);
  background: var(--green-soft-hover);
}
.deal-pager__link.is-disabled,
.deal-pager__step.is-disabled {
  opacity: .4;
  pointer-events: none;
  cursor: default;
}
.deal-pager__ellipsis {
  display: grid;
  place-items: center;
  min-width: 24px;
  min-height: 44px;
  color: var(--muted);
  font: 800 12px var(--font);
}
.deal-pager__link:focus-visible,
.deal-pager__step:focus-visible {
  outline: 1px solid var(--green);
  outline-offset: 1px;
}
.order-start-list { display: grid; gap: 9px; width: 100%; }
.order-start-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 82px;
  padding: 14px 16px;
  border: .5px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.order-start-card[hidden] { display: none; }
.order-start-card:hover {
  border-color: var(--green);
  background: var(--green-soft);
}
.order-start-card:focus-visible {
  outline: 1px solid var(--green);
  outline-offset: 1px;
}
.order-start-card__icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: .5px solid color-mix(in srgb, var(--green) 25%, var(--line));
  background: var(--green-soft);
  color: var(--green);
}
.order-start-card__icon i { font-size: 18px; line-height: 1; }
.order-start-card__copy { display: grid; gap: 4px; min-width: 0; }
.order-start-card__copy strong {
  color: var(--ink);
  font-family: var(--display);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.2;
}
.order-start-card__copy small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.45;
}
.order-start-card > .hgi-stroke {
  color: var(--green);
  font-size: 18px;
  line-height: 1;
}
.order-template-list { display: grid; gap: 9px; width: 100%; }
.order-template-card { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; min-height: 82px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--white); color: var(--ink); text-align: left; font: inherit; cursor: pointer; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.order-template-card:hover { border-color: var(--green); box-shadow: 0 8px 20px rgba(46, 72, 54, .08); transform: translateY(-1px); }
.order-template-card:focus-visible { outline: 3px solid color-mix(in srgb, var(--green) 42%, transparent); outline-offset: 2px; }
.order-template-card__icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--green-soft); color: var(--green); }
.order-template-card__copy { display: grid; gap: 3px; min-width: 0; }
.order-template-card__copy strong { font-size: 15px; line-height: 1.25; }
.order-template-card__copy small { overflow: hidden; color: var(--muted); font-size: 12px; line-height: 1.35; text-overflow: ellipsis; white-space: nowrap; }
.order-template-card__copy em { color: var(--green); font-size: 12px; font-style: normal; line-height: 1.35; }
.order-template-card > .hgi-stroke { color: var(--muted); font-size: 18px; }
.deal {
  position: relative;
  display: grid;
  gap: 10px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 14px 16px;
  border: .5px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--white);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  overflow-wrap: anywhere;
}
.deal.is-selected {
  border-color: var(--green);
  background: var(--white);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--green) 18%, transparent);
}
.deal--draft {
  border-color: color-mix(in srgb, var(--green) 28%, var(--line));
}
.deal--locked {
  opacity: .72;
  cursor: not-allowed;
}
.deal__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.deal__status,
.deal__badge {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  min-height: 22px;
  padding: 2px 8px;
  border: .5px solid color-mix(in srgb, var(--green) 28%, var(--line));
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .01em;
  text-transform: none;
  line-height: 1.2;
  white-space: nowrap;
}
.deal__status--muted {
  border-color: color-mix(in srgb, var(--rose) 35%, var(--line));
  background: color-mix(in srgb, var(--rose) 10%, var(--white));
  color: var(--rose);
}
.deal__status--alert {
  border-color: color-mix(in srgb, #b42318 30%, var(--line));
  background: color-mix(in srgb, #b42318 9%, var(--white));
  color: #b42318;
}
.deal__badge--ready {
  border-color: color-mix(in srgb, var(--green) 35%, var(--line));
  background: var(--green-soft);
  color: var(--green);
}
.deal__badge--done {
  border-color: color-mix(in srgb, var(--rose) 28%, var(--line));
  background: color-mix(in srgb, var(--rose) 12%, var(--white));
  color: var(--rose);
}
.deal__meta .deal__badge {
  white-space: nowrap;
}
.deal__body {
  display: grid;
  gap: 4px;
  min-width: 0;
}
.deal__title {
  margin: 0;
  color: var(--ink);
  font-family: var(--display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.15;
}
.deal__summary,
.deal__manager {
  color: var(--muted);
  font-size: var(--meta-size);
  font-weight: 500;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.deal__meta {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: var(--meta-size);
  font-weight: 500;
  line-height: 1.3;
}
.deal__created { font-variant-numeric: tabular-nums; }
.deal__check { display: none !important; }

.sticky-action, .selection-bar { position: sticky; bottom: 0; margin-top: auto; }
.product-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.product-card { position: relative; overflow: hidden; padding: 0; border: 1px solid var(--line); background: var(--white); color: var(--ink); text-align: left; cursor: pointer; }
.product-card.is-selected { border: 2px solid var(--green); }.product-card img { display: block; width: 100%; height: 134px; object-fit: cover; background: var(--sand); }
.product-card__body { display: grid; gap: 8px; padding: 10px; }.product-card__body strong { font-size: 14px; }.product-card__body small { color: var(--muted); font-size: 11px; }
.product-card__select { position: absolute; top: 8px; right: 8px; display: none; place-items: center; width: 24px; height: 24px; background: var(--green); color: #fff; font-size: 13px; }.product-card.is-selected .product-card__select { display: grid; }
.selection-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 0 0; background: var(--paper); }.selection-bar span { font-size: 13px; font-weight: 800; }.selection-bar .button { min-width: 0; }

.product-tabs { display: grid; gap: 7px; padding-bottom: 12px; }.product-tab { min-height: 44px; border: 1px solid var(--line); padding: 9px 12px; background: transparent; color: var(--muted); font: 800 11px var(--font); cursor: pointer; text-align: left; }.product-tab.is-active { border-color: var(--green); background: var(--green); color: #fff; }
.config-tools { margin-bottom: 12px; }.fit-button { display: grid; grid-template-columns: 1fr auto; gap: 2px; width: 100%; padding: 14px; border: 1px solid var(--line); background: var(--white); color: var(--ink); text-align: left; cursor: pointer; }.fit-button span { font-size: 14px; font-weight: 800; }.fit-button small { grid-column: 1; color: var(--muted); font-size: 11px; }.fit-button b { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-size: 20px; font-weight: 400; }
.fit-panel { display: grid; gap: 12px; padding: 14px; border: 1px solid var(--line); border-top: 0; background: #eee6dc; }.fit-panel__label { margin: 0; color: var(--rose); font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }.fit-fields { display: grid; gap: 7px; }.fit-section { border: 1px solid var(--line); background: var(--white); }.fit-section > summary { position: relative; display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 12px 34px 12px 12px; font-size: 13px; font-weight: 800; cursor: pointer; list-style: none; }.fit-section > summary::-webkit-details-marker, .fit-field summary::-webkit-details-marker { display: none; }.fit-section > summary::after { position: absolute; right: 12px; content: '+'; font-size: 17px; font-weight: 400; }.fit-section[open] > summary::after { content: '−'; }.fit-section > summary small, .fit-field summary small { color: var(--muted); font-size: 10px; font-weight: 600; }.fit-section > div { display: grid; gap: 7px; padding: 0 9px 9px; }.fit-field { border: 1px solid var(--line); background: var(--paper); }.fit-field summary { position: relative; display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 11px 34px 11px 11px; font-size: 12px; font-weight: 800; cursor: pointer; list-style: none; }.fit-field summary::after { position: absolute; right: 11px; content: '+'; font-size: 17px; font-weight: 400; }.fit-field[open] summary::after { content: '−'; }.fit-field select { width: calc(100% - 22px); margin: 0 11px 11px; padding: 10px; font-size: 13px; }
.config-groups { display: grid; gap: 7px; }.config-group { border: 1px solid var(--line); background: var(--white); }.config-group__head { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 14px; border: 0; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }.config-group__head span { display: grid; gap: 3px; }.config-group__head strong { font-size: 14px; }.config-group__head small { color: var(--muted); font-size: 11px; }.config-group__head b { font-size: 22px; font-weight: 400; }
.option-strip { display: flex; gap: 8px; overflow-x: auto; padding: 0 14px 14px; scrollbar-width: none; }.option-card { flex: 0 0 116px; overflow: hidden; padding: 0; border: 1px solid var(--line); background: var(--white); color: var(--ink); text-align: left; cursor: pointer; }.option-card.is-selected { border: 2px solid var(--green); }.option-card img { display: block; width: 100%; height: 78px; object-fit: cover; }.option-card span { display: block; padding: 7px; font-size: 10px; line-height: 1.2; }
.config-intro { margin: 0 0 14px; color: var(--muted); font-size: 14px; line-height: 1.45; }.config-steps { display: grid; gap: 9px; }.config-step { display: grid; grid-template-columns: 42px 1fr auto; align-items: center; gap: 12px; min-height: 80px; padding: 14px; border: 1px solid var(--line); background: var(--white); color: var(--ink); text-align: left; cursor: pointer; }.config-step__number { display: grid; place-items: center; width: 34px; height: 34px; background: var(--sand); color: var(--green); font-size: 13px; font-weight: 800; }.config-step span:not(.config-step__number) { display: grid; gap: 3px; }.config-step strong { font-size: 15px; }.config-step small { color: var(--muted); font-size: 11px; }.config-step > b { color: var(--green); font-size: 18px; }.section-back { width: max-content; min-height: 44px; margin-bottom: 4px; border: 0; padding: 0; background: transparent; color: var(--green); font: 800 13px var(--font); cursor: pointer; }.option-list { display: grid; gap: 7px; padding: 0 14px 14px; }.option-choice { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; border: 1px solid var(--line); padding: 11px; background: var(--paper); color: var(--ink); text-align: left; font: 600 13px/1.3 var(--font); cursor: pointer; }.option-choice.is-selected { border-color: var(--green); background: #edf1ed; }.option-choice b { color: var(--green); font-size: 10px; white-space: nowrap; }
.summary-list { display: grid; gap: 16px; margin-top: 22px; }.summary-product { padding-bottom: 15px; border-bottom: 1px solid var(--line); }.summary-product > .summary-product__head { display: flex; align-items: center; gap: 10px; }.summary-product img { width: 45px; height: 45px; object-fit: cover; }.summary-product h2 { margin: 0; font-size: 20px; }.summary-product dl { display: grid; gap: 8px; margin: 12px 0 0; }.summary-product dl div { display: flex; justify-content: space-between; gap: 16px; font-size: 12px; }.summary-product dt { color: var(--muted); }.summary-product dd { margin: 0; text-align: right; font-weight: 800; }.button--send { margin-top: 26px; }
.success-screen { align-items: stretch; }

/* Configuration uses one table pattern everywhere: no hidden choice drawer per row. */
.config-tools { margin: 0 0 12px; }
.measurements-list { display: grid; gap: 12px; }
.fit-master {
  display: grid;
  gap: 6px;
  margin: 0 0 8px;
  padding: 14px 16px;
  border: .5px solid var(--line);
  border-radius: 8px;
  background: #fbfbfa;
}
.fit-master__label {
  color: var(--ink);
  font-size: var(--meta-size);
  font-weight: 600;
}
.fit-master__input {
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: var(--control-radius, 6px);
  background: var(--white);
  color: var(--ink);
  font-size: var(--body-size);
  outline: none;
}
.fit-master__input:focus {
  box-shadow: inset 0 0 0 1px #496451;
}
.fit-panel, .config-accordion, .summary-accordion { border: 1px solid var(--line); background: var(--white); }
.measurements-list .fit-panel {
  display: block;
  gap: unset;
  padding: 0;
  overflow: clip;
}
.fit-panel > summary, .config-accordion > summary, .summary-accordion > summary { display: flex; align-items: center; justify-content: space-between; min-height: 58px; padding: 12px 14px; cursor: pointer; list-style: none; }
.fit-panel > summary::-webkit-details-marker, .config-accordion > summary::-webkit-details-marker, .summary-accordion > summary::-webkit-details-marker { display: none; }
.fit-panel > summary span, .config-accordion > summary span { display: grid; gap: 3px; }
.fit-panel > summary strong, .config-accordion > summary strong, .summary-accordion > summary strong { font-size: 16px; line-height: 1.2; }
.fit-panel > summary small, .config-accordion > summary small, .summary-accordion > summary small { color: var(--muted); font-size: 12px; }
.fit-panel > summary i, .config-accordion > summary i, .summary-accordion > summary > i { color: var(--green); font-size: 21px; font-weight: 400; line-height: 1; }
.fit-panel[open] > summary i, .config-accordion[open] > summary i { transform: none; }
.fit-fields { display: grid; gap: 8px; padding: 0 8px 8px; }
.fit-section { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: var(--paper); }
.fit-section > summary { display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 10px 12px; cursor: pointer; list-style: none; }
.fit-section > summary::-webkit-details-marker { display: none; }
.fit-section > summary::marker { content: ''; }
.fit-section > summary::after,
.fit-section[open] > summary::after,
.fit-field summary::after,
.fit-field[open] summary::after { content: none !important; }
.fit-section > summary span { display: grid; gap: 2px; }.fit-section > summary strong { font-size: 14px; }.fit-section > summary small { color: var(--muted); font-size: 12px; }
.fit-section > summary i,
.fit-panel > summary i,
.config-accordion > summary i,
.summary-accordion > summary > i {
  display: inline-flex;
  flex: 0 0 22px;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  overflow: visible;
  color: var(--green);
  font-size: 18px;
  font-weight: 400;
  font-style: normal;
  line-height: 1;
}
.fit-section[open] > summary i,
.fit-panel[open] > summary i,
.config-accordion[open] > summary i,
.summary-accordion[open] > summary i { transform: none; }
.config-table-wrap { overflow-x: auto; border-top: 1px solid var(--line); }
.config-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.config-table th, .config-table td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.config-table tr:last-child th, .config-table tr:last-child td { border-bottom: 0; }
.config-table th { width: 43%; color: var(--muted); font-size: 13px; font-weight: 600; line-height: 1.3; }
.config-table td { width: 57%; color: var(--ink); font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.config-table select {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  min-height: 40px;
  height: 40px;
  padding: 8px 38px 8px 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: var(--ink);
  font: 400 13px / 1.2 var(--font);
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}
.config-table select::-ms-expand { display: none; }
.config-text-input {
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--ink);
  font: 400 13px/1.2 var(--font);
}
.config-text-input:focus {
  outline: 1px solid var(--green);
  outline-offset: 0;
}
.summary-product { display: grid; gap: 8px; padding-bottom: 18px; }
.summary-product__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.summary-edit { cursor: pointer; }
.summary-accordion summary { color: var(--ink); }
.empty-state { display: grid; gap: 8px; padding: 18px; border: 1px dashed #bdb2a8; background: #f2ede7; color: var(--ink); }.empty-state strong { font-size: 15px; }.empty-state span { color: var(--muted); font-size: 13px; line-height: 1.45; }
.button:disabled { cursor: not-allowed; opacity: .45; transform: none; }
.field-error[hidden] { display: none; }

/* Keep supporting copy readable on a phone; values no longer overpower labels. */
.product-card__body small, .config-step small, .deal small { font-size: 12px; }
.summary-product dd { font-size: 13px; font-weight: 600; }
@media (min-width:700px) {
  body { padding: 24px; }
  .app-shell:not(.admin-shell) {
    /* iPad portrait — не растягивать конфигуратор на весь десктоп */
    max-width: 768px;
    width: 100%;
    height: calc(100dvh - 48px);
    max-height: calc(100dvh - 48px);
  }
  .app-shell.admin-shell {
    height: calc(100dvh - 48px);
    max-height: calc(100dvh - 48px);
  }
  .product-grid { grid-template-columns: repeat(3,1fr); }
  .product-card img { height: 146px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation-duration: 1ms !important;
  }
  .deal-modal__panel {
    transform: none !important;
  }
}

/* Accordion open/close: native ::details-content только где есть interpolate-size (Chromium).
   На iOS Safari — JS-анимация высоты в bindAccordionIcons. */
@supports (interpolate-size: allow-keywords) {
  details::details-content {
    block-size: 0;
    opacity: 0;
    overflow: clip;
    transition:
      block-size var(--motion-accordion),
      opacity .3s ease,
      content-visibility var(--motion-accordion) allow-discrete;
  }
  details[open]::details-content {
    block-size: auto;
    opacity: 1;
  }
  details.config-accordion::details-content,
  details.summary-accordion::details-content,
  details.summary-product--panel::details-content,
  details.fit-panel::details-content,
  details.fit-section::details-content {
    transition:
      block-size var(--motion-accordion),
      opacity .32s var(--motion-ease),
      content-visibility var(--motion-accordion) allow-discrete;
  }
  details.fit-panel::details-content,
  details.fit-section::details-content,
  details.summary-product--panel::details-content {
    block-size: 0;
    opacity: 0;
    overflow: clip;
  }
  details.fit-panel[open]::details-content,
  details.fit-section[open]::details-content,
  details.summary-product--panel[open]::details-content {
    block-size: auto;
    opacity: 1;
  }
  details.fit-panel[open].is-picking::details-content,
  details.fit-section[open].is-picking::details-content,
  details.fit-panel[open]:has(.select-combobox.is-open)::details-content,
  details.fit-section[open]:has(.select-combobox.is-open)::details-content,
  details[open].is-picking::details-content,
  details.fabric-panel[open].is-picking::details-content,
  details[open]:has(.select-combobox.is-open)::details-content {
    overflow: visible;
  }
}

details > summary > i,
.fit-panel > summary > i,
.config-accordion > summary > i,
.summary-accordion > summary > i,
.passport-panel > summary > i,
.summary-product--panel > summary > i,
.product-tab-set--bundle > summary > i {
  transition: transform .28s var(--motion-ease), opacity .2s ease;
  transform-origin: center;
}
details.is-toggling > summary > i {
  animation: accordion-icon-pop .28s var(--motion-ease);
}
@keyframes accordion-icon-pop {
  0% { transform: scale(.72); opacity: .45; }
  60% { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

/* Premium utilitarian minimalism: a quiet document surface rather than a generic app shell. */
:root {
  --ink: #20201e;
  --paper: #f8f5f1;
  --white: #ffffff;
  --green: #496451;
  --green-soft: #f3f6f3;
  --green-soft-hover: #edf1ed;
  --sand: #dacec4;
  --line: #ded8d1;
  --muted: #6e6b67;
  --rose: #947061;
  --font: Manrope, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --display: "Iowan Old Style", Baskerville, Georgia, serif;
  --mono: var(--font);
  --action-height: 52px;
  --icon-size: 36px;
  --section-rhythm: 24px;
  --control-radius: 6px;
  --card-radius: 8px;
  --label-size: 10px;
  --meta-size: 12px;
  --body-size: 13px;
  --label-tracking: .06em;
}

body { background: #ebe5df; color: var(--ink); font: 16px/1.6 var(--font); }
.app-shell { background: var(--paper); }
.screen { --screen-pad-x: 20px; --screen-pad-top: 24px; padding: var(--screen-pad-top) var(--screen-pad-x) 0; }
.screen[data-screen="unlock"],
.success-screen,
.screen[data-screen="success"] {
  --bottom-nav-height: 0px;
  padding-bottom: max(24px, env(safe-area-inset-bottom));
  background: var(--paper);
}
.brand { color: var(--ink); font-family: var(--mono); font-size: var(--body-size); font-weight: 700; letter-spacing: .16em; }
.brand--small { font-size: var(--meta-size); }
.brand-logo { display: block; width: 76px; height: auto; max-height: 20px; object-fit: contain; object-position: left center; }
.brand-logo--hero { width: 100px; max-height: 25px; margin-bottom: 68px; }
.eyebrow, .step-count, .summary-product__eyebrow, .product-switcher-label, .staff-role {
  color: var(--green);
  font-family: var(--mono);
  font-size: var(--label-size);
  font-weight: 700;
  letter-spacing: var(--label-tracking);
  text-transform: uppercase;
}
.step-count { color: var(--muted); text-transform: none; letter-spacing: .08em; font-weight: 600; }
.lockup .brand { margin-bottom: 68px; }
.lockup h1, .screen-heading h1, .screen-heading h2, .success-screen h1 { color: var(--ink); font-family: var(--display); font-size: 48px; font-weight: 500; letter-spacing: -.045em; line-height: .98; }
.screen-heading--compact h1, .screen-heading--compact h2 { font-size: clamp(24px, 5.5vw, 28px); }
.intro, .screen-heading p { color: var(--muted); line-height: 1.55; }
.button { min-height: var(--action-height); border-radius: var(--control-radius); font-size: var(--body-size); font-weight: 600; letter-spacing: .01em; transition: background-color .2s ease, transform .2s ease; }
.button--primary { background: var(--green); }.button--primary:hover { background: #3e5747; }
.button--green { background: var(--green); }.button--green:hover { background: #3e5747; }
.button--search { justify-content: center; gap: 9px; }.button--search i { font-size: 18px; line-height: 1; }
.button--quiet { border-color: var(--line); background: var(--white); color: var(--green); }.text-button { color: var(--ink); }
.button--create-client { display: flex; align-items: center; justify-content: center; gap: 9px; width: 100%; margin-top: 12px; color: var(--green); text-align: center; border-color: color-mix(in srgb, var(--green) 35%, var(--line)); background: var(--green-soft); }
.button-icon { font-size: 18px; line-height: 1; }
.icon-button { display: grid; place-items: center; }.icon-button i { font-size: 16px; }.topbar { border-bottom: 1px solid var(--line); }
.sticky-action, .selection-bar { border-top: .5px solid var(--line); }
.selection-bar { padding-top: 14px; }
.person-card__monogram { background: var(--green); border-radius: 50%; }
.success-mark { background: var(--ink); border-radius: var(--card-radius); }
.crm-link {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: var(--icon-size);
  height: var(--icon-size);
  flex: 0 0 var(--icon-size);
  margin-left: 0;
  border: .5px solid color-mix(in srgb, var(--green) 35%, var(--line));
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  text-decoration: none;
  transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
}
.crm-link:hover { border-color: var(--green); background: var(--green-soft-hover); }
.crm-link:focus-visible { outline: 1px solid var(--green); outline-offset: 1px; }
.crm-link[data-tooltip]::after,
.crm-link[data-tooltip]::before {
  position: absolute;
  z-index: 8;
  opacity: 0;
  pointer-events: none;
  transition: opacity .12s ease, transform .12s ease;
}
.crm-link[data-tooltip]::after {
  content: attr(data-tooltip);
  right: 0;
  bottom: calc(100% + 8px);
  padding: 5px 8px;
  border-radius: 4px;
  background: var(--ink);
  color: #fff;
  font-family: var(--font);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .01em;
  line-height: 1.2;
  white-space: nowrap;
  transform: translateY(2px);
}
.crm-link[data-tooltip]::before {
  content: "";
  right: 12px;
  bottom: calc(100% + 4px);
  width: 8px;
  height: 8px;
  background: var(--ink);
  transform: translateY(2px) rotate(45deg);
}
.crm-link[data-tooltip]:hover,
.crm-link[data-tooltip]:focus-visible { z-index: 8; }
.crm-link[data-tooltip]:hover::after,
.crm-link[data-tooltip]:hover::before,
.crm-link[data-tooltip]:focus-visible::after,
.crm-link[data-tooltip]:focus-visible::before {
  opacity: 1;
  transform: translateY(0);
}
.crm-link[data-tooltip]:hover::before,
.crm-link[data-tooltip]:focus-visible::before {
  transform: translateY(0) rotate(45deg);
}
.crm-link i { font-size: 16px; line-height: 1; }
.crm-link.is-disabled,
a[data-crm-deal-link].is-disabled {
  opacity: .45;
  pointer-events: none;
}
.deal, .product-card, .fit-panel, .config-accordion, .summary-accordion, .empty-state { border-color: var(--line); border-radius: 8px; }
.deal:disabled { cursor: not-allowed; }
.product-grid { gap: 12px; }.product-card { border-radius: 8px; }.product-card.is-selected { border-color: var(--ink); }.product-card img { filter: saturate(.72) contrast(.96); }.product-card__select { background: var(--ink); border-radius: 4px; }
.product-card { display: grid; grid-template-rows: auto 1fr auto; }
.product-quantity { display: grid; grid-template-columns: 34px 1fr 34px; align-items: center; gap: 6px; padding: 0 10px 10px; }
.product-quantity > span { text-align: center; color: var(--ink); font-family: var(--mono); font-size: 12px; font-weight: 600; }
.quantity-control { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 5px; background: var(--white); color: var(--ink); font-size: 20px; font-weight: 400; line-height: 1; cursor: pointer; }.quantity-control i { font-size: 18px; line-height: 1; }
.quantity-control:hover:not(:disabled) { border-color: var(--green); color: var(--green); }
.product-tabs { display: grid; gap: 8px; }.product-tab { border-radius: 5px; border-color: var(--line); color: var(--muted); text-align: left; }.product-tab.is-active { border-color: var(--green); background: var(--green); color: #fff; }
.product-switcher-label { margin: 0 0 8px; color: var(--muted); font-family: var(--mono); font-size: 10px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; }
.product-tabs { overflow: visible; padding: 0; border: 0; border-radius: 0; background: transparent; }
.screen[data-screen="configure"] .screen-heading--configure {
  display: grid;
  gap: 0;
  margin: 0 0 var(--section-rhythm);
}
.screen[data-screen="configure"] .screen-heading__solo[hidden],
.screen[data-screen="configure"] .product-tabs[hidden] {
  display: none !important;
}
.screen[data-screen="configure"] .screen-heading__solo h2 {
  margin: 0;
}
.screen[data-screen="configure"] .product-tabs {
  display: block;
  margin: 0;
  overflow: visible;
  position: relative;
  z-index: 8;
}
.screen[data-screen="configure"] .product-switcher--heading {
  margin: 0;
  width: 100%;
  overflow: visible;
}
.screen[data-screen="configure"] .product-switcher--heading > summary {
  min-height: 68px;
  padding: 14px 16px;
  gap: 12px;
}
.screen[data-screen="configure"] .product-switcher--heading > summary > span {
  display: grid;
  gap: 3px;
  min-width: 0;
}
.screen[data-screen="configure"] .product-switcher--heading > summary small {
  max-width: min(420px, 70vw);
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.screen[data-screen="configure"] .product-switcher__body {
  display: grid;
  gap: 14px;
  padding: 12px 14px 14px;
  border-top: 1px solid var(--line);
  background: color-mix(in srgb, var(--paper) 55%, var(--white));
}
.screen[data-screen="configure"] .product-switcher__group {
  display: grid;
  gap: 8px;
}
.screen[data-screen="configure"] .product-switcher__group-title {
  margin: 0;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
}
.screen[data-screen="configure"] .product-switcher__options {
  display: grid;
  gap: 6px;
}
.screen[data-screen="configure"] .product-switcher__option {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--ink);
  font: 600 13px/1.2 var(--font);
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition:
    border-color .2s var(--motion-ease),
    background .2s var(--motion-ease),
    color .2s var(--motion-ease),
    transform .2s var(--motion-ease),
    box-shadow .2s var(--motion-ease);
}
.screen[data-screen="configure"] .product-switcher__option.is-active {
  border-color: var(--green);
  background: var(--green-soft);
  color: var(--green);
}
.screen[data-screen="configure"] .product-switcher__option.is-selecting {
  transform: scale(.985);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--green) 45%, transparent);
}
.screen[data-screen="configure"] .product-switcher__option:hover,
.screen[data-screen="configure"] .product-switcher__option:focus-visible {
  border-color: color-mix(in srgb, var(--green) 35%, var(--line));
  outline: 1px solid color-mix(in srgb, var(--green) 30%, transparent);
  outline-offset: 0;
}
.screen[data-screen="configure"] .product-switcher--heading.is-closing-switch {
  pointer-events: none;
}
.screen[data-screen="configure"] [data-fabric-slot],
.screen[data-screen="configure"] [data-material-slot],
.screen[data-screen="configure"] [data-config-groups],
.screen[data-screen="configure"] [data-copy-product],
.screen[data-screen="configure"] .product-switcher--heading,
.screen[data-screen="configure"] [data-configure-solo] {
  transition:
    opacity .22s var(--motion-ease),
    transform .28s var(--motion-ease);
}
.screen[data-screen="configure"] .is-product-leaving {
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
}
.screen[data-screen="configure"] .is-product-entering {
  animation: product-switch-enter .34s var(--motion-ease) both;
}
@keyframes product-switch-enter {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.select-combobox__hint {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.25;
}
.fabric-suggestion.is-active .select-combobox__hint {
  color: color-mix(in srgb, currentColor 72%, transparent);
}
.fabric-suggestion--with-hint {
  min-height: 48px;
  padding-top: 8px;
  padding-bottom: 8px;
}
.select-combobox__option-label {
  display: block;
  font-weight: 600;
}
.copy-product-slot:empty { display: none; }
.template-actions.copy-product-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 10px;
  width: 100%;
  margin: 0;
}
.template-actions.copy-product-actions:has(> :only-child) {
  grid-template-columns: 1fr;
}
.copy-product-actions .copy-product-action {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
  margin: 0;
  color: var(--green);
  font-size: 13px;
}
.copy-product-actions .copy-product-action i { font-size: 18px; line-height: 1; }
.copy-product-action--danger {
  color: var(--rose);
  border-color: color-mix(in srgb, var(--rose) 35%, var(--line));
}
.copy-product-action--danger:hover {
  border-color: var(--rose);
  background: color-mix(in srgb, var(--rose) 10%, var(--white));
  color: var(--rose);
}
.fabric-slot { position: relative; z-index: 5; margin: 0 0 7px; overflow: visible; }
.fabric-slot:has(.fabric-panel.is-picking) { z-index: 24; }
.fabric-panel.config-accordion { overflow: visible; }
.fabric-panel.is-picking { z-index: 24; }
.fabric-panel > summary span, .fabric-panel--loading span { display: grid; gap: 3px; }
.fabric-panel > summary small, .fabric-panel--loading small { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: min(270px, 55vw); }
.fabric-panel--loading strong { font-size: 15px; }
.fabric-panel__body { position: relative; z-index: 2; display: grid; gap: 0; padding: 0; border-top: 1px solid var(--line); overflow: visible; }
.fabric-tier-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  padding: 12px 14px;
}
.fabric-tier {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 8px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--ink);
  font: 600 13px/1.2 var(--font);
  text-align: center;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition:
    border-color .2s var(--motion-ease),
    background .2s var(--motion-ease),
    color .2s var(--motion-ease);
}
.fabric-tier.is-active {
  border-color: var(--green);
  background: var(--green-soft);
  color: var(--green);
}
.fabric-tier:hover,
.fabric-tier:focus-visible {
  border-color: color-mix(in srgb, var(--green) 35%, var(--line));
  outline: 1px solid color-mix(in srgb, var(--green) 30%, transparent);
  outline-offset: 0;
}
.fabric-fields-table {
  border-top: 1px solid var(--line);
  overflow: visible;
}
.fabric-fields-table.config-table-wrap {
  overflow: visible;
}
.fabric-fields-table .config-table {
  overflow: visible;
}
.fabric-fields-table .config-table th { width: 43%; }
.fabric-fields-table .config-table td { width: 57%; position: relative; overflow: visible; }
.fabric-fields-table .fabric-input-control,
.fabric-fields-table .config-text-input,
.fabric-fields-table input[data-fabric-value] {
  width: 100%;
  min-width: 0;
}
.fabric-fields-table input[data-fabric-value],
.fabric-fields-table input.fabric-input--freeform,
.fabric-fields-table .config-text-input,
.select-combobox__input {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  min-height: 40px;
  height: 40px;
  padding: 8px 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: var(--ink);
  font: 400 13px / 1.2 var(--font);
}
.fabric-fields-table input[data-fabric-value],
.select-combobox__input {
  padding-right: 38px;
}
.fabric-fields-table input.fabric-input--freeform {
  padding-right: 10px;
}
.select-combobox__input {
  cursor: pointer;
}
.select-combobox__input:focus,
.select-combobox__input:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 1px var(--green);
}
.fabric-fields-table input:focus-visible,
.config-table .select-control select:focus,
.config-table .select-control select:focus-visible,
.select-control select:focus,
.select-control select:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 1px var(--green);
}
.fabric-panel.is-picking .fabric-fields-table tr:has(.fabric-input-control) td,
.material-panel.is-picking .config-table-wrap,
.config-accordion.is-picking .config-table-wrap,
.fit-section.is-picking .config-table-wrap,
.fit-panel.is-picking .config-table-wrap {
  overflow: visible;
  position: relative;
  z-index: 30;
}
.material-panel.is-picking,
.config-accordion.is-picking,
.fit-section.is-picking,
.fit-panel.is-picking,
.config-accordion:has(.select-combobox.is-open),
.fit-section:has(.select-combobox.is-open),
.fit-panel:has(.select-combobox.is-open),
.material-panel:has(.select-combobox.is-open) {
  position: relative;
  overflow: visible;
  z-index: 80;
}
.fabric-panel.is-picking .fabric-input-control,
.select-combobox.is-open {
  z-index: 90;
}
.config-table td:has(.select-combobox.is-open),
.config-table tr:has(.select-combobox.is-open) {
  overflow: visible;
  position: relative;
  z-index: 90;
}
.select-combobox.is-open .select-combobox__list,
.select-combobox.is-open .fabric-suggestions {
  z-index: 100;
}
.fabric-select-label { display: grid; gap: 6px; color: var(--muted); font-size: 12px; font-weight: 500; min-width: 0; }
.fabric-input-control,
.select-control,
.select-combobox {
  position: relative;
  display: block;
  z-index: 3;
  min-width: 0;
  width: 100%;
}
.fabric-select-label input {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 8px 38px 8px 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  font: 400 12px / 1.35 var(--font);
}
.fabric-select-label input.fabric-input--freeform { padding-right: 10px; }
.fabric-picker-button {
  position: absolute;
  top: 4px;
  right: 4px;
  z-index: 1;
  display: grid;
  width: 36px;
  height: 36px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}
.select-control > .fabric-picker-button:not([data-select-picker]) {
  pointer-events: none;
  cursor: inherit;
}
.fabric-picker-button:hover { color: var(--green); }
.fabric-picker-button:focus-visible { outline: 1px solid var(--green); outline-offset: 1px; }
.fabric-picker-button i { position: static; pointer-events: none; color: currentColor; font-size: 16px; line-height: 1; transform: none; }
.fabric-select-label input:focus-visible { outline: none; box-shadow: inset 0 0 0 1px var(--green); }
.fabric-meta-fields { display: grid; gap: 10px; }
.fabric-meta-field { display: grid; gap: 6px; color: var(--muted); font-size: 12px; font-weight: 500; min-width: 0; }
.fabric-meta-field input {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 8px 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  font: 400 12px / 1.35 var(--font);
  background: var(--white);
}
.fabric-meta-field input:focus-visible { outline: none; box-shadow: inset 0 0 0 1px var(--green); }
.fabric-suggestions {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 50;
  display: grid;
  gap: 0;
  width: 100%;
  max-height: min(280px, 42dvh);
  margin: 0;
  padding: 4px;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
  list-style: none;
  border: .5px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  box-shadow: 0 10px 28px rgba(28, 24, 20, .12);
}
.fabric-suggestions[hidden] { display: none !important; }
body > .fabric-suggestions.select-combobox__list {
  /* портал из combobox: поверх shell/аккордеонов на iPad */
  z-index: 200;
}
.fabric-suggestion-group {
  padding: 8px 10px 4px;
  color: var(--muted);
  font: 500 11px/1.3 var(--font);
}
.fabric-suggestion-group:first-child { padding-top: 6px; }
.fabric-suggestion {
  display: block;
  width: 100%;
  min-height: 40px;
  margin: 0;
  padding: 8px 10px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--ink);
  font: 500 13px/1.35 var(--font);
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.fabric-suggestion:hover,
.fabric-suggestion.is-active { background: var(--green-soft); color: var(--ink); }
.fabric-suggestion--empty { color: var(--muted); cursor: default; }
.fabric-suggestion--empty:hover { background: transparent; }
.fabric-panel--loading { display: grid; min-height: 58px; padding: 14px 16px; }
.config-intro { max-width: 38ch; font-size: 14px; line-height: 1.55; }
.fit-panel, .config-accordion, .summary-accordion { background: var(--white); }
.fit-panel > summary, .config-accordion > summary, .summary-accordion > summary { padding: 14px 16px; }
.fit-panel > summary strong, .config-accordion > summary strong { font-size: 15px; }
.fit-section { border-color: var(--line); border-radius: 8px; overflow: hidden; background: #fbfbfa; }.fit-section > summary { padding: 12px; }
.fit-section.is-picking,
.fit-section:has(.select-combobox.is-open) {
  overflow: visible;
}
.config-table-wrap { border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; }
.config-table th, .config-table td { border-color: var(--line); padding: 12px; }
.config-table th { color: var(--muted); font-size: 12px; font-weight: 500; }.config-table td { font-size: 13px; font-weight: 400; }
.config-text-input { border-color: var(--line); font-weight: 400; }
.screen[data-screen="configure"] > .sticky-action { margin-top: 28px; }
.summary-product__head h3 { font-family: var(--display); font-size: 22px; font-weight: 500; letter-spacing: -.025em; }
.summary-accordion summary { font-size: 13px; }.empty-state { background: #fbf3db; border-style: solid; }.empty-state strong { font-size: 14px; }
input, select { border-color: var(--line); border-radius: 5px; }
button:focus-visible, input:focus-visible { outline-color: #346538; }
.select-control select:focus-visible { outline: none; }

/* Text hierarchy: reserve emphasis for decisions, not labels and values. */
label { font-weight: 600; }
.product-tab, .summary-accordion summary strong { font-weight: 600; }
.summary-accordion summary small { font-weight: 500; }

/* Footers stick via .screen > .step-footer in the final pass; keep buttons in flow. */
.sticky-action { position: static; }
.selection-bar { margin-top: auto; }

/* Catalog: compact rows make the whole order visible without a horizontal rail. */
.product-grid { display: grid; grid-template-columns: 1fr; gap: 8px; overflow: visible; padding: 0; border: 0; border-radius: 0; background: transparent; }
.product-card { display: grid; grid-template-columns: 74px minmax(0, 1fr) auto; grid-template-rows: 1fr; min-height: 82px; border: .5px solid var(--line); border-radius: 8px; box-shadow: none; }
.product-card.is-selected { border-width: 1px; border-color: var(--green); background: #f3f6f3; box-shadow: none; }
.product-card img { grid-column: 1; align-self: stretch; width: 74px; height: 100%; min-height: 82px; object-fit: cover; filter: saturate(.72) contrast(.96); }
.product-card__body { grid-column: 2; align-content: center; min-height: 0; padding: 10px 12px; }
.product-card__body strong { font-weight: 600; }
.product-quantity { grid-column: 3; align-self: center; grid-template-columns: 32px 24px 32px; gap: 4px; padding: 0 10px 0 0; }
.quantity-control { width: 32px; height: 32px; }
.product-card__capabilities { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-height: 22px; color: var(--green); }
.product-capability { display: inline-flex; align-items: center; gap: 4px; min-height: 22px; padding: 2px 6px; border: .5px solid var(--line); border-radius: 999px; color: var(--green); font-size: 10px; font-weight: 500; line-height: 1; white-space: nowrap; }
.product-capability i { font-size: 14px; line-height: 1; }
.screen[data-screen="catalog"] .screen-heading h1,
.screen[data-screen="catalog"] .screen-heading h2,
.screen[data-screen="catalog"] .screen-heading > p:last-child,
.screen[data-screen="order-start"] .screen-heading h2 {
  white-space: normal;
  overflow-wrap: anywhere;
}
.screen[data-screen="order-start"] .screen-heading > p {
  max-width: none;
  white-space: nowrap;
}
.screen[data-screen="body-measurements"] .screen-heading > p {
  max-width: 42ch;
}
.screen[data-screen="unlock"] #unlock-title {
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}
.passport-panel {
  margin: 14px 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}
.passport-panel > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 52px;
  padding: 12px 14px;
  cursor: pointer;
  list-style: none;
}
.passport-panel > summary::-webkit-details-marker { display: none; }
.passport-panel > summary span { display: grid; gap: 2px; }
.passport-panel > summary strong { font-size: 14px; }
.passport-panel > summary small { color: var(--muted); font-size: 12px; }
.passport-panel > summary > i { color: var(--green); font-size: 20px; flex: 0 0 auto; }
.passport-panel--docs {
  border: .5px solid var(--line);
  background: #fbfbfa;
  overflow: hidden;
}
.passport-panel--docs .passport-docs-error {
  margin: 0;
  padding: 10px 12px 12px;
  border-top: .5px solid var(--line);
}
.passport-panel--contact {
  margin: 0 0 var(--section-rhythm);
  border: .5px solid var(--line);
  border-radius: 8px;
  background: #fbfbfa;
  overflow: hidden;
}
.contact-passport__head {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 10px;
}
.contact-passport__head .contact-passport__identity {
  display: grid;
  gap: 2px;
  flex: 1 1 auto;
  min-width: 0;
}
.contact-passport__head .deal__title {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  font-size: 20px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.contact-passport__head [data-passport-summary] {
  flex: 0 0 auto;
  margin-left: 0;
}
.passport-panel.passport-panel--contact > summary.contact-passport__head {
  min-height: 58px;
  padding: 14px 16px;
}
.passport-panel.passport-panel--contact > summary.contact-passport__head > i {
  flex: 0 0 auto;
  font-size: 21px;
}
.phone-input--table {
  width: 100%;
  min-height: 32px;
  margin: 0;
  border: none;
  background: transparent;
  box-shadow: none;
  justify-content: flex-end;
  gap: 0;
  padding: 0;
}
.phone-input--table span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
  padding: 0;
  letter-spacing: 0;
}
.phone-input--table input {
  flex: 0 1 auto;
  width: 15ch;
  max-width: 100%;
  min-width: 0;
  padding: 4px 0 4px 2px;
  text-align: left;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}
.phone-input--table:focus-within {
  box-shadow: none;
}
.passport-form {
  display: grid;
  gap: 8px;
  padding: 0 14px 14px;
}
.passport-form--table {
  gap: 0;
  padding: 0;
}
.passport-form--table .config-table-wrap {
  border-top: .5px solid var(--line);
  background: var(--white);
}
.passport-form--table .summary-table th,
.passport-form--table .summary-table td {
  text-align: left;
  vertical-align: middle;
}
.body-measurements-form {
  margin: 0;
}
.body-measurements-panel {
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  overflow: hidden;
}
.body-measurements-panel > summary.body-measurements-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 58px;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
}
.body-measurements-panel > summary.body-measurements-panel__head::-webkit-details-marker { display: none; }
.body-measurements-panel__head span {
  display: grid;
  gap: 3px;
  min-width: 0;
  flex: 1;
}
.body-measurements-panel__head strong {
  font-size: 15px;
  line-height: 1.2;
}
.body-measurements-panel__head small {
  color: var(--muted);
  font-size: 12px;
}
.body-measurements-panel .config-table-wrap {
  border-top: 1px solid var(--line);
}
.body-measurements-panel .config-table th label {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  color: inherit;
  font: inherit;
}
.body-measurements-panel .config-table td {
  text-align: right;
}
.body-measurements-panel .config-table .config-text-input {
  width: 100%;
  box-sizing: border-box;
  min-height: 40px;
  margin: 0;
  padding: 8px 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  background: #fff;
  color: var(--ink);
  text-align: right;
  font: 400 13px / 1.2 var(--font);
}
.body-measurements-panel .config-table .config-text-input:focus {
  outline: none;
  box-shadow: inset 0 0 0 1px var(--green);
}
.body-measure-unit {
  color: var(--muted);
  font-size: 12px;
  font-weight: 400;
  line-height: 1;
}
.body-measurements-panel__footer {
  padding: 10px 12px 12px;
  border-top: .5px solid var(--line);
  background: var(--white);
}
.body-measurements-panel__footer .button--compact {
  width: 100%;
  min-height: 40px;
  margin-top: 0;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 600;
  gap: 8px;
}
.body-measurements-panel__footer .button--compact i {
  font-size: 16px;
  line-height: 1;
}
.passport-form--table .summary-table th label {
  color: inherit;
  font: inherit;
}
.passport-form--table .summary-table td {
  padding: 10px 12px;
}
.passport-panel .passport-form--table .config-table .config-text-input {
  width: 100%;
  box-sizing: border-box;
  min-height: 40px;
  margin: 0;
  padding: 8px 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  color: var(--ink);
  text-align: right;
  font: 400 13px/1.2 var(--font);
  box-shadow: none;
}
.passport-panel .passport-form--table .config-table .config-text-input:focus {
  outline: 1px solid var(--green);
  outline-offset: 0;
}
.passport-panel .passport-form--table .config-table .phone-input--table {
  width: 100%;
  min-height: 40px;
  margin: 0;
  padding: 0 10px 0 12px;
  border: .5px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  box-shadow: none;
  justify-content: flex-end;
  gap: 0;
}
.passport-panel .passport-form--table .config-table .phone-input--table span {
  color: var(--ink);
  font-size: 13px;
  font-weight: 400;
  padding: 0;
}
.passport-panel .passport-form--table .config-table .phone-input--table input {
  flex: 0 1 auto;
  width: 15ch;
  max-width: 100%;
  min-width: 0;
  min-height: 38px;
  padding: 8px 0 8px 2px;
  border: 0;
  background: transparent;
  text-align: left;
  font: 400 13px/1.2 var(--font);
  color: var(--ink);
  box-shadow: none;
  outline: none;
}
.passport-panel .passport-form--table .config-table .phone-input--table:focus-within {
  outline: 1px solid var(--green);
  outline-offset: 0;
  box-shadow: none;
}
.passport-id-input {
  display: flex;
  align-items: stretch;
  justify-content: flex-end;
  gap: 6px;
  width: 100%;
  min-height: 40px;
  padding: 0 10px;
  border: .5px solid var(--line);
  border-radius: 5px;
  background: var(--white);
  box-sizing: border-box;
}
.passport-id-input:focus-within {
  outline: 1px solid var(--green);
  outline-offset: 0;
}
.passport-panel .passport-form--table .config-table .passport-id-input .config-text-input {
  flex: 0 1 auto;
  width: auto;
  min-width: 0;
  min-height: 38px;
  margin: 0;
  padding: 8px 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  text-align: right;
}
.passport-panel .passport-form--table .config-table .passport-id-input .config-text-input:focus {
  outline: none;
  box-shadow: none;
}
.passport-panel .passport-form--table .config-table .passport-id-input [data-passport-series] {
  width: 4.5ch;
  flex: 0 0 4.5ch;
}
.passport-panel .passport-form--table .config-table .passport-id-input [data-passport-number] {
  width: 7ch;
  flex: 0 0 7ch;
}
.passport-form__footer {
  display: grid;
  gap: 8px;
  padding: 10px 12px 12px;
  border-top: .5px solid var(--line);
  background: var(--white);
}
.passport-form__actions {
  display: grid;
  grid-template-columns: minmax(0, 30%) minmax(0, 70%);
  align-items: center;
  gap: 8px;
}
.passport-form__actions--crm {
  grid-template-columns: minmax(0, 30%) minmax(0, 70%);
}
.passport-form__actions--crm .button--compact[hidden] {
  display: none;
}
.passport-form__footer > [data-passport-save] {
  width: 100%;
}
.passport-form__actions .button--compact {
  width: 100%;
  min-height: 40px;
  margin-top: 0;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 600;
  gap: 8px;
  text-decoration: none;
}
.passport-form__actions .button--compact i {
  font-size: 16px;
  line-height: 1;
}
.passport-form__footer .button--compact {
  width: 100%;
  min-height: 40px;
  margin-top: 0;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 600;
  gap: 8px;
}
.passport-form__footer .button--compact i {
  font-size: 16px;
  line-height: 1;
}
.passport-panel > summary + .passport-form--table .config-table-wrap {
  border-top: 0;
}
.docs-summary {
  margin: 16px 0;
}
.docs-summary .config-table-wrap,
.docs-delivery .config-table-wrap,
.passport-panel--docs .config-table-wrap {
  border-top: .5px solid var(--line);
  background: var(--white);
}
.docs-summary .summary-table th,
.docs-summary .summary-table td,
.docs-delivery .summary-table th,
.docs-delivery .summary-table td,
.passport-panel--docs .summary-table th,
.passport-panel--docs .summary-table td {
  text-align: left;
  vertical-align: middle;
}
.docs-summary .summary-table td,
.passport-panel--docs .summary-table td {
  font-weight: 400;
  text-align: right;
}
.docs-summary .summary-table tr[data-docs-total-row] th,
.docs-summary .summary-table tr[data-docs-total-row] td {
  font-weight: 600;
}
.docs-summary .summary-table td[data-docs-prepay],
.docs-summary .summary-table td[data-docs-remainder] {
  font-weight: 600;
}
.passport-panel--docs .summary-table td.is-empty {
  color: var(--muted);
}
.docs-delivery {
  margin: 16px 0;
}
.docs-delivery .summary-table th label {
  color: inherit;
  font: inherit;
}
.docs-delivery .summary-table td {
  padding: 6px 8px;
}
.docs-delivery .config-text-input {
  width: 100%;
  box-sizing: border-box;
  text-align: right;
}
.docs-wishes {
  margin: 16px 0;
}
.docs-wishes__body {
  padding: 0;
  border-top: .5px solid var(--line);
  background: var(--white);
}
.docs-wishes .summary-wishes__input {
  margin: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.docs-wishes .summary-wishes__input:focus {
  box-shadow: none;
  outline: 1px solid var(--green);
  outline-offset: -1px;
}
.docs-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 14px 0 8px;
}
.docs-actions .button {
  width: 100%;
  min-height: 44px;
  margin-top: 0;
  padding: 0 10px;
  font-size: 12px;
  gap: 6px;
}
.docs-actions .button i {
  font-size: 16px;
  line-height: 1;
  flex: 0 0 auto;
}
.docs-actions .button span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.screen[data-screen="documents"] .text-input { margin-bottom: 10px; }
.screen[data-screen="documents"] .docs-delivery .text-input,
.screen[data-screen="documents"] .passport-form--table .text-input { margin-bottom: 0; }
.success-actions__row { display: grid; gap: 8px; }
.summary-list { display: grid; gap: 12px; margin-top: 0; overflow: visible; }
.summary-review-copy {
  max-width: 36ch;
  margin: 0 0 14px;
  color: var(--muted);
  font-size: var(--body-size);
  line-height: 1.45;
}
.screen[data-screen="summary"] .screen-heading--compact {
  margin-bottom: 14px;
}
.summary-wishes {
  display: grid;
  gap: 8px;
  margin: 16px 0 0;
}
.summary-wishes__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.summary-wishes__label {
  color: var(--ink);
  font-size: var(--meta-size);
  font-weight: 600;
}
.summary-wishes__input {
  width: 100%;
  min-height: 96px;
  padding: 12px 14px;
  border: .5px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  font: 400 13px / 1.45 var(--font);
  resize: vertical;
  outline: none;
}
.summary-wishes__input:focus {
  box-shadow: inset 0 0 0 1px var(--green);
}
.summary-wishes__input::placeholder { color: var(--muted); }
.summary-body-panel {
  margin: 0 0 12px;
  border-radius: 8px;
  overflow: hidden;
  background: #fbfbfa;
}
.summary-body-panel > summary {
  gap: 10px;
}
.summary-body-panel > summary > span {
  display: grid;
  gap: 2px;
  min-width: 0;
  flex: 1;
  justify-items: start;
}
.summary-body-panel > summary > span > .deal__title,
.summary-body-panel > summary > span > strong.deal__title {
  margin: 0;
  color: var(--ink);
  font-family: var(--display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.15;
}
.summary-body-panel > summary > span small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
  text-align: left;
  white-space: nowrap;
}
.summary-body-panel__body .summary-table th,
.summary-body-panel__body .summary-table td {
  text-align: left;
  vertical-align: middle;
}
.summary-body-panel__body .summary-table td {
  font-weight: 400;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.summary-body-panel__body .summary-table td.is-empty {
  color: var(--muted);
  font-style: italic;
}
.summary-body-panel > summary > .summary-edit {
  display: grid;
  place-items: center;
  width: 28px;
  min-width: 28px;
  height: 28px;
  min-height: 28px;
  flex: 0 0 28px;
  padding: 0;
  border: .5px solid color-mix(in srgb, var(--green) 35%, var(--line));
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  box-shadow: none;
}
.summary-body-panel > summary > .summary-edit i {
  font-size: 14px;
  line-height: 1;
  color: var(--green);
  flex: none;
  width: auto;
  height: auto;
}
.summary-body-panel__body .config-table-wrap {
  border-top: .5px solid var(--line);
}
.summary-product {
  display: grid;
  gap: 0;
  overflow: visible;
  padding: 0;
  border: .5px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}
.summary-product--panel {
  display: block;
  overflow: hidden;
}
.summary-product--panel > summary.summary-product__head {
  list-style: none;
  cursor: pointer;
}
.summary-product--panel > summary.summary-product__head::-webkit-details-marker { display: none; }
.summary-product--panel > summary.summary-product__head > i {
  flex: 0 0 auto;
  color: var(--green);
  font-size: 18px;
  line-height: 1;
}
.summary-product__body {
  display: grid;
  gap: 0;
  padding: 10px 0 10px;
  border-top: .5px solid var(--line);
}
.summary-fit__head,
.summary-product__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 14px 12px;
}
.summary-product--bundle > .summary-product__head {
  border-bottom: .5px solid var(--line);
}
.summary-product--panel.summary-product--bundle > .summary-product__head {
  border-bottom: 0;
}
.summary-product__identity {
  display: grid;
  gap: 4px;
  flex: 1 1 auto;
  min-width: 0;
}
.summary-product__identity strong,
.summary-product__identity strong.deal__title,
.summary-product__identity h3.deal__title {
  margin: 0;
  color: var(--ink);
  font-family: var(--display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.2;
  overflow-wrap: break-word;
  word-break: normal;
  hyphens: manual;
}
.summary-product__identity small,
.summary-product__identity .summary-product__fabric,
.summary-product__identity .summary-product__detail,
.summary-product__identity .summary-product__changes,
.summary-product__identity p.summary-product__fabric,
.summary-product__identity p.summary-product__detail,
.summary-product__identity p.summary-product__changes {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
}
.summary-product__identity .summary-product__changes,
.summary-product__identity p.summary-product__changes {
  display: block;
}
.summary-product__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  margin-left: auto;
}
.summary-product__price {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
  white-space: nowrap;
}
.summary-product__price > span {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
}
.summary-product__price input {
  width: 7.5rem;
  min-height: 34px;
  border: .5px solid var(--line);
  border-radius: var(--control-radius, 6px);
  padding: 7px 9px;
  background: var(--white);
  color: var(--ink);
  font: 600 14px/1 var(--font);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.summary-product__price.is-empty {
  color: var(--muted);
  font-weight: 500;
}
.summary-product__price.is-empty > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
}
.summary-product__price.is-invalid input,
.summary-product__price.is-empty.is-invalid input {
  border-color: #c75a54;
}
.summary-product__price.is-invalid:focus-within input,
.summary-product__price.is-empty.is-invalid:focus-within input {
  outline: 1px solid #c75a54;
  outline-offset: 0;
}
.summary-fit__head h3,
.summary-product__head h3 {
  margin: 0;
  color: var(--ink);
  font-family: var(--display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.15;
}
.summary-fit__head p,
.summary-product__head p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}
.summary-fit__list {
  display: grid;
  gap: 0;
  border-top: .5px solid var(--line);
}
.summary-fit .summary-review {
  margin: 0;
  border: 0;
  border-radius: 0;
  border-top: .5px solid var(--line);
  background: transparent;
}
.summary-fit .summary-review:first-child { border-top: 0; }
.summary-fabric {
  margin: 0;
  padding: 0;
  border: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.summary-fabric > span {
  margin-right: 6px;
  color: var(--muted);
  font-weight: 500;
}
.summary-fabric > strong { color: var(--ink); font-weight: 600; }
.summary-accordion .summary-fabric-edit {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0 12px 12px;
  border: 0;
  border-bottom: .5px solid var(--line);
  border-radius: 0;
  background: transparent;
}
.summary-fabric-edit__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}
.summary-fabric-edit__head > span {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.summary-fabric-edit__head > small {
  min-width: 0;
  color: var(--ink);
  font-size: 12px;
  font-weight: 500;
  text-align: right;
  overflow-wrap: anywhere;
}
.summary-fabric-edit__tiers.fabric-tier-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  width: 100%;
  min-width: 0;
  padding: 0;
}
.summary-fabric-edit__field {
  display: grid;
  gap: 6px;
  width: 100%;
  min-width: 0;
}
.summary-fabric-edit__field > span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
}
.summary-fabric-edit__field input {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 10px 12px;
  border: .5px solid var(--line);
  border-radius: var(--control-radius);
  background: var(--white);
  color: var(--ink);
  font: 500 14px/1.3 var(--font);
}
.summary-fabric-edit .fabric-input-control input { padding-right: 38px; }
.summary-fabric-edit .fabric-input-control input.fabric-input--freeform { padding-right: 12px; }
.summary-fabric-edit.is-picking { z-index: 14; }
.summary-fabric-edit__field input:focus {
  outline: 1px solid var(--green);
  outline-offset: 1px;
  border-color: var(--green);
}
.summary-product > .summary-fabric {
  margin: 0 14px 10px;
}
.summary-product .summary-review {
  margin: 0 10px 10px;
  overflow: hidden;
  border: .5px solid var(--line);
  border-radius: 8px;
  background: #fbfbfa;
}
.summary-review__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 52px;
  padding: 12px;
  color: var(--ink);
}
.summary-review__head > span {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  flex: 1;
}
.summary-review__head strong { font-size: 14px; font-weight: 600; line-height: 1.2; }
.summary-review__head small {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  text-align: right;
  white-space: nowrap;
}
.summary-review__head > .summary-edit {
  display: grid;
  place-items: center;
  width: 28px;
  min-width: 28px;
  height: 28px;
  min-height: 28px;
  flex: 0 0 28px;
  padding: 0;
  border: .5px solid color-mix(in srgb, var(--green) 35%, var(--line));
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  box-shadow: none;
  transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
}
.summary-review__head > .summary-edit i {
  display: inline-flex;
  width: auto;
  height: auto;
  font-size: 14px;
  line-height: 1;
}
.summary-review__head > .summary-edit:hover,
.summary-review__head > .summary-edit:focus-visible {
  border-color: var(--green);
  background: var(--green-soft-hover, var(--green-soft));
  color: var(--green);
}
.summary-review__head > .summary-edit:focus-visible {
  outline: 1px solid var(--green);
  outline-offset: 1px;
}
.summary-review__body {
  display: grid;
  gap: 8px;
  padding: 0 10px 12px;
}
.summary-review__empty {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
}
.summary-review-fabric {
  display: grid;
  gap: 2px;
  padding: 10px 12px;
  border: .5px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}
.summary-review-fabric > span {
  color: var(--green);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.summary-review-fabric > strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -.02em;
  line-height: 1.25;
  overflow-wrap: anywhere;
}
.summary-review-fabric > small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.summary-review-fabric.is-empty > strong { color: var(--muted); font-weight: 500; }
.summary-fabric-meta {
  display: grid;
  gap: 0;
  margin: 8px 0 0;
  padding-top: 8px;
  border-top: .5px solid var(--line);
}
.summary-fabric-meta > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 0;
}
.summary-fabric-meta dt {
  color: var(--muted);
  font-size: 11px;
  font-weight: 500;
}
.summary-fabric-meta dd {
  margin: 0;
  color: var(--ink);
  font-size: 12px;
  font-weight: 500;
  text-align: right;
  overflow-wrap: anywhere;
}
.summary-fabric-meta dd.is-empty {
  color: var(--muted);
  font-weight: 500;
  font-style: italic;
}
.summary-kv-group {
  display: grid;
  gap: 0;
  padding: 0;
  border: .5px solid var(--line);
  border-radius: 8px;
  background: #fbfbfa;
  overflow: hidden;
}
.summary-kv-group__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 52px;
  padding: 12px;
  color: var(--ink);
}
.summary-kv-group__head > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  flex: 1;
}
.summary-kv-group__head strong { font-size: 14px; font-weight: 600; line-height: 1.2; }
.summary-kv-group__head [data-passport-summary] {
  flex: 0 0 auto;
  margin-left: auto;
}
.summary-kv-group__head small {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  text-align: right;
  white-space: nowrap;
}
.passport-panel--contact > summary.contact-passport__head.summary-kv-group__head {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
}
.passport-panel--contact > summary.contact-passport__head > .contact-passport__identity {
  display: grid;
  gap: 2px;
  flex: 1 1 auto;
  min-width: 0;
}
.passport-panel--contact > summary.contact-passport__head > .contact-passport__identity > .deal__title {
  flex: unset;
  min-width: 0;
  margin: 0;
  color: var(--ink);
  font-family: var(--display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.passport-panel--contact > summary.contact-passport__head > .contact-passport__identity > .deal__manager {
  min-width: 0;
  max-width: 100%;
}
.passport-panel--contact > summary.contact-passport__head > .contact-passport__identity > .deal__manager[hidden] {
  display: none;
}
.passport-panel--contact > summary.contact-passport__head > .deal__title {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  color: var(--ink);
  font-family: var(--display);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.passport-panel--contact > summary.contact-passport__head > [data-passport-summary] {
  flex: 0 0 auto;
  margin-left: auto;
}
.passport-panel--contact > summary.contact-passport__head > i {
  flex: 0 0 auto;
  margin-left: 0;
}
.summary-product .summary-review .summary-kv-group .config-table-wrap {
  border-top: .5px solid var(--line);
  background: var(--white);
}
.summary-product .summary-review .summary-table th,
.summary-product .summary-review .summary-table td {
  text-align: left;
  vertical-align: middle;
}
.summary-product .summary-review .summary-table td {
  font-weight: 400;
  text-align: right;
}
.summary-product .summary-review .summary-table td.is-empty {
  color: var(--muted);
  font-style: italic;
}
.summary-bundle-items {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}
.summary-bundle-item {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border-top: .5px solid var(--line);
}
.summary-bundle-item:first-child { border-top: 0; }
.summary-bundle-item__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}
.summary-bundle-item__copy {
  display: grid;
  gap: 4px;
  flex: 1;
  min-width: 0;
}
.summary-bundle-item__row > .summary-edit {
  flex: 0 0 36px;
}
.summary-bundle-item__copy strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
}
.summary-bundle-item__copy .summary-product__fabric {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
}
.summary-bundle-item .summary-fabric { margin: 0; }
.summary-bundle-item .summary-review {
  margin: 0;
  background: var(--paper);
}

.summary-product__actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  position: relative;
  z-index: 2;
}
.summary-product__actions .summary-edit {
  width: 28px;
  min-width: 28px;
  height: 28px;
  min-height: 28px;
  flex: 0 0 28px;
  pointer-events: auto;
}
.summary-product__actions .summary-edit i {
  font-size: 14px;
  line-height: 1;
}
.summary-product--panel > summary.summary-product__head > .summary-product__actions {
  margin-left: 0;
}
.summary-product--panel > summary.summary-product__head > .summary-product__meta {
  margin-left: auto;
}
@media (max-width: 560px) {
  /* На телефоне: название на всю ширину, цена и действия — второй ряд */
  .summary-fit__head,
  .summary-product__head,
  .summary-product--panel > summary.summary-product__head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    column-gap: 8px;
    row-gap: 10px;
  }
  .summary-product__identity {
    grid-column: 1 / -1;
  }
  .summary-product__meta,
  .summary-product--panel > summary.summary-product__head > .summary-product__meta {
    grid-column: 1;
    margin-left: 0;
    justify-self: start;
  }
  .summary-product__actions,
  .summary-product--panel > summary.summary-product__head > .summary-product__actions {
    grid-column: 2;
    justify-self: end;
  }
  .summary-product--panel > summary.summary-product__head > i {
    grid-column: 3;
    justify-self: end;
  }
}
.summary-edit--danger {
  border-color: color-mix(in srgb, #c75a54 40%, var(--line));
  background: color-mix(in srgb, #c75a54 8%, #fff);
  color: #b04a45;
}
.summary-edit--danger:hover,
.summary-edit--danger:focus-visible {
  border-color: #c75a54;
  background: color-mix(in srgb, #c75a54 14%, #fff);
}

/* Final consistency pass: shared tokens, bottom footers, one card/button language. */
.topbar { margin-bottom: 26px; padding-bottom: 10px; }
.topbar .icon-button + .brand-logo { margin-left: 10px; }
.icon-button {
  width: var(--icon-size);
  height: var(--icon-size);
  border: .5px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--green);
  text-decoration: none;
}
.icon-button i { font-size: 16px; }
.icon-button--solid { background: var(--green); color: #fff; border-color: var(--green); }
.icon-button--solid i { color: #fff; }
.screen-heading, .screen-heading--compact { margin: 0 0 var(--section-rhythm); }
.screen-heading h1, .screen-heading h2, .lockup h1, .success-screen h1, .success-deal {
  max-width: 100%;
  font-size: clamp(34px, 8vw, 44px);
  line-height: 1;
  white-space: normal;
  overflow-wrap: anywhere;
}
.screen-heading--compact h1, .screen-heading--compact h2 {
  max-width: 100%;
  font-size: clamp(24px, 5.5vw, 28px);
  line-height: 1.1;
  white-space: normal;
  overflow-wrap: anywhere;
}
.screen-heading p, .intro { margin: 12px 0 0; font-size: var(--body-size); }
.screen-context { margin: 8px 0 0; color: var(--muted); font-size: var(--body-size); }
.order-timeline {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 0 0 16px;
}
.order-timeline[hidden] { display: none !important; }
.order-timeline__shell {
  width: 100%;
  padding: 0;
  box-sizing: border-box;
}
.order-timeline__track {
  display: flex;
  align-items: flex-start;
  width: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}
.order-timeline__step {
  --marker-size: 28px;
  --rail-y: calc(var(--marker-size) / 2);
  position: relative;
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 0;
  color: var(--muted);
}
.order-timeline__step:not(:first-child)::before,
.order-timeline__step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: var(--rail-y);
  height: 1px;
  transform: translateY(-50%);
  background: color-mix(in srgb, var(--line) 80%, var(--muted));
  pointer-events: none;
}
.order-timeline__step:not(:first-child)::before {
  left: 0;
  right: calc(50% + var(--marker-size) / 2);
}
.order-timeline__step:not(:last-child)::after {
  left: calc(50% + var(--marker-size) / 2);
  right: 0;
}
.order-timeline__step.is-done:not(:first-child)::before,
.order-timeline__step.is-done:not(:last-child)::after,
.order-timeline__step.is-current:not(:first-child)::before {
  background: var(--green);
}
.order-timeline__marker {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: var(--marker-size);
  min-width: var(--marker-size);
  height: var(--marker-size);
  min-height: var(--marker-size);
  margin: 0;
  padding: 0;
  border: .5px solid color-mix(in srgb, var(--green) 35%, var(--line));
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  box-shadow: none;
  font: 600 11px/1 var(--font);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
  appearance: none;
  -webkit-appearance: none;
  transition:
    background .22s var(--motion-ease),
    border-color .22s var(--motion-ease),
    color .22s var(--motion-ease),
    transform .18s var(--motion-ease);
}
.order-timeline__step.is-done .order-timeline__marker {
  border-color: color-mix(in srgb, var(--green) 35%, var(--line));
  background: var(--green-soft);
  color: var(--green);
}
.order-timeline__step.is-current .order-timeline__marker {
  border-color: var(--green);
  background: var(--green-soft);
  color: var(--green);
  box-shadow: none;
}
.order-timeline__step.is-todo .order-timeline__marker {
  border-color: color-mix(in srgb, var(--line) 75%, var(--muted));
  background: var(--white);
  color: color-mix(in srgb, var(--muted) 80%, var(--line));
}
.order-timeline__step.is-todo.is-jumpable .order-timeline__marker {
  border-color: color-mix(in srgb, var(--green) 35%, var(--line));
  background: var(--green-soft);
  color: var(--green);
}
.order-timeline__label {
  position: relative;
  z-index: 1;
  display: block;
  max-width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .01em;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: center;
  appearance: none;
  -webkit-appearance: none;
  transition: color .22s var(--motion-ease);
}
button.order-timeline__marker,
button.order-timeline__label {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
button.order-timeline__marker:hover,
button.order-timeline__marker:focus-visible {
  border-color: var(--green);
  background: var(--green-soft-hover, var(--green-soft));
  color: var(--green);
  transform: none;
  outline: 1px solid var(--green);
  outline-offset: 1px;
}
button.order-timeline__label:hover,
button.order-timeline__label:focus-visible {
  color: var(--green);
  outline: none;
}
button.order-timeline__label:focus-visible {
  box-shadow: 0 1px 0 0 color-mix(in srgb, var(--green) 45%, transparent);
}
.order-timeline__step.is-done {
  color: color-mix(in srgb, var(--green) 72%, var(--muted));
}
.order-timeline__step.is-current {
  color: var(--green);
}
.order-timeline__step.is-current .order-timeline__label {
  font-weight: 700;
  color: var(--green);
}
.order-timeline__step.is-todo .order-timeline__label {
  color: var(--muted);
  font-weight: 550;
}
.order-timeline__track--vertical {
  flex-direction: column;
  align-items: stretch;
  gap: 0;
}
.order-timeline__track--vertical .order-timeline__step,
.order-timeline__track--vertical .order-timeline__step:first-child,
.order-timeline__track--vertical .order-timeline__step:last-child {
  flex: 0 0 auto;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  min-height: 40px;
  padding: 2px 4px 2px 0;
}
.order-timeline__track--vertical .order-timeline__step:not(:first-child)::before,
.order-timeline__track--vertical .order-timeline__step:not(:last-child)::after {
  display: none;
}
.order-timeline__track--vertical .order-timeline__step::before {
  content: '';
  display: block;
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--marker-size) / 2);
  width: 1px;
  height: auto;
  transform: translateX(-50%);
  background: color-mix(in srgb, var(--line) 85%, var(--muted));
  pointer-events: none;
}
.order-timeline__track--vertical .order-timeline__step:first-child::before { top: 50%; }
.order-timeline__track--vertical .order-timeline__step:last-child::before { bottom: 50%; }
.order-timeline__track--vertical .order-timeline__step.is-done::before,
.order-timeline__track--vertical .order-timeline__step.is-current::before {
  background: var(--green);
}
.order-timeline__track--vertical .order-timeline__label,
.order-timeline__track--vertical .order-timeline__step:first-child .order-timeline__label,
.order-timeline__track--vertical .order-timeline__step:last-child .order-timeline__label {
  flex: 1 1 auto;
  width: auto;
  max-width: none;
  padding: 8px 10px;
  text-align: left;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
  border-radius: 8px;
}
.order-timeline__track--vertical .order-timeline__step.is-current .order-timeline__label {
  background: var(--green-soft);
}

@media (max-width: 560px) {
  .order-timeline__step { gap: 6px; }
  .order-timeline__label { font-size: 11px; }
}

.screen[data-screen="configure"] .screen-heading--compact {
  display: grid;
  gap: 0;
}
.screen[data-screen="configure"] .screen-heading--compact h2 {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
}
.screen[data-screen="configure"] .screen-context {
  margin: 0;
}
.field-label { color: var(--ink); font-size: var(--meta-size); font-weight: 600; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: var(--action-height);
  border: .5px solid var(--line);
  border-radius: var(--control-radius);
  padding: 0 16px;
  font-size: var(--body-size);
  font-weight: 600;
  text-decoration: none;
}
.button > i { flex: 0 0 auto; font-size: 18px; line-height: 1; }
.button--primary { border-color: var(--green); background: var(--green); color: #fff; }
.button--quiet { color: var(--green); background: var(--white); }
.button--quiet:hover { border-color: var(--green); background: var(--green-soft); }
.button--create-client {
  margin-top: 12px;
  border-color: color-mix(in srgb, var(--green) 35%, var(--line));
  background: var(--green-soft);
  color: var(--green);
}
.button--create-client > span {
  color: var(--green);
}
.button:active, .quantity-control:active, .icon-button:active, .crm-link:active, .summary-edit:active { transform: scale(.98); }
.button--search { justify-content: center; }

/* Bottom nav bar — действия шага */
.screen:not([data-screen="unlock"]):not([data-screen="success"]) {
  position: relative;
  min-height: 100%;
}
.screen > .step-footer,
.screen > .selection-bar.step-footer {
  position: sticky;
  bottom: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 7fr);
  align-items: stretch;
  gap: var(--bottom-nav-gap, 8px);
  width: auto;
  max-width: none;
  min-width: 0;
  margin: auto calc(-1 * var(--screen-pad-x, 20px)) 0;
  padding: var(--bottom-nav-pad, 10px) var(--screen-pad-x, 20px) max(10px, env(safe-area-inset-bottom));
  border-top: 1px solid color-mix(in srgb, var(--line) 88%, var(--ink));
  background: color-mix(in srgb, var(--paper) 92%, #fff);
  box-shadow: 0 -10px 28px rgba(32, 32, 30, .08);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-sizing: border-box;
}
.screen > .step-footer > .button,
.screen > .selection-bar.step-footer > .button {
  width: 100%;
  min-width: 0;
  min-height: var(--bottom-nav-action, 48px);
  margin: 0;
  border-radius: 10px;
}
.screen > .step-footer > .step-footer__back,
.screen > .selection-bar.step-footer > .step-footer__back {
  grid-column: 1;
  background: var(--white);
}
.screen > .step-footer > .button--primary,
.screen > .selection-bar.step-footer > .button--primary {
  grid-column: 2;
}
.screen > .step-footer > .button:only-child,
.screen > .selection-bar.step-footer > .button:only-child {
  grid-column: 1 / -1;
}
.screen > .step-footer.step-footer--back-only {
  grid-template-columns: minmax(0, 3fr) minmax(0, 7fr);
}
.screen > .step-footer.step-footer--back-only > .button:only-child {
  grid-column: 1;
}
html.is-keyboard-open .screen > .step-footer,
html.is-keyboard-open .screen > .selection-bar.step-footer {
  position: static;
  z-index: auto;
  margin-left: 0;
  margin-right: 0;
  width: 100%;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.screen[data-screen="client"] .button--create-client {
  position: relative;
  z-index: 1;
  margin-bottom: 8px;
  flex: 0 0 auto;
}
.screen[data-screen="deals"] .button--create-client {
  margin-top: 0;
  margin-bottom: 12px;
}
.screen[data-screen="deals"] .button--create-client.button--create-deal-empty {
  display: grid;
  place-content: center;
  gap: 8px;
  min-height: 130px;
  padding: 14px 16px;
  border: .5px solid var(--line);
  border-radius: var(--card-radius);
  background: var(--white);
  color: var(--green);
  font-size: 15px;
  font-weight: 600;
  box-shadow: none;
}
.screen[data-screen="deals"] .button--create-client.button--create-deal-empty:hover {
  border-color: var(--green);
  background: var(--green-soft);
}
.screen[data-screen="deals"] .button--create-client.button--create-deal-empty > i {
  font-size: 22px;
}
.screen[data-screen="client"] .search-footer > .button--search {
  grid-column: 1 / -1;
}

/* Модальные футеры — прежний 30/70, без bottom-nav chrome. */
.search-form .step-footer.search-footer:not(.selection-bar),
.deal-form .step-footer:not(.selection-bar) {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 7fr);
  align-items: stretch;
  gap: 8px;
  border-top: .5px solid var(--line);
}
.deal-form .step-footer:not(.selection-bar) > .button {
  width: 100%;
  min-width: 0;
  margin: 0;
}
.deal-form .step-footer:not(.selection-bar) > .step-footer__back { grid-column: 1; }
.deal-form .step-footer:not(.selection-bar) > .button--primary { grid-column: 2; }
.deal-form .step-footer:not(.selection-bar) > .button:only-child { grid-column: 1 / -1; }
.deal-form .step-footer.step-footer--stack:not(.selection-bar) {
  grid-template-columns: 1fr;
}
.deal-form .step-footer.step-footer--stack:not(.selection-bar) > .button,
.deal-form .step-footer.step-footer--stack:not(.selection-bar) > .button--primary,
.deal-form .step-footer.step-footer--stack:not(.selection-bar) > .step-footer__back {
  grid-column: 1 / -1;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin: 0;
}
.screen[data-screen="configure"] > .sticky-action { margin-top: 0; }
.copy-product-slot { margin-top: 16px; }
.copy-product-action { margin: 0; }
.summary-edit {
  display: grid;
  place-items: center;
  width: var(--icon-size);
  min-height: var(--icon-size);
  padding: 0;
  border: .5px solid color-mix(in srgb, var(--green) 35%, var(--line));
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  text-decoration: none;
}
.summary-edit i { font-size: 16px; }
.success-screen {
  justify-content: flex-start;
  align-items: stretch;
  min-height: 100dvh;
}
.success-screen > .topbar,
.success-screen > .success-copy,
.success-screen > .success-actions {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}
.success-screen .topbar .icon-button {
  color: var(--green);
  border-color: var(--line);
  background: var(--paper);
  pointer-events: none;
}
.success-copy {
  display: grid;
  gap: 8px;
  width: 100%;
  margin: 8px 0 16px;
}
.success-screen h1,
.success-deal {
  margin: 0;
  color: var(--ink);
  font-family: var(--display);
  font-size: clamp(34px, 8vw, 48px);
  font-weight: 500;
  letter-spacing: -.045em;
  line-height: .98;
}
.success-deal[hidden] { display: none; }
.success-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: var(--body-size);
  line-height: 1.45;
}
.success-actions {
  display: grid;
  gap: 8px;
  width: 100%;
  margin-top: 0;
}
.success-actions__row {
  display: grid;
  gap: 8px;
  margin: 0;
  grid-template-columns: 1fr;
}
.success-actions__row--docs,
.success-actions__row--primary {
  grid-template-columns: 1fr;
}
.success-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 40px;
  height: 40px;
  margin: 0;
  padding: 0 14px;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
}
.success-actions .button--quiet.success-action { margin-top: 0; }
.success-action > i {
  flex: 0 0 auto;
  font-size: 16px;
  line-height: 1;
}
.success-action > span {
  max-width: 100%;
  font-size: var(--body-size);
  font-weight: 600;
  letter-spacing: .01em;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
}
.success-action--new {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}
@media (max-width: 390px) {
  .screen-heading h1, .screen-heading h2, .lockup h1, .success-screen h1, .success-deal { font-size: 34px; }
  .screen-heading--compact h1, .screen-heading--compact h2 { font-size: 24px; }
}

/* Nested measurement sections use Hugeicons +/-. Hide native markers
   and legacy CSS +/- so they cannot overlap the icon. */
.fit-section > summary {
  list-style: none !important;
}

.fit-section > summary::-webkit-details-marker {
  display: none !important;
}

.fit-section > summary::marker {
  content: "" !important;
}

.fit-section > summary::after,
.fit-section[open] > summary::after {
  content: none !important;
}

.material-slot { margin: 0 0 7px; }
.material-slot:empty { display: none; }
.material-panel.config-accordion { margin: 0; }
.template-actions { display: flex; flex-wrap: wrap; align-items: end; gap: 10px; margin: 12px 0; }
.template-actions .material-field { display: grid; gap: 6px; min-width: min(100%, 280px); flex: 1 1 240px; }
.template-actions .material-field > span:first-child {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}
.summary-photos { display: grid; gap: 10px; margin: 16px 0 0; padding-top: 16px; border-top: .5px solid var(--line); }
.summary-photos__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.summary-wishes__head small,
.summary-photos__head small,
.summary-photos__note {
  color: var(--muted, #69736b);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
}
.summary-photos__actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.photo-picker { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 12px; border: .5px solid var(--line); border-radius: 10px; background: var(--white); color: var(--ink); font-size: 13px; font-weight: 600; cursor: pointer; }
.photo-picker:hover { border-color: var(--green); background: var(--green-soft); color: var(--green); }
.photo-picker:focus-within { outline: 2px solid var(--green); outline-offset: 2px; }
.photo-picker--camera { border-color: color-mix(in srgb, var(--green) 35%, var(--line)); color: var(--green); }
.photo-picker input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.summary-photos__selected { display: flex; flex-wrap: wrap; gap: 8px; min-height: 20px; color: var(--muted); font-size: 12px; }
.summary-photo-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px;
  height: 72px;
  padding: 0;
  overflow: hidden;
  border: .5px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
}
.summary-photo-chip__thumb {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  background: color-mix(in srgb, var(--line) 35%, var(--white));
}
.summary-photo-chip button {
  position: absolute;
  top: 4px;
  right: 4px;
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--white) 88%, transparent);
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(0, 0, 0, .12);
  cursor: pointer;
}
.summary-photo-chip button:hover { background: var(--white); color: var(--danger, #a34336); }
.summary-photo-chip button:focus-visible { outline: 1px solid var(--green); outline-offset: 1px; }
@media (max-width: 390px) { .summary-photos__actions { grid-template-columns: 1fr; } }
