:root {
  --rose: #d48a94;
  --rose-deep: #b86b75;
  --rose-soft: #f3d6da;
  --accent: var(--rose);
  --accent-deep: var(--rose-deep);
  --accent-soft: #e8a8b0;
  --gold: var(--rose);
  --gold-deep: var(--rose-deep);
  --plate: #2a1f22;
  --bg: #faf4f5;
  --surface: #ffffff;
  --surface-2: #fffcfc;
  --text: #2a1f22;
  --muted: #8a6e74;
  --line: rgba(42, 31, 34, 0.1);
  --ok: #2f9e6a;
  --danger: #c43c4a;
  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", serif;
  --font: "DM Sans", "Segoe UI", system-ui, sans-serif;
  --radius: 14px;
  --shadow: 0 18px 40px rgba(42, 31, 34, 0.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(900px 480px at 8% -8%, rgba(212, 138, 148, 0.18), transparent 55%),
    radial-gradient(700px 400px at 100% 0%, rgba(243, 214, 218, 0.55), transparent 50%),
    var(--bg);
  min-height: 100vh;
  line-height: 1.5;
}

a { color: var(--rose-deep); }

.banner {
  background: var(--plate);
  color: #f5e9eb;
  text-align: center;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  padding: 0.45rem 1rem;
  font-weight: 700;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  position: relative;
  z-index: 20;
}

.shell {
  max-width: 960px;
  margin: 0 auto;
  padding: 24px 16px 64px;
}

.shell-narrow { max-width: 560px; }
.shell-wide { max-width: 1180px; }

h1, h2, h3 {
  margin: 0 0 10px;
  letter-spacing: -0.03em;
  font-weight: 700;
}

.muted { color: var(--muted); }

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: inherit;
  text-decoration: none;
}

.brand strong { display: block; }
.brand small { color: var(--muted); font-size: 0.8rem; }

.mark {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  background: url("/assets/mark.svg") center / cover no-repeat;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.3);
}

.btn, button {
  border: 0;
  border-radius: 12px;
  background: var(--rose);
  color: #fff;
  font-weight: 700;
  padding: 0.75rem 1.1rem;
  cursor: pointer;
  font: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.btn:hover, button:hover {
  background: var(--rose-deep);
  color: #fff;
}

.btn:active, button:active { transform: translateY(1px); }

.btn-ghost, button.ghost, a.btn.ghost {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 600;
}

.btn-ghost:hover, button.ghost:hover, a.btn.ghost:hover {
  background: var(--rose-soft);
  border-color: rgba(212, 138, 148, 0.45);
  color: var(--rose-deep);
}

.btn-gold, button.btn-gold {
  background: linear-gradient(180deg, #e4a0a8, var(--rose));
  color: #fff;
}

.btn-gold:hover, button.btn-gold:hover {
  background: var(--rose-deep);
  color: #fff;
}

.btn-danger, button.btn-danger {
  background: rgba(196, 60, 74, 0.1);
  color: var(--danger);
  border: 1px solid rgba(196, 60, 74, 0.22);
}

.btn-sm, button.btn-sm {
  padding: 0.4rem 0.7rem;
  font-size: 0.85rem;
  border-radius: 9px;
}

.grid { display: grid; gap: 12px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card, .row, .stat, .panel-box {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: 0 1px 0 rgba(42, 31, 34, 0.02);
}

.stat b {
  display: block;
  font-size: 1.55rem;
  letter-spacing: -0.03em;
  color: var(--rose-deep);
}

.stat span {
  color: var(--muted);
  font-size: 0.85rem;
}

.tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
  background: var(--rose-soft);
  color: var(--rose-deep);
  white-space: nowrap;
}

.tag.done { background: rgba(47, 158, 106, 0.14); color: var(--ok); }
.tag.warn { background: rgba(212, 138, 148, 0.2); color: #9a5560; }
.tag.danger { background: rgba(196, 60, 74, 0.12); color: var(--danger); }

label {
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 600;
}

input, select, textarea {
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 0.7rem 0.85rem;
  font: inherit;
  background: var(--surface-2);
  color: var(--text);
  width: 100%;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: rgba(212, 138, 148, 0.55);
  box-shadow: 0 0 0 3px rgba(212, 138, 148, 0.18);
}

input[type="color"] { padding: 0.2rem; height: 42px; }

input[type="date"] {
  max-width: 220px;
  min-height: 44px;
  width: auto;
  min-width: 11.5rem;
  color-scheme: light;
  line-height: 1.25;
}

input[type="date"]::-webkit-calendar-picker-indicator {
  cursor: pointer;
  opacity: 0.75;
  padding: 2px;
}

.form { display: grid; gap: 14px; }
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.cta-row.tight { margin: 0; }

.error { color: var(--danger); font-size: 0.9rem; }
.ok { color: var(--ok); }
.hidden { display: none !important; }

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

.list { display: grid; gap: 10px; }

.cad-search {
  display: block;
  margin: 0 0 12px;
  max-width: 320px;
}

.hours-grid {
  display: grid;
  gap: 8px;
}

.hours-day {
  display: grid;
  grid-template-columns: 4.5rem 1fr 1fr;
  gap: 8px;
  align-items: center;
}

.hours-day span {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
}

.row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.row strong { display: block; }
.row small { color: var(--muted); }

.slot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.slot {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 11px;
  padding: 0.7rem;
  text-align: center;
  cursor: pointer;
  font-weight: 600;
  color: var(--text);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}

.slot small { color: var(--muted); font-weight: 500; }

.slot:hover {
  border-color: rgba(212, 138, 148, 0.5);
  transform: translateY(-1px);
}

.slot.selected {
  border-color: var(--rose);
  background: var(--rose-soft);
  color: var(--rose-deep);
}

.toast {
  position: fixed;
  bottom: 16px;
  right: 16px;
  background: var(--plate);
  color: #fff;
  border: 1px solid transparent;
  padding: 12px 16px;
  border-radius: 12px;
  z-index: 50;
  max-width: 320px;
  box-shadow: var(--shadow);
}

table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
th, td {
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
}
th { color: var(--muted); font-weight: 600; }

.panel { animation: fadeIn 0.28s ease; }
.section-gap { margin-top: 28px; }
.stack-gap { margin-bottom: 16px; }
.mt-20 { margin-top: 20px; }
.mt-24 { margin-top: 24px; }
.date-input { max-width: 180px; }

.reports-topbar {
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 12px;
}
.reports-actions {
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 8px;
}
.reports-date {
  display: grid;
  gap: 4px;
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 600;
}
.reports-date input {
  font-weight: 500;
  color: var(--text);
}

.select-auto { width: auto; }
.pro-name {
  border-left: 4px solid var(--rose);
  padding-left: 10px;
  display: block;
}

.pos-step {
  padding: 12px 0;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 10px;
}
.pos-step:first-of-type { border-top: 0; padding-top: 0; }
.pos-step-title {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.pos-add-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}
.pos-select { width: 100%; }
.pos-disabled { opacity: 0.55; }
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* ——— Public home ——— */
.page-public { overflow-x: hidden; }

.hero {
  position: relative;
  min-height: calc(100svh - 34px);
  display: flex;
  flex-direction: column;
  isolation: isolate;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(
      180deg,
      rgba(42, 31, 34, 0.22) 0%,
      rgba(42, 31, 34, 0.08) 28%,
      transparent 48%
    ),
    url("/assets/hero-salao.jpg") center 35% / cover no-repeat;
  animation: fadeIn 1.1s ease both;
}

.hero-photo-zone {
  flex: 1 1 auto;
  min-height: clamp(180px, 38vh, 420px);
  display: flex;
  justify-content: flex-end;
  align-items: flex-start;
  padding: 18px clamp(16px, 4vw, 28px);
  position: relative;
  z-index: 1;
}

.hero-team-link {
  color: #fffaf8;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  letter-spacing: 0.01em;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.55);
  border-bottom: 1px solid transparent;
  transition: opacity 0.2s ease, border-color 0.2s ease;
  opacity: 0.92;
}

.hero-team-link:hover {
  opacity: 1;
  border-bottom-color: rgba(255, 250, 248, 0.55);
  color: #fffaf8;
}

.hero-band {
  position: relative;
  z-index: 1;
  background: var(--bg);
  padding: 4px 0 clamp(28px, 5vh, 48px);
}

.hero-band::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: clamp(56px, 10vh, 96px);
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(250, 244, 245, 0.4) 40%,
    var(--bg) 100%
  );
  pointer-events: none;
}

.hero-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px;
  width: 100%;
}

.hero-copy {
  max-width: min(40rem, 94vw);
  animation: riseIn 0.75s ease both;
}

.hero-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
  animation: riseIn 0.7s ease both;
}

.hero-brand .mark {
  width: 48px;
  height: 48px;
  border-radius: 14px;
}

.hero-brand-name {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 5.4vw, 3.5rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--text);
  text-wrap: balance;
}

.hero-brand-meta {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
}

.hero-copy h1 {
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  font-weight: 500;
  line-height: 1.35;
  margin: 0 0 10px;
  max-width: 28em;
  text-wrap: balance;
  color: var(--plate);
}

.hero-lede {
  color: var(--muted);
  max-width: 40ch;
  margin: 0;
  font-size: 1.05rem;
}

.hero-copy .cta-row { animation: riseIn 0.7s ease 0.14s both; }

.page-public .hero-copy .btn.ghost {
  background: var(--surface);
  border-color: rgba(42, 31, 34, 0.14);
}

.public-section {
  max-width: 960px;
  margin: 0 auto;
  padding: 56px 16px 28px;
}

.public-section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 2.6vw, 1.85rem);
  font-weight: 600;
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}

.section-lede {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 0.98rem;
}

.service-list {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.service-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
}

.service-row strong {
  display: block;
  font-weight: 600;
}

.service-row small {
  color: var(--muted);
  font-size: 0.85rem;
}

.service-price {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: var(--text);
}

.section-cta {
  margin: 22px 0 0;
}

.section-cta a {
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  color: var(--rose-deep);
}

.section-cta a:hover { opacity: 0.8; }

.team-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
}

.team-item {
  margin: 0;
  padding: 16px 0 16px 14px;
  border-bottom: 1px solid var(--line);
  border-left: 3px solid var(--pro-accent, var(--rose));
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.public-footer {
  max-width: 960px;
  margin: 0 auto;
  padding: 40px 16px 64px;
  color: var(--muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--line);
}

/* ——— Booking steps ——— */
.steps {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.step-pill {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.step-pill.on {
  color: #fff;
  background: var(--rose);
  border-color: transparent;
}

.code-xl {
  font-size: 1.6rem;
  letter-spacing: 0.12em;
  color: var(--rose-deep);
  font-weight: 800;
}

.pay-qr-wrap {
  display: flex;
  justify-content: center;
  margin: 12px 0;
}
.pay-qr-wrap img {
  width: min(240px, 70vw);
  height: auto;
  border-radius: 12px;
  background: #fff;
  padding: 10px;
  border: 1px solid var(--line);
}
#pay-brcode,
#pix-modal-brcode {
  width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.75rem;
  resize: vertical;
}
.pix-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 16px;
}
.pix-modal.hidden { display: none !important; }
.pix-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(42, 31, 34, 0.45);
}
.pix-modal-card {
  position: relative;
  z-index: 1;
  width: min(420px, 100%);
  max-height: 90vh;
  overflow: auto;
}

/* ——— Admin shell ——— */
.login-wrap {
  min-height: calc(100vh - 34px);
  display: grid;
  place-items: center;
  padding: 24px 16px;
}

.login-card {
  width: 100%;
  max-width: 400px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px 24px;
  box-shadow: var(--shadow);
}

.login-card .cred {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 8px 0 0;
}

.app-shell {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: calc(100vh - 34px);
}

.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--line);
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: sticky;
  top: 0;
  height: calc(100vh - 34px);
  overflow-y: auto;
}

.sidebar .brand { padding: 4px 8px 16px; }

.nav-group {
  margin-top: 10px;
}

.nav-group-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 8px 10px 6px;
}

.nav-tabs {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
}

.nav-tabs button {
  background: transparent;
  border: 1px solid transparent;
  color: var(--muted);
  font-weight: 600;
  padding: 0.55rem 0.85rem;
  justify-content: flex-start;
  border-radius: 10px;
  width: 100%;
}

.nav-tabs button:hover {
  background: rgba(212, 138, 148, 0.08);
  color: var(--text);
}

.nav-tabs button.active {
  background: var(--rose-soft);
  border-color: rgba(212, 138, 148, 0.4);
  color: var(--rose-deep);
}

.app-main {
  padding: 22px 22px 48px;
  min-width: 0;
}

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

.sidebar-toggle {
  display: none;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
}

.sidebar-backdrop {
  display: none;
}

@keyframes riseIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-media,
  .hero-copy,
  .hero-brand,
  .hero-copy .cta-row,
  .panel,
  .btn, button, .slot {
    animation: none !important;
    transition: none !important;
  }
}

@media (max-width: 900px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed;
    left: 0;
    top: 34px;
    bottom: 0;
    width: min(280px, 86vw);
    z-index: 40;
    transform: translateX(-105%);
    transition: transform 0.25s ease;
    height: auto;
    box-shadow: var(--shadow);
  }
  .sidebar.open { transform: translateX(0); }
  .sidebar-backdrop.open {
    display: block;
    position: fixed;
    inset: 34px 0 0;
    background: rgba(42, 31, 34, 0.35);
    z-index: 35;
  }
  .sidebar-toggle { display: inline-flex; }
  .app-main { padding: 16px 14px 48px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .hero { min-height: calc(100svh - 34px); }
  .hero-copy .cta-row { flex-direction: column; align-items: stretch; }
  .hero-copy .cta-row .btn { width: 100%; }
  .team-list { grid-template-columns: 1fr; }
  .row {
    flex-direction: column;
    align-items: flex-start;
  }
}
