/* ----- Vitruvian Tailor — beta styles ----- */
/* Brand palette: cream, charcoal, deep forest, muted gold */

:root {
  --bg: #F5F1E8;
  --bg-soft: #EDE6D5;
  --ink: #1A1A1A;
  --ink-soft: #4A453E;
  --ink-mute: #8A8278;
  --line: #DCD5C3;
  --line-soft: #E8E2D4;
  --accent: #2D4A3E;
  --accent-soft: #3C5F50;
  --gold: #B8956A;
  --gold-soft: #C9A87C;
  --danger: #8C2F2F;
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 18px;
  --serif: "Cormorant Garamond", "Georgia", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --shadow-sm: 0 1px 2px rgba(26,26,26,.04), 0 2px 8px rgba(26,26,26,.04);
  --shadow: 0 4px 12px rgba(26,26,26,.06), 0 12px 32px rgba(26,26,26,.06);
  --shadow-lg: 0 12px 36px rgba(26,26,26,.12), 0 24px 64px rgba(26,26,26,.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
}

@media (max-width: 720px) {
  .container { padding: 0 20px; }
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }

img, svg { display: block; max-width: 100%; }

/* ===== HEADER ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(245, 241, 232, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line-soft);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--serif);
  font-weight: 500;
  font-size: 18px;
  letter-spacing: 0.12em;
}

.logo-mark {
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-mark-image {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid rgba(220, 213, 195, 0.95);
  box-shadow: var(--shadow-sm);
  background: #F9F4EA;
}

.logo-mark-image--mono {
  object-fit: contain;
  padding: 2px;
}

.logo-text { color: var(--ink); }
.logo-thin { color: var(--ink-mute); font-weight: 300; }

.primary-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
  font-weight: 400;
}

.primary-nav a {
  color: var(--ink-soft);
  transition: color 0.15s ease;
}

.primary-nav a:hover { color: var(--ink); }

@media (max-width: 800px) {
  .primary-nav { gap: 16px; }
  .primary-nav a:not(.btn) { display: none; }
}

/* On phones only the primary CTA survives — two buttons overflow 375px,
   and the full wordmark wraps, so the monogram carries "· TAILOR". */
@media (max-width: 560px) {
  .primary-nav { gap: 12px; }
  .primary-nav .btn-ghost { display: none; }
  .header-inner .logo-text { font-size: 15px; white-space: nowrap; }
  .header-inner .logo-thin { display: none; }
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  padding: 10px 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.18s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--ink);
  color: var(--bg);
}
.btn-primary:hover {
  background: var(--accent);
  color: var(--bg);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover { background: var(--bg-soft); color: var(--ink); }

.btn-link {
  background: transparent;
  color: var(--ink-soft);
  padding: 10px 12px;
}
.btn-link:hover { color: var(--ink); }

.btn-lg {
  font-size: 15px;
  padding: 14px 28px;
}

.btn-outline {
  background: transparent;
  border-color: var(--ink);
  color: var(--ink);
}
.btn-outline:hover { background: var(--ink); color: var(--bg); }

/* ===== HERO ===== */
.hero {
  padding: 80px 0 120px;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
}

@media (max-width: 900px) {
  .hero { padding: 48px 0 72px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
}

.eyebrow {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 18px;
}

.display {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(48px, 7vw, 88px);
  line-height: 1.02;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 24px;
}

.display em {
  font-style: italic;
  font-weight: 300;
  color: var(--accent);
}

.lede {
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin-bottom: 36px;
  max-width: 520px;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.trust-row {
  display: flex;
  gap: 20px;
  font-size: 13px;
  color: var(--ink-mute);
  flex-wrap: wrap;
}

.hero-art {
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--ink);
  position: relative;
}

.hero-art-logo {
  justify-content: flex-end;
}

.brand-panel {
  width: 100%;
  max-width: 560px;
  padding: 36px 34px 30px;
  border-radius: 28px;
  background: rgba(245, 241, 232, 0.78);
  border: 1px solid rgba(220, 213, 195, 0.95);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  text-align: center;
}

.brand-logo-image {
  width: min(100%, 520px);
  height: auto;
  margin: 0 auto;
  display: block;
}

.brand-panel-note {
  margin-top: 18px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--ink-mute);
}

.brand-panel-caption {
  margin-top: 10px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: var(--ink-soft);
}

.brand-callout {
  margin-top: 0;
}

.brand-callout-inner {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: 28px;
  align-items: center;
}

.brand-callout-logo {
  width: 100%;
  height: auto;
  border-radius: 22px;
  border: 1px solid var(--line-soft);
  box-shadow: var(--shadow);
  background: #F9F4EA;
}

@media (max-width: 900px) {
  .brand-callout-inner {
    grid-template-columns: 1fr;
  }
}

.vitruvian-svg {
  width: 100%;
  max-width: 420px;
  height: auto;
}

.hero-photo {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--line-soft);
}

.hero-photo-wrap {
  position: relative;
  width: 100%;
}

.hero-photo-mark {
  position: absolute;
  bottom: -14px;
  right: -14px;
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 10px 16px;
  border-radius: 999px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--ink-soft);
  letter-spacing: 0.02em;
  box-shadow: var(--shadow-sm);
}

/* ===== SECTIONS ===== */
section { padding: 96px 0; }

@media (max-width: 720px) {
  section { padding: 64px 0; }
}

.section-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1.15;
  letter-spacing: -0.005em;
  margin-bottom: 16px;
  color: var(--ink);
}

.section-lede {
  font-size: 18px;
  color: var(--ink-soft);
  max-width: 640px;
  margin-bottom: 48px;
}

/* ===== PROBLEM ===== */
.problem { background: var(--bg-soft); border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }

.problem-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  margin-top: 32px;
}

@media (max-width: 800px) {
  .problem-grid { grid-template-columns: 1fr; }
}

.problem-card {
  background: var(--bg);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 32px;
}

.problem-card .num {
  display: inline-block;
  font-family: var(--serif);
  font-style: italic;
  font-size: 32px;
  color: var(--gold);
  margin-bottom: 16px;
}

.problem-card h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 26px;
  line-height: 1.2;
  margin-bottom: 12px;
}

.problem-card p {
  color: var(--ink-soft);
  line-height: 1.6;
}

/* ===== HOW IT WORKS ===== */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin-top: 32px;
}

@media (max-width: 900px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 520px) {
  .steps { grid-template-columns: 1fr; }
}

.step {
  position: relative;
  padding-top: 20px;
}

.step::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 40px;
  height: 1px;
  background: var(--accent);
}

.step-num {
  display: inline-block;
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--accent);
  margin-bottom: 12px;
  letter-spacing: 0.1em;
}

.step h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 24px;
  margin-bottom: 10px;
  line-height: 1.2;
}

.step p {
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.6;
}

/* ===== CATEGORIES ===== */
.categories { background: var(--bg-soft); border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }

.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.cat-card {
  background: var(--bg);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.cat-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.cat-img {
  height: 240px;
  background-color: var(--bg-soft);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  position: relative;
  overflow: hidden;
}

.cat-shirt   { background-image: url('assets/shirt.jpg'); }
.cat-chino   { background-image: url('assets/chino.jpg'); }
.cat-trouser { background-image: url('assets/trouser.jpg'); }
.cat-tee     { background-image: url('assets/tee.jpg'); }
.cat-suit    { background-image: url('assets/suit.jpg'); }

.cat-card h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 22px;
  padding: 20px 20px 6px;
  line-height: 1.2;
}

.cat-card p {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.55;
  padding: 0 20px 22px;
}

/* ===== CTA ===== */
.cta {
  text-align: center;
  background: var(--ink);
  color: var(--bg);
}

.cta-inner { max-width: 720px; margin: 0 auto; }

.cta h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.15;
  margin-bottom: 20px;
  color: var(--bg);
}

.cta p {
  color: rgba(245, 241, 232, 0.75);
  font-size: 17px;
  margin-bottom: 32px;
}

.cta .btn-primary {
  background: var(--bg);
  color: var(--ink);
}
.cta .btn-primary:hover { background: var(--gold); color: var(--ink); }

/* ===== FOOTER ===== */
.site-footer {
  background: var(--bg-soft);
  border-top: 1px solid var(--line-soft);
  padding: 56px 0;
  text-align: center;
}

.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: 0.12em;
  font-size: 16px;
  margin-bottom: 14px;
}

.footer-tag {
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: var(--ink-soft);
  margin-bottom: 16px;
}

.footer-small {
  font-size: 12px;
  color: var(--ink-mute);
}

/* =============================================
   PROFILE / MEASUREMENT BUILDER PAGE
   ============================================= */
.profile-page {
  background: var(--bg);
  min-height: 100vh;
}

.profile-shell {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 48px;
  padding: 56px 0 96px;
}

@media (max-width: 1000px) {
  .profile-shell { grid-template-columns: 1fr; gap: 32px; }
}

.profile-figure {
  position: sticky;
  top: 100px;
  align-self: start;
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  padding: 32px;
}

@media (max-width: 1000px) {
  .profile-figure { position: static; }
}

.profile-figure h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 28px;
  margin-bottom: 8px;
}

.profile-figure p {
  color: var(--ink-soft);
  font-size: 14px;
  margin-bottom: 20px;
}

.body-svg-wrap {
  position: relative;
  width: 100%;
  max-width: 360px;
  margin: 0 auto;
}

.body-svg {
  width: 100%;
  height: auto;
  color: var(--ink);
}

.hot {
  fill: var(--gold);
  fill-opacity: 0.85;
  stroke: var(--bg);
  stroke-width: 2;
  cursor: pointer;
  transition: all 0.18s ease;
}

.hot:hover {
  fill: var(--accent);
  r: 9;
}

.hot.done {
  fill: var(--accent);
}

.profile-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-card {
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 28px 32px;
}

.form-card h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 22px;
  margin-bottom: 16px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (max-width: 560px) {
  .form-grid { grid-template-columns: 1fr; }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field label {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.field label .help-btn {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink-mute);
  width: 18px;
  height: 18px;
  border-radius: 50%;
  font-size: 11px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  padding: 0;
}

.field label .help-btn:hover {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.field input, .field select {
  font-family: var(--sans);
  font-size: 15px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--ink);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field input:focus, .field select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(45,74,62,0.12);
}

.field.is-warning input,
.field.is-warning select {
  border-color: #B98D63;
  box-shadow: 0 0 0 3px rgba(185, 141, 99, 0.12);
}

.field-feedback {
  font-size: 12px;
  line-height: 1.45;
  color: var(--ink-mute);
}

.measurement-review {
  background: #F8F4EA;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-soft);
}

.measurement-review--warning {
  border-color: #D5C59F;
  background: #FBF6E8;
}

.field .measurement-review {
  margin-top: 8px;
}

.input-row {
  display: flex;
  align-items: stretch;
  gap: 0;
}

.input-row input {
  flex: 1;
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
}

.input-row .unit {
  display: flex;
  align-items: center;
  padding: 0 14px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-left: none;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 13px;
  color: var(--ink-mute);
  font-weight: 500;
}

.unit-toggle {
  display: inline-flex;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px;
  font-size: 13px;
  font-weight: 500;
}

.unit-toggle button {
  background: transparent;
  border: none;
  padding: 6px 14px;
  border-radius: 999px;
  cursor: pointer;
  color: var(--ink-mute);
  font-family: var(--sans);
}

.unit-toggle button.active {
  background: var(--ink);
  color: var(--bg);
}

.form-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 8px;
}

.form-actions .spacer { flex: 1; }

.completion-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.completion-bar-track {
  flex: 1;
  height: 6px;
  background: var(--line-soft);
  border-radius: 999px;
  overflow: hidden;
}

.completion-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  width: 0%;
  transition: width 0.3s ease;
}

.completion-bar-pct {
  font-size: 13px;
  color: var(--ink-soft);
  font-weight: 500;
  min-width: 36px;
  text-align: right;
}

/* ===== MODAL ===== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(26,26,26,0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.modal {
  background: var(--bg);
  border-radius: var(--radius-lg);
  max-width: 560px;
  width: 100%;
  max-height: 86vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--line-soft);
  transform: translateY(8px) scale(0.98);
  transition: transform 0.2s ease;
}

.modal-backdrop.open .modal {
  transform: translateY(0) scale(1);
}

.modal-header {
  padding: 28px 32px 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.modal-header h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 28px;
  line-height: 1.15;
}

.modal-close {
  background: transparent;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: var(--ink-mute);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover { background: var(--bg-soft); color: var(--ink); }

.modal-body {
  padding: 16px 32px 28px;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.65;
}

.modal-body h4 {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--ink);
  margin: 18px 0 6px;
}

.modal-body ul {
  padding-left: 18px;
  margin: 4px 0;
}

.modal-body li { margin-bottom: 4px; }

.modal-body .pro-tip {
  background: var(--bg-soft);
  border-left: 3px solid var(--gold);
  padding: 12px 16px;
  margin-top: 18px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 14px;
  font-style: italic;
  color: var(--ink-soft);
}

/* ===== TAILOR-SLIP MODE ===== */
.mode-tabs {
  display: inline-flex;
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 4px;
  margin-bottom: 28px;
}

.mode-tabs button {
  background: transparent;
  border: none;
  padding: 8px 18px;
  border-radius: 999px;
  cursor: pointer;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-soft);
}

.mode-tabs button.active {
  background: var(--ink);
  color: var(--bg);
}

.tailor-slip-panel {
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
}

.tailor-slip-panel h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 28px;
  margin-bottom: 10px;
}

.tailor-slip-panel p {
  color: var(--ink-soft);
  max-width: 480px;
  margin: 0 auto 24px;
  font-size: 15px;
}

.slip-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.upload-zone {
  display: block;
  text-align: left;
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  padding: 36px 24px;
  background: var(--bg);
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.upload-zone:hover, .upload-zone.drag {
  border-color: var(--accent);
  background: var(--bg-soft);
}

.upload-zone .upload-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(184, 149, 106, 0.12);
  color: var(--accent);
  font-size: 22px;
  margin-bottom: 12px;
}

.upload-zone strong {
  display: block;
  font-size: 16px;
  color: var(--ink);
}

.upload-zone p {
  margin: 8px 0 0;
  color: var(--ink-soft);
  font-size: 14px;
}

.upload-zone .upload-support {
  display: block;
  margin-top: 10px;
  color: var(--ink-mute);
  font-size: 13px;
}

.upload-status {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-soft);
  background: var(--bg);
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.55;
}

.slip-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 18px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--ink-soft);
  text-align: left;
}

.slip-consent input {
  margin-top: 3px;
  accent-color: var(--accent);
}

.slip-actions--stacked {
  margin-top: 0;
  justify-content: flex-start;
}

.slip-actions .btn[disabled] {
  opacity: 0.6;
  pointer-events: none;
}

.uploaded-preview {
  margin-top: 18px;
  border-radius: var(--radius);
  overflow: hidden;
  max-height: 320px;
  border: 1px solid var(--line-soft);
}

.uploaded-preview img { width: 100%; height: auto; display: block; }

/* ===== AUTH (SIGNUP) ===== */
.auth-page {
  min-height: 100vh;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 24px;
}

.auth-card {
  background: var(--bg);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  padding: 48px 44px;
  max-width: 440px;
  width: 100%;
  box-shadow: var(--shadow);
}

.auth-card .logo {
  justify-content: center;
  margin-bottom: 28px;
}

.auth-card h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 36px;
  text-align: center;
  margin-bottom: 8px;
  line-height: 1.15;
}

.auth-card .auth-sub {
  text-align: center;
  color: var(--ink-soft);
  font-size: 15px;
  margin-bottom: 32px;
}

.auth-form { display: flex; flex-direction: column; gap: 16px; }

.auth-form .btn-primary { width: 100%; padding: 14px; }

.auth-foot {
  text-align: center;
  margin-top: 22px;
  font-size: 14px;
  color: var(--ink-soft);
}
.auth-foot a { color: var(--accent); font-weight: 500; }

/* ===== DASHBOARD ===== */
.dashboard {
  padding: 56px 0 96px;
}

.dashboard-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.dashboard-hero h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(36px, 4vw, 52px);
  line-height: 1.1;
}

.dashboard-hero p {
  color: var(--ink-soft);
  font-size: 16px;
  margin-top: 6px;
}

.measure-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 32px;
}

.measure-tile {
  background: var(--bg-soft);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 18px 20px;
}

.measure-tile .name {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-mute);
  margin-bottom: 6px;
}

.measure-tile .val {
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 500;
  color: var(--ink);
}

.measure-tile .val .unit-small {
  font-size: 14px;
  color: var(--ink-mute);
  font-weight: 400;
  margin-left: 4px;
  font-family: var(--sans);
}

.measure-tile.empty .val { color: var(--ink-mute); font-style: italic; font-size: 18px; }

/* ===== UTILITIES ===== */
.muted { color: var(--ink-mute); }
.center { text-align: center; }
.flex { display: flex; }
.gap-2 { gap: 8px; }
.gap-4 { gap: 16px; }
.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }

/* Print stylesheet for tailor slip */
@media print {
  body * { visibility: hidden; }
  .print-slip, .print-slip * { visibility: visible; }
  .print-slip { position: absolute; left: 0; top: 0; width: 100%; padding: 24px; }
}

/* ===== BETA BANNER ===== */
.beta-banner {
  position: relative;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 8px 16px;
  background: #111;
  color: #f4f1ec;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-family: inherit;
  border-bottom: 1px solid #2a2a2a;
}
.beta-banner__label {
  font-weight: 600;
  letter-spacing: 0.16em;
}
.beta-banner__copy {
  letter-spacing: 0;
  text-transform: none;
  opacity: 0.85;
  font-size: 12px;
}
.beta-banner__dismiss {
  background: transparent;
  border: 1px solid #555;
  color: inherit;
  font: inherit;
  font-size: 11px;
  letter-spacing: 0.1em;
  padding: 2px 8px;
  cursor: pointer;
  border-radius: 2px;
}
.beta-banner__dismiss:hover { border-color: #f4f1ec; }
@media (max-width: 640px) {
  .beta-banner { flex-wrap: wrap; gap: 8px; padding: 8px 12px; }
  .beta-banner__copy { flex-basis: 100%; text-align: center; }
}
@media print {
  .beta-banner { display: none !important; }
}

/* ----- Legal pages (terms, returns, privacy) ----- */
.legal { max-width: 720px; margin: 0 auto; padding: 72px 0 104px; }
.legal h1 {
  font-family: var(--serif); font-weight: 400; font-size: clamp(38px, 4.4vw, 54px);
  line-height: 1.1; letter-spacing: -0.01em; margin-bottom: 16px;
}
.legal .legal-meta { font-size: 13px; color: var(--ink-mute); margin-bottom: 40px; }
.legal .lede-text {
  font-family: var(--serif); font-size: 20px; line-height: 1.6;
  color: var(--ink-soft); margin-bottom: 40px;
}
.legal h2 {
  font-family: var(--serif); font-weight: 500; font-size: 27px;
  margin: 48px 0 12px; padding-top: 20px; border-top: 1px solid var(--line-soft);
}
.legal h3 { font-family: var(--sans); font-weight: 600; font-size: 16px; margin: 26px 0 8px; }
.legal p, .legal li { font-size: 16px; line-height: 1.75; color: var(--ink); }
.legal p { margin-bottom: 16px; }
.legal ul, .legal ol { margin: 0 0 18px 22px; }
.legal li { margin-bottom: 9px; }
.legal .callout {
  background: var(--bg-soft); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px 24px; margin: 26px 0;
}
.legal .callout p:last-child { margin-bottom: 0; }
.legal dl { margin: 0 0 20px; }
.legal dt { font-weight: 600; font-size: 15px; margin-top: 14px; }
.legal dd { margin: 4px 0 0; font-size: 15px; color: var(--ink-soft); line-height: 1.7; }
.legal-nav {
  display: flex; flex-wrap: wrap; gap: 10px 18px;
  margin-bottom: 44px; padding-bottom: 20px; border-bottom: 1px solid var(--line-soft);
  font-size: 14px;
}
.legal-nav a { color: var(--ink-mute); }
.legal-nav a:hover { color: var(--accent); }
.legal-nav a[aria-current="page"] { color: var(--ink); font-weight: 500; }
.footer-legal { margin-top: 10px; font-size: 13px; }
.footer-legal a { color: var(--ink-mute); }
.footer-legal a:hover { color: var(--accent); }
.footer-entity { margin-top: 10px; font-size: 12px; color: var(--ink-mute); }

/* ----- Dashboard: order history ----- */
.orders-section { margin: 40px 0 8px; }
.orders-title { font-family: var(--serif); font-weight: 500; font-size: 28px; margin-bottom: 18px; }
.order-card {
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px 24px; margin-bottom: 14px;
  box-shadow: var(--shadow-sm);
}
.order-head {
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; margin-bottom: 6px;
}
.order-items { font-family: var(--serif); font-size: 20px; font-weight: 500; }
.order-status {
  flex-shrink: 0; padding: 4px 12px; border-radius: 999px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.04em;
  background: var(--bg-soft); color: var(--ink-soft); border: 1px solid var(--line);
}
.order-status--paid { background: var(--accent); color: var(--bg); border-color: var(--accent); }
.order-status--fulfilled { background: var(--ink); color: var(--gold); border-color: var(--ink); }
.order-status--cancelled { color: var(--ink-mute); }
.order-meta { font-size: 14px; color: var(--ink-mute); margin-bottom: 10px; }
.order-note { font-size: 14px; line-height: 1.65; color: var(--ink-soft); margin-bottom: 6px; }
.order-frozen { font-size: 13px; color: var(--ink-mute); }
@media (max-width: 520px) {
  .order-head { flex-direction: column; align-items: flex-start; gap: 8px; }
}

/* Accessible torso-only guide: native buttons support keyboard and touch. */
.profile-figure .guide-eyebrow { font-size: 10px; letter-spacing: .13em; margin-bottom: 10px; color: var(--gold); }
.torso-guide { position: relative; max-width: 320px; margin: 0 auto; }
.torso-guide img { display: block; width: 100%; height: auto; border-radius: 12px; }
.guide-point { position: absolute; transform: translate(-50%, -50%); width: 36px; height: 36px; padding: 0; border: 2px solid var(--bg); border-radius: 50%; background: var(--accent); color: #fff; font: 600 12px var(--sans); cursor: pointer; box-shadow: 0 2px 8px #203b3026; }
.guide-point:hover, .guide-point.done { background: var(--gold); color: var(--ink); }
.guide-point:focus-visible, .guide-basics button:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.guide-basics { display: flex; gap: 10px; margin: 18px 0 14px; }
.guide-basics button { flex: 1; padding: 10px; background: transparent; color: var(--ink); border: 1px solid var(--gold); border-radius: 6px; cursor: pointer; font: inherit; }
.guide-basics button.done { background: var(--gold); }
.profile-figure .guide-note { font-size: 12px; line-height: 1.5; margin-bottom: 12px; }
.guide-key { display: grid; grid-template-columns: 1fr 1fr; gap: 5px 24px; padding-left: 20px; font-size: 12px; color: var(--ink-soft); }

.field-instruction { font-size: 12px; line-height: 1.5; color: var(--ink-soft); margin: 0 0 12px; }
.measurement-intro { font-size: 13px; line-height: 1.6; color: var(--ink-soft); margin-bottom: 22px; }
.profile-figure .guide-note { margin-top: 16px; }
