:root {
  --beige: #f3eee6;
  --white: #fffdf9;
  --brown: #251a13;
  --muted: #75695f;
  --gold: #b9934a;
  --line: rgba(73, 54, 40, .16);
  --radius: 8px;
  --shadow: 0 20px 60px rgba(37, 26, 19, .12);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--white);
  color: var(--brown);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.modal-open {
  overflow: hidden;
}

.agenda-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px clamp(18px, 5vw, 64px);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 253, 249, .92);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  font-weight: 900;
}

.brand span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--brown);
  color: var(--gold);
}

nav { display: flex; gap: 8px; }
nav a {
  padding: 9px 12px;
  border-radius: 999px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 800;
}
nav a:hover { background: var(--brown); color: var(--white); }

.hero,
.planner,
.admin-section {
  padding: clamp(58px, 8vw, 110px) clamp(18px, 5vw, 72px);
}

.hero {
  min-height: 58vh;
  display: grid;
  align-items: end;
  background:
    linear-gradient(120deg, rgba(255, 253, 249, .96), rgba(243, 238, 230, .84)),
    url("https://images.unsplash.com/photo-1573497491208-6b1acb260507?auto=format&fit=crop&w=1600&q=82") center/cover;
}

.hero div,
.section-head {
  max-width: 840px;
}

.eyebrow {
  display: inline-flex;
  margin: 0 0 16px;
  padding: 6px 12px;
  border: 1px solid rgba(185, 147, 74, .55);
  border-radius: 999px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }
h1 {
  max-width: 850px;
  font-size: clamp(46px, 7vw, 92px);
  line-height: .9;
  letter-spacing: -.045em;
}
h2 { font-size: clamp(34px, 4vw, 62px); line-height: .95; letter-spacing: -.03em; }
h3 { font-size: 24px; }
p { color: var(--muted); font-size: 18px; line-height: 1.55; }

.panel {
  max-width: 1080px;
  padding: clamp(22px, 3vw, 34px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

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

label {
  display: grid;
  gap: 6px;
  color: var(--brown);
  font-size: 14px;
  font-weight: 850;
}

.full { grid-column: 1 / -1; }

.duration-control {
  max-width: 260px;
  margin-bottom: 18px;
}

input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbf8f2;
  color: var(--brown);
  padding: 12px 13px;
  font: inherit;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(185, 147, 74, .14);
}

.slot-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 24px;
}

.calendar-wrap {
  display: grid;
  grid-template-columns: minmax(320px, .95fr) minmax(280px, .7fr);
  gap: 18px;
  align-items: start;
}

.calendar-card,
.time-card,
.booking-details {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbf8f2;
  padding: 16px;
}

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

.calendar-head h3 {
  margin: 0;
  text-align: center;
}

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

.calendar-weekdays span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  text-align: center;
}

.calendar-empty {
  min-height: 72px;
}

.calendar-day {
  min-height: 82px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--brown);
  cursor: pointer;
  padding: 10px;
  text-align: left;
}

.calendar-day strong,
.calendar-day span {
  display: block;
}

.calendar-day strong {
  font-size: 20px;
}

.calendar-day span {
  margin-top: 12px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
}

.calendar-day.active {
  background: var(--brown);
  color: var(--white);
  border-color: var(--brown);
}

.calendar-day.active span {
  color: var(--gold);
}

.calendar-day:disabled {
  opacity: .42;
  cursor: not-allowed;
}

.slot-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin: 12px 0 22px;
}

.slot {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--beige);
  cursor: pointer;
  padding: 14px;
  color: var(--brown);
  font-weight: 850;
  text-align: left;
}

.slot.active {
  background: var(--brown);
  color: var(--white);
  border-color: var(--brown);
}

.booking-details {
  margin-top: 18px;
}

.booking-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(37, 26, 19, .48);
}

.booking-dialog {
  position: relative;
  width: min(760px, 100%);
  max-height: min(88vh, 760px);
  overflow: auto;
  padding: clamp(22px, 4vw, 36px);
  border: 1px solid rgba(185, 147, 74, .35);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 24px 80px rgba(20, 12, 7, .28);
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--white);
  color: var(--brown);
  cursor: pointer;
  font: inherit;
  font-weight: 900;
}

.chosen-slot {
  padding: 12px 14px;
  border: 1px solid rgba(185, 147, 74, .35);
  border-radius: var(--radius);
  background: var(--beige);
  color: var(--brown);
  font-weight: 850;
}

.button {
  min-height: 46px;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  padding: 12px 18px;
  font: inherit;
  font-weight: 900;
}

.button.primary { background: var(--brown); color: var(--white); }
.button.ghost { background: var(--white); color: var(--brown); border-color: var(--line); }

.status {
  min-height: 24px;
  margin: 14px 0 0;
  color: var(--muted);
  font-weight: 760;
}

.status.success,
.status.error {
  padding: 14px;
  border-radius: var(--radius);
}
.status.success { background: var(--beige); color: var(--brown); border: 1px solid rgba(185,147,74,.4); }
.status.error { background: #fff0ed; color: #7a2d25; border: 1px solid rgba(163,63,53,.28); }

.admin-section { background: var(--beige); }
.admin-dashboard {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.login-panel {
  max-width: 520px;
  margin: 0 auto;
}

.admin-welcome,
.admin-log-panel {
  grid-column: 1 / -1;
}

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

.admin-welcome .full {
  flex-basis: 100%;
}

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

.list-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbf8f2;
  padding: 12px;
}

.list-item strong,
.list-item span {
  display: block;
}
.list-item span { color: var(--muted); margin-top: 4px; }
.list-item p { margin: 8px 0 0; font-size: 15px; }

@media (max-width: 760px) {
  .agenda-header { align-items: flex-start; flex-direction: column; }
  nav { flex-wrap: wrap; }
  .form-grid,
  .calendar-wrap,
  .admin-dashboard { grid-template-columns: 1fr; }
  .slot-head { align-items: flex-start; flex-direction: column; }
}
