:root {
  --bg: #f6eee8;
  --bg-soft: #fff9f5;
  --surface: rgba(255, 255, 255, 0.86);
  --surface-strong: #fffdfb;
  --surface-muted: #f4e7df;
  --line: rgba(121, 87, 74, 0.14);
  --accent: #c58474;
  --accent-strong: #a96053;
  --accent-soft: #f3d9cf;
  --success: #6f9880;
  --danger: #b46d69;
  --text: #2b1c17;
  --text-soft: #6e5951;
  --text-faint: #9f8a82;
  --shadow: 0 24px 50px rgba(124, 92, 80, 0.14);
  --shadow-soft: 0 14px 28px rgba(124, 92, 80, 0.1);
  --radius-xl: 30px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI", "Trebuchet MS", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(245, 210, 198, 0.7), transparent 34%),
    radial-gradient(circle at right center, rgba(240, 229, 208, 0.8), transparent 28%),
    linear-gradient(180deg, #fbf5f0 0%, #f3e6df 100%);
}

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

button {
  cursor: pointer;
  border: 0;
  background: none;
}

.app-shell {
  position: relative;
  width: min(100%, 440px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 18px 16px calc(28px + env(safe-area-inset-bottom));
  overflow: hidden;
}

.ambient {
  position: absolute;
  border-radius: 999px;
  filter: blur(16px);
  opacity: 0.65;
  pointer-events: none;
  animation: drift 11s ease-in-out infinite;
}

.ambient-one {
  top: 54px;
  right: -30px;
  width: 138px;
  height: 138px;
  background: rgba(244, 202, 190, 0.9);
}

.ambient-two {
  left: -38px;
  top: 36%;
  width: 120px;
  height: 120px;
  background: rgba(232, 221, 194, 0.78);
  animation-delay: -4s;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: center;
  gap: 12px;
  padding: 8px 0 14px;
  backdrop-filter: blur(14px);
}

.topbar-copy {
  text-align: center;
}

.topbar-kicker {
  margin: 0 0 4px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.topbar-title {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 24px;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.55);
  box-shadow: var(--shadow-soft);
}

.screen-host {
  position: relative;
  z-index: 1;
}

.screen {
  display: grid;
  gap: 16px;
  animation: reveal 0.45s ease;
}

.card {
  position: relative;
  overflow: hidden;
  padding: 20px;
  border-radius: var(--radius-xl);
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero-card {
  padding: 24px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(249, 238, 232, 0.95)),
    var(--surface);
}

.eyebrow,
.section-label,
.service-kicker,
.calendar-hint,
.support-text,
.contact-label {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.hero-title,
.section-title {
  margin: 8px 0 0;
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.05;
}

.hero-title {
  font-size: 34px;
}

.hero-subtitle {
  margin: 10px 0 0;
  font-size: 18px;
  font-weight: 600;
}

.hero-text,
.section-text,
.selection-strong,
.summary-value,
.contact-value,
.empty-title,
.empty-text,
.status-badge,
.booking-title,
.hero-helper {
  margin: 0;
}

.hero-text,
.section-text,
.hero-helper,
.summary-value,
.contact-value,
.empty-text {
  color: var(--text-soft);
  line-height: 1.6;
}

.hero-chips,
.pill-row,
.service-meta,
.certificate-grid,
.summary-list,
.contact-stack,
.booking-list,
.service-list {
  display: grid;
  gap: 12px;
}

.hero-chips,
.pill-row,
.service-meta {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hero-chips {
  margin-top: 18px;
}

.chip,
.meta-pill,
.tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.75);
  border: 1px solid var(--line);
  color: var(--text-soft);
  font-size: 13px;
  text-align: center;
}

.welcome-card {
  display: grid;
  gap: 16px;
}

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

.action-tile,
.primary-button,
.secondary-button,
.ghost-button,
.text-button {
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    background-color 0.18s ease,
    color 0.18s ease,
    border-color 0.18s ease;
}

.action-tile {
  min-height: 108px;
  padding: 18px 16px;
  border-radius: 24px;
  text-align: left;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-soft);
  color: var(--text);
  font-weight: 600;
}

.action-tile--primary,
.primary-button {
  background: linear-gradient(135deg, var(--accent) 0%, #d9a191 100%);
  color: #fffaf7;
  box-shadow: 0 18px 28px rgba(169, 96, 83, 0.24);
}

.action-tile small {
  display: block;
  margin-top: 8px;
  color: var(--text-soft);
  font-weight: 400;
}

.action-tile--primary small {
  color: rgba(255, 250, 247, 0.82);
}

.floating-note {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.section-title {
  font-size: 30px;
}

.section-title--compact {
  font-size: 24px;
}

.section-text {
  margin-top: 10px;
}

.hero-helper {
  margin-top: 10px;
}

.progress-track {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.progress-step {
  position: relative;
  display: grid;
  gap: 6px;
  padding: 12px 10px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.48);
  border: 1px solid rgba(255, 255, 255, 0.6);
  text-align: center;
}

.progress-step span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  margin: 0 auto;
  border-radius: 999px;
  background: rgba(197, 132, 116, 0.18);
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 700;
}

.progress-step p {
  margin: 0;
  font-size: 12px;
  color: var(--text-soft);
}

.progress-step.is-active {
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-soft);
}

.progress-step.is-active span,
.progress-step.is-complete span {
  background: var(--accent);
  color: #fff;
}

.progress-step.is-complete {
  border-color: rgba(197, 132, 116, 0.28);
}

.service-card {
  display: grid;
  gap: 16px;
}

.service-title,
.booking-title {
  margin: 8px 0 0;
  font-size: 22px;
  line-height: 1.2;
}

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

.meta-pill {
  min-height: 48px;
  justify-content: flex-start;
  padding-inline: 16px;
  background: rgba(244, 231, 223, 0.8);
}

.primary-button,
.secondary-button,
.ghost-button,
.text-button {
  min-height: 52px;
  padding: 12px 18px;
  border-radius: 18px;
  font-weight: 600;
}

.secondary-button {
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid var(--line);
  color: var(--text);
  box-shadow: var(--shadow-soft);
}

.ghost-button {
  min-width: 52px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid var(--line);
  color: var(--text);
}

.text-button {
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid transparent;
  color: var(--text-soft);
}

.text-button.is-danger {
  color: var(--danger);
}

.calendar-card,
.confirm-card,
.summary-card {
  display: grid;
  gap: 16px;
}

.calendar-toolbar {
  display: grid;
  grid-template-columns: 52px 1fr 52px;
  align-items: center;
  gap: 12px;
}

.calendar-toolbar > div {
  text-align: center;
}

.calendar-month {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 24px;
}

.weekday-row,
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.weekday-name {
  text-align: center;
  font-size: 12px;
  color: var(--text-faint);
}

.calendar-spacer {
  aspect-ratio: 0.8;
}

.calendar-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  aspect-ratio: 0.8;
  border-radius: 18px;
  text-align: center;
  border: 1px solid transparent;
}

.calendar-cell span:first-child {
  font-size: 16px;
  font-weight: 700;
}

.calendar-cell span:last-child {
  font-size: 11px;
  color: var(--text-faint);
}

.calendar-cell.is-locked {
  background: rgba(255, 255, 255, 0.38);
  color: rgba(43, 28, 23, 0.36);
  border-color: rgba(121, 87, 74, 0.08);
}

.calendar-cell.is-open {
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow-soft);
}

.calendar-cell.is-selected {
  background: linear-gradient(135deg, var(--accent) 0%, #d9a191 100%);
  color: #fff;
}

.calendar-cell.is-selected span:last-child {
  color: rgba(255, 255, 255, 0.82);
}

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

.time-slot {
  min-height: 56px;
  padding: 12px 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 600;
  box-shadow: var(--shadow-soft);
}

.time-slot.is-busy {
  color: rgba(43, 28, 23, 0.34);
  background: rgba(255, 255, 255, 0.42);
  box-shadow: none;
}

.summary-list {
  gap: 10px;
}

.summary-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid rgba(121, 87, 74, 0.08);
}

.summary-label {
  color: var(--text-faint);
}

.summary-value {
  text-align: right;
  font-weight: 600;
  color: var(--text);
}

.booking-head,
.split-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.status-badge.is-success {
  background: rgba(111, 152, 128, 0.14);
  color: #4f7660;
}

.status-badge.is-accent {
  background: rgba(197, 132, 116, 0.14);
  color: var(--accent-strong);
}

.status-badge.is-danger {
  background: rgba(180, 109, 105, 0.14);
  color: var(--danger);
}

.booking-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.contact-stack,
.certificate-grid {
  grid-template-columns: 1fr;
}

.contact-item,
.certificate-option,
.empty-state {
  padding: 16px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid rgba(121, 87, 74, 0.08);
}

.contact-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

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

.certificate-option strong {
  display: block;
  font-size: 22px;
  margin-bottom: 6px;
}

.empty-state {
  text-align: center;
}

.empty-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 24px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(18px + env(safe-area-inset-bottom));
  z-index: 20;
  width: min(calc(100% - 32px), 380px);
  padding: 14px 18px;
  border-radius: 18px;
  background: rgba(43, 28, 23, 0.9);
  color: #fff;
  box-shadow: 0 18px 32px rgba(43, 28, 23, 0.28);
  transform: translate(-50%, 24px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.noscript {
  padding: 24px;
  text-align: center;
  color: var(--text);
}

button:hover:not(:disabled),
button:focus-visible:not(:disabled) {
  transform: translateY(-2px);
}

button:focus-visible {
  outline: 2px solid rgba(169, 96, 83, 0.28);
  outline-offset: 2px;
}

button:disabled {
  cursor: not-allowed;
}

[hidden] {
  display: none !important;
}

@keyframes reveal {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes drift {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }

  50% {
    transform: translate3d(0, 10px, 0) scale(1.04);
  }
}

@media (max-width: 380px) {
  .action-grid,
  .booking-actions,
  .hero-chips,
  .pill-row,
  .service-meta {
    grid-template-columns: 1fr;
  }

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

  .section-title {
    font-size: 26px;
  }
}
