* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  width: 1080px;
  height: 100vh;
  font-family: -apple-system, "Microsoft YaHei", sans-serif;
  background-color: #eed39b;
  background-image:
    radial-gradient(circle at 18% 22%, rgba(255, 247, 222, 0.26) 0 1px, transparent 1px),
    radial-gradient(circle at 72% 34%, rgba(176, 119, 45, 0.10) 0 1px, transparent 1px),
    linear-gradient(135deg, rgba(255,255,255,0.22) 0 25%, transparent 25% 50%, rgba(180,120,40,0.04) 50% 75%, transparent 75%);
  background-size: 34px 34px, 46px 46px, 26px 26px;
  overflow-x: hidden;
  overflow-y: hidden;
}

body.reservation-page {
  height: auto;
  min-height: 100vh;
  overflow-y: auto;
}

#app {
  width: 1080px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

body.reservation-page #app {
  height: auto;
  min-height: 100vh;
  overflow: visible;
}

.kiosk-home-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  width: 1080px;
  height: 100vh;
  background-color: #eed39b;
  background-image:
    radial-gradient(circle at 18% 22%, rgba(255, 247, 222, 0.26) 0 1px, transparent 1px),
    radial-gradient(circle at 72% 34%, rgba(176, 119, 45, 0.10) 0 1px, transparent 1px),
    linear-gradient(135deg, rgba(255,255,255,0.22) 0 25%, transparent 25% 50%, rgba(180,120,40,0.04) 50% 75%, transparent 75%);
  background-size: 34px 34px, 46px 46px, 26px 26px;
  overflow-x: hidden;
  overflow-y: hidden;
}
.kiosk-home-container {
  width: 1080px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 120px;
  position: relative;
}
.kiosk-home-container::before,
.kiosk-home-container::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  filter: blur(2px);
}
.kiosk-home-container::before {
  width: 400px;
  height: 400px;
  top: -80px;
  left: -100px;
}
.kiosk-home-container::after {
  width: 300px;
  height: 300px;
  right: -80px;
  bottom: 100px;
}
.kiosk-home-header {
  text-align: center;
  margin-bottom: 48px;
  position: relative;
  z-index: 1;
}
.kiosk-home-logo {
  margin: 0 auto 24px;
  font-size: 80px;
  line-height: 1;
}
.kiosk-home-header h1 {
  font-size: 56px;
  color: #7c4a16;
  letter-spacing: 8px;
  text-shadow: 0 2px 10px rgba(255,255,255,0.35);
}
.kiosk-home-time {
  font-size: 32px;
  color: #8a5a1f;
  margin-top: 16px;
}
.kiosk-home-cards {
  display: flex;
  flex-direction: column;
  gap: 44px;
  position: relative;
  z-index: 1;
}
.kiosk-home-card {
  width: 760px;
  height: 300px;
  border: 0;
  background: rgba(255,255,255,0.82);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 12px 36px rgba(135, 83, 28, 0.12);
  border: 1px solid rgba(139, 90, 31, 0.18);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  font-family: inherit;
}
.kiosk-home-card:active {
  transform: translateY(-4px);
}
.kiosk-home-icon {
  width: 128px;
  height: 128px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 68px;
  margin-bottom: 22px;
  color: #fff;
}
.kiosk-home-card.daily .kiosk-home-icon {
  background: linear-gradient(135deg, #4caf50, #2e7d32);
}
.kiosk-home-card.activity .kiosk-home-icon {
  background: linear-gradient(135deg, #d79a2b, #b7791f);
}
.kiosk-home-card.reservation .kiosk-home-icon {
  background: linear-gradient(135deg, #c98924, #9a5f15);
}
.kiosk-home-title {
  font-size: 44px;
  font-weight: 700;
  color: #2f2417;
  margin-bottom: 12px;
}
.kiosk-home-desc {
  display: none;
}
.kiosk-home-footer {
  position: absolute;
  bottom: 60px;
  color: #7c4a16;
  font-size: 22px;
  text-align: center;
}

.header {
  text-align: center;
  padding: 60px 0 40px;
  color: #7c4a16;
}
.header h1 {
  font-size: 56px;
  letter-spacing: 8px;
}
.header .time {
  font-size: 32px;
  margin-top: 16px;
  opacity: 0.9;
}

.main {
  flex: 1;
  padding: 40px 60px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

/* 人脸识别 */
.face-area {
  text-align: center;
}
.camera-box {
  width: 500px;
  height: 500px;
  margin: 0 auto 16px;
  border-radius: 50%;
  border: 6px solid #b7791f;
  overflow: hidden;
  background: #000;
  position: relative;
}
.camera-box video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scaleX(-1);
}
.camera-box canvas {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  transform: scaleX(-1);
}
.recognition-guide {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 470px;
  height: 470px;
  transform: translate(-50%, -50%);
  border: 4px solid rgba(76, 175, 80, 0.95);
  border-radius: 50%;
  box-shadow:
    0 0 0 999px rgba(0, 0, 0, 0.22),
    0 0 18px rgba(76, 175, 80, 0.65);
  pointer-events: none;
  z-index: 2;
}
.face-inline-error {
  min-height: 38px;
  margin-top: 12px;
  color: #d32f2f;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
}
.status-bar {
  position: absolute;
  bottom: 0;
  left: 0; right: 0;
  background: rgba(0,0,0,0.6);
  color: #fff;
  font-size: 20px;
  padding: 8px;
  text-align: center;
  z-index: 3;
}

.debug-panel {
  position: fixed;
  left: 20px;
  bottom: 20px;
  z-index: 9999;
  width: 680px;
  max-height: 520px;
  overflow: auto;
  padding: 16px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.78);
  color: #00ff99;
  font: 18px/1.45 Consolas, Menlo, monospace;
  white-space: pre-wrap;
  text-align: left;
  box-shadow: 0 8px 30px rgba(0,0,0,0.35);
}

.debug-controls {
  position: fixed;
  left: 20px;
  top: 20px;
  z-index: 9999;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  width: 760px;
}
.debug-controls button {
  border: 0;
  border-radius: 6px;
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.78);
  color: #fff;
  font-size: 18px;
  cursor: pointer;
}
.debug-controls button.active {
  background: #1677ff;
}

.btn-face {
  width: 400px;
  height: 80px;
  font-size: 32px;
  background: #b7791f;
  color: #fff;
  border: none;
  border-radius: 40px;
  cursor: pointer;
  letter-spacing: 4px;
}
.btn-face:active { background: #9a5f15; }
.btn-face:disabled { background: #999; cursor: not-allowed; }

/* 分隔线 */
.divider {
  text-align: center;
  position: relative;
  margin: 10px 0;
}
.divider::before, .divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 42%;
  height: 2px;
  background: #ccc;
}
.divider::before { left: 0; }
.divider::after { right: 0; }
.divider span {
  background: #fff7ed;
  padding: 0 24px;
  font-size: 28px;
  color: #999;
  position: relative;
}

/* 手动签到 */
.manual-area {
  text-align: center;
}
.manual-area h2 {
  font-size: 36px;
  color: #333;
  margin-bottom: 24px;
}
.phone-input {
  width: 700px;
  height: 80px;
  font-size: 40px;
  text-align: center;
  border: 3px solid #ccc;
  border-radius: 16px;
  outline: none;
  letter-spacing: 6px;
  margin-bottom: 24px;
}
.phone-input:focus { border-color: #f59e0b; }

.numpad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  width: 700px;
  margin: 0 auto 24px;
}
.numpad button {
  height: 80px;
  font-size: 36px;
  border: 2px solid #ddd;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  font-weight: bold;
}
.numpad button:active { background: #e0e0e0; }
.numpad .btn-clear { background: #ffcdd2; color: #c62828; border-color: #ef9a9a; }
.numpad .btn-delete { background: #fff3e0; color: #e65100; border-color: #ffcc80; }

.btn-submit {
  width: 700px;
  height: 80px;
  font-size: 36px;
  background: #4caf50;
  color: #fff;
  border: none;
  border-radius: 40px;
  cursor: pointer;
  letter-spacing: 4px;
}
.btn-submit:active { background: #388e3c; }

/* 弹窗 */
.modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}
.modal-content {
  position: relative;
  background: #fff;
  border-radius: 36px;
  padding: 90px 120px;
  text-align: center;
  min-width: 750px;
  animation: popIn 0.3s ease;
}
.modal-close {
  position: absolute;
  top: 28px;
  right: 32px;
  width: 72px;
  height: 72px;
  border: none;
  border-radius: 50%;
  background: #f2f2f2;
  color: #555;
  font-size: 56px;
  line-height: 1;
  font-weight: 700;
  font-family: Arial, "Microsoft YaHei", sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0,0,0,0.12);
}
.modal-close:active {
  background: #e0e0e0;
  transform: scale(0.96);
}
@keyframes popIn {
  from { transform: scale(0.8); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}
.modal-content.error { border: 4px solid #f44336; }
.face-snapshot {
  width: 360px;
  height: 360px;
  border-radius: 50%;
  object-fit: cover;
  border: 9px solid #4caf50;
  margin: 0 auto 30px;
  display: block;
  box-shadow: 0 9px 36px rgba(0,0,0,0.15);
}
.success-icon {
  width: 168px;
  height: 168px;
  margin: 0 auto 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4caf50, #2e7d32);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 123px;
  line-height: 1;
  font-weight: 700;
  font-family: Arial, "Microsoft YaHei", sans-serif;
  box-shadow: 0 12px 33px rgba(76, 175, 80, 0.32);
}

.error-icon {
  width: 96px;
  height: 96px;
  margin: 0 auto 28px;
  border-radius: 50%;
  background: #f44336;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 72px;
  line-height: 1;
  font-weight: 700;
  font-family: Arial, "Microsoft YaHei", sans-serif;
  box-shadow: 0 8px 22px rgba(244, 67, 54, 0.28);
}
.modal-content h2 { font-size: 60px; margin-bottom: 24px; }
.modal-user-name { color: #e53935; }
.points-text { font-size: 54px; color: #4caf50; font-weight: bold; }
.total-text {
  font-size: 57px;
  color: #4a3321;
  font-weight: 700;
  margin-top: 27px;
}
.total-text span {
  color: #e53935;
  font-size: 72px;
  font-weight: 800;
}

/* 返回按钮 */
.btn-back {
  position: fixed;
  top: 40px; left: 40px;
  background: rgba(255,255,255,0.9);
  border: none; border-radius: 40px;
  padding: 14px 32px;
  font-size: 26px; color: #333;
  cursor: pointer; z-index: 50;
  box-shadow: 0 2px 12px rgba(0,0,0,0.15);
  text-decoration: none;
  display: inline-flex; align-items: center; gap: 8px;
}
.btn-back:active { background: #e0e0e0; }

/* 扫描线动画 */
.scan-line {
  position: absolute;
  left: 21%; right: 21%;
  height: 3px;
  background: linear-gradient(90deg, transparent, #4caf50, transparent);
  animation: scanMove 2s ease-in-out infinite;
  z-index: 2;
}
@keyframes scanMove {
  0% { top: 21%; opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { top: 79%; opacity: 0; }
}
