﻿:root {
  --bg: #f3efe6;
  --ink: #1b1b1b;
  --muted: #4f4a42;
  --accent: #0d6a71;
  --accent-2: #f59e0b;
  --card: #ffffff;
  --stroke: #e6e0d4;
  --shadow: 0 24px 60px rgba(27, 27, 27, 0.12);
  --radius: 20px;
}

* {
  box-sizing: border-box;
}


body {
  margin: 0;
  font-family: "Space Grotesk", system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--bg);
  min-height: 100vh;
  line-height: 1.5;
}

.app-loading #loginView,
.app-loading #appView,
.app-loading #clientView {
  display: none !important;
}

h1, h2, h3 {
  font-family: "Fraunces", "Times New Roman", serif;
  margin: 0 0 12px;
}

p {
  margin: 0 0 12px;
}

a {
  color: inherit;
  text-decoration: none;
}

.bg {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: -2;
}

.public.public-cover .bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--public-cover-image);
  background-size: cover;
  background-position: center;
  opacity: 0.22;
}

.blob {
  position: absolute;
  width: 460px;
  height: 460px;
  border-radius: 50%;
  opacity: 0.35;
  animation: float 16s ease-in-out infinite;
}

.blob-a {
  background: radial-gradient(circle at 30% 30%, #f7d794, transparent 70%);
  top: -140px;
  left: -80px;
}

.blob-b {
  background: radial-gradient(circle at 70% 20%, #6ee7b7, transparent 70%);
  bottom: -180px;
  right: -120px;
  animation-delay: -4s;
}

.grain {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='0.08'/%3E%3C/svg%3E");
  opacity: 0.5;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 24px clamp(20px, 4vw, 48px);
}

.plan-page .topbar {
  position: sticky;
  top: 0;
  background: rgba(243, 239, 230, 0.92);
  backdrop-filter: blur(10px);
  z-index: 6;
}

.public .topbar {
  position: sticky;
  top: 0;
  background: rgba(243, 239, 230, 0.9);
  backdrop-filter: blur(8px);
  z-index: 5;
}

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

.brand-button {
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  text-align: left;
  color: inherit;
}

.brand-logo {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 12px 22px rgba(0, 0, 0, 0.18);
}

.brand-title {
  font-size: 20px;
  font-weight: 600;
}

.brand-sub {
  font-size: 13px;
  color: var(--muted);
}

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

.business-switch {
  flex: 1 1 280px;
  max-width: 360px;
}

.business-switch-field {
  display: grid;
  gap: 6px;
}

.business-switch-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.business-switch select {
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid rgba(13, 106, 113, 0.16);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 24px rgba(27, 27, 27, 0.08);
  color: var(--ink);
  font: inherit;
}

.business-switch select:disabled {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  cursor: default;
}

.mobile-actions {
  display: none;
  margin-left: auto;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  padding: 8px;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.icon-burger {
  width: 18px;
  height: 12px;
  display: inline-block;
  background:
    linear-gradient(currentColor, currentColor) 0 0 / 100% 2px,
    linear-gradient(currentColor, currentColor) 0 5px / 100% 2px,
    linear-gradient(currentColor, currentColor) 0 10px / 100% 2px;
  background-repeat: no-repeat;
}

.icon-dots {
  width: 22px;
  height: 6px;
  display: inline-block;
  position: relative;
}

.icon-dots::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 4px;
  height: 4px;
  margin-top: -2px;
  margin-left: -2px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: -8px 0 0 currentColor, 8px 0 0 currentColor;
}

.icon-filter {
  width: 18px;
  height: 18px;
  display: block;
}

.menu {
  position: relative;
}

.menu-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  display: grid;
  gap: 4px;
  min-width: 220px;
  padding: 8px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
  box-shadow: var(--shadow);
  z-index: 12;
}

.notification-menu {
  position: relative;
}

.notification-trigger {
  position: relative;
  width: 46px;
  height: 46px;
  padding: 0;
  display: inline-grid;
  place-items: center;
  border-radius: 15px;
  overflow: visible;
}

.notification-trigger::before {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 18px;
  background: radial-gradient(circle, rgba(13, 106, 113, 0.22) 0%, rgba(13, 106, 113, 0) 72%);
  opacity: 0;
  transform: scale(0.85);
  pointer-events: none;
}

.notification-trigger.has-alert::before {
  opacity: 1;
  animation: notification-pulse 1.9s ease-out infinite;
}

.icon-bell {
  width: 26px;
  height: 26px;
  display: block;
  background: no-repeat center/contain;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none' stroke='%231b1b1b' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 8a6 6 0 1 1 12 0c0 7 3 9 3 9H3s3-2 3-9'/%3E%3Cpath d='M10 20a2 2 0 0 0 4 0'/%3E%3C/svg%3E");
  transform-origin: top center;
}

.notification-trigger.has-alert .icon-bell {
  animation: notification-ring 1.6s ease-in-out infinite;
}

.notification-count {
  position: absolute;
  top: -2px;
  right: -1px;
  min-width: 19px;
  height: 19px;
  padding: 0 5px;
  border-radius: 999px;
  background: #0d6a71;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 6px 16px rgba(13, 106, 113, 0.35);
}

@keyframes notification-ring {
  0%, 100% {
    transform: rotate(0deg) scale(1);
  }
  10% {
    transform: rotate(14deg) scale(1.05);
  }
  20% {
    transform: rotate(-12deg) scale(1.05);
  }
  30% {
    transform: rotate(10deg) scale(1.04);
  }
  40% {
    transform: rotate(-8deg) scale(1.03);
  }
  50% {
    transform: rotate(0deg) scale(1);
  }
}

@keyframes notification-pulse {
  0% {
    transform: scale(0.82);
    opacity: 0.55;
  }
  70% {
    transform: scale(1.08);
    opacity: 0;
  }
  100% {
    transform: scale(1.12);
    opacity: 0;
  }
}

.notification-panel {
  min-width: 340px;
  max-width: 400px;
  padding: 0;
  overflow: hidden;
}

.notification-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  background: linear-gradient(180deg, rgba(246, 249, 252, 0.96), rgba(255, 255, 255, 0.96));
}

.notification-panel-tools {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.notification-list {
  display: grid;
  max-height: 420px;
  overflow: auto;
}

.notification-item {
  display: grid;
  gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(255, 255, 255, 0.98);
}

.notification-item:last-child {
  border-bottom: none;
}

.notification-item.is-unseen {
  background: rgba(13, 106, 113, 0.08);
}

.notification-item-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.notification-item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  font-size: 12px;
  color: var(--muted);
}

.notification-item-copy {
  font-size: 13px;
  color: #334155;
}

.notification-item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.notification-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.notification-pill.is-pending {
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
}

.notification-pill.is-done {
  background: rgba(15, 118, 110, 0.14);
  color: #0f766e;
}

.notification-empty {
  padding: 18px 16px;
  color: var(--muted);
  font-size: 13px;
}

.menu-item {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: none;
  background: transparent;
  text-align: left;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  cursor: pointer;
}

.menu-item:hover {
  background: rgba(13, 106, 113, 0.08);
}

.menu-item:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.session-badge {
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(13, 106, 113, 0.12);
  color: var(--accent);
  font-size: 13px;
}

.hidden {
  display: none !important;
}

.no-scroll {
  overflow: hidden;
}

.overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 15, 15, 0.4);
  backdrop-filter: blur(6px);
  display: grid;
  align-items: end;
  justify-items: center;
  z-index: 20;
}

.overlay.side {
  align-items: stretch;
  justify-items: end;
}

.overlay.confirm-overlay {
  align-items: center;
  padding: 20px;
}

.overlay.confirm-overlay.warning {
  background: rgba(120, 53, 15, 0.28);
}

.drawer {
  width: min(560px, 96vw);
  max-height: 92vh;
  background: var(--card);
  border-radius: 24px 24px 0 0;
  padding: 20px;
  box-shadow: var(--shadow);
  overflow-y: auto;
  animation: slideUp 0.2s ease both;
}

.drawer.right {
  width: min(420px, 92vw);
  height: 100vh;
  max-height: 100vh;
  border-radius: 24px 0 0 24px;
  animation: slideFromRight 0.2s ease both;
}

.confirm-drawer {
  width: min(460px, 92vw);
  max-height: min(90vh, 520px);
  border-radius: 24px;
  animation: fadeIn 0.2s ease both;
}

.overlay.confirm-overlay.warning .confirm-drawer {
  border: 1px solid rgba(180, 83, 9, 0.28);
  background: linear-gradient(180deg, rgba(255, 247, 237, 0.98), rgba(255, 255, 255, 0.98));
}

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

.centered {
  display: grid;
  place-items: center;
  padding: 40px 20px 80px;
  gap: 24px;
}

.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.6);
  animation: fadeIn 0.6s ease both;
}

.login {
  width: min(520px, 92vw);
}

.restore-password-card {
  width: min(560px, 92vw);
}

.restore-password-head {
  display: grid;
  gap: 10px;
}

.auth-tabs {
  display: flex;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.7);
  margin-bottom: 16px;
}

.auth-tab {
  flex: 1;
  padding: 8px 12px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-weight: 600;
  cursor: pointer;
}

.auth-tab.active {
  background: var(--ink);
  color: #fff;
}

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

.auth-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.auth-link:hover {
  text-decoration: underline;
}

.stack {
  display: grid;
  gap: 16px;
}

label {
  display: grid;
  gap: 8px;
  font-size: 14px;
}

input, select, textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  font-family: inherit;
  font-size: 14px;
  background: #fff;
}

textarea {
  resize: vertical;
}

.btn {
  padding: 12px 18px;
  border-radius: 12px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  position: relative;
  transition: transform 0.08s ease, box-shadow 0.12s ease, filter 0.12s ease;
}

button,
.tabs button,
.brand-button {
  transition: transform 0.08s ease, filter 0.12s ease;
}

.btn.primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 30px rgba(13, 106, 113, 0.22);
}

.btn.ghost {
  background: transparent;
  border: 1px solid var(--stroke);
  color: var(--ink);
}

.btn.whatsapp-btn {
  background-color: #22c55e;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32' fill='%23fff'%3E%3Cpath d='M16 4.6C9.7 4.6 4.6 9.7 4.6 16c0 2.3.7 4.6 2.1 6.5L5 27.4l5-1.6c1.8 1 3.8 1.5 5.9 1.5 6.3 0 11.4-5.1 11.4-11.3S22.3 4.6 16 4.6zm0 20.7c-1.9 0-3.7-.5-5.3-1.4l-.4-.2-2.9.9.9-2.8-.2-.4C7.2 19.7 6.7 17.9 6.7 16 6.7 10.9 10.9 6.7 16 6.7S25.3 10.9 25.3 16 21.1 25.3 16 25.3zm5.3-7.1c-.3-.1-1.8-.9-2.1-1s-.5-.1-.7.1-.8 1-.9 1.2-.3.2-.6.1c-.3-.1-1.2-.4-2.3-1.4-.8-.7-1.4-1.6-1.6-1.9-.2-.3 0-.5.1-.6l.4-.4c.1-.1.2-.3.3-.4.1-.1.1-.3 0-.5s-.7-1.6-1-2.1c-.3-.6-.6-.5-.7-.5h-.6c-.2 0-.5.1-.7.3s-1 1-1 2.4 1 2.7 1.2 2.9c.1.2 1.9 2.9 4.6 4 1.7.7 2.3.8 3.1.7.5-.1 1.6-.6 1.8-1.2.2-.6.2-1.1.1-1.2-.1-.1-.3-.2-.6-.3z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 30px 30px;
  border: 1px solid #16a34a;
  color: #fff;
  box-shadow: 0 10px 20px rgba(34, 197, 94, 0.25);
  border-radius: 999px;
}

.btn.danger {
  color: #b91c1c;
  border-color: rgba(185, 28, 28, 0.4);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  filter: none;
}

.link-btn {
  background: transparent;
  border: none;
  padding: 0;
  font-size: 13px;
  color: var(--accent);
  text-decoration: underline;
  cursor: pointer;
}

.link-btn:hover {
  opacity: 0.75;
}

.btn.small {
  padding: 8px 12px;
  font-size: 12px;
}

.btn.loading {
  padding-right: 40px;
}

.btn.loading::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 14px;
  height: 14px;
  margin-top: -7px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-top-color: currentColor;
  animation: spin 0.8s linear infinite;
}

.btn:active {
  transform: translateY(1px) scale(0.99);
  filter: brightness(0.97);
}

button:not(:disabled):active,
.tabs button:not(:disabled):active,
.brand-button:not(:disabled):active {
  transform: translateY(1px) scale(0.99);
  filter: brightness(0.97);
}

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

.hint {
  margin-top: 12px;
  color: #a16207;
  font-size: 13px;
}

.hint.warn {
  color: #b91c1c;
  background: rgba(185, 28, 28, 0.08);
  border: 1px solid rgba(185, 28, 28, 0.25);
  padding: 8px 10px;
  border-radius: 10px;
}

.hint.success {
  color: #0f766e;
  background: rgba(13, 148, 136, 0.08);
  border: 1px solid rgba(13, 148, 136, 0.22);
  padding: 8px 10px;
  border-radius: 10px;
}

.app {
  padding: 0 clamp(20px, 4vw, 48px) 80px;
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
  align-items: start;
}

.client-app {
  padding: 0 clamp(20px, 4vw, 48px) 80px;
  display: grid;
  gap: 24px;
  max-width: 960px;
  margin: 0 auto;
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.pagination label {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pagination-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.content {
  display: grid;
  gap: 18px;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(6px);
}

.tabs button {
  background: transparent;
  border: 1px solid transparent;
  color: var(--muted);
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
}

.tabs button.active {
  background: var(--ink);
  color: #fff;
}

.sidebar {
  position: sticky;
  top: 20px;
  align-self: start;
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.view-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  align-items: start;
}

.view-stack {
  display: grid;
  gap: 20px;
  grid-template-columns: minmax(0, 1fr);
}

.agenda-full {
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

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

.controls {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.inline-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}

.toggle input {
  width: auto;
}

.mode-select {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mode-option {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: #fff;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.mode-option input {
  margin: 0;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  accent-color: var(--accent);
  -webkit-appearance: auto;
  appearance: auto;
  transform: scale(0.95);
}

.mode-option.active {
  border-color: var(--accent);
  background: rgba(13, 106, 113, 0.12);
  color: var(--ink);
  font-weight: 600;
}

.password-field {
  position: relative;
  display: flex;
  align-items: center;
}

.password-field input {
  padding-right: 44px;
}

.password-toggle {
  position: absolute;
  right: 12px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--stroke);
  background: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
}

.password-toggle::before {
  content: "";
  width: 16px;
  height: 16px;
  display: block;
  background: no-repeat center/contain;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none' stroke='%231b1b1b' stroke-width='1.6'%3E%3Cpath d='M2 12s4.5-7 10-7 10 7 10 7-4.5 7-10 7S2 12 2 12Z'/%3E%3Ccircle cx='12' cy='12' r='3.5'/%3E%3C/svg%3E");
}

.password-toggle.is-visible::before {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none' stroke='%231b1b1b' stroke-width='1.6'%3E%3Cpath d='M2 12s4.5-7 10-7 10 7 10 7-4.5 7-10 7S2 12 2 12Z'/%3E%3Cpath d='M4 4l16 16'/%3E%3C/svg%3E");
}

.password-toggle:focus-visible {
  outline: 2px solid rgba(13, 106, 113, 0.4);
  outline-offset: 2px;
}

.divider {
  height: 1px;
  background: var(--stroke);
  margin: 20px 0;
}

.list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
  font-size: 14px;
}

.reserve-quick {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(13, 106, 113, 0.08);
}

.reserve-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.reserve-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
  font-family: inherit;
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}

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

.list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.stats {
  display: grid;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(13, 106, 113, 0.08);
}

.stat-label {
  display: block;
  font-size: 12px;
  color: var(--muted);
}

.stat-value {
  font-size: 20px;
  font-weight: 600;
}

.stat-value.small {
  font-size: 14px;
}

.public-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(245, 158, 11, 0.12);
}

.plan-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(13, 106, 113, 0.12);
}

.business-overview-head {
  align-items: flex-start;
}

.business-overview-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
}

.business-overview-block {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(13, 106, 113, 0.18);
  color: var(--ink);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.02em;
}

.badge:empty {
  display: none;
}

.plan-choice {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px dashed var(--stroke);
  background: #fafafa;
  font-size: 13px;
}

.plan-choice .plan-name {
  font-weight: 600;
  color: var(--ink);
}

.billing-alert {
  position: sticky;
  top: 12px;
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(220, 38, 38, 0.25);
  background: rgba(254, 226, 226, 0.7);
}

.billing-alert-title {
  font-weight: 700;
  color: #b91c1c;
}

.billing-alert-text {
  font-size: 13px;
  color: #7f1d1d;
}

.billing-card {
  display: grid;
  gap: 18px;
}

.billing-primary-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.billing-primary-actions .btn {
  flex: 0 0 auto;
}

.billing-link-row {
  display: flex;
  justify-content: flex-end;
}

.billing-summary-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.billing-lifecycle-note {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(15, 118, 110, 0.08);
  border: 1px solid rgba(15, 118, 110, 0.14);
}

.billing-invoice {
  display: grid;
  gap: 16px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
}

@media (min-width: 700px) {
  .billing-invoice {
    grid-template-columns: 1.4fr 0.8fr 0.8fr;
    align-items: center;
  }
}

@media (max-width: 900px) {
  .business-overview-grid,
  .billing-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .business-overview-grid,
  .billing-summary-grid {
    grid-template-columns: 1fr;
  }

  .billing-primary-actions {
    width: 100%;
    justify-content: stretch;
  }

  .billing-primary-actions .btn {
    flex: 1 1 100%;
  }

  .billing-flow-row {
    flex-direction: column;
  }

  .billing-flow-row strong {
    text-align: left;
  }
}

.billing-history {
  display: grid;
  gap: 12px;
}

.billing-history-item {
  display: grid;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
}

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

.billing-history-title {
  font-weight: 600;
}

.billing-history-meta {
  color: var(--muted);
  font-size: 13px;
}

.billing-history-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.link-button {
  padding: 0;
  border: 0;
  background: transparent;
  color: #0d6a71;
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.link-button.danger {
  color: #b91c1c;
}

.billing-flow-modal {
  width: min(560px, 94vw);
}

.billing-flow-summary {
  display: grid;
  gap: 10px;
}

.billing-flow-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
}

.billing-flow-row span {
  color: var(--muted);
  font-size: 13px;
}

.billing-flow-row strong {
  text-align: right;
}

.billing-flow-warning {
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(185, 28, 28, 0.08);
  border: 1px solid rgba(185, 28, 28, 0.12);
  color: #7f1d1d;
  font-size: 13px;
  line-height: 1.6;
}

.billing-flow-agreements {
  display: grid;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(15, 23, 42, 0.02);
}

.billing-flow-agreements .terms-panel {
  margin: 0;
}

.billing-flow-agreements .terms-body {
  padding: 0;
}

.billing-flow-agreements .link {
  width: fit-content;
}

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

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

.select-multi {
  min-height: 120px;
}

.table-wrap {
  overflow-x: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.table th {
  text-align: left;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  padding: 10px 8px;
  border-bottom: 1px solid var(--stroke);
}

.table td {
  padding: 12px 8px;
  border-bottom: 1px solid var(--stroke);
  vertical-align: top;
}

.table tr:hover {
  background: rgba(13, 106, 113, 0.06);
}

.appointments {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 16px;
}

.appointments li {
  padding: 16px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  display: grid;
  gap: 12px;
  background: #fff;
}

.appointment-group {
  padding: 6px 4px;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.appointment-card {
  position: relative;
  overflow: hidden;
  border-left: 6px solid rgba(13, 106, 113, 0.22);
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
}

.appointment-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(13, 106, 113, 0.06), rgba(245, 158, 11, 0.05));
  opacity: 0.7;
  pointer-events: none;
}

.appointment-card > * {
  position: relative;
  z-index: 1;
}

.appointment-card[data-status="pending"] {
  border-left-color: #f97316;
}

.appointment-card[data-status="confirmed"] {
  border-left-color: #16a34a;
}

.appointment-card[data-status="completed"] {
  border-left-color: #2563eb;
}

.appointment-card[data-status="cancelled"] {
  border-left-color: #ef4444;
  opacity: 0.68;
  filter: grayscale(0.15);
}

.appointment-card[data-status="no_show"] {
  border-left-color: #6b7280;
}

.appointment-title {
  display: grid;
  gap: 6px;
}

.appointment-service {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 8px;
}

.appointment-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
  text-transform: capitalize;
}

.appointment-dot {
  color: rgba(15, 23, 42, 0.4);
}

.appointment-status .badge {
  font-size: 11px;
}

.appointment-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--muted);
}

.appointment-time {
  font-weight: 600;
  color: var(--ink);
}

.appointment-amount {
  font-weight: 700;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 6px;
}

.appointment-business,
.appointment-staff {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.inline-icon {
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: inherit;
}

.inline-icon svg {
  width: 16px;
  height: 16px;
  display: block;
}

.agenda-board {
  margin-top: 12px;
  border: 1px solid var(--stroke);
  border-radius: 16px;
  background: #fff;
  overflow: hidden;
}

.agenda-scroll {
  overflow-x: auto;
  overflow-y: hidden;
  width: 100%;
}

.agenda-board-header,
.agenda-board-body {
  display: flex;
  min-width: 100%;
}

.agenda-time-col {
  width: 70px;
  flex: 0 0 70px;
  border-right: 1px solid var(--stroke);
  background: #fafafa;
  position: sticky;
  left: 0;
  z-index: 3;
}

.agenda-time-col-header {
  height: 48px;
  background: #fff;
}

.agenda-time-slot {
  height: var(--row-height, 36px);
  padding: 4px 8px;
  font-size: 11px;
  color: var(--muted);
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
}

.agenda-staff-header {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(190px, 1fr);
}

.agenda-staff-label {
  padding: 12px 14px;
  border-right: 1px solid var(--stroke);
  background: #fff;
  font-size: 13px;
  font-weight: 600;
}

.agenda-board-body {
  border-top: 1px solid var(--stroke);
  position: relative;
}

.agenda-grid {
  position: relative;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(190px, 1fr);
  isolation: isolate;
  min-height: 120px;
}

.agenda-column {
  position: relative;
  z-index: 1;
  border-right: 1px solid var(--stroke);
  background-image: linear-gradient(rgba(15, 23, 42, 0.07) 1px, transparent 1px);
  background-size: 100% var(--row-height, 36px);
  background-position: top left;
}

.agenda-business-break {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px solid rgba(148, 163, 184, 0.22);
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  background:
    linear-gradient(rgba(148, 163, 184, 0.06), rgba(148, 163, 184, 0.06)),
    repeating-linear-gradient(
      -45deg,
      rgba(148, 163, 184, 0.05) 0,
      rgba(148, 163, 184, 0.05) 8px,
      rgba(255, 255, 255, 0) 8px,
      rgba(255, 255, 255, 0) 16px
    );
  pointer-events: none;
  z-index: 0;
}

.agenda-business-break.compact {
  border-top-color: rgba(148, 163, 184, 0.18);
  border-bottom-color: rgba(148, 163, 184, 0.18);
}

.agenda-business-break-label {
  position: absolute;
  top: 6px;
  left: 10px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: #64748b;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.agenda-business-break.compact .agenda-business-break-label {
  top: 2px;
  padding: 1px 6px;
  font-size: 9px;
}

.agenda-column.drag-target {
  background: rgba(13, 106, 113, 0.08);
}

.agenda-column.drag-valid {
  background: rgba(34, 197, 94, 0.1);
}

.agenda-column.drag-warning {
  background: rgba(239, 68, 68, 0.1);
}

.agenda-column.drag-invalid {
  background: rgba(153, 27, 27, 0.12);
}

.agenda-drop-highlight {
  position: absolute;
  left: 6px;
  right: 6px;
  border-radius: 12px;
  border: 2px dashed transparent;
  pointer-events: none;
  z-index: 2;
}

.agenda-drop-highlight.valid {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(22, 163, 74, 0.65);
  box-shadow: inset 0 0 0 1px rgba(240, 253, 244, 0.65);
}

.agenda-drop-highlight.warning {
  background: rgba(239, 68, 68, 0.18);
  border-color: rgba(220, 38, 38, 0.62);
  box-shadow: inset 0 0 0 1px rgba(254, 242, 242, 0.65);
}

.agenda-drop-highlight.invalid {
  background: rgba(153, 27, 27, 0.18);
  border-color: rgba(127, 29, 29, 0.7);
}

.agenda-event {
  position: absolute;
  left: 6px;
  right: 6px;
  border-radius: 4px;
  border: 1px solid var(--stroke);
  padding: 8px;
  background: #fff;
  display: grid;
  gap: 6px;
  font-size: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  cursor: pointer;
}

.agenda-event.draggable {
  cursor: grab;
}

.agenda-event.dragging {
  opacity: 0.55;
  cursor: grabbing;
}

.agenda-now-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 2px solid #ef4444;
  z-index: 4;
  pointer-events: none;
  box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.15);
}

.agenda-now-line::before {
  content: "";
  position: absolute;
  left: 6px;
  top: -5px;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #ef4444;
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.2);
}

.agenda-event.pending {
  border-left: 4px solid #f97316;
  background: #fff7ed;
}

.agenda-event.confirmed {
  border-left: 4px solid #16a34a;
  background: #ecfdf3;
}

.agenda-event.completed {
  border-left: 4px solid #2563eb;
  background: #eff6ff;
}

.agenda-event.no_show {
  border-left: 4px solid #6b7280;
  background: #f3f4f6;
}

.agenda-event.payment-paid {
  border-left: 4px solid #16a34a;
  background: #ecfdf3;
}

.agenda-event.payment-pending {
  border-left: 4px solid #f59e0b;
  background: #fff7ed;
}

.agenda-event.payment-partial {
  border-left: 4px solid #2563eb;
  background: #eff6ff;
}

.agenda-event.payment-none {
  border-left: 4px solid #94a3b8;
  background: #f8fafc;
}

.agenda-event-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.agenda-event-time {
  font-weight: 500;
  color: var(--muted);
  font-size: 11px;
}

.agenda-event .badge {
  font-size: 10px;
  padding: 2px 8px;
}

.agenda-event-client {
  font-weight: 600;
  color: var(--ink);
}

.agenda-event-client .client-link,
.agenda-flyout-client .client-link {
  color: inherit;
}

.agenda-event-meta {
  color: var(--muted);
  font-size: 11px;
}

.agenda-event-payment {
  display: flex;
  align-items: center;
}

.agenda-payment-badge {
  font-size: 10px;
  padding: 2px 8px;
  letter-spacing: 0.2px;
}

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

.agenda-board .agenda-event-actions {
  display: none;
}

.agenda-event.compact {
  padding: 4px 6px;
  gap: 4px;
}

.agenda-event.compact .agenda-event-meta,
.agenda-event.compact .agenda-event-actions {
  display: none;
}

.agenda-event.compact .agenda-event-time,
.agenda-event.compact .agenda-event-client {
  font-size: 11px;
  line-height: 1.2;
}

.agenda-event.compact .agenda-event-payment {
  margin-top: 2px;
}

.agenda-flyout {
  position: fixed;
  z-index: 40;
  width: min(320px, 92vw);
  left: 0;
  top: 0;
  pointer-events: auto;
}

.agenda-flyout-card {
  background: #fff;
  border: 1px solid var(--stroke);
  border-radius: 16px;
  padding: 14px;
  display: grid;
  gap: 8px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
}

.agenda-flyout-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.agenda-flyout-client {
  font-weight: 700;
  color: var(--ink);
  font-size: 15px;
}

.agenda-flyout-time {
  color: var(--muted);
  font-size: 12px;
}

.agenda-flyout-status {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.agenda-flyout-close {
  padding: 4px 8px;
}

.agenda-flyout:not(.pinned) .agenda-flyout-close {
  display: none;
}

.agenda-flyout-meta {
  color: var(--muted);
  font-size: 12px;
}

.agenda-flyout-money {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  background: #fff;
  box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.agenda-flyout-money .appointment-balance {
  font-size: 18px;
}

.appointment-balance.none {
  color: #64748b;
}

.agenda-flyout-note {
  font-size: 12px;
  color: var(--muted);
}

.agenda-flyout.payment-pending .agenda-flyout-money {
  border-color: rgba(245, 158, 11, 0.35);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), #ffffff 60%);
}

.agenda-flyout.payment-paid .agenda-flyout-money {
  border-color: rgba(22, 163, 74, 0.3);
  background: linear-gradient(135deg, rgba(22, 163, 74, 0.08), #ffffff 60%);
}

.agenda-flyout.payment-partial .agenda-flyout-money {
  border-color: rgba(37, 99, 235, 0.3);
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.08), #ffffff 60%);
}

.agenda-flyout.payment-none .agenda-flyout-money {
  border-color: rgba(100, 116, 139, 0.3);
  background: linear-gradient(135deg, rgba(100, 116, 139, 0.08), #ffffff 60%);
}

.agenda-flyout.payment-cancelled .agenda-flyout-money {
  border-color: rgba(100, 116, 139, 0.3);
  background: linear-gradient(135deg, rgba(100, 116, 139, 0.08), #ffffff 60%);
}

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

.payment-appointment {
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #f8fafc;
  padding: 12px;
  display: grid;
  gap: 4px;
  margin: 12px 0;
  font-size: 12px;
  color: var(--muted);
}

.payment-appointment strong {
  font-size: 14px;
  color: var(--ink);
}

.payment-appointment .client-link {
  color: inherit;
}

.payment-appointment-cell {
  display: grid;
  gap: 2px;
}

.payments-pro-view {
  display: grid;
  gap: 18px;
}

.payments-pro-card {
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 249, 252, 0.98));
}

.payments-head {
  align-items: flex-start;
  gap: 16px;
}

.payments-head .controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.payments-stats {
  margin-top: 18px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.payments-toolbar {
  margin-top: 18px;
}

.payments-period-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px 18px;
  align-items: center;
  padding: 18px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(13, 106, 113, 0.08), rgba(255, 255, 255, 0.96) 48%, rgba(244, 247, 250, 0.98));
}

.payments-period-copy {
  display: grid;
  gap: 6px;
}

.payments-period-kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.payments-period-title {
  font-size: 24px;
  line-height: 1.05;
  color: #0f172a;
}

.payments-period-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.payments-period-inputs {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.payments-period-inputs label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.payments-period-inputs input {
  min-width: 0;
}

.payments-filter-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.payments-bulk-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 18px;
  background: rgba(248, 250, 252, 0.92);
}

.payments-select-all {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--ink);
}

.payments-table-wrap {
  margin-top: 18px;
}

.payments-table {
  min-width: 1460px;
}

.payments-table td,
.payments-table th {
  vertical-align: top;
}

.payments-select-col {
  width: 48px;
}

.payments-row-selected {
  background: rgba(13, 106, 113, 0.07);
}

.payments-row-selected td {
  background: transparent;
}

.payments-last-payment {
  min-width: 150px;
}

.payments-row-actions {
  min-width: 160px;
}

.payments-drawer {
  width: min(560px, calc(100vw - 24px));
}

.payments-table .client-link {
  font-weight: 600;
  color: inherit;
}

.agenda-empty {
  padding: 16px;
  color: var(--muted);
  font-size: 14px;
}

.agenda-grid .agenda-empty {
  position: absolute;
  top: 12px;
  left: 12px;
  right: auto;
  bottom: auto;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  max-width: calc(100% - 24px);
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(255, 255, 255, 0.86);
  font-weight: 600;
  z-index: 2;
  pointer-events: none;
}

.agenda-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin: 12px 0 8px;
}

.agenda-nav {
  display: flex;
  gap: 8px;
  align-items: center;
}

.agenda-date-picker {
  width: 140px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid var(--stroke);
  font-family: inherit;
  font-size: 13px;
  background: #fff;
}

.agenda-filters {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.agenda-count {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(13, 106, 113, 0.08);
  border: 1px solid rgba(13, 106, 113, 0.12);
  font-size: 12px;
}

.agenda-count .stat-label {
  margin: 0;
  display: inline;
}

.agenda-select select {
  min-width: 120px;
}

.agenda-search input {
  min-width: 220px;
}

.autocomplete-wrap {
  position: relative;
}

.autocomplete {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--card);
  border: 1px solid var(--stroke);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 6px;
  max-height: 220px;
  overflow-y: auto;
  z-index: 18;
}

.autocomplete-item {
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  padding: 8px 10px;
  border-radius: 10px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
}

.autocomplete-item:hover {
  background: rgba(13, 106, 113, 0.08);
}

.autocomplete-empty {
  padding: 8px 10px;
  color: var(--muted);
  font-size: 13px;
}

.settings-section {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.65);
}

.settings-section-actions {
  display: flex;
  justify-content: flex-end;
}

.section-head h4 {
  margin: 0 0 4px;
  font-size: 16px;
}

.section-head p {
  margin: 0;
}

.media-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.media-field {
  display: grid;
  gap: 10px;
}

.media-preview {
  min-height: 120px;
  border-radius: 16px;
  border: 1px dashed var(--stroke);
  background: rgba(255, 255, 255, 0.7);
  display: grid;
  place-items: center;
  padding: 10px;
  text-align: center;
}

.media-preview.logo img {
  max-width: 140px;
  max-height: 120px;
  object-fit: contain;
}

.media-preview.avatar {
  min-height: 160px;
  overflow: hidden;
  border-style: solid;
}

.media-preview.avatar img {
  width: 100%;
  max-width: none;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
}

.media-preview.cover {
  min-height: 140px;
  background-size: cover;
  background-position: center;
}

.media-preview.cover.has-image {
  border-style: solid;
}

.payment-provider-fields {
  display: none;
  gap: 10px;
}

.payment-provider-fields.active {
  display: grid;
}

.terms-panel {
  display: grid;
  gap: 14px;
}

.terms-body {
  border: 1px solid var(--stroke);
  border-radius: 16px;
  padding: 16px;
  max-height: 46vh;
  overflow-y: auto;
  background: rgba(255, 255, 255, 0.7);
}

.terms-page .container {
  padding-top: 24px;
  padding-bottom: 48px;
}

.terms-card {
  max-width: 840px;
  margin: 0 auto;
}

.terms-content {
  display: grid;
  gap: 16px;
  line-height: 1.6;
  color: var(--ink);
}

.terms-content h3 {
  margin: 12px 0 0;
}

.terms-content ul {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 6px;
  color: var(--muted);
}

.footer {
  padding: 24px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

.terms-body h3 {
  margin-top: 0;
}

.terms-list ul {
  margin: 8px 0 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
}

.file-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

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

.media-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
}

.media-gallery-item {
  position: relative;
  min-height: 120px;
  overflow: hidden;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.76);
}

.media-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-gallery-item.pending::after {
  content: "Pendiente";
  position: absolute;
  left: 10px;
  bottom: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.78);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
}

.media-gallery-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  min-width: 30px;
  min-height: 30px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.1);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.12);
}

.public-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.public-contact-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  color: var(--ink);
}

.agenda-strip {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  padding: 6px 2px 8px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.day-item {
  flex: 0 0 auto;
  min-width: 54px;
  padding: 6px 8px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fff;
  text-align: center;
  cursor: pointer;
  scroll-snap-align: start;
}

.day-item .day-name {
  font-size: 10px;
  color: var(--muted);
  text-transform: capitalize;
}

.day-item .day-number {
  font-size: 15px;
  font-weight: 600;
}

.day-item .day-month {
  font-size: 10px;
  color: var(--muted);
}

.day-item.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.day-item.active .day-name,
.day-item.active .day-month {
  color: rgba(255, 255, 255, 0.8);
}

.day-item.today {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(13, 106, 113, 0.12);
}

.agenda-day-label {
  padding: 6px 10px;
  font-weight: 600;
  color: var(--muted);
  text-transform: capitalize;
}

.agenda-day-empty {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px dashed var(--stroke);
  color: var(--muted);
}

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

.badge {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge.pending {
  background: #fff7ed;
  color: #9a3412;
}

.badge.confirmed {
  background: #ecfdf3;
  color: #166534;
}

.badge.cancelled {
  background: #fef2f2;
  color: #b91c1c;
}

.badge.completed {
  background: #eff6ff;
  color: #1d4ed8;
}

.badge.no_show {
  background: #f3f4f6;
  color: #374151;
}

.appointment-status {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}

.payment-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.payment-badge .payment-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
  display: inline-block;
}

.payment-badge.paid {
  background: rgba(22, 163, 74, 0.15);
  color: #15803d;
}

.payment-badge.pending {
  background: rgba(245, 158, 11, 0.16);
  color: #b45309;
}

.payment-badge.partial {
  background: rgba(37, 99, 235, 0.16);
  color: #1d4ed8;
}

.payment-badge.none {
  background: rgba(100, 116, 139, 0.16);
  color: #475569;
}

.payment-badge.cancelled {
  background: rgba(100, 116, 139, 0.2);
  color: #64748b;
}

.appointment-meta {
  display: grid;
  gap: 6px;
  font-size: 14px;
  color: var(--muted);
}

.appointment-payment {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  font-size: 14px;
  color: var(--muted);
}

.appointment-balance {
  font-weight: 600;
  font-size: 15px;
  color: var(--ink);
}

.appointment-balance.pending {
  color: #b45309;
}

.appointment-balance.paid {
  color: #15803d;
}

.appointment-balance.cancelled {
  color: #6b7280;
}

.appointment-coupon {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
}

.appointment-coupon .coupon-select {
  min-width: 180px;
}

.appointment-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.appointment-contact-link {
  background: #22c55e;
  border: 1px solid #16a34a;
  color: #fff;
  box-shadow: 0 10px 20px rgba(34, 197, 94, 0.2);
}

.appointment-contact-link:hover {
  filter: brightness(0.96);
}

.calendar-head {
  align-items: flex-start;
  gap: 18px;
}

.calendar-toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-left: auto;
}

.calendar-nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
}

.calendar-nav .btn {
  min-width: 42px;
}

.calendar-mode-wrap {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  border: 1px solid var(--stroke);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
}

.calendar-mode-wrap select {
  border: 0;
  background: transparent;
  padding: 0;
}

.calendar-grid {
  margin-top: 18px;
  display: grid;
  gap: 14px;
  overflow-x: auto;
}

.calendar-empty {
  border: 1px dashed var(--stroke);
  border-radius: 18px;
  padding: 28px 20px;
  text-align: center;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.88);
}

.calendar-week-table-wrap {
  overflow-x: auto;
}

.calendar-week-table {
  width: 100%;
  min-width: 1080px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
}

.calendar-week-column.current,
.calendar-week-cell.current,
.calendar-cell.current {
  border-color: rgba(13, 106, 113, 0.42);
  box-shadow: 0 0 0 1px rgba(13, 106, 113, 0.12);
}

.calendar-week-column {
  padding: 14px 12px;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-bottom: 0;
  background: rgba(13, 106, 113, 0.05);
  vertical-align: top;
}

.calendar-week-column:first-child {
  border-top-left-radius: 20px;
}

.calendar-week-column:last-child {
  border-top-right-radius: 20px;
}

.calendar-week-row {
  display: table-row;
}

.calendar-week-cell {
  padding: 12px;
  border: 1px solid rgba(148, 163, 184, 0.34);
  border-top: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 249, 252, 0.98));
  vertical-align: top;
  min-height: 320px;
  overflow: hidden;
}

.calendar-week-cell:first-child {
  border-bottom-left-radius: 20px;
}

.calendar-week-cell:last-child {
  border-bottom-right-radius: 20px;
}

.calendar-week-mobile-head {
  display: none;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.calendar-week-list {
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: 248px;
  min-width: 0;
}

.calendar-week-list > * {
  min-width: 0;
  max-width: 100%;
}

.calendar-day-anchor {
  border: 0;
  background: transparent;
  padding: 0;
  display: grid;
  gap: 4px;
  text-align: left;
  cursor: pointer;
}

.calendar-day-title {
  font-size: 13px;
  font-weight: 800;
  text-transform: capitalize;
  color: #0f172a;
}

.calendar-day-date {
  font-size: 12px;
  color: var(--muted);
}

.calendar-day-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  min-height: 32px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(13, 106, 113, 0.1);
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
}

.calendar-day-empty {
  min-height: 88px;
  border: 1px dashed var(--stroke);
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  font-size: 13px;
}

.calendar-day-open {
  width: 100%;
  margin-top: 10px;
  border: 0;
  background: rgba(15, 23, 42, 0.02);
  padding: 10px 12px;
  border-radius: 12px;
  font-weight: 700;
  color: var(--accent);
  cursor: pointer;
  box-sizing: border-box;
}

.calendar-week-appointment {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 14px;
  padding: 9px 10px;
  background: #fff;
  display: grid;
  gap: 6px;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.04);
  box-sizing: border-box;
  overflow: hidden;
}

.calendar-week-appointment.selected {
  border-color: rgba(13, 106, 113, 0.55);
  box-shadow: 0 0 0 2px rgba(13, 106, 113, 0.12);
}

.calendar-week-appointment-top,
.calendar-week-appointment-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.calendar-appointment-time {
  font-size: 11px;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
}

.calendar-appointment-client {
  font-size: 13px;
  font-weight: 800;
  color: #111827;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calendar-appointment-client .client-link,
.calendar-detail-client .client-link {
  color: inherit;
  max-width: 100%;
}

.calendar-appointment-meta {
  font-size: 12px;
  color: var(--muted);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.calendar-week-appointment .payment-badge {
  padding: 3px 8px;
  font-size: 10px;
}

.appointment-table-card {
  overflow: visible;
}

.appointment-table-head {
  align-items: flex-start;
  gap: 16px;
}

.appointment-table-toolbar {
  margin-top: 18px;
  display: grid;
  gap: 14px;
}

.appointment-table-filter-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.appointment-table-filter-grid label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.appointment-table-wrap {
  margin-top: 18px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  background: #fff;
}

.appointment-table {
  min-width: 1180px;
}

.appointment-actions-head {
  width: 180px;
}

.appointment-head-menu {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.appointment-columns-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  min-width: 220px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.14);
  padding: 14px;
  z-index: 5;
}

.appointment-columns-title {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.appointment-columns-list {
  display: grid;
  gap: 8px;
}

.appointment-columns-option {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: #0f172a;
}

.appointment-table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.calendar-month-shell {
  display: grid;
  gap: 10px;
}

.calendar-month-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
  min-width: 980px;
}

.calendar-month-weekday {
  padding: 0 6px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.calendar-month {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
  min-width: 980px;
}

.calendar-cell {
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 18px;
  padding: 12px;
  min-height: 122px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 250, 252, 0.98));
  display: grid;
  gap: 12px;
  align-content: start;
  text-align: left;
  cursor: pointer;
}

.calendar-cell.outside {
  opacity: 0.32;
  cursor: default;
}

.calendar-cell-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.calendar-cell .count {
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}

.calendar-cell-total {
  min-width: 40px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(13, 106, 113, 0.1);
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.calendar-cell-label {
  font-size: 13px;
  color: var(--muted);
}

.calendar-detail-drawer {
  max-width: 620px;
}

.calendar-detail-summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.calendar-detail-client {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
}

.calendar-detail-time {
  margin-top: 4px;
  font-size: 13px;
  color: var(--muted);
}

.calendar-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.calendar-detail-item {
  display: grid;
  gap: 4px;
}

.calendar-detail-item span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.calendar-detail-item strong {
  font-size: 14px;
  color: #0f172a;
}

.calendar-detail-note {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.04);
  color: #334155;
  font-size: 13px;
  line-height: 1.5;
}

.calendar-detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

@media (max-width: 820px) {
  .calendar-head {
    flex-direction: column;
    align-items: stretch;
  }

  .appointment-table-filter-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .calendar-toolbar {
    margin-left: 0;
  }

  .calendar-week-table {
    min-width: 0;
  }

  .calendar-week-table thead {
    display: none;
  }

  .calendar-week-table tbody,
  .calendar-week-table tr,
  .calendar-week-table td {
    display: block;
    width: 100%;
  }

  .calendar-week-row {
    display: grid;
    gap: 12px;
  }

  .calendar-week-cell {
    min-height: auto;
    border-top: 1px solid rgba(148, 163, 184, 0.34);
    border-radius: 18px;
  }

  .calendar-week-cell:first-child,
  .calendar-week-cell:last-child {
    border-radius: 18px;
  }

  .calendar-week-mobile-head {
    display: flex;
  }

  .calendar-week-list {
    min-height: 0;
  }
}

@media (max-width: 680px) {
  .appointment-table-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .calendar-nav,
  .calendar-toolbar {
    width: 100%;
    justify-content: space-between;
  }

  .calendar-detail-grid {
    grid-template-columns: 1fr;
  }

  .calendar-week-appointment-top,
  .calendar-week-appointment-bottom {
    align-items: flex-start;
  }

  .calendar-week-appointment-bottom {
    flex-wrap: wrap;
  }
}

.clients-crm-card {
  overflow: hidden;
}

.client-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-link:hover,
.client-link:focus-visible {
  text-decoration: underline;
}

.clients-toolbar {
  margin-top: 18px;
  display: grid;
  gap: 12px;
}

.clients-search input {
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  padding: 13px 16px;
  background: rgba(255, 255, 255, 0.94);
}

.client-tag-filters,
.client-tag-presets,
.client-tag-preview,
.client-card-tags,
.client-detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.crm-tag-filter,
.crm-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.crm-tag-filter {
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #fff;
  color: #334155;
  cursor: pointer;
}

.crm-tag-filter.active {
  border-color: rgba(13, 106, 113, 0.5);
  background: rgba(13, 106, 113, 0.1);
  color: var(--accent);
}

.crm-tag {
  background: rgba(15, 23, 42, 0.06);
  color: #334155;
}

.crm-tag.is-filled {
  background: rgba(13, 106, 113, 0.12);
  color: var(--accent);
}

.crm-tag.muted-chip {
  background: rgba(148, 163, 184, 0.12);
  color: var(--muted);
}

.clients-stats,
.client-detail-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.clients-stats {
  margin-top: 18px;
}

.crm-stat-card {
  border: 1px solid rgba(148, 163, 184, 0.26);
  border-radius: 18px;
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 249, 252, 0.98));
  display: grid;
  gap: 6px;
}

.crm-stat-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.crm-stat-value {
  font-size: 28px;
  line-height: 1;
  color: #0f172a;
}

.crm-stat-meta {
  font-size: 12px;
  color: var(--muted);
}

.section-kicker {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}

.notifications-view {
  gap: 18px;
}

.notifications-toolbar {
  align-items: flex-start;
}

.notifications-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.crm-stat {
  border: 1px solid rgba(148, 163, 184, 0.26);
  border-radius: 18px;
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 249, 252, 0.98));
  display: grid;
  gap: 6px;
}

.clients-table-panel,
.client-detail-screen {
  margin-top: 18px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 249, 252, 0.98));
  padding: 18px;
}

.clients-table-panel {
  display: grid;
  gap: 16px;
}

.clients-list-head h3,
.client-detail-empty h3,
.client-section-head h4 {
  margin: 0;
}

.clients-list-empty,
.client-detail-empty,
.client-detail-loading,
.crm-empty-block {
  border: 1px dashed rgba(148, 163, 184, 0.45);
  border-radius: 18px;
  padding: 22px 18px;
  background: rgba(255, 255, 255, 0.82);
  display: grid;
  gap: 6px;
  color: var(--muted);
}

.clients-table-wrap {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 18px;
  background: #fff;
}

.clients-table {
  min-width: 860px;
}

.clients-table-row {
  cursor: pointer;
}

.clients-table-row.is-selected {
  background: rgba(13, 106, 113, 0.08);
}

.clients-table-client,
.clients-table-contact {
  display: grid;
  gap: 4px;
}

.client-detail-header,
.client-activity-head,
.client-benefit-head,
.client-debt-card {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.clients-table-name {
  font-size: 16px;
  font-weight: 800;
  color: #0f172a;
}

.clients-table-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.clients-table-notes {
  min-width: 220px;
  max-width: 340px;
}

.clients-table-notes .muted {
  color: var(--muted);
}

.client-detail-contact {
  margin-top: 4px;
  font-size: 12px;
  color: var(--muted);
}

.client-notes-block p {
  margin: 0;
  font-size: 13px;
  color: #334155;
  line-height: 1.5;
}

.client-detail {
  display: grid;
  gap: 18px;
}

.client-detail-screen-head {
  align-items: flex-start;
  gap: 16px;
}

.client-detail-screen-head .controls,
.client-detail-header .inline-actions,
.client-section-head .inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.client-detail-header {
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 22px;
  padding: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(246, 248, 252, 0.98));
}

.client-detail-name-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.client-detail-name-row h3 {
  margin: 0;
  font-size: 26px;
}

.client-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 18px;
}

.client-detail-section {
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 22px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.98);
  display: grid;
  gap: 14px;
}

.client-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.client-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.client-profile-item,
.client-notes-block {
  display: grid;
  gap: 4px;
}

.client-profile-item span,
.client-notes-block span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.client-profile-item strong {
  font-size: 14px;
  color: #0f172a;
}

.client-activity-list,
.client-debt-list {
  display: grid;
  gap: 12px;
}

.client-history-table-wrap {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 18px;
  background: #fff;
  overflow-x: auto;
}

.client-history-table {
  min-width: 980px;
}

.client-history-pagination {
  margin-top: 2px;
}

.client-history-actions {
  flex-wrap: wrap;
  gap: 6px;
}

.client-benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.client-activity-card,
.client-benefit-card,
.client-debt-card {
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 18px;
  padding: 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(248, 250, 252, 0.98));
}

.client-activity-meta,
.client-benefit-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
}

.client-benefit-meta {
  font-weight: 700;
  color: var(--accent);
}

.client-debt-card-side {
  display: grid;
  gap: 8px;
  justify-items: end;
}

.clients-editor-help {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.staff-view {
  gap: 16px;
}

.staff-filter-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.staff-table {
  min-width: 980px;
}

.staff-table td {
  vertical-align: middle;
}

.staff-editor-summary {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.staff-services-drawer {
  width: min(980px, 96vw);
  border-radius: 24px;
  max-height: min(92vh, 920px);
}

.staff-services-filter-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.staff-services-table {
  min-width: 980px;
}

.staff-services-table td {
  vertical-align: middle;
}

.services-head {
  align-items: flex-start;
  gap: 16px;
}

.services-filter-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.services-filter-grid label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.addons-filter-grid {
  grid-template-columns: minmax(180px, 220px);
}

.addons-table .inline-actions {
  flex-wrap: wrap;
}

.addons-name-cell {
  display: grid;
  gap: 4px;
  min-width: 220px;
}

.addons-name-title {
  font-weight: 700;
  color: var(--ink);
}

.addons-name-meta {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.addons-editor-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.addons-editor-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(13, 106, 113, 0.08);
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
}

.services-table-wrap {
  overflow-x: auto;
}

.services-table {
  min-width: 1040px;
}

.services-table td {
  vertical-align: middle;
}

.services-empty-row {
  text-align: center;
  padding: 28px 12px;
}

.resources-filter-grid,
.blocks-filter-grid,
.members-filter-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.packages-filter-grid,
.coupons-filter-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.packages-client-filter-grid,
.ledger-filter-grid,
.waitlist-filter-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.compact-admin-table td {
  vertical-align: middle;
}

.resources-table {
  min-width: 860px;
}

.blocks-table,
.members-table,
.client-packages-table,
.ledger-table,
.redemptions-table,
.waitlist-table {
  min-width: 980px;
}

.packages-table,
.coupons-table {
  min-width: 1080px;
}

.packages-guide-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.members-guide-grid {
  margin-top: 18px;
}

.members-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.packages-guide-step {
  position: relative;
  display: grid;
  gap: 8px;
  padding: 18px 18px 18px 56px;
  border-radius: 18px;
  border: 1px solid rgba(13, 106, 113, 0.14);
  background: linear-gradient(180deg, rgba(13, 106, 113, 0.06), rgba(255, 255, 255, 0.92));
}

.packages-guide-step h3 {
  margin: 0;
  font-size: 16px;
}

.packages-guide-step p {
  margin: 0;
  line-height: 1.55;
}

.packages-guide-index {
  position: absolute;
  top: 18px;
  left: 18px;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}

.packages-view .clients-editor-help {
  display: grid;
  gap: 10px;
}

.resource-name-cell,
.resource-kind-cell,
.block-staff-cell,
.block-range-cell,
.block-reason-cell,
.member-name-cell,
.member-contact-cell,
.package-name-cell,
.coupon-code-cell {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.resource-name-title,
.block-staff-title,
.member-name-title,
.package-name-title,
.coupon-code-title {
  font-weight: 700;
  color: var(--ink);
}

.resource-name-meta,
.block-staff-meta,
.block-range-meta,
.member-name-meta,
.package-name-meta,
.coupon-code-meta {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.members-editor-tools {
  justify-content: space-between;
}

.admin-editor-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.admin-editor-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: rgba(13, 106, 113, 0.08);
  color: var(--ink);
  font-size: 12px;
  font-weight: 600;
}

.service-state-badge.upcoming {
  background: rgba(14, 165, 233, 0.12);
  color: #0369a1;
}

.service-state-badge.past {
  background: rgba(148, 163, 184, 0.18);
  color: #475569;
}

.member-role-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.member-role-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.member-role-badge.role-owner {
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
}

.member-role-badge.role-admin {
  background: rgba(13, 106, 113, 0.12);
  color: var(--accent);
}

.member-role-badge.role-staff {
  background: rgba(99, 102, 241, 0.12);
  color: #4338ca;
}

.service-name-cell,
.service-time-cell,
.service-assignment-cell {
  display: grid;
  gap: 4px;
}

.service-assignment-link {
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.service-assignment-link:focus-visible,
.service-summary-link:focus-visible {
  outline: 2px solid rgba(14, 116, 144, 0.38);
  outline-offset: 3px;
}

.service-name-cell {
  min-width: 260px;
}

.service-name-title {
  font-weight: 700;
  color: #0f172a;
}

.service-name-meta {
  font-size: 12px;
  line-height: 1.45;
  color: var(--muted);
}

.service-price-cell {
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
}

.service-assignment-cell strong,
.service-time-cell strong {
  color: #0f172a;
}

.service-state-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.service-state-badge.active {
  background: rgba(22, 163, 74, 0.14);
  color: #15803d;
}

.service-state-badge.inactive {
  background: rgba(148, 163, 184, 0.18);
  color: #475569;
}

.services-editor-summary {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.service-staff-summary {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.service-staff-view {
  gap: 16px;
}

.service-staff-toolbar {
  display: grid;
  gap: 12px;
  grid-template-columns: minmax(220px, 1.1fr) minmax(240px, 1fr) auto;
  align-items: end;
}

.service-staff-toolbar > label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
}

.service-staff-table {
  min-width: 820px;
}

.service-staff-table td {
  vertical-align: middle;
}

.service-staff-filter-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.service-staff-page-table {
  min-width: 1080px;
}

.service-summary-chip {
  display: grid;
  gap: 4px;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 249, 252, 0.98));
}

.service-summary-link {
  width: 100%;
  appearance: none;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.service-summary-chip strong {
  font-size: 18px;
  color: #0f172a;
}

@media (max-width: 1180px) {
  .clients-table {
    min-width: 760px;
  }

  .services-table {
    min-width: 920px;
  }
}

@media (max-width: 920px) {
  .clients-stats,
  .client-detail-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .client-detail-screen {
    padding: 18px;
  }

  .services-filter-grid,
  .services-editor-summary,
  .admin-editor-summary,
  .service-staff-summary,
  .staff-editor-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .staff-services-filter-grid {
    grid-template-columns: 1fr;
  }

  .service-staff-toolbar {
    grid-template-columns: 1fr;
  }

  .service-staff-filter-grid {
    grid-template-columns: 1fr;
  }

  .client-detail-grid,
  .client-profile-grid {
    grid-template-columns: 1fr;
  }

  .client-detail-screen-head,
  .client-detail-header,
  .client-section-head {
    flex-direction: column;
    align-items: stretch;
  }
}

@media (max-width: 640px) {
  .clients-stats,
  .client-detail-metrics,
  .client-benefits-grid,
  .packages-guide-grid {
    grid-template-columns: 1fr;
  }

  .services-filter-grid,
  .services-editor-summary,
  .admin-editor-summary,
  .service-staff-summary,
  .staff-editor-summary {
    grid-template-columns: 1fr;
  }

  .members-quick-actions,
  .members-editor-tools {
    flex-direction: column;
    align-items: stretch;
  }

  .staff-services-drawer {
    width: min(96vw, 680px);
  }

  .service-staff-page-table {
    min-width: 0;
  }

  .compact-admin-table {
    min-width: 0;
  }

  .compact-admin-table thead {
    display: none;
  }

  .compact-admin-table,
  .compact-admin-table tbody,
  .compact-admin-table tr,
  .compact-admin-table td {
    display: block;
    width: 100%;
  }

  .compact-admin-table tbody {
    display: grid;
    gap: 12px;
  }

  .compact-admin-table tr {
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 18px;
    padding: 14px;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(248, 250, 252, 0.98));
  }

  .compact-admin-table td {
    padding: 8px 0;
    border: 0;
    border-bottom: 1px dashed rgba(148, 163, 184, 0.35);
    display: grid;
    grid-template-columns: minmax(96px, 110px) minmax(0, 1fr);
    gap: 10px;
    align-items: start;
  }

  .compact-admin-table td:last-child {
    border-bottom: 0;
    padding-bottom: 0;
  }

  .compact-admin-table td::before {
    content: attr(data-label);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
  }

  .service-staff-page-table thead {
    display: none;
  }

  .service-staff-page-table,
  .service-staff-page-table tbody,
  .service-staff-page-table tr,
  .service-staff-page-table td {
    display: block;
    width: 100%;
  }

  .service-staff-page-table tbody {
    display: grid;
    gap: 12px;
    padding: 12px;
  }

  .service-staff-page-table tr {
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 18px;
    padding: 14px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 249, 252, 0.98));
  }

  .service-staff-page-table td {
    border: 0;
    padding: 0;
  }

  .service-staff-page-table td + td {
    margin-top: 10px;
  }

  .service-staff-page-table td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 4px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--muted);
  }

  .client-detail-header,
  .client-activity-head,
  .client-benefit-head,
  .client-debt-card,
  .client-activity-meta,
  .client-detail-screen-head,
  .client-section-head {
    flex-direction: column;
  }

  .client-detail-screen {
    padding: 16px;
  }

  .client-detail-screen-head .controls,
  .client-detail-header .inline-actions,
  .client-section-head .inline-actions,
  .client-history-actions {
    width: 100%;
  }

  .client-detail-screen-head .controls .btn,
  .client-detail-header .inline-actions .btn,
  .client-section-head .inline-actions .btn,
  .client-history-actions .btn {
    width: 100%;
  }

  .client-history-table {
    min-width: 0;
  }

  .client-history-table thead {
    display: none;
  }

  .client-history-table,
  .client-history-table tbody,
  .client-history-table tr,
  .client-history-table td {
    display: block;
    width: 100%;
  }

  .client-history-table tbody {
    display: grid;
    gap: 12px;
  }

  .client-history-table tr {
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 18px;
    padding: 14px;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(248, 250, 252, 0.98));
  }

  .client-history-table td {
    padding: 8px 0;
    border: 0;
    border-bottom: 1px dashed rgba(148, 163, 184, 0.35);
    display: grid;
    grid-template-columns: minmax(96px, 110px) minmax(0, 1fr);
    gap: 10px;
    align-items: start;
  }

  .client-history-table td:last-child {
    border-bottom: 0;
    padding-bottom: 0;
  }

  .client-history-table td::before {
    content: attr(data-label);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
  }

  .client-history-pagination {
    gap: 12px;
  }

  .client-history-pagination,
  .client-history-pagination .pagination-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .client-debt-card-side {
    justify-items: start;
  }
}

@media (max-width: 1180px) {
  .payments-table {
    min-width: 1280px;
  }
}

@media (max-width: 920px) {
  .payments-filter-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .payments-period-bar {
    grid-template-columns: 1fr;
  }

  .payments-period-controls {
    justify-content: flex-start;
  }

  .payments-head,
  .payments-bulk-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .payments-head .controls {
    width: 100%;
  }
}

@media (max-width: 640px) {
  .payments-filter-grid {
    grid-template-columns: 1fr;
  }

  .payments-stats {
    grid-template-columns: 1fr;
  }

  .payments-period-title {
    font-size: 20px;
  }

  .payments-period-controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .payments-period-controls .btn,
  .payments-period-inputs {
    width: 100%;
  }

  .payments-period-inputs {
    grid-template-columns: 1fr;
  }

  .payments-head .controls,
  .payments-row-actions {
    width: 100%;
  }

  .payments-head .controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .payments-head .controls .btn,
  .payments-row-actions .btn {
    width: 100%;
  }

  .payments-drawer {
    width: min(100vw - 16px, 560px);
  }
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(13, 106, 113, 0.12);
  color: var(--accent);
  font-size: 13px;
}

.label {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 8px;
}

.slot-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

#appointmentOverlay .slot-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 10px;
  max-height: min(260px, 34vh);
  overflow-y: auto;
  padding-right: 4px;
  overscroll-behavior: contain;
}

#appointmentOverlay .slot-list .slot {
  width: 100%;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
}

#appointmentOverlay .slot-list::-webkit-scrollbar {
  width: 8px;
}

#appointmentOverlay .slot-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.55);
}

.slot {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: #fff;
  cursor: pointer;
  font-size: 13px;
}

.slot.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.slot.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.public-main {
  display: grid;
  gap: 24px;
  padding: 0 clamp(20px, 4vw, 48px) 80px;
  grid-template-columns: 1fr;
  align-items: start;
}

.public-hero {
  background: linear-gradient(140deg, rgba(13, 106, 113, 0.12), rgba(245, 158, 11, 0.12));
}

.public-status-card {
  display: grid;
  gap: 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 250, 252, 0.98));
}

.public-status-card h2 {
  margin: 0;
  font-size: clamp(24px, 3vw, 32px);
  line-height: 1.15;
}

.public-status-meta {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(13, 106, 113, 0.06);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.6;
}

.public-steps {
  display: grid;
  gap: 12px;
  margin: 18px 0;
}

.public-greeting {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(13, 106, 113, 0.08);
  font-weight: 600;
}

.public-greeting.is-proxy {
  background: rgba(245, 158, 11, 0.16);
  color: #92400e;
}

.public-quick {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px dashed var(--stroke);
  background: rgba(255, 255, 255, 0.7);
}

.public-quick-text {
  font-size: 14px;
}

.public-promotions {
  display: grid;
  gap: 10px;
}

.public-promo-card {
  display: grid;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(13, 106, 113, 0.18);
  background: rgba(13, 106, 113, 0.05);
}

.public-promo-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.public-promo-body {
  display: grid;
  gap: 6px;
}

.public-promo-amount {
  font-weight: 600;
  color: var(--accent);
}

.public-promo-warning {
  color: #b45309;
  font-size: 13px;
  line-height: 1.45;
}

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

.step-index {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: #fff;
  font-weight: 600;
}

.public-info {
  display: grid;
  gap: 10px;
}

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

.public-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-end;
  flex-wrap: wrap;
}

.public-business {
  font-size: 18px;
  font-weight: 600;
}

.slug-field {
  min-width: 220px;
}

.public-summary {
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: rgba(13, 106, 113, 0.06);
  display: grid;
  gap: 8px;
}

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

.public-charge-options {
  display: grid;
  gap: 10px;
}

.payment-choice-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.choice-pill {
  position: relative;
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.choice-pill input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.choice-pill.is-active {
  border-color: var(--accent);
  background: rgba(13, 106, 113, 0.08);
  box-shadow: 0 0 0 2px rgba(13, 106, 113, 0.12);
}

.choice-pill-title {
  font-weight: 600;
  color: var(--ink);
}

.choice-pill-meta {
  font-size: 12px;
  color: var(--muted);
}

.public-actions {
  display: grid;
  gap: 12px;
  margin-top: 6px;
}

@media (min-width: 700px) {
  .public-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.client-filters {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  margin: 16px 0 20px;
}

.client-filter-date-row,
.client-filters-footer {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.client-filter-date-row {
  display: grid;
  grid-template-columns: auto 40px minmax(0, 1fr) 40px;
  align-items: center;
  gap: 10px;
}

.client-filter-date-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}

.client-filter-date-row input {
  width: 100%;
}

.client-filter-date-row .btn {
  width: 40px;
  min-width: 40px;
  justify-content: center;
}

.client-filters-footer {
  justify-content: space-between;
}

.client-filters-apply {
  display: none;
}

@media (min-width: 981px) {
  .client-filters {
    grid-template-columns: minmax(150px, 180px) minmax(150px, 180px) minmax(150px, 180px) minmax(280px, 1fr) auto;
    align-items: end;
  }

  .client-filters > label {
    min-width: 0;
  }

  .client-filter-date-row,
  .client-filters-footer {
    grid-column: auto;
    margin: 0;
  }

  .client-filters-footer {
    align-self: end;
    justify-content: flex-end;
    flex-wrap: nowrap;
  }
}

.client-filters-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.client-app .card-head {
  align-items: flex-start;
  flex-wrap: wrap;
}

.client-explore-btn {
  white-space: nowrap;
}

.client-filters-toggle {
  display: none;
}

.client-debt-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(13, 106, 113, 0.06);
  margin: 12px 0 18px;
}

.client-debt-summary .debt-amount {
  font-size: 22px;
  font-weight: 700;
  color: #b45309;
}

.client-debt-summary.is-zero .debt-amount {
  color: #15803d;
}

.client-debt-summary .debt-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.debt-summary {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 12px 0 4px;
  flex-wrap: wrap;
}

.debt-summary .debt-amount {
  font-size: 18px;
  font-weight: 700;
  color: #0d6a71;
}

.debt-filters {
  display: grid;
  gap: 12px;
  margin: 12px 0;
}

.debt-list {
  display: grid;
  gap: 12px;
}

.debt-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
}

.debt-item-main {
  display: flex;
  align-items: center;
  gap: 10px;
}

.debt-item-meta {
  font-size: 12px;
  color: var(--muted);
}

#clientFiltersOverlay .client-filters {
  grid-template-columns: 1fr;
  margin-top: 16px;
}

.benefit-card,
.coupon-card {
  display: grid;
  gap: 10px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--stroke);
  background: #fff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 18px 34px rgba(27, 27, 27, 0.08);
}

.benefit-card::before,
.coupon-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(13, 106, 113, 0.12), rgba(245, 158, 11, 0.08));
  opacity: 0.35;
  pointer-events: none;
}

.benefit-card > *,
.coupon-card > * {
  position: relative;
  z-index: 1;
}

.benefit-head,
.coupon-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.benefit-meta {
  font-weight: 600;
}

.coupon-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  color: var(--muted);
}

.coupon-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}

.schedule-breaks-summary .label {
  font-weight: 600;
  margin-bottom: 8px;
}

.schedule-breaks-summary .stack {
  gap: 6px;
}

.day-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(64px, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.day-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: #fff;
  font-size: 12px;
}

.day-chip input {
  width: auto;
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.check-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fff;
  font-size: 13px;
}

.check-item input {
  width: auto;
}

.mini-panel {
  margin-top: 12px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.7);
  display: grid;
  gap: 12px;
}

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

.confirm-copy {
  display: grid;
  gap: 10px;
}

.confirm-copy p {
  margin: 0;
}

.confirm-compare {
  display: grid;
  gap: 12px;
}

.confirm-compare-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.72);
}

.confirm-compare-body {
  display: grid;
  gap: 6px;
  font-size: 13px;
}

.small {
  font-size: 12px;
}

.public-hero ul {
  margin: 0;
  padding-left: 18px;
}

.public-hero li {
  margin-bottom: 6px;
}

.pricing {
  width: min(980px, 94vw);
}

.plan-page .top-actions {
  flex-wrap: wrap;
}

.plan-wrapper {
  width: min(1100px, 92vw);
  margin: 0 auto 80px;
  display: grid;
  gap: 32px;
}

.plan-hero {
  border: 1px solid var(--stroke);
  border-radius: 28px;
  padding: clamp(24px, 4vw, 36px);
  background:
    radial-gradient(circle at top left, rgba(13, 106, 113, 0.12), transparent 36%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(252, 248, 243, 0.92));
  box-shadow: var(--shadow);
}

.plan-hero-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: 1.4fr 0.9fr;
  align-items: stretch;
}

.plan-hero-copy h1 {
  font-size: clamp(30px, 4vw, 46px);
  max-width: 11ch;
  margin-bottom: 14px;
}

.plan-hero-copy > .muted {
  max-width: 62ch;
}

.plan-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.plan-hero-cta {
  margin: 20px 0 18px;
  display: grid;
  gap: 6px;
}

.plan-price {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.plan-price-amount {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 700;
  font-family: "Fraunces", "Times New Roman", serif;
}

.plan-price-cycle {
  font-size: 16px;
  color: var(--muted);
}

.plan-proof-strip {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.proof-chip {
  padding: 16px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.84);
  display: grid;
  gap: 6px;
}

.metric-title {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.metric-value {
  font-weight: 600;
}

.proof-chip strong,
.section-metric-value {
  font-size: clamp(22px, 3vw, 32px);
  line-height: 1;
  font-family: "Fraunces", "Times New Roman", serif;
}

.proof-chip span {
  font-size: 13px;
  color: var(--muted);
}

.plan-hero-card {
  border: 1px solid var(--stroke);
  border-radius: 20px;
  padding: 20px;
  background: linear-gradient(180deg, #fff, rgba(249, 247, 243, 0.96));
  display: grid;
  gap: 14px;
  align-content: start;
  box-shadow: 0 20px 40px rgba(24, 34, 45, 0.08);
}

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

.plan-card-price {
  display: grid;
  gap: 4px;
}

.plan-card-amount {
  font-size: 28px;
  font-weight: 700;
}

.plan-card-list {
  display: grid;
  gap: 8px;
}

.plan-card-item {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.55;
}

.plan-card-item strong {
  color: var(--ink);
}

.plan-section {
  display: grid;
  gap: 16px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
}

.section-head--stack {
  align-items: flex-start;
}

.section-head-metric {
  min-width: 160px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.9);
  text-align: right;
}

.feature-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.feature-card {
  border: 1px solid var(--stroke);
  border-radius: 18px;
  padding: 18px;
  background: #fff;
  display: grid;
  gap: 12px;
}

.feature-card--highlight {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 1), rgba(245, 249, 248, 0.92));
}

.feature-list {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  display: grid;
  gap: 8px;
}

.vertical-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.vertical-card {
  border: 1px solid var(--stroke);
  border-radius: 20px;
  padding: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(251, 245, 239, 0.94));
  display: grid;
  gap: 12px;
  min-height: 220px;
}

.vertical-card h3 {
  margin: 0;
  font-size: 22px;
}

.vertical-card p {
  margin: 0;
}

.trusted-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.trusted-card,
.trusted-empty {
  border: 1px solid var(--stroke);
  border-radius: 22px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 34px rgba(24, 34, 45, 0.08);
}

.trusted-card-media {
  display: block;
  text-decoration: none;
}

.trusted-card-cover {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
  background: linear-gradient(135deg, rgba(13, 106, 113, 0.18), rgba(245, 158, 11, 0.12));
}

.trusted-card-cover-fallback {
  display: grid;
  place-items: center;
}

.trusted-card-cover-fallback span {
  font-size: 44px;
  font-family: "Fraunces", "Times New Roman", serif;
  color: var(--accent);
}

.trusted-card-body {
  display: grid;
  gap: 14px;
  padding: 18px;
}

.trusted-card-brand {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
}

.trusted-card-logo {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  object-fit: cover;
  display: block;
  border: 1px solid rgba(27, 27, 27, 0.08);
}

.trusted-card-logo-fallback {
  display: grid;
  place-items: center;
  background: rgba(13, 106, 113, 0.12);
  color: var(--accent);
  font-weight: 700;
}

.trusted-card-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(13, 106, 113, 0.1);
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.trusted-card h3,
.trusted-empty strong {
  margin: 8px 0 0;
  font-size: 20px;
}

.trusted-card p,
.trusted-empty span {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.trusted-card-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--muted);
}

.trusted-empty {
  padding: 20px;
  display: grid;
  gap: 10px;
}

.trusted-card--loading {
  opacity: 0.88;
}

.compare-grid {
  display: grid;
  grid-template-columns: minmax(160px, 0.9fr) minmax(0, 1fr) minmax(0, 1fr);
  border: 1px solid var(--stroke);
  border-radius: 20px;
  overflow: hidden;
  background: #fff;
}

.compare-head {
  padding: 14px 16px;
  font-weight: 600;
  background: rgba(27, 27, 27, 0.06);
  border-bottom: 1px solid var(--stroke);
}

.compare-head--turnos {
  background: rgba(13, 106, 113, 0.12);
}

.compare-head--other {
  background: rgba(245, 158, 11, 0.12);
}

.compare-head--empty {
  background: transparent;
  border-bottom: 1px solid var(--stroke);
}

.compare-label {
  padding: 12px 16px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  background: rgba(27, 27, 27, 0.04);
  border-top: 1px solid var(--stroke);
}

.compare-cell {
  padding: 12px 16px;
  font-size: 13px;
  color: var(--muted);
  border-top: 1px solid var(--stroke);
}

.compare-cell--turnos {
  color: var(--ink);
  background: rgba(13, 106, 113, 0.03);
}

.compare-cell--other {
  background: rgba(245, 158, 11, 0.03);
}

.compare-cell.highlight {
  font-weight: 700;
  color: var(--accent);
}

.check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  margin-right: 8px;
  background: rgba(13, 106, 113, 0.15);
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
}

.plan-footer {
  text-align: center;
  padding: 24px 16px 40px;
  font-size: 12px;
  color: var(--muted);
}

.faq-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.faq-card {
  border: 1px solid var(--stroke);
  border-radius: 18px;
  padding: 18px;
  background: #fff;
}

.faq-card h3 {
  margin-bottom: 10px;
  font-size: 18px;
}

@media (max-width: 980px) {
  .plan-hero-copy h1 {
    max-width: none;
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .section-head-metric {
    width: 100%;
    text-align: left;
  }

  .vertical-card {
    min-height: 0;
  }
}

@media (max-width: 640px) {
  .plan-hero-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .proof-chip strong,
  .section-metric-value {
    font-size: 26px;
  }

  .trusted-card-foot {
    align-items: flex-start;
    flex-direction: column;
  }
}

.help-page {
  min-height: 100vh;
}

.help-wrapper {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 72px;
  display: grid;
  gap: 22px;
}

.help-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.9fr);
  gap: 20px;
  align-items: stretch;
  background:
    radial-gradient(circle at top right, rgba(245, 158, 11, 0.18), transparent 34%),
    linear-gradient(145deg, rgba(13, 106, 113, 0.14), rgba(255, 255, 255, 0.96));
}

.help-hero h1 {
  margin: 12px 0;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.02;
}

.help-hero-copy {
  display: grid;
  gap: 12px;
}

.help-hero-stats {
  display: grid;
  gap: 14px;
  align-content: start;
}

.help-tabs {
  position: sticky;
  top: 76px;
  z-index: 6;
  display: flex;
  gap: 10px;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding: 12px;
  border: 1px solid var(--stroke);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px);
}

.help-tab {
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-weight: 600;
  white-space: nowrap;
  padding: 10px 16px;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.help-tab:hover {
  border-color: rgba(13, 106, 113, 0.18);
  color: var(--ink);
}

.help-tab.is-active {
  background: rgba(13, 106, 113, 0.12);
  border-color: rgba(13, 106, 113, 0.24);
  color: var(--accent);
  transform: translateY(-1px);
}

.help-section {
  display: grid;
  gap: 18px;
  scroll-margin-top: 150px;
}

.help-support-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.help-cta {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(13, 106, 113, 0.22);
  background: linear-gradient(145deg, rgba(13, 106, 113, 0.08), rgba(245, 158, 11, 0.08));
}

.help-cta h3 {
  margin: 6px 0 0;
  font-size: 24px;
}

@media (max-width: 900px) {
  .help-hero {
    grid-template-columns: 1fr;
  }

  .help-support-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .help-wrapper {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  .help-tabs {
    top: 68px;
    padding: 10px;
  }

  .help-tab {
    padding: 9px 14px;
    font-size: 14px;
  }

  .help-hero h1 {
    font-size: clamp(28px, 10vw, 40px);
  }
}

.pricing-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 16px;
}

.price-card {
  border: 1px solid var(--stroke);
  border-radius: 16px;
  padding: 18px;
  background: #fff;
  display: grid;
  gap: 10px;
}

.price-card.highlight {
  border-color: rgba(13, 106, 113, 0.4);
  background: rgba(13, 106, 113, 0.06);
}

.price-card ul {
  margin: 0;
  padding-left: 18px;
}

.price-card li {
  margin-bottom: 6px;
  font-size: 13px;
  color: var(--muted);
}

.kpi-grid {
  margin-top: 16px;
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.kpi-card {
  padding: 16px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: #fff;
  display: grid;
  gap: 6px;
}

.payment-note {
  padding: 12px;
  border-radius: 12px;
  background: rgba(13, 106, 113, 0.08);
  font-size: 13px;
}

.benefit-item {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.65);
}

.share-qr {
  display: grid;
  gap: 12px;
  place-items: center;
  text-align: center;
  padding: 16px 0;
}

.share-qr img {
  width: 220px;
  height: 220px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: #fff;
}

.tabs-list {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.tab-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fff;
  font-size: 14px;
}

.tab-option input {
  width: auto;
}

.result-card {
  text-align: center;
  display: grid;
  gap: 12px;
}

.result-status {
  font-size: 22px;
  font-weight: 700;
}

.result-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 14px 18px;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  box-shadow: var(--shadow);
  z-index: 10;
}

.toast.error {
  background: #b91c1c;
}

.toast.success {
  background: #15803d;
}

@keyframes float {
  0% {
    transform: translateY(0px) scale(1);
  }
  50% {
    transform: translateY(20px) scale(1.03);
  }
  100% {
    transform: translateY(0px) scale(1);
  }
}

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

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

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideFromLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideFromRight {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (min-width: 980px) {
  .public-main {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  }

  .overlay {
    align-items: stretch;
    justify-items: end;
  }

  .drawer {
    width: min(440px, 38vw);
    height: 100%;
    max-height: none;
    border-radius: 0;
    animation: slideIn 0.2s ease both;
  }
}

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

@media (max-width: 980px) {
  .plan-hero-grid {
    grid-template-columns: 1fr;
  }

  .plan-page .topbar {
    align-items: flex-start;
  }

  .plan-page .top-actions {
    width: 100%;
    justify-content: flex-start;
    gap: 10px;
  }

  .plan-page .top-actions .btn {
    flex: 1 1 160px;
    text-align: center;
  }

  .compare-grid {
    grid-template-columns: 1fr;
  }

  .compare-head--empty {
    display: none;
  }

  .compare-head--turnos,
  .compare-head--other {
    display: none;
  }

  .compare-cell--turnos::before {
    content: "TurnosFlex · ";
    font-weight: 600;
    color: var(--ink);
  }

  .compare-cell--other::before {
    content: "Otros · ";
    font-weight: 600;
    color: var(--muted);
  }

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

  .sidebar {
    position: static;
  }

  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }

  .public-main {
    grid-template-columns: 1fr;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .public-header {
    align-items: flex-start;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .business-switch {
    width: 100%;
    max-width: none;
  }

  .public .topbar {
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }

  .public .top-actions {
    margin-left: auto;
    justify-content: flex-end;
  }

  .agenda-staff-header,
  .agenda-grid {
    grid-auto-columns: minmax(160px, 1fr);
  }

  .agenda-time-col {
    width: 60px;
    flex-basis: 60px;
  }
}

@media (max-width: 600px) {
  .topbar {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
  }

  .business-switch {
    order: 3;
    width: 100%;
    flex-basis: 100%;
  }

  .brand {
    min-width: 0;
  }

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

  .brand-sub {
    display: none;
  }

  .public .topbar {
    padding: 18px 16px;
  }

  .client-filters-wrap {
    display: none;
  }

  .client-filters-actions {
    display: flex;
  }

  .client-filters-toggle {
    display: inline-flex;
  }

  .client-filters-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .client-filters-footer .btn {
    width: 100%;
    justify-content: center;
  }

  .client-filter-date-row {
    grid-template-columns: auto 40px minmax(0, 1fr) 40px;
    align-items: center;
  }

  .client-filter-date-row .btn {
    width: 40px;
    justify-content: center;
  }

  .client-filters-apply {
    display: inline-flex;
  }

  .agenda-staff-header,
  .agenda-grid {
    grid-auto-columns: minmax(140px, 1fr);
  }

  .agenda-time-col {
    width: 54px;
    flex-basis: 54px;
  }

  .agenda-event {
    padding: 6px;
  }

  .public .top-actions .btn {
    padding: 10px 12px;
    font-size: 13px;
  }

  .public .card {
    padding: 20px;
  }

  .brand-logo {
    width: 40px;
    height: 40px;
    border-radius: 10px;
  }

  .top-actions {
    display: none;
  }

  .mobile-actions {
    display: flex;
  }

  body.auth-mode .top-actions {
    display: flex;
  }

  body.auth-mode .mobile-actions {
    display: none;
  }

  .agenda-controls {
    align-items: stretch;
  }

  .agenda-filters {
    width: 100%;
  }

  .agenda-search input {
    width: 100%;
    min-width: 0;
  }

  .agenda-strip {
    gap: 8px;
  }

  .drawer.right {
    width: 100%;
    border-radius: 0;
  }
}

@media (max-width: 980px) {
  .notifications-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .notification-panel {
    min-width: min(88vw, 340px);
    max-width: min(88vw, 360px);
  }
}

@media (max-width: 640px) {
  .notifications-stats {
    grid-template-columns: 1fr;
  }

  .notification-panel {
    right: -8px;
    min-width: min(92vw, 320px);
    max-width: min(92vw, 340px);
  }

  .notification-item {
    padding: 12px 14px;
  }

  .notification-panel-head {
    padding: 12px 14px;
    align-items: flex-start;
  }

.notification-panel-tools {
  width: 100%;
  justify-content: flex-start;
}
}

.member-role-badge.role-admin-plus {
  background: rgba(14, 116, 144, 0.12);
  color: #0f766e;
}

.billing-support-view {
  gap: 20px;
}

.billing-support-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(320px, 0.9fr);
  gap: 18px;
  align-items: start;
}

.billing-support-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.billing-support-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: 20px;
}

.billing-support-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.billing-support-form {
  gap: 14px;
}

.billing-support-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.billing-support-form label {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.billing-support-form label.is-disabled {
  opacity: 0.72;
}

.billing-support-source {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.22);
}

.billing-support-overview {
  height: 100%;
}

.billing-support-overview-grid {
  display: grid;
  gap: 12px;
}

.billing-support-overview-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(248, 250, 252, 0.96), rgba(241, 245, 249, 0.82));
  border: 1px solid rgba(148, 163, 184, 0.22);
}

.billing-support-overview-card strong {
  font-size: 1.1rem;
  color: #0f172a;
}

.billing-support-table td strong {
  display: inline-block;
  margin-bottom: 4px;
}

.billing-support-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 106px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
}

.billing-support-status.active {
  background: rgba(34, 197, 94, 0.12);
  color: #166534;
}

.billing-support-status.queued {
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
}

.billing-support-status.muted {
  background: rgba(148, 163, 184, 0.16);
  color: #475569;
}

@media (max-width: 980px) {
  .billing-support-hero,
  .billing-support-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .billing-support-stats,
  .billing-support-form-grid {
    grid-template-columns: 1fr;
  }

  .billing-support-source {
    flex-direction: column;
    align-items: flex-start;
  }
}

.public-booking-shell {
  display: grid;
  gap: 22px;
  width: 100%;
  grid-column: 1 / -1;
}

.public-booking-layout {
  display: grid;
  gap: 24px;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.9fr);
  align-items: start;
}

.public-booking-main {
  display: grid;
  gap: 18px;
}

.public-booking-aside {
  position: sticky;
  top: 24px;
}

.public-summary-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 20px;
  border: 1px solid var(--stroke);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(248, 250, 252, 0.98)),
    linear-gradient(145deg, rgba(13, 106, 113, 0.08), rgba(245, 158, 11, 0.1));
}

.public-summary-head {
  display: grid;
  gap: 4px;
}

.booking-summary-items,
.selected-service-list,
.professional-selection-list {
  display: grid;
  gap: 12px;
}

.wizard-progress {
  display: flex;
  align-items: center;
  gap: 0;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  padding-bottom: 2px;
}

.wizard-progress::-webkit-scrollbar {
  display: none;
}

.wizard-progress-item {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0;
  flex: 0 0 auto;
  padding: 0 24px 0 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: rgba(15, 23, 42, 0.42);
  text-align: left;
  white-space: nowrap;
  box-shadow: none;
}

.wizard-progress-item::after {
  content: ">";
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-52%);
  color: rgba(15, 23, 42, 0.26);
  font-size: 13px;
  font-weight: 700;
}

.wizard-progress-item:last-child {
  padding-right: 0;
}

.wizard-progress-item:last-child::after {
  content: none;
}

.wizard-progress-item.is-active {
  color: var(--ink);
}

.wizard-progress-item.is-complete {
  color: rgba(15, 23, 42, 0.68);
}

.wizard-progress-index {
  display: none;
}

.wizard-progress-copy {
  display: inline-flex;
  align-items: center;
}

.wizard-progress-copy strong,
.wizard-progress-copy span {
  display: block;
}

.wizard-progress-copy strong {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.wizard-progress-item.is-active .wizard-progress-copy strong {
  font-weight: 700;
}

.wizard-progress-copy span {
  display: none;
}

.wizard-step {
  display: grid;
  gap: 18px;
}

.wizard-step-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.wizard-step-head h2 {
  margin: 2px 0 8px;
}

.wizard-step-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.service-category-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.service-category-tab {
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: #fff;
  color: var(--ink);
  font-weight: 600;
}

.service-category-tab.is-active {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

.service-group-list {
  display: grid;
  gap: 14px;
}

.service-group-card,
.selected-service-card,
.professional-card,
.booking-summary-item,
.service-option-item {
  display: grid;
  gap: 10px;
  padding: 18px 20px;
  border-radius: 20px;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 32px rgba(15, 23, 42, 0.06);
}

.service-group-card-head,
.selected-service-card-head,
.booking-summary-item-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.service-group-card-title,
.selected-service-card-title {
  display: grid;
  gap: 4px;
}

.service-group-meta,
.selected-service-meta,
.booking-summary-item-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
}

.booking-item-status {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.booking-item-status.is-booked {
  background: rgba(13, 106, 113, 0.1);
  color: #0f766e;
}

.booking-item-status.is-pending {
  background: rgba(180, 83, 9, 0.12);
  color: #b45309;
}

.service-group-price,
.selected-service-price,
.booking-summary-item-price {
  font-weight: 700;
  color: var(--ink);
}

.service-group-action {
  width: 40px;
  min-width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: #fff;
  font-size: 24px;
  line-height: 1;
}

.selected-services-panel {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 20px;
  border: 1px dashed var(--stroke);
  background: rgba(248, 250, 252, 0.9);
}

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

.selected-service-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.selected-service-remove {
  padding: 0;
  border: 0;
  background: transparent;
  color: #b91c1c;
  font-weight: 600;
}

.professional-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.professional-choice-grid {
  display: grid;
  gap: 10px;
}

.professional-choice {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: #fff;
  cursor: pointer;
}

.professional-choice input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.professional-choice.is-active {
  border-color: rgba(13, 106, 113, 0.34);
  background: rgba(13, 106, 113, 0.08);
}

.professional-choice-copy {
  display: grid;
  gap: 2px;
}

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

.time-toolbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.time-month-label {
  font-size: 22px;
  font-weight: 700;
  color: var(--ink);
}

.day-pill-list {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.day-pill {
  display: grid;
  gap: 6px;
  justify-items: center;
  padding: 12px 6px;
  border-radius: 22px;
  border: 1px solid var(--stroke);
  background: #fff;
}

.day-pill.is-active {
  border-color: transparent;
  background: var(--accent);
  color: #fff;
}

.day-pill.is-disabled {
  opacity: 0.45;
}

.day-pill-number {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(15, 23, 42, 0.08);
  font-size: 18px;
  font-weight: 700;
}

.day-pill.is-active .day-pill-number {
  border-color: rgba(255, 255, 255, 0.26);
}

.slot-list {
  display: grid;
  gap: 12px;
}

.slot-list .slot {
  width: 100%;
  display: grid;
  gap: 6px;
  justify-content: flex-start;
  padding: 18px 20px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: #fff;
  text-align: left;
  outline: none;
  transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.slot-time {
  font-size: 22px;
  font-weight: 700;
  color: var(--ink);
}

.slot-meta {
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}

.slot-list .slot.is-partial {
  border-color: rgba(180, 83, 9, 0.22);
  background: linear-gradient(180deg, rgba(255, 251, 235, 0.94), rgba(255, 255, 255, 0.98));
}

.slot-list .slot.active {
  border-color: color-mix(in srgb, var(--accent) 55%, white);
  background: color-mix(in srgb, var(--accent) 10%, white);
  color: var(--ink);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 18%, transparent);
}

.slot-list .slot:focus-visible {
  border-color: color-mix(in srgb, var(--accent) 55%, white);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 18%, transparent);
}

.slot-list .slot.active .slot-meta {
  color: var(--ink);
}

.booking-flow-note {
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(13, 106, 113, 0.14);
  background: rgba(13, 106, 113, 0.06);
  color: #0f4b52;
  font-size: 13px;
  line-height: 1.55;
}

.service-option-drawer {
  display: grid;
  gap: 16px;
}

.service-option-list {
  display: grid;
  gap: 12px;
}

.service-option-item {
  cursor: pointer;
}

.service-option-item.is-active {
  border-color: rgba(13, 106, 113, 0.34);
  background: rgba(13, 106, 113, 0.08);
}

.service-option-item input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 1180px) {
  .public-booking-layout {
    grid-template-columns: 1fr;
  }

  .public-booking-aside {
    position: static;
  }
}

@media (max-width: 900px) {
  .wizard-progress-item {
    padding-right: 20px;
  }

  .day-pill-list {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .public-booking-aside {
    display: none;
  }

  .wizard-progress {
    margin-bottom: 2px;
  }

  .wizard-step-head,
  .time-toolbar,
  .wizard-step-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .day-pill-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .slot-list .slot {
    padding: 16px 18px;
  }

  .slot-time {
    font-size: 20px;
  }
}
