@font-face {
  font-family: system-ui-fa;
  src: local("Tahoma");
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

:root {
  --bg-main: #f7efe9;
  --bg-light: #fffaf6;
  --bg-soft: #ead9d2;

  --wine: #6f243b;
  --wine-dark: #4d1828;
  --wine-light: #9b566c;

  --rose: #d7b5b1;
  --rose-soft: #f0dfda;

  --gold: #b99568;
  --gold-soft: #d9c3a4;

  --text-main: #2b2022;
  --text-soft: #6f5a5f;
  --white: #ffffff;

  --border: rgba(111, 36, 59, 0.15);
  --shadow: rgba(77, 24, 40, 0.14);
}

body {
  margin: 0;
  font-family: system-ui-fa, Tahoma, Arial, sans-serif;
  background: var(--bg-main);
  color: var(--text-main);
}

.section {
  min-height: 100vh;
  padding: 48px 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-section {
  flex-direction: column;
  gap: 32px;
  background:
    radial-gradient(
      circle at top right,
      rgba(215, 181, 177, 0.45) 0%,
      transparent 42%
    ),
    linear-gradient(145deg, #fffaf6 0%, #f7eee9 48%, #ead8d1 100%);
}

.main-logo {
  width: min(78vw, 520px);
  height: auto;
  display: block;
}

.panel {
  width: min(920px, 100%);
  background: rgba(255, 250, 246, 0.9);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 38px 24px;
  box-shadow: 0 24px 70px var(--shadow);
  text-align: center;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.info-section {
  background: linear-gradient(180deg, #f7efe9 0%, #fffaf6 100%);
}

.booking-section {
  background:
    radial-gradient(
      circle at bottom left,
      rgba(155, 86, 108, 0.18),
      transparent 45%
    ),
    linear-gradient(180deg, #fffaf6 0%, #ead8d1 100%);
}

h1,
h2,
h3,
h4,
p {
  margin-top: 0;
}

h1,
h2 {
  font-size: clamp(24px, 4vw, 40px);
  margin-bottom: 30px;
  color: var(--wine-dark);
  font-weight: 800;
}

h3,
h4 {
  color: var(--wine);
}

p {
  color: var(--text-soft);
}

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

label {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-weight: 700;
  color: var(--wine-dark);
}

input {
  width: 100%;
  min-height: 56px;
  border: 1px solid rgba(111, 36, 59, 0.25);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  padding: 12px 16px;
  font-family: inherit;
  font-size: 17px;
  color: var(--text-main);
  outline: none;
  text-align: center;
  transition:
    border-color 0.25s ease,
    box-shadow 0.25s ease,
    background 0.25s ease;
}

input::placeholder {
  color: #a28d91;
}

input:focus {
  border-color: var(--wine-light);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(111, 36, 59, 0.1);
}

button {
  font-family: inherit;
  cursor: pointer;
}

.primary-btn,
.secondary-btn,
.reserve-btn,
.popup-btn,
.option-btn,
.time-btn {
  border: 0;
  border-radius: 14px;
  padding: 15px 28px;
  font-size: 16px;
  font-weight: 800;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    background 0.25s ease,
    color 0.25s ease,
    border-color 0.25s ease;
}

.primary-btn,
.secondary-btn,
.reserve-btn {
  background: linear-gradient(135deg, var(--wine) 0%, var(--wine-dark) 100%);
  color: var(--white);
  box-shadow: 0 12px 30px rgba(77, 24, 40, 0.24);
}

.primary-btn:hover,
.secondary-btn:hover,
.reserve-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(77, 24, 40, 0.3);
  background: linear-gradient(135deg, var(--wine-light) 0%, var(--wine) 100%);
}

.picker-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

.picker-box {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px 12px;
  box-shadow: 0 12px 30px rgba(77, 24, 40, 0.07);
}

.popup-btn,
.option-btn,
.time-btn {
  width: 100%;
  background: var(--rose-soft);
  color: var(--wine-dark);
  border: 1px solid rgba(111, 36, 59, 0.14);
}

.popup-btn:hover,
.option-btn:hover,
.time-btn:hover {
  transform: translateY(-2px);
  background: var(--rose);
  color: var(--wine-dark);
  box-shadow: 0 10px 24px rgba(77, 24, 40, 0.12);
}

.selected-text {
  min-height: 24px;
  margin: 12px 0 0;
  font-weight: 800;
  color: var(--wine);
}

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

.result-message {
  margin-top: 22px;
  line-height: 2;
  font-weight: 800;
  color: #2f6b45;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(37, 18, 25, 0.64);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 100;
}

.modal.active {
  display: flex;
}

.modal-content {
  position: relative;
  width: min(520px, 100%);
  max-height: 88vh;
  overflow: auto;
  background: var(--bg-light);
  border: 1px solid rgba(185, 149, 104, 0.22);
  border-radius: 22px;
  padding: 32px 20px 24px;
  text-align: center;
  box-shadow: 0 30px 90px rgba(37, 18, 25, 0.3);
}

.close-btn {
  position: absolute;
  top: 12px;
  left: 14px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: var(--wine-dark);
  color: var(--white);
  font-size: 26px;
  line-height: 1;
  transition:
    transform 0.2s ease,
    background 0.2s ease;
}

.close-btn:hover {
  transform: rotate(90deg);
  background: var(--wine-light);
}

.option-list,
.time-list {
  display: grid;
  gap: 10px;
}

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

.calendar-header button {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: var(--wine);
  color: var(--white);
  font-size: 28px;
  transition:
    transform 0.2s ease,
    background 0.2s ease;
}

.calendar-header button:hover {
  transform: scale(1.06);
  background: var(--wine-light);
}

.week-days,
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 7px;
}

.week-days {
  margin-bottom: 7px;
  color: var(--wine);
  font-weight: 800;
}

.day-btn {
  aspect-ratio: 1;
  border: 1px solid rgba(111, 36, 59, 0.15);
  border-radius: 12px;
  background: #fff;
  color: var(--text-main);
  font-weight: 800;
  transition:
    transform 0.2s ease,
    background 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease;
}

.day-btn:hover {
  transform: translateY(-1px);
  border-color: var(--wine-light);
  background: var(--rose-soft);
}

.day-btn.active {
  background: linear-gradient(135deg, var(--wine) 0%, var(--wine-dark) 100%);
  color: var(--white);
  border-color: transparent;
}

.day-btn.empty {
  visibility: hidden;
}

.time-title {
  margin: 22px 0 12px;
  color: var(--wine-dark);
}

.time-btn.active {
  background: linear-gradient(135deg, var(--wine) 0%, var(--wine-dark) 100%);
  color: var(--white);
  border-color: transparent;
}

.field-error {
  display: none;
  color: #b3233d;
  font-size: 13px;
  font-weight: 800;
  margin-top: -4px;
}

label.has-error .field-error {
  display: block;
}

label.has-error input {
  border-color: #b3233d;
  box-shadow: 0 0 0 4px rgba(179, 35, 61, 0.1);
}

@media (max-width: 760px) {
  .form-grid,
  .picker-row {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 36px 14px;
  }

  .panel {
    padding: 30px 16px;
    border-radius: 20px;
  }

  .primary-btn,
  .secondary-btn,
  .reserve-btn,
  .popup-btn,
  .option-btn,
  .time-btn {
    font-size: 15px;
    padding: 14px 20px;
  }
}
