:root {
  --bg: #111111;
  --card: #1a1a1a;
  --text: #f5f5f5;
  --muted: #888888;
  --gold: #c9a55c;
  --goldHover: #d4b76a;
  --ok: #4caf50;
  --err: #e57373;
  --radius: 12px;
  --shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
  --bezBg1: #2a2317;
  --bezBg2: #1a140c;
  --bezPanel: rgba(72, 58, 42, 0.55);
  --bezBorder: rgba(201, 165, 92, 0.26);
}

* {
  box-sizing: border-box;
}
html,
body {
  height: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    Inter,
    system-ui,
    -apple-system,
    Segoe UI,
    Roboto,
    Arial,
    sans-serif;
}

a {
  color: inherit;
}

.theme-bez {
  background:
    radial-gradient(900px 450px at 50% 14%, rgba(201, 165, 92, 0.12), transparent 55%),
    radial-gradient(700px 420px at 18% 65%, rgba(201, 165, 92, 0.1), transparent 60%),
    radial-gradient(700px 420px at 82% 65%, rgba(201, 165, 92, 0.1), transparent 60%),
    linear-gradient(180deg, var(--bezBg1), var(--bezBg2));
}

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

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

.brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.brand h1 {
  margin: 0;
  font-family: Montserrat, Inter, system-ui, sans-serif;
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.6px;
}
.brand .sub {
  color: var(--muted);
  font-size: 13px;
}

.card {
  background: var(--card);
  border: 1px solid rgba(201, 165, 92, 0.18);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

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

.muted {
  color: var(--muted);
}
.small {
  font-size: 13px;
}
.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.btn {
  appearance: none;
  border: 1px solid rgba(201, 165, 92, 0.35);
  background: transparent;
  color: var(--text);
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  transition:
    transform 0.08s ease,
    box-shadow 0.15s ease,
    border-color 0.15s ease,
    background 0.15s ease;
}
.btn.ghost {
  border-color: rgba(255, 255, 255, 0.08);
  color: rgba(245, 245, 245, 0.85);
  background: rgba(255, 255, 255, 0.02);
}
.btn:hover {
  border-color: rgba(212, 183, 106, 0.8);
  box-shadow: 0 0 0 3px rgba(201, 165, 92, 0.12);
  transform: translateY(-1px);
}
.btn.primary {
  background: linear-gradient(160deg, #dfc27a 0%, #c9a55c 55%, #a8813a 100%);
  color: #111;
  border-color: transparent;
  font-weight: 600;
  box-shadow: 0 2px 14px rgba(201, 165, 92, 0.30);
}
.btn.primary:hover {
  background: linear-gradient(160deg, #e8ce8e 0%, #d4b76a 55%, #b8914a 100%);
  box-shadow: 0 4px 20px rgba(201, 165, 92, 0.40);
}
.btn.danger {
  border-color: rgba(229, 115, 115, 0.55);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.pill {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(201, 165, 92, 0.25);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  color: var(--muted);
}

.calendar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
  margin-top: 12px;
}

.public .calendar {
  gap: 6px;
  max-width: 440px;
  margin: 12px auto 0;
}
.calendar .dow {
  color: rgba(245, 245, 245, 0.6);
  font-size: 12px;
  text-align: center;
  font-weight: 600;
  letter-spacing: 0.3px;
  padding-bottom: 4px;
}
.public .calendar .dow {
  font-size: 13px;
}
.day {
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  padding: 10px 8px;
  min-height: 44px;
  text-align: center;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.02);
  transition:
    border-color 0.15s ease,
    transform 0.08s ease,
    box-shadow 0.15s ease,
    background 0.15s ease;
}

.public .day {
  min-height: 46px;
  padding: 10px 4px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
}
.day:hover {
  transform: translateY(-1px);
  border-color: rgba(201, 165, 92, 0.5);
  box-shadow: 0 0 0 3px rgba(201, 165, 92, 0.1);
}
.day.disabled {
  opacity: 0.18;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.day.available {
  border-color: rgba(201, 165, 92, 0.75);
  background: rgba(201, 165, 92, 0.18);
  color: #f5e6c0;
  font-weight: 700;
  box-shadow: 0 0 0 1px rgba(201, 165, 92, 0.2) inset;
}
.day.available:hover {
  background: rgba(201, 165, 92, 0.28);
  border-color: rgba(201, 165, 92, 0.95);
  box-shadow: 0 0 10px rgba(201, 165, 92, 0.2);
  transform: translateY(-2px);
}
.day.selected {
  background: rgba(201, 165, 92, 0.35);
  border-color: rgba(212, 183, 106, 0.95);
  box-shadow: 0 0 0 3px rgba(201, 165, 92, 0.25);
  color: #fff;
}

.slots {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.slot {
  min-width: 92px;
}

label {
  display: block;
  font-size: 13px;
  margin: 12px 0 6px;
  color: var(--muted);
}
input,
textarea,
select {
  width: 100%;
  background: #121212;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text);
  border-radius: 10px;
  padding: 10px 12px;
  outline: none;
}
textarea {
  min-height: 90px;
  resize: vertical;
}
input:focus,
textarea:focus,
select:focus {
  border-color: rgba(201, 165, 92, 0.7);
  box-shadow: 0 0 0 3px rgba(201, 165, 92, 0.12);
}

.row {
  display: flex;
  gap: 12px;
}
.row > * {
  flex: 1;
}
@media (max-width: 520px) {
  .row {
    flex-direction: column;
  }
}

.alert {
  margin-top: 12px;
  border-radius: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
}
.alert.ok {
  border-color: rgba(76, 175, 80, 0.45);
}
.alert.err {
  border-color: rgba(229, 115, 115, 0.55);
}

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

.tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 10px 0 0;
}
.tab {
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.tab.active {
  background: rgba(201, 165, 92, 0.14);
  border-color: rgba(201, 165, 92, 0.60);
  color: var(--gold);
  font-weight: 600;
}

.table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.table th,
.table td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  text-align: left;
  font-size: 13px;
  vertical-align: middle;
}
.table th {
  color: var(--muted);
  font-weight: 600;
}
.table tr:last-child td {
  border-bottom: none;
}

/* Public wizard (Bez Birolo style) */
.public {
  max-width: 980px;
}

.public-admin-link {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 10;
  backdrop-filter: blur(10px);
  background: rgba(0, 0, 0, 0.25);
  border-color: rgba(201, 165, 92, 0.25);
  text-decoration: none;
}

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px 0 10px;
  text-align: center;
}

.logo-img {
  display: block;
  width: min(220px, 70vw);
  height: auto;
  border-radius: 10px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}
.logo-mark {
  font-family: Montserrat, Inter, system-ui, sans-serif;
  letter-spacing: 1.4px;
  font-weight: 600;
  color: rgba(201, 165, 92, 0.95);
}
.logo-sub {
  margin-top: 6px;
  font-size: 12px;
  letter-spacing: 3.2px;
  color: rgba(245, 245, 245, 0.55);
}

.hero-title {
  font-family: Montserrat, Inter, system-ui, sans-serif;
  letter-spacing: 4px;
  font-size: 14px;
  color: rgba(201, 165, 92, 0.95);
}
.hero-muted {
  color: rgba(245, 245, 245, 0.45);
  font-size: 12px;
  letter-spacing: 2px;
}

.wizard {
  margin-top: 10px;
}

.stepper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 10px auto 16px;
  color: rgba(245, 245, 245, 0.55);
}
.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 72px;
}
.step .dot {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  font-size: 13px;
}
.step .label {
  font-size: 12px;
  letter-spacing: 0.2px;
}
.step.active {
  color: rgba(201, 165, 92, 0.95);
}
.step.active .dot {
  border-color: rgba(201, 165, 92, 0.65);
  background: rgba(201, 165, 92, 0.2);
  color: #111;
  box-shadow: 0 0 14px rgba(201, 165, 92, 0.35);
}
.step.done .dot {
  border-color: rgba(201, 165, 92, 0.35);
  background: rgba(201, 165, 92, 0.1);
  color: rgba(245, 245, 245, 0.85);
}
.line {
  width: 64px;
  height: 1px;
  background: rgba(255, 255, 255, 0.12);
}

.panel {
  background: var(--bezPanel);
  border-color: var(--bezBorder);
  border-top-color: rgba(201, 165, 92, 0.45);
  backdrop-filter: blur(20px);
  padding: 22px;
}
@media (max-width: 520px) {
  .panel {
    padding: 16px;
  }
  .line {
    width: 38px;
  }
}

.panel-head {
  display: flex;
  align-items: center;
  gap: 12px;
}
.panel-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(201, 165, 92, 0.12);
  border: 1px solid rgba(201, 165, 92, 0.2);
}
.panel-title {
  font-size: 18px;
  font-weight: 600;
}
.panel-sub {
  margin-top: 2px;
  font-size: 13px;
  color: rgba(245, 245, 245, 0.55);
}

.month-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
}
.month-title {
  color: rgba(245, 245, 245, 0.7);
  font-weight: 600;
  text-transform: lowercase;
  letter-spacing: 0.2px;
}

.today-bar {
  margin-top: 14px;
  padding: 11px 16px;
  border-radius: 12px;
  background: rgba(201, 165, 92, 0.10);
  border: 1px solid rgba(201, 165, 92, 0.28);
  color: rgba(201, 165, 92, 0.90);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-align: center;
}

.consult-notice {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(201, 165, 92, 0.07);
  border: 1px solid rgba(201, 165, 92, 0.22);
  font-size: 13px;
  color: rgba(245, 245, 245, 0.75);
  line-height: 1.5;
}
.consult-notice strong {
  color: rgba(201, 165, 92, 0.95);
}
.consult-notice-icon {
  flex-shrink: 0;
  font-size: 15px;
  margin-top: 1px;
}

.hint {
  margin-top: 14px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.back-link {
  appearance: none;
  border: none;
  background: transparent;
  color: rgba(201, 165, 92, 0.92);
  cursor: pointer;
  padding: 0;
  font-size: 13px;
}
.back-link:hover {
  text-decoration: underline;
}

.slots-big .btn {
  min-width: 140px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.12);
  border-color: rgba(255, 255, 255, 0.1);
}
.slots-big .btn.primary {
  background: rgba(201, 165, 92, 0.85);
  color: #1a140c;
}

.panel input,
.panel textarea,
.panel select {
  background: rgba(0, 0, 0, 0.14);
  border-color: rgba(255, 255, 255, 0.1);
}
.panel select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, rgba(245, 245, 245, 0.6) 50%),
    linear-gradient(135deg, rgba(245, 245, 245, 0.6) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) calc(1em + 2px),
    calc(100% - 13px) calc(1em + 2px);
  background-size:
    5px 5px,
    5px 5px;
  background-repeat: no-repeat;
}

.actions {
  display: flex;
  gap: 12px;
  margin-top: 14px;
}
.actions .btn {
  flex: 1;
}
.actions .btn.ghost {
  background: rgba(255, 255, 255, 0.03);
}

.success {
  text-align: center;
  padding: 24px 0 6px;
}
@keyframes popIn {
  from { transform: scale(0.6); opacity: 0; }
  to   { transform: scale(1);   opacity: 1; }
}

.success-mark {
  width: 62px;
  height: 62px;
  margin: 0 auto 10px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 2px solid rgba(201, 165, 92, 0.55);
  color: rgba(201, 165, 92, 0.95);
  font-size: 26px;
  animation: popIn 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
.success-title {
  font-family: Montserrat, Inter, system-ui, sans-serif;
  font-weight: 600;
  color: rgba(201, 165, 92, 0.95);
  font-size: 20px;
}
.summary {
  margin: 16px auto 0;
  max-width: 520px;
  text-align: left;
  padding: 14px 14px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.summary-row {
  display: flex;
  gap: 10px;
  padding: 8px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.summary-row:last-child {
  border-bottom: none;
}
.summary-k {
  width: 90px;
  color: rgba(245, 245, 245, 0.5);
  font-size: 12px;
}
.summary-v {
  flex: 1;
  font-weight: 600;
}

.footer {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin-top: 18px;
  color: rgba(201, 165, 92, 0.75);
}

/* Admin (Bez Birolo style) */
.admin-page {
  max-width: 1120px;
}

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

.admin-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.admin-logo-wrap {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.14);
  padding: 8px 10px;
  backdrop-filter: blur(10px);
}

.admin-logo {
  display: block;
  height: 36px;
  width: auto;
  max-width: 240px;
  object-fit: contain;
}

.admin-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.admin-kicker {
  font-family: Montserrat, Inter, system-ui, sans-serif;
  letter-spacing: 2px;
  font-size: 12px;
  color: rgba(201, 165, 92, 0.95);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.admin-sub {
  color: rgba(245, 245, 245, 0.5);
  font-size: 12px;
}

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

@media (max-width: 720px) {
  .admin-topbar {
    flex-direction: column;
    align-items: stretch;
  }
  .admin-actions {
    justify-content: stretch;
  }
  .admin-actions .btn {
    flex: 1;
  }
}

.admin-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 980px) {
  .admin-grid {
    grid-template-columns: 1fr;
  }
}

.admin-card {
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.12);
  padding: 16px;
}

.admin-calendar .day {
  min-height: 54px;
  border-radius: 12px;
}

.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
