html { scrollbar-gutter: stable; }

.reservation-dialog {
  box-sizing: border-box;
  width: min(580px, calc(100% - 32px));
  max-width: none;
  max-height: calc(100dvh - 40px);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 18px;
  background: #fff;
  color: #16191f;
  box-shadow: 0 24px 80px #0003;
  overflow: visible !important;
  font-family: inherit;
}
.reservation-dialog[open] { display: flex; flex-direction: column; }
.reservation-dialog::backdrop { background: rgba(8, 13, 20, .66); }
.reservation-dialog * { box-sizing: border-box; }
.reservation-dialog [hidden] { display: none !important; }
.reservation-dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex: none;
  min-height: 60px;
  padding: 10px 20px 10px 24px;
  border-bottom: 1px solid #d5d8dc;
}
.reservation-dialog-header h2 { margin: 0; font-size: 18px; line-height: 1.4; font-weight: 600; }
.reservation-close {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 6px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
}
.reservation-close:hover { background: #f0f2f5; }
.reservation-close img { width: 24px; height: 24px; }
.reservation-dialog-body { min-height: 0; padding: 20px 28px 24px; overflow: visible; }
.reservation-field { display: grid; grid-template-columns: 86px minmax(0, 1fr); align-items: start; gap: 12px; margin-bottom: 12px; }
.reservation-field > label { padding-top: 11px; color: #27354a; font-size: 15px; line-height: 20px; }
.reservation-required { color: #d93043; }
.reservation-field input {
  display: block;
  width: 100%;
  height: 42px;
  padding: 10px 12px;
  border: 1px solid #8391a6;
  border-radius: 4px;
  background: #fff;
  color: #172b45;
  font: inherit;
  font-size: 15px;
}
.reservation-field input::placeholder { color: #8590a0; }
.reservation-field input:focus { border-color: #066cff; outline: 2px solid #066cff26; outline-offset: 1px; }
.reservation-field input[aria-invalid="true"] { border-color: #cc293d; }

/* 公司名称智能匹配下拉列表样式 */
.company-search-wrapper {
  position: relative;
}

.company-suggest-list {
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  display: none;
  gap: 2px;
  padding: 8px;
  border: 1px solid #d5dfed;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(31, 74, 134, .15);
  max-height: 240px;
  overflow-y: auto;
  list-style: none;
  margin: 0;
}

.company-suggest-list.show {
  display: grid;
}

.company-suggest-list li {
  display: flex;
  align-items: center;
  min-height: 34px;
  padding: 3px 8px;
  border-radius: 5px;
  font-size: 14px;
  cursor: pointer;
  color: #172b45;
}

.company-suggest-list li:hover,
.company-suggest-list li.highlighted {
  background: #f2f7ff;
}

.company-suggest-list li.suggest-hint {
  color: #8590a0;
  cursor: default;
  justify-content: center;
}

.company-suggest-list li.suggest-hint:hover {
  background: transparent;
}
.reservation-code-row { display: flex; gap: 12px; }
.reservation-code-row input { min-width: 0; flex: 1; }
.reservation-code-button {
  flex: none;
  min-width: 112px;
  min-height: 42px;
  padding: 8px 12px;
  border: 1px solid #066cff;
  border-radius: 4px;
  background: #fff;
  color: #066cff;
  font: inherit;
  font-size: 14px;
  cursor: pointer;
}
.reservation-code-button:hover:not(:disabled) { background: #f2f7ff; }
.reservation-code-button:disabled { color: #748095; border-color: #bfc7d2; cursor: default; }
.reservation-error, .reservation-code-hint { margin: 6px 0 0; font-size: 12px; line-height: 1.5; }
.reservation-error { color: #ba2339; }
.reservation-code-hint { color: #526681; }
.reservation-choice { display: flex; align-items: flex-start; gap: 8px; color: #3e4c60; font-size: 14px; line-height: 1.5; cursor: pointer; }
.reservation-dialog input[type="checkbox"] { flex: none; width: 16px; height: 16px; margin: 3px 0 0; accent-color: #066cff; cursor: pointer; }
.reservation-consent { margin-top: 18px; padding-top: 16px; border-top: 1px solid #d5d8dc; }
.reservation-consent .reservation-choice { font-size: 13px; }
@media (min-width: 640px) {
  .reservation-consent .reservation-choice { font-size: 14px; }
  .reservation-dialog input[type="checkbox"] { width: 18px; height: 18px; margin-top: 2px; }
}
.reservation-consent a { color: #066cff; text-decoration: underline; text-underline-offset: 3px; }
.reservation-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 42px;
  margin-top: 18px;
  padding: 11px 24px;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(110deg, #066cff 0%, #943bfa 100%);
  color: #fff;
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
}
.reservation-submit:hover { background: linear-gradient(110deg, #0065f2 0%, #892cf0 100%); }
.reservation-submit:disabled { opacity: .7; cursor: not-allowed; }
.reservation-dialog :is(button, a, input[type="checkbox"]):focus-visible { outline: 2px solid #066cff; outline-offset: 3px; }
.reservation-status { margin: 14px 0 0; padding: 12px 14px; border-radius: 6px; background: #f0f7ff; color: #18345d; font-size: 14px; line-height: 1.6; }
body#page #agenda .agenda-reservation { cursor: pointer; }
body#page #agenda .agenda-reservation:hover { background: linear-gradient(110deg, #0065f2 0%, #892cf0 100%); }
body#page #agenda .agenda-reservation:focus-visible { outline: 2px solid #5ea8ff; outline-offset: 3px; }

/* ---- "体验全新AI产品" 开关 ---- */
.reservation-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 12px 0;
  color: #3e4c60;
  font-size: 14px;
  cursor: pointer;
}
.reservation-toggle input {
  position: absolute;
  z-index: 1;
  top: 0;
  left: 0;
  width: 44px;
  height: 24px;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.reservation-toggle-track {
  position: relative;
  flex: none;
  width: 44px;
  height: 24px;
  border-radius: 12px;
  background: #dfe2e9;
  transition: background .2s ease;
}
.reservation-toggle-track::before {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(28, 44, 79, .22);
  transition: transform .2s ease;
}
.reservation-toggle input:checked + .reservation-toggle-track {
  background: #7a4ff4;
}
.reservation-toggle input:checked + .reservation-toggle-track::before {
  transform: translateX(20px);
}
.reservation-toggle input:focus-visible + .reservation-toggle-track {
  outline: 2px solid #066cff;
  outline-offset: 2px;
}
.reservation-new {
  padding: 2px 8px;
  border-radius: 10px;
  background: #7a4ff4;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.3;
}

/* ---- "关心的领域" 下拉多选 ---- */
.reservation-label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  color: #27354a;
}
.reservation-areas {
  position: relative;
}
.reservation-areas summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  list-style: none;
  width: 100%;
  height: 42px;
  padding: 0 12px;
  border: 1px solid #8391a6;
  border-radius: 4px;
  background: #fff;
  color: #8590a0;
  font-size: 15px;
  cursor: pointer;
}
.reservation-areas summary::-webkit-details-marker { display: none; }
.reservation-areas summary::after {
  content: '';
  width: 7px;
  height: 7px;
  margin-left: 10px;
  border-right: 1.5px solid #607695;
  border-bottom: 1.5px solid #607695;
  transform: rotate(45deg) translateY(-2px);
}
.reservation-areas[data-selected="true"] summary {
  color: #172b45;
}
.reservation-areas summary:focus-visible {
  outline: 2px solid #066cff;
  outline-offset: 2px;
}
.reservation-areas[data-invalid="true"] summary {
  border-color: #cc293d;
}
.reservation-options {
  position: absolute;
  z-index: 10000;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  display: grid;
  gap: 2px;
  padding: 8px;
  border: 1px solid #d5dfed;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(31, 74, 134, .15);
}
.reservation-options label {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 34px;
  padding: 3px 8px;
  border-radius: 5px;
  font-size: 14px;
  cursor: pointer;
}
.reservation-options label:hover {
  background: #f1f6ff;
}
.reservation-options input {
  flex: none;
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: #066cff;
}

@media (max-width: 600px) {
  .reservation-dialog { max-height: calc(100dvh - 24px); border-radius: 20px; }
  .reservation-dialog-header { padding: 12px 18px; }
  .reservation-dialog-header h2 { font-size: 16px; }
  .reservation-dialog-body { padding: 24px; }
  .reservation-field { grid-template-columns: 1fr; gap: 6px; }
  .reservation-field > label { padding-top: 0; }
  .reservation-code-button { min-width: 118px; padding-inline: 8px; }
}

/* ========== 移动端（body.mobile-page）弹窗覆盖样式 ==========
   原位于 mobile/mobile.css，为保持弹窗样式单一来源并入本文件。
   仅在移动端页面（<body class="mobile-page">）生效。 */
body.mobile-page .reservation-dialog { width: min(420px, calc(100% - 24px)); }
body.mobile-page .reservation-dialog-body { padding: 16px 20px 22px; }
body.mobile-page .reservation-field { grid-template-columns: 1fr; gap: 4px; }
body.mobile-page .reservation-field > label { padding-top: 0; }
body.mobile-page .reservation-code-button { min-width: 104px; }
