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

:root {
  --brand-orange: #f39800;
  --brand-orange-dark: #e08800;
  --brand-red: #e60012;
  --brand-brown: #8f5d3f;
  --page-bg: #f7f3ef;
  --text: #2d261f;
  --muted: #6b6258;
  --border: #e0d6cd;
  --white: #fff;
  --line-green: #06c755;
  --header-h: 56px;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: Arial, "Microsoft JhengHei", "PingFang TC", sans-serif;
  background: var(--page-bg);
  color: var(--text);
  line-height: 1.55;
}

body.menu-open { overflow: hidden; }

a { color: var(--brand-brown); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: var(--header-h);
  padding: 8px 14px;
  background: var(--white);
  border-bottom: 2px solid var(--brand-orange);
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
}

.logo-slot {
  flex: 0 1 auto;
  display: flex;
  align-items: center;
  min-width: 0;
}

.site-logo {
  display: block;
  height: 42px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
}

.menu-btn {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  min-height: 44px;
  min-width: 44px;
  padding: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
}

.menu-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
}

.side-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: min(280px, 88vw);
  height: 100%;
  max-height: 100dvh;
  background: var(--white);
  z-index: 200;
  box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
  transform: translateX(100%);
  transition: transform 0.28s ease;
  overflow-y: auto;
}

.side-menu.is-open { transform: translateX(0); }

.side-menu[hidden] {
  display: block !important;
  visibility: hidden;
  pointer-events: none;
}

.side-menu.is-open[hidden] {
  visibility: visible;
  pointer-events: auto;
}

.side-menu-inner { padding: calc(var(--header-h) + 12px) 20px 24px; }

.side-menu-inner h3 {
  margin: 0 0 12px;
  color: var(--brand-orange);
  font-size: 1.125rem;
}

.side-menu-inner p { margin: 8px 0; font-size: 0.9375rem; }

.menu-hours { color: var(--muted); font-size: 0.875rem !important; }

.menu-close {
  margin-top: 20px;
  width: 100%;
  min-height: 48px;
  border: none;
  border-radius: 6px;
  background: var(--brand-orange);
  color: var(--white);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
}

.menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 150;
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.menu-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

.menu-overlay[hidden] { display: block !important; }

.page {
  max-width: 480px;
  margin: 0 auto;
  padding: 0 0 28px;
  min-height: calc(100dvh - var(--header-h));
}

.load-error {
  margin: 12px 14px;
  padding: 12px 14px;
  background: #fdecea;
  color: var(--brand-red);
  border-radius: 6px;
  font-size: 0.9375rem;
}

.product-banner { background: var(--white); }

.product-banner-img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 220px;
  object-fit: cover;
}

.table-section {
  margin-top: 10px;
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.table-section-head {
  margin: 0;
  padding: 12px 14px;
  background: var(--brand-orange);
  color: var(--white);
  font-size: 1.125rem;
  font-weight: 700;
}

.data-table { background: var(--white); }

.data-row {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid #ebe3db;
  min-height: 48px;
}

.data-row:last-child { border-bottom: none; }

.data-label {
  flex: 0 0 32%;
  max-width: 120px;
  padding: 12px 10px;
  background: #f3ebe3;
  font-size: 0.9375rem;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-right: 1px solid #ebe3db;
}

.data-value {
  flex: 1;
  padding: 12px 14px;
  font-size: 1rem;
  display: flex;
  align-items: center;
  word-break: break-word;
}

.kv-amount { color: var(--brand-red); font-weight: 700; }

.form-field-stack {
  border-bottom: 1px solid var(--border);
  background: var(--white);
}

.field-head {
  margin: 0;
  padding: 10px 14px 8px;
  background: #fff6ea;
  font-size: 0.9375rem;
  font-weight: 700;
  border-bottom: 1px solid #f0e4d4;
}

.field-head em {
  font-style: normal;
  color: var(--brand-red);
  font-weight: 500;
  font-size: 0.8125rem;
  margin-left: 4px;
}

.form-field-body { padding: 12px 14px 14px; }

.form-field-body input,
.form-field-body select,
.address-fields input,
.address-fields select {
  width: 100%;
  min-height: 52px;
  padding: 14px 16px;
  font-size: 1.0625rem;
  font-family: inherit;
  border: 1px solid #cbbbac;
  border-radius: 8px;
  background: var(--white);
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
}

.form-field-body select,
.address-fields select {
  background-image: linear-gradient(45deg, transparent 50%, #666 50%), linear-gradient(135deg, #666 50%, transparent 50%);
  background-position: calc(100% - 20px) calc(50% + 2px), calc(100% - 14px) calc(50% + 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 40px;
}

.address-fields {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.address-select-label { display: block; }

.address-select-title {
  display: block;
  margin-bottom: 6px;
  font-size: 1rem;
  color: var(--muted);
  font-weight: 600;
}

.terms-block {
  padding: 16px 14px;
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.terms-open-btn {
  display: block;
  width: 100%;
  min-height: 48px;
  margin-bottom: 12px;
  padding: 10px 14px;
  border: 1px solid var(--brand-orange);
  border-radius: 8px;
  background: #fffaf3;
  color: var(--brand-brown);
  font-size: 1.0625rem;
  font-weight: 700;
  cursor: pointer;
  text-align: left;
}

.agree-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 1rem;
  cursor: pointer;
}

.agree-row input {
  width: 20px;
  height: 20px;
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--brand-orange);
}

.btn-primary,
.btn-outline,
.btn-line {
  display: block;
  width: 100%;
  min-height: 54px;
  padding: 14px 18px;
  border: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  text-align: center;
}

.btn-block { margin-left: 14px; margin-right: 14px; width: calc(100% - 28px); }

.btn-primary { background: var(--brand-orange); color: var(--white); }

.btn-primary:hover:not(:disabled) { background: var(--brand-orange-dark); }

.btn-primary:disabled { background: #ccc; cursor: not-allowed; }

.btn-red { background: var(--brand-red) !important; }

.btn-red:hover:not(:disabled) { background: #c4000f !important; }

.btn-outline {
  background: var(--white);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-line {
  background: var(--line-green);
  color: var(--white);
}

.btn-line:hover { background: #05a847; }

#booking-form .btn-primary { margin-top: 8px; margin-bottom: 8px; }

.error-msg {
  margin: 0 14px 12px;
  color: var(--brand-red);
  font-size: 0.9375rem;
}

.error-msg[hidden] { display: none !important; }

.reminder-box {
  margin: 12px 14px 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.9375rem;
}

.reminder-box summary {
  padding: 14px;
  cursor: pointer;
  font-weight: 700;
  color: var(--brand-orange);
  list-style: none;
}

.reminder-box summary::-webkit-details-marker { display: none; }

.reminder-box ul {
  margin: 0;
  padding: 0 14px 14px 32px;
  color: var(--muted);
}

.reminder-box li { margin-bottom: 6px; }

.page-footer {
  margin-top: 20px;
  padding: 16px 14px 8px;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
}

.footer-links a { color: var(--brand-brown); font-size: 0.875rem; }

.footer-note { margin: 8px 0; line-height: 1.5; }

.copyright { margin: 8px 0 0; font-size: 0.75rem; }

.completion-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: transparent;
  pointer-events: none;
}

.completion-modal-overlay[hidden] { display: none !important; }

.completion-modal {
  pointer-events: auto;
  width: 100%;
  max-width: 340px;
  background: var(--white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
}

.completion-modal-header {
  padding: 14px 16px;
  background: var(--brand-orange);
  text-align: center;
}

.completion-modal-header h3 {
  margin: 0;
  color: var(--white);
  font-size: 1.125rem;
  font-weight: 700;
}

.completion-modal-body {
  padding: 24px 18px 20px;
  text-align: center;
}

.completion-congrats-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 10px;
}

.completion-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--brand-orange);
  color: var(--white);
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1;
  flex-shrink: 0;
}

.completion-modal-congrats {
  margin: 0;
  color: var(--brand-orange);
  font-size: 1.25rem;
  font-weight: 700;
}

.completion-modal-notice {
  margin: 0 0 20px;
  color: var(--brand-red);
  font-size: 1rem;
  line-height: 1.6;
}

.completion-modal-body .btn-block {
  margin: 0;
  width: 100%;
}

.modal {
  border: none;
  border-radius: 12px;
  padding: 0;
  max-width: min(420px, calc(100vw - 28px));
  width: 100%;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}

.modal::backdrop {
  background: rgba(0, 0, 0, 0.5);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 14px 16px;
  background: var(--brand-orange);
  color: var(--white);
}

.modal-header h3 {
  margin: 0;
  font-size: 1.0625rem;
}

.modal-close {
  border: none;
  background: transparent;
  color: var(--white);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
}

.modal-body {
  padding: 16px;
  max-height: min(60vh, 420px);
  overflow-y: auto;
  font-size: 0.9375rem;
  line-height: 1.65;
}

.text-modal-body h4 {
  margin: 14px 0 8px;
  font-size: 1rem;
  color: var(--brand-brown);
}

.text-modal-body h4:first-child { margin-top: 0; }

.text-modal-body p { margin: 0 0 10px; }

.modal-footer { padding: 0 16px 16px; }

@media (min-width: 481px) {
  body { background: #ece7e1; }
  .page { box-shadow: 0 0 24px rgba(0, 0, 0, 0.08); background: var(--page-bg); }
}


