:root {
  --bg: #f6f3ee;
  --surface: #fffdf9;
  --surface-strong: #ffffff;
  --ink: #18221f;
  --muted: #6f756f;
  --line: #ded8cd;
  --emerald: #17624a;
  --emerald-deep: #0d3d31;
  --clay: #b66a48;
  --sand: #e8dccb;
  --blue: #315a6f;
  --amber: #c69335;
  --shadow: 0 18px 42px rgba(28, 36, 32, 0.1);
  --radius: 8px;
  font-family: "Segoe UI", Tahoma, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
}

[hidden] {
  display: none !important;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.auth-shell {
  display: grid;
  grid-template-columns: minmax(360px, 0.85fr) minmax(460px, 1.15fr);
  min-height: 100vh;
  background:
    linear-gradient(120deg, rgba(23, 98, 74, 0.08), rgba(182, 106, 72, 0.08)),
    var(--bg);
}

.auth-brand-panel {
  display: flex;
  flex-direction: column;
  gap: 34px;
  padding: clamp(28px, 5vw, 64px);
  background:
    linear-gradient(0deg, rgba(26, 39, 34, 0.9), rgba(26, 39, 34, 0.68)),
    url("./assets/design-bedroom.png") center / cover;
  color: #f8f3e9;
}

.auth-brand {
  color: #f8f3e9;
}

.auth-copy {
  max-width: 620px;
}

.auth-copy h1 {
  margin: 0;
  color: #ffffff;
  font-size: clamp(30px, 4vw, 54px);
  line-height: 1.18;
}

.auth-copy p {
  margin: 18px 0 0;
  color: #d5cebf;
  font-size: 16px;
  line-height: 1.9;
}

.auth-roadmap {
  display: grid;
  gap: 12px;
  margin-top: auto;
}

.auth-roadmap div {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 12px;
  padding: 13px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
}

.auth-roadmap span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #cf9d57;
  color: #17231f;
  font-weight: 900;
}

.auth-roadmap strong,
.auth-roadmap small {
  display: block;
}

.auth-roadmap small {
  margin-top: 5px;
  color: #d5cebf;
  line-height: 1.5;
}

.auth-card {
  align-self: center;
  justify-self: center;
  width: min(680px, calc(100% - 40px));
  max-height: calc(100vh - 48px);
  overflow: auto;
  padding: clamp(22px, 4vw, 38px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-strong);
  box-shadow: var(--shadow);
}

.auth-page {
  display: none;
}

.auth-page.active {
  display: block;
}

.auth-header {
  margin-bottom: 20px;
}

.auth-header .panel-label {
  margin-bottom: 12px;
}

.auth-header h2 {
  font-size: clamp(26px, 3vw, 36px);
}

.auth-header p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.8;
}

.auth-secondary {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}

.auth-secondary.single {
  justify-content: center;
}

.auth-secondary button {
  border: 0;
  background: transparent;
  color: var(--emerald);
  font-weight: 800;
}

.field {
  position: relative;
}

.field-error {
  min-height: 18px;
  color: #a33a2e;
  font-size: 12px;
  font-weight: 700;
}

input.invalid,
.password-field:has(input.invalid) {
  border-color: #c65445;
  box-shadow: 0 0 0 3px rgba(198, 84, 69, 0.12);
}

.password-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  border: 1px solid #d8d0c4;
  border-radius: 7px;
  background: #ffffff;
}

.password-field input {
  border: 0;
  box-shadow: none;
}

.password-field input:focus {
  box-shadow: none;
}

.password-field:focus-within {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(23, 98, 74, 0.14);
}

.password-toggle {
  min-width: 58px;
  height: 34px;
  margin-inline-end: 6px;
  border: 0;
  border-radius: 6px;
  background: #eef5ef;
  color: var(--emerald-deep);
  font-size: 12px;
  font-weight: 800;
}

.check-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.check-row input {
  width: 18px;
  min-width: 18px;
  height: 18px;
  margin-top: 2px;
}

.dev-logins {
  display: none;
  margin-top: 14px;
  border-top: 1px solid #eee5da;
  padding-top: 12px;
}

body.show-dev-logins .dev-logins {
  display: block;
}

.dev-logins summary {
  cursor: pointer;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.stepper {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.stepper li {
  min-height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid #e0d6ca;
  border-radius: 7px;
  background: #fbf7f0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.stepper li.active {
  border-color: var(--emerald);
  background: var(--emerald);
  color: #ffffff;
}

.stepper li.done {
  border-color: #a8c6b5;
  background: #edf7f1;
  color: var(--emerald-deep);
}

.supplier-step {
  display: none;
}

.supplier-step.active {
  display: grid;
  gap: 12px;
}

.step-actions {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding-top: 16px;
  border-top: 1px solid #eee5da;
}

.review-box {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid #e1d7ca;
  border-radius: var(--radius);
  background: #fbf7f0;
}

.review-box div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #eee5da;
}

.review-box div:last-child {
  border-bottom: 0;
}

.review-box span {
  color: var(--muted);
  font-size: 12px;
}

.review-box strong {
  text-align: left;
}

.app-shell {
  display: grid;
  grid-template-columns: 292px minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding: 24px;
  background: #1a2722;
  color: #f8f3e9;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: #cf9d57;
  color: #16231f;
  border-radius: var(--radius);
  font-weight: 800;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 18px;
}

.brand small {
  margin-top: 4px;
  color: #cfc7b9;
  font-size: 12px;
  line-height: 1.5;
}

.main-nav {
  display: grid;
  gap: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 12px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: #e7e0d4;
  text-align: right;
}

.nav-item svg,
.top-actions svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-item.active,
.nav-item:hover {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.nav-item.disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.sidebar-note {
  margin-top: auto;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
}

.sidebar-note strong,
.sidebar-note span {
  display: block;
}

.sidebar-note span {
  margin-top: 8px;
  color: #d5cebf;
  font-size: 13px;
  line-height: 1.7;
}

.workspace {
  min-width: 0;
  padding: 26px;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

.section-kicker {
  margin: 0 0 8px;
  color: var(--clay);
  font-weight: 700;
  font-size: 13px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 0;
  font-size: clamp(25px, 3vw, 40px);
  line-height: 1.25;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 20px;
}

h3 {
  margin-bottom: 8px;
  font-size: 18px;
}

.top-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.auth-actions {
  align-items: center;
}

.session-card {
  min-width: 210px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-strong);
}

.session-card span,
.session-card small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.session-card strong {
  display: block;
  margin: 3px 0;
  font-size: 15px;
}

.primary-button,
.ghost-button,
.wide-action {
  border-radius: var(--radius);
  min-height: 44px;
  padding: 0 16px;
  font-weight: 700;
}

.primary-button,
.wide-action {
  border: 1px solid var(--emerald-deep);
  background: var(--emerald);
  color: #ffffff;
}

.ghost-button {
  border: 1px solid var(--line);
  background: var(--surface-strong);
  color: var(--ink);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.view {
  display: none;
}

.active-view {
  display: block;
}

.customer-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.92fr) minmax(420px, 1.35fr) minmax(280px, 0.8fr);
  gap: 16px;
  align-items: start;
}

.accounts-layout,
.auth-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.7fr) minmax(420px, 1.1fr) minmax(280px, 0.8fr);
  gap: 16px;
  align-items: start;
}

.auth-layout {
  grid-template-columns: minmax(300px, 0.85fr) minmax(460px, 1.15fr) minmax(260px, 0.7fr);
}

.auth-stage {
  min-height: 620px;
}

.auth-title {
  margin-bottom: 18px;
}

.auth-title .panel-label {
  margin-bottom: 12px;
}

.auth-title p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.auth-choice-grid {
  display: grid;
  gap: 12px;
}

.auth-choice {
  display: block;
  width: 100%;
  min-height: 112px;
  padding: 18px;
  border: 1px solid #d8d0c4;
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--ink);
  text-align: right;
}

.auth-choice.primary {
  border-color: rgba(23, 98, 74, 0.35);
  background: #eef7f1;
}

.auth-choice:hover {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(23, 98, 74, 0.1);
}

.auth-choice strong,
.auth-choice span {
  display: block;
}

.auth-choice strong {
  font-size: 20px;
}

.auth-choice span {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.6;
}

.back-link {
  margin-bottom: 16px;
  border: 0;
  background: transparent;
  color: var(--emerald);
  font-weight: 800;
}

.auth-flow-steps {
  display: grid;
  gap: 12px;
}

.flow-step {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 12px;
  border: 1px solid #e3d8ca;
  border-radius: var(--radius);
  background: #ffffff;
}

.flow-step.active {
  border-color: rgba(23, 98, 74, 0.35);
  background: #eef7f1;
}

.flow-step > span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--sand);
  color: var(--emerald-deep);
  font-weight: 900;
}

.flow-step strong,
.flow-step small {
  display: block;
}

.flow-step small {
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.5;
}

.form-section-title {
  margin-top: 4px;
  padding: 10px 0 2px;
  border-top: 1px solid #eee5da;
  color: var(--emerald-deep);
  font-weight: 900;
}

.account-form {
  display: grid;
  gap: 12px;
}

.demo-logins {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 14px;
}

.demo-logins button,
.segment,
.row-actions button {
  min-height: 38px;
  border: 1px solid #d8d0c4;
  border-radius: 7px;
  background: #ffffff;
  color: var(--ink);
  font-weight: 700;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 14px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #f4ede2;
}

.segment.active {
  border-color: var(--emerald);
  background: var(--emerald);
  color: #ffffff;
}

.supplier-fields {
  display: none;
  gap: 12px;
}

.supplier-fields.show {
  display: grid;
}

.profile-card {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.profile-card.compact {
  margin-bottom: 14px;
}

.profile-avatar {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  background: var(--emerald);
  color: #ffffff;
  font-size: 22px;
  font-weight: 900;
}

.profile-card strong,
.profile-card span {
  display: block;
}

.profile-card span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.profile-card dl,
.detail-list {
  display: grid;
  grid-column: 1 / -1;
  gap: 8px;
  margin: 12px 0 0;
}

.profile-card dl div,
.detail-list div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 0;
  border-top: 1px solid #eee5da;
}

dt {
  color: var(--muted);
  font-size: 12px;
}

dd {
  margin: 0;
  color: var(--ink);
  font-weight: 700;
  text-align: left;
}

.account-policy {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.account-policy div,
.approval-banner {
  padding: 12px;
  border: 1px solid #e1d7ca;
  border-radius: var(--radius);
  background: #ffffff;
}

.account-policy strong,
.account-policy span,
.approval-banner strong,
.approval-banner span {
  display: block;
}

.account-policy span,
.approval-banner span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.approval-banner {
  margin-bottom: 16px;
}

.approval-banner.success {
  border-color: #a6ccb8;
  background: #edf7f1;
}

.approval-banner.warning {
  border-color: #e2c47e;
  background: #fff8df;
}

.approval-banner.danger {
  border-color: #d9a09a;
  background: #fff0ee;
}

.approval-banner.info {
  border-color: #c4d2dc;
  background: #eef6fa;
}

.panel,
.metric {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel {
  padding: 18px;
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.panel-heading > div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel-label {
  display: grid;
  place-items: center;
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  border-radius: 6px;
  background: var(--sand);
  color: var(--emerald-deep);
  font-weight: 800;
  font-size: 13px;
}

.status-chip {
  border: 1px solid #d7c4ad;
  border-radius: 999px;
  padding: 6px 10px;
  color: #6d4b2f;
  background: #fff7ed;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.intake-form,
.supplier-form {
  display: grid;
  gap: 12px;
}

label {
  display: grid;
  gap: 7px;
  color: #39413d;
  font-size: 13px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #d8d0c4;
  border-radius: 7px;
  background: #ffffff;
  color: var(--ink);
  padding: 10px 11px;
  outline: none;
}

textarea {
  resize: vertical;
  line-height: 1.7;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(23, 98, 74, 0.14);
}

.form-row,
.treatment-grid {
  display: grid;
  gap: 10px;
}

.form-row.three {
  grid-template-columns: repeat(3, 1fr);
}

.form-row.two,
.treatment-grid {
  grid-template-columns: repeat(2, 1fr);
}

.photo-wall {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 14px 0;
}

.photo-slot {
  min-height: 88px;
  border: 1px dashed #b8a997;
  border-radius: var(--radius);
  background: linear-gradient(145deg, #fffaf1, #eee2d1);
  color: #54483c;
}

.photo-slot span,
.photo-slot small {
  display: block;
}

.photo-slot span {
  font-weight: 800;
}

.photo-slot small {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.wide-action {
  width: 100%;
}

.design-options {
  display: grid;
  gap: 14px;
}

.design-card {
  display: grid;
  grid-template-columns: 196px minmax(0, 1fr);
  gap: 14px;
  padding: 10px;
  border: 1px solid #ded7ca;
  border-radius: var(--radius);
  background: #ffffff;
}

.design-card.selected {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(23, 98, 74, 0.12);
}

.design-card img {
  width: 100%;
  height: 168px;
  object-fit: cover;
  border-radius: 7px;
  background: #ddd;
}

.design-content {
  min-width: 0;
}

.design-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.design-cost {
  color: var(--emerald);
  font-weight: 900;
  white-space: nowrap;
}

.design-copy {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.palette {
  display: flex;
  gap: 6px;
  margin: 10px 0;
}

.swatch {
  width: 24px;
  height: 24px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 50%;
}

.design-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 10px 0;
}

.design-tags span {
  border: 1px solid #ddd3c5;
  border-radius: 999px;
  padding: 5px 8px;
  background: #fbf7f0;
  color: #5f554b;
  font-size: 12px;
  font-weight: 700;
}

.select-design {
  border: 1px solid var(--emerald);
  border-radius: 7px;
  background: #f3faf5;
  color: var(--emerald-deep);
  padding: 9px 12px;
  font-weight: 800;
}

.summary-block {
  display: grid;
  gap: 5px;
  padding: 14px;
  border-radius: var(--radius);
  background: #eef5ef;
}

.summary-block span,
.cost-lines span,
.total-line span {
  color: var(--muted);
  font-size: 13px;
}

.summary-block strong {
  font-size: 18px;
}

.cost-lines {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.cost-line,
.total-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.cost-line strong,
.total-line strong {
  white-space: nowrap;
}

.total-line {
  align-items: center;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.total-line strong {
  color: var(--emerald);
  font-size: 21px;
}

.timeline {
  display: grid;
  gap: 14px;
  margin-top: 22px;
}

.timeline-step {
  display: flex;
  gap: 10px;
  align-items: center;
  color: var(--muted);
}

.timeline-step span {
  width: 12px;
  height: 12px;
  border: 2px solid #bbb1a5;
  border-radius: 50%;
}

.timeline-step.done span,
.timeline-step.active span {
  border-color: var(--emerald);
  background: var(--emerald);
}

.timeline-step p {
  margin: 0;
  font-size: 13px;
}

.supplier-layout,
.ops-layout,
.admin-layout {
  display: grid;
  grid-template-columns: minmax(300px, 0.75fr) minmax(420px, 1.25fr);
  gap: 16px;
}

.admin-layout {
  grid-template-columns: minmax(560px, 1.35fr) minmax(330px, 0.85fr);
}

.admin-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 16px;
}

.admin-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.compact-select {
  max-width: 210px;
}

.catalog-table,
.order-list,
.rules-list,
.accounts-table {
  display: grid;
  gap: 10px;
}

.product-row,
.order-row,
.rules-list div {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr 0.75fr 0.75fr;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid #e4ded3;
  border-radius: var(--radius);
  background: #ffffff;
}

.product-row strong,
.order-row strong,
.rules-list strong {
  display: block;
}

.product-row span,
.order-row span,
.rules-list span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.ops-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 16px;
}

.metric {
  padding: 18px;
}

.metric span,
.metric small {
  display: block;
  color: var(--muted);
}

.metric strong {
  display: block;
  margin: 10px 0 6px;
  font-size: 30px;
}

.rules-list div {
  grid-template-columns: 0.7fr 1.3fr;
}

.account-row {
  display: grid;
  grid-template-columns: minmax(200px, 1.2fr) 0.45fr 0.55fr minmax(190px, 0.85fr);
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid #e4ded3;
  border-radius: var(--radius);
  background: #ffffff;
}

.account-row.selected {
  border-color: var(--emerald);
  box-shadow: 0 0 0 3px rgba(23, 98, 74, 0.1);
}

.account-main {
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  text-align: right;
}

.account-main strong,
.account-main span {
  display: block;
}

.account-main span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.account-status {
  justify-self: start;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 800;
}

.account-status.active {
  background: #edf7f1;
  color: #17624a;
}

.account-status.pending {
  background: #fff8df;
  color: #8a5d13;
}

.account-status.suspended {
  background: #fff0ee;
  color: #a33a2e;
}

.row-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.row-actions button {
  min-height: 34px;
  padding: 0 9px;
  font-size: 12px;
}

.detail-list {
  margin-bottom: 16px;
}

.admin-edit-grid {
  display: grid;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.toast {
  position: fixed;
  left: 24px;
  bottom: 24px;
  max-width: min(420px, calc(100vw - 48px));
  padding: 14px 16px;
  border-radius: var(--radius);
  background: #17231f;
  color: #ffffff;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: 180ms ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1200px) {
  .auth-shell {
    grid-template-columns: 1fr;
  }

  .auth-brand-panel {
    min-height: auto;
  }

  .auth-roadmap {
    grid-template-columns: repeat(2, 1fr);
  }

  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 5;
    flex-direction: row;
    align-items: center;
    padding: 14px 18px;
  }

  .main-nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    flex: 1;
  }

  .sidebar-note {
    display: none;
  }

  .customer-grid,
  .accounts-layout,
  .auth-layout,
  .admin-layout {
    grid-template-columns: 1fr 1fr;
  }

  .cart-panel,
  .profile-panel,
  .auth-stage,
  .admin-detail-panel {
    grid-column: 1 / -1;
  }

  .ops-grid,
  .admin-metrics {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 780px) {
  .auth-shell {
    display: block;
  }

  .auth-brand-panel {
    padding: 22px;
  }

  .auth-copy h1 {
    font-size: 30px;
  }

  .auth-roadmap {
    grid-template-columns: 1fr;
  }

  .auth-card {
    width: calc(100% - 24px);
    max-height: none;
    margin: 12px auto 24px;
    padding: 18px;
  }

  .auth-secondary {
    align-items: stretch;
    flex-direction: column;
  }

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

  .step-actions {
    grid-template-columns: 1fr;
  }

  .workspace {
    padding: 16px;
  }

  .sidebar {
    align-items: stretch;
    flex-direction: column;
  }

  .topbar,
  .panel-heading,
  .design-meta {
    align-items: stretch;
    flex-direction: column;
  }

  .top-actions {
    justify-content: stretch;
  }

  .top-actions button {
    flex: 1;
  }

  .customer-grid,
  .accounts-layout,
  .auth-layout,
  .supplier-layout,
  .admin-layout,
  .ops-layout,
  .ops-grid,
  .admin-metrics,
  .form-row.three,
  .form-row.two,
  .treatment-grid,
  .photo-wall,
  .demo-logins {
    grid-template-columns: 1fr;
  }

  .design-card,
  .product-row,
  .order-row,
  .rules-list div,
  .account-row {
    grid-template-columns: 1fr;
  }

  .session-card {
    width: 100%;
  }

  .design-card img {
    height: 220px;
  }
}
