:root {
  color-scheme: light;
  --ink: #1f1c16;
  --muted: #5b5247;
  --accent: #c66b3d;
  --accent-dark: #9c4b26;
  --accent-soft: #f2c7a5;
  --sea: #2e6f63;
  --sea-soft: #cfe5de;
  --bg: #f7efe3;
  --bg-dark: #e7d4bc;
  --card: #fff8ef;
  --shadow: rgba(30, 20, 10, 0.12);
  --border: rgba(47, 40, 32, 0.2);
}

* {
  box-sizing: border-box;
}

.is-hidden {
  display: none !important;
}

body {
  margin: 0;
  font-family: "Gill Sans", "Trebuchet MS", "Verdana", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at top, #fff7e7, var(--bg) 50%, #efe0c7);
}

.page {
  min-height: 100vh;
  padding: 32px clamp(20px, 5vw, 64px) 48px;
}

.landing-shell {
  max-width: 1100px;
  margin: 0 auto;
}

.landing-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 32px;
  align-items: start;
}

.landing-card {
  background: var(--card);
  border-radius: 24px;
  padding: 24px;
  border: 1px solid var(--border);
  box-shadow: 0 20px 50px var(--shadow);
}

.landing-form {
  display: grid;
  gap: 16px;
}

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

.landing-form input {
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  font-size: 0.95rem;
  font-family: inherit;
}

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

.landing-feature-title {
  margin: 24px 0 8px;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.feature-list {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 8px;
  font-size: 0.95rem;
  color: var(--ink);
}

.feature-list li {
  line-height: 1.4;
  color: var(--muted);
}

.landing-status {
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--muted);
}

.landing-status.error {
  color: #8b1c1c;
}

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

.hero-banner {
  margin-bottom: 24px;
}

.hero-banner img {
  width: 100%;
  max-height: 240px;
  object-fit: cover;
  border-radius: 20px;
  border: 1px solid var(--border);
  box-shadow: 0 16px 32px rgba(31, 28, 22, 0.12);
}

.hero-logo {
  max-width: 140px;
  max-height: 90px;
  margin-bottom: 12px;
  object-fit: contain;
}

.announcement {
  margin-top: 20px;
  padding: 18px 20px;
  border-radius: 18px;
  background: var(--accent-soft);
  border: 1px solid rgba(198, 107, 61, 0.25);
  color: var(--ink);
}

.demo-banner {
  margin-top: 20px;
  padding: 16px 20px;
  border-radius: 16px;
  background: #f0efe9;
  border: 1px solid var(--border);
  color: var(--ink);
  font-size: 0.95rem;
}

.announcement h2 {
  margin: 0 0 8px;
  font-size: 1.1rem;
}

.announcement p {
  margin: 0;
  color: var(--ink);
}

.info-box {
  margin-top: 20px;
}

.info-box .panel-header {
  margin-bottom: 10px;
}

.info-box-body {
  margin: 0;
  color: var(--ink);
}

.footer-strap {
  margin-top: 32px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  align-items: center;
}

.link-button {
  background: none;
  border: none;
  color: var(--sea);
  text-decoration: underline;
  padding: 0;
  font: inherit;
  cursor: pointer;
}

.link-button:hover {
  color: var(--sea);
  opacity: 0.8;
}

.hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 24px;
}

body.is-embed .hero,
body.is-embed .footer-strap,
body.is-embed .side-panel {
  display: none;
}

body.is-embed .calendar-shell {
  flex: 1;
}

body.is-embed #openBooking {
  display: none;
}

body.is-embed .embed-book-now {
  display: inline-flex;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.24em;
  font-size: 0.7rem;
  margin: 0 0 8px;
  color: var(--muted);
}

.hero h1 {
  font-family: "Garamond", "Palatino Linotype", serif;
  font-size: clamp(2rem, 3.5vw, 3.4rem);
  margin: 0 0 12px;
}

.lead {
  margin: 0;
  font-size: 1rem;
  color: var(--muted);
  max-width: 46ch;
}

.hero-tag {
  background: var(--accent-soft);
  color: var(--accent-dark);
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
}

.hero-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.layout {
  margin-top: 32px;
  display: grid;
  grid-template-columns: minmax(0, 2.1fr) minmax(260px, 1fr);
  gap: 32px;
  align-items: start;
}

.calendar-shell {
  background: var(--card);
  border-radius: 24px;
  padding: 24px;
  box-shadow: 0 20px 50px var(--shadow);
  border: 1px solid rgba(198, 107, 61, 0.15);
}

.calendar-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.label {
  margin: 0;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
}

#monthLabel {
  margin: 4px 0 0;
  font-size: clamp(1.4rem, 2.6vw, 2.2rem);
  font-family: "Garamond", "Palatino Linotype", serif;
}

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

.view-toggle {
  display: inline-flex;
  gap: 8px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 248, 239, 0.8);
}

.toggle {
  padding: 8px 14px;
  font-size: 0.82rem;
}

.toggle.active {
  background: var(--sea-soft);
  color: var(--sea);
  border-color: transparent;
}

button {
  border: none;
  padding: 10px 16px;
  border-radius: 999px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  font-family: inherit;
}

a.primary,
a.ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 999px;
  font-size: 0.9rem;
  text-decoration: none;
  line-height: 1.2;
}

button:active {
  transform: scale(0.97);
}

@media (min-width: 721px) {
  #openBooking {
    display: none;
  }
}

.primary {
  background: var(--accent);
  color: #fffaf2;
  box-shadow: 0 10px 20px rgba(198, 107, 61, 0.3);
}

.primary.danger {
  background: #b13522;
  box-shadow: 0 10px 20px rgba(177, 53, 34, 0.3);
}

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

.ghost.danger {
  color: #8b1c1c;
  border-color: rgba(139, 28, 28, 0.4);
}

.weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin-top: 24px;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
}

.weekdays span {
  padding: 8px;
  text-align: center;
}

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

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

.day {
  background: #fff;
  border-radius: 18px;
  min-height: 120px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  border: 1px solid rgba(47, 40, 32, 0.12);
  position: relative;
}

.day.outside {
  background: #f4ecdf;
  color: rgba(91, 82, 71, 0.6);
}

.week-day {
  background: #fff;
  border-radius: 18px;
  min-height: 140px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border: 1px solid rgba(47, 40, 32, 0.12);
}

.week-day.outside {
  background: #f4ecdf;
  color: rgba(91, 82, 71, 0.6);
}

.week-day.selected {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.week-date {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-weight: 700;
  font-size: 0.85rem;
}

.week-date .today {
  color: var(--sea);
}

.booking-count {
  margin-top: auto;
  align-self: flex-start;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--sea-soft);
  color: var(--sea);
  font-size: 0.75rem;
  font-weight: 600;
}

.day.selected {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.day .date {
  font-weight: 700;
  font-size: 0.9rem;
}

.day .today {
  color: var(--sea);
}

.day button {
  align-self: flex-start;
  padding: 6px 12px;
  font-size: 0.75rem;
  border-radius: 12px;
  background: var(--sea-soft);
  color: var(--sea);
}

.booking-chip {
  background: rgba(198, 107, 61, 0.1);
  color: var(--accent-dark);
  padding: 6px 8px;
  border-radius: 12px;
  font-size: 0.72rem;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.booking-chip.pending {
  background: rgba(46, 111, 99, 0.12);
  color: var(--sea);
}

.booking-chip .muted {
  color: rgba(91, 82, 71, 0.75);
  font-size: 0.68rem;
}

.booking-dots {
  display: none;
  gap: 4px;
  flex-wrap: wrap;
}

.booking-dots .dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.55rem;
  color: #fffaf2;
  line-height: 1;
}

.booking-dots .dot.more {
  width: 12px;
  height: 12px;
  font-weight: 700;
}

.day-view {
  margin-top: 16px;
  padding: 16px;
  border-radius: 18px;
  border: 1px dashed rgba(47, 40, 32, 0.2);
  background: rgba(255, 248, 239, 0.7);
  display: grid;
  gap: 12px;
}

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

.day-view-title {
  font-family: "Garamond", "Palatino Linotype", serif;
  font-size: 1.1rem;
  font-weight: 600;
}

.day-bookings {
  display: grid;
  gap: 10px;
}

.availability {
  border-top: 1px dashed rgba(47, 40, 32, 0.2);
  padding-top: 12px;
  display: grid;
  gap: 10px;
}

.availability-title {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.7rem;
  color: var(--muted);
  margin: 0;
}

.availability-slots {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.availability-slot {
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(47, 40, 32, 0.2);
  font-size: 0.75rem;
  background: #fffaf2;
  color: var(--ink);
  cursor: pointer;
  font-family: inherit;
}

.day-booking {
  text-align: left;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(47, 40, 32, 0.15);
  background: #fff;
  color: inherit;
  display: grid;
  gap: 4px;
  width: 100%;
  font-family: inherit;
}

.day-booking.pending {
  background: rgba(46, 111, 99, 0.08);
}

.day-booking .meta {
  font-size: 0.75rem;
  color: var(--muted);
}

.side-panel {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.panel-card {
  background: #fff;
  border-radius: 20px;
  padding: 20px;
  border: 1px solid var(--border);
  box-shadow: 0 12px 24px rgba(31, 28, 22, 0.08);
}

.panel-card.info {
  background: linear-gradient(140deg, #fff3e1, #f7e5cc);
}

.admin-section {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

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

.admin-section-header.button-row {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.admin-section-header.email-actions {
  gap: 8px;
}

.admin-section h4 {
  margin: 0;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.admin-settings {
  display: grid;
  gap: 12px;
  text-align: left;
  padding-top: 8px;
}

.admin-settings .field {
  margin: 0;
}

.admin-settings .field.inline-field {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  text-align: left;
}

.admin-settings .field.inline-field span {
  flex: 0 1 auto;
  margin-right: auto;
  text-align: left;
  line-height: 1.2;
}

.admin-settings .field.inline-field input[type="number"] {
  margin-left: auto;
  max-width: 120px;
}

.approval-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.approval-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(47, 111, 99, 0.08);
  border: 1px solid rgba(47, 111, 99, 0.2);
  cursor: pointer;
}

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

.approval-item button {
  white-space: nowrap;
}

.approval-title {
  font-weight: 600;
  font-size: 0.9rem;
}

.approval-meta {
  font-size: 0.75rem;
  color: var(--muted);
}

.admin-log-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}

.admin-log-actions {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.banned-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(47, 40, 32, 0.12);
  background: rgba(255, 248, 239, 0.9);
}

.banned-item .meta {
  font-size: 0.75rem;
  color: var(--muted);
}

.admin-list {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.admin-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(47, 40, 32, 0.12);
  background: rgba(255, 248, 239, 0.9);
}

.admin-item .meta {
  font-size: 0.75rem;
  color: var(--muted);
}

.modal-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.branding-preview {
  width: 100%;
  max-height: 200px;
  object-fit: contain;
  border-radius: 16px;
  border: 1px solid rgba(47, 40, 32, 0.12);
  background: rgba(255, 248, 239, 0.9);
  padding: 8px;
}

.admin-log-item {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(47, 40, 32, 0.12);
  background: rgba(255, 248, 239, 0.9);
}

.admin-log-text {
  font-size: 0.8rem;
  color: var(--ink);
}

.user-history-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.user-history-item {
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(47, 40, 32, 0.12);
  background: rgba(255, 248, 239, 0.9);
  display: grid;
  gap: 6px;
}

.user-history-title {
  font-weight: 600;
  color: var(--ink);
}

.user-history-meta,
.user-history-status {
  font-size: 0.8rem;
  color: var(--muted);
}

.user-history-actions {
  margin-top: 4px;
}

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

#adminAdminsCard .panel-header {
  gap: 20px;
}

.panel-header-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.panel-header .panel-toggle {
  padding: 6px 12px;
  font-size: 0.75rem;
}

.panel-body.is-hidden {
  display: none;
}

.panel-header h3 {
  margin: 0;
  font-family: "Garamond", "Palatino Linotype", serif;
  font-size: 1.3rem;
  cursor: pointer;
}

.tag {
  background: var(--sea-soft);
  color: var(--sea);
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.stack {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--muted);
}

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

.color-value {
  font-size: 0.75rem;
  color: var(--muted);
  font-family: "Courier New", "Lucida Console", monospace;
}

.color-value.highlight {
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(31, 28, 22, 0.12);
  color: var(--ink);
}

.color-input-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}

.color-input-row input[type="text"] {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(47, 40, 32, 0.2);
  font-size: 0.95rem;
  font-family: inherit;
}

.color-wheel {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 0;
  height: 0;
}
.field input {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(47, 40, 32, 0.2);
  font-size: 0.95rem;
  font-family: inherit;
}

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

.hours-row {
  display: grid;
  grid-template-columns: minmax(90px, 0.8fr) repeat(2, minmax(120px, 1fr));
  gap: 10px;
  align-items: center;
}

.hours-row.hours-header {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.hours-day {
  font-size: 0.85rem;
  color: var(--ink);
}

.hours-label {
  text-align: center;
}

.hours-input {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(47, 40, 32, 0.2);
  font-size: 0.95rem;
  font-family: inherit;
  width: 100%;
}

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

.field.checkbox-field input {
  width: auto;
  padding: 0;
}

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

.hint {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
}

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

.status {
  margin-top: 16px;
  padding: 12px;
  border-radius: 12px;
  background: rgba(47, 111, 99, 0.12);
  color: var(--sea);
  font-size: 0.85rem;
}

.status.error {
  background: rgba(198, 61, 61, 0.12);
  color: #8b1c1c;
}

.modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 30;
}

.modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(31, 28, 22, 0.4);
}

.modal-card {
  position: relative;
  background: #fffaf2;
  border-radius: 20px;
  padding: 24px;
  max-width: 360px;
  width: min(90vw, 360px);
  box-shadow: 0 20px 40px rgba(31, 28, 22, 0.25);
  border: 1px solid rgba(198, 107, 61, 0.25);
  display: grid;
  gap: 12px;
  text-align: center;
  z-index: 1;
}

.modal-card.scrollable {
  max-height: 85vh;
  overflow-y: auto;
}

.text-editor {
  width: 100%;
  min-height: 120px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(47, 40, 32, 0.2);
  font-size: 0.95rem;
  font-family: inherit;
  resize: vertical;
}

input.text-editor {
  min-height: 0;
  height: auto;
  resize: none;
}

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

  .hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .calendar-actions {
    width: 100%;
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  .hero-banner img {
    max-height: 180px;
  }

  .hero-logo {
    max-width: 120px;
    max-height: 72px;
  }

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

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

  .weekdays {
    display: none;
  }

  .day {
    min-height: 64px;
    padding: 8px;
    gap: 4px;
  }

  .day .date {
    font-size: 0.8rem;
  }

  .calendar-shell {
    padding: 16px;
  }

  .booking-chip {
    display: none;
  }

  .day.expanded .booking-chip {
    display: flex;
  }

  .booking-dots {
    display: flex;
  }

  .day.expanded .booking-dots {
    display: none;
  }
}
