/* style.css —— 哇喔 云端版门户（落地页 + 自助开通）
   约束：原生 CSS、无构建、无外部字体/图片/CDN；移动端优先（酒店主常用手机）。
   断点：640px（平板双列）/ 900px（桌面双栏、宽屏布局）。
   写样式前请先读 README「契约对齐」：本目录只对接口负责，不臆造端点。 */

:root {
  color-scheme: light;
  --brand: #087c61;
  --brand-dark: #05624d;
  --brand-soft: #e2f4ec;
  --ink: #17382f;
  --ink-soft: #39584e;
  --muted: #6c857a;
  --line: #dbe8e1;
  --bg: #f4faf7;
  --white: #ffffff;
  --danger: #a33f32;
  --radius: 14px;
  --shadow-sm: 0 6px 20px rgba(23, 56, 47, 0.05);
  --shadow-md: 0 18px 46px rgba(23, 56, 47, 0.09);
  --font: system-ui, -apple-system, "Segoe UI", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
}

[hidden] {
  display: none !important;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

a {
  color: var(--brand);
  text-decoration: none;
}

a:hover {
  color: var(--brand-dark);
}

svg {
  display: block;
}

:focus-visible {
  outline: 3px solid rgba(8, 124, 97, 0.42);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  top: -64px;
  left: 12px;
  z-index: 60;
  padding: 10px 16px;
  border-radius: 0 0 10px 10px;
  background: var(--brand);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: 0;
  color: #fff;
}

.wrap {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-left: max(18px, env(safe-area-inset-left));
  padding-right: max(18px, env(safe-area-inset-right));
}

/* ---------------- 顶栏 ---------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  width: 38px;
  height: 38px;
  flex: none;
  display: block;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-text strong {
  font-size: 17px;
  letter-spacing: 0.5px;
}

.brand-text small {
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--muted);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 14px;
  font-weight: 600;
}

.site-nav a:not(.btn) {
  color: var(--ink-soft);
}

.site-nav a:not(.btn):hover {
  color: var(--brand);
}

@media (max-width: 719px) {
  .site-nav {
    gap: 0;
  }

  .site-nav a:not(.btn) {
    display: none;
  }
}

/* ---------------- 按钮 ---------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 11px;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:active {
  transform: translateY(1px);
}

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

.btn-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 8px 20px rgba(8, 124, 97, 0.22);
}

.btn-primary:hover {
  background: var(--brand-dark);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--ink-soft);
}

.btn-ghost:hover {
  background: #fff;
  border-color: #b9d8ca;
  color: var(--ink);
}

.btn-light {
  background: #fff;
  color: var(--brand-dark);
}

.btn-light:hover {
  background: #eafaf2;
  color: var(--brand-dark);
}

.btn-sm {
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 9px;
  font-size: 13px;
}

.btn-lg {
  min-height: 50px;
  padding: 13px 24px;
  border-radius: 13px;
  font-size: 16px;
}

.btn-block {
  width: 100%;
}

/* ---------------- 首屏 ---------------- */
.hero {
  padding: 28px 0 40px;
  background:
    radial-gradient(circle at 10% 6%, #d9f3e5 0, rgba(217, 243, 229, 0) 42%),
    radial-gradient(circle at 94% 0, #dcecfb 0, rgba(220, 236, 251, 0) 40%),
    linear-gradient(180deg, #f6fbf8, #fff 80%);
}

.hero-inner {
  display: grid;
  gap: 32px;
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 2.5px;
  color: var(--brand);
}

.hero h1 {
  margin: 10px 0 14px;
  font-size: clamp(30px, 8.2vw, 52px);
  line-height: 1.16;
  letter-spacing: -0.8px;
  color: var(--ink);
}

.lede {
  max-width: 560px;
  margin: 0 0 22px;
  font-size: 16px;
  color: var(--ink-soft);
}

.lede strong {
  color: var(--brand-dark);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
  color: var(--muted);
}

.hero-points li {
  position: relative;
  padding-left: 18px;
}

.hero-points li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--brand);
  font-weight: 800;
}

.hero-board {
  display: flex;
  justify-content: center;
}

.board-card {
  width: 100%;
  max-width: 470px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 60px rgba(20, 60, 48, 0.12);
  transform: rotate(-1.2deg);
}

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

.board-top strong {
  display: block;
  font-size: 15px;
}

.board-top small {
  font-size: 11px;
  color: var(--muted);
}

.board-badge {
  flex: none;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 10px;
  font-weight: 800;
}

.board {
  display: grid;
  gap: 6px;
}

.board-row {
  display: grid;
  grid-template-columns: minmax(62px, 1.25fr) repeat(4, minmax(0, 1fr));
  gap: 5px;
  align-items: center;
}

.board-head span {
  font-size: 10px;
  font-weight: 700;
  text-align: center;
  color: var(--muted);
}

.board-head .board-room {
  text-align: left;
}

.board-room {
  overflow: hidden;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--ink-soft);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cell {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 27px;
  border: 1px dashed #dbe8e1;
  border-radius: 6px;
  background: #f4f8f5;
  color: #9cb2a6;
  font-size: 10px;
  font-weight: 700;
}

.cell.booked {
  border: 1px solid #f3ddb4;
  background: #fff1d9;
  color: #96651c;
}

.cell.inhouse {
  border: 1px solid #bfe8d4;
  background: #ddf4e7;
  color: #0c7256;
}

.cell.blocked {
  border: 1px solid #d3deef;
  background: #e8eef7;
  color: #4f6684;
}

.cell.dirty {
  border: 1px solid #f2d2cb;
  background: #fbe6e2;
  color: #a6503f;
}

.board-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  color: var(--muted);
  font-size: 10px;
}

.board-legend span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}

.dot.booked {
  background: #e5a840;
}

.dot.inhouse {
  background: #2e9c76;
}

.dot.blocked {
  background: #7d94b5;
}

.dot.dirty {
  background: #d97763;
}

/* ---------------- 通用区块 ---------------- */
.section {
  padding: 44px 0;
}

.section-alt {
  background: var(--bg);
}

.section h2 {
  margin: 4px 0 10px;
  font-size: clamp(22px, 5.6vw, 34px);
  line-height: 1.25;
  letter-spacing: -0.4px;
  color: var(--ink);
}

.section-lede {
  max-width: 620px;
  margin: 0 0 24px;
  font-size: 15px;
  color: var(--muted);
}

/* ---------------- 功能卡片 ---------------- */
.feature-grid {
  display: grid;
  gap: 14px;
}

.feature-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 32px rgba(23, 56, 47, 0.09);
}

.feature-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 14px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: var(--brand-soft);
  color: var(--brand);
}

.feature-icon svg {
  width: 23px;
  height: 23px;
}

.feature-card h3 {
  margin: 0 0 6px;
  font-size: 16px;
  color: var(--ink);
}

.feature-card p {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
}

@media (min-width: 640px) {
  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }
}

@media (min-width: 960px) {
  .feature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
  }
}

/* ---------------- 开通流程 ---------------- */
.steps {
  display: grid;
  gap: 14px;
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
}

.step {
  padding: 22px 20px 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.step-num {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin-bottom: 12px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}

.step h3 {
  margin: 0 0 6px;
  font-size: 16px;
}

.step p {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
}

@media (min-width: 760px) {
  .steps {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.how-note {
  max-width: 760px;
  margin: 0;
  padding: 14px 16px;
  border: 1px dashed #bfe0d1;
  border-radius: 12px;
  background: #fff;
  font-size: 13.5px;
  color: var(--ink-soft);
}

.how-note strong {
  color: var(--brand-dark);
}

/* ---------------- 行动号召 ---------------- */
.cta-band {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  padding: 26px 22px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--brand), #055b48 70%);
  color: #e9f7f1;
  box-shadow: 0 20px 44px rgba(8, 124, 97, 0.22);
}

.cta-band h2 {
  margin: 0 0 8px;
  font-size: clamp(21px, 5.4vw, 30px);
  letter-spacing: -0.4px;
  color: #fff;
}

.cta-band p {
  margin: 0;
  font-size: 14.5px;
  color: #c7e9dd;
}

@media (min-width: 760px) {
  .cta-band {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 36px 40px;
  }
}

/* ---------------- 常见问题 ---------------- */
.faq-list {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  overflow: hidden;
}

.faq-item {
  border-top: 1px solid var(--line);
}

.faq-item:first-child {
  border-top: 0;
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 17px 18px;
  list-style: none;
  cursor: pointer;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--ink);
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  flex: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 16px;
  font-weight: 700;
  transition: transform 0.18s ease;
}

.faq-item[open] summary {
  color: var(--brand-dark);
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item p {
  margin: 0;
  padding: 0 18px 18px;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--muted);
}

.faq-item code {
  padding: 1px 5px;
  border-radius: 5px;
  background: #f2f8f4;
  color: var(--ink-soft);
  font-size: 12.5px;
  word-break: break-all;
}

/* ---------------- 页脚 ---------------- */
.site-footer {
  padding: 30px 0 22px;
  background: #0e2f27;
  color: #cfe3da;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.footer-brand .brand {
  color: #fff;
}

.footer-brand .brand:hover {
  color: #fff;
}

.footer-brand .brand-text small {
  color: #8fb5a8;
}

.brand-light .brand-mark {
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.18));
}

.footer-brand p {
  margin: 10px 0 0;
  font-size: 12.5px;
  color: #9fc2b5;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  font-size: 13px;
}

.footer-nav a {
  color: #cfe3da;
}

.footer-nav a:hover {
  color: #fff;
}

.footer-meta {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 11.5px;
  color: #8fb5a8;
}

.footer-meta p {
  margin: 0;
}

.site-footer-lite .footer-meta {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

@media (min-width: 760px) {
  .footer-inner {
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
  }
}

/* ---------------- 开通页：页头与整体 ---------------- */
.signup-page {
  background:
    radial-gradient(circle at 88% 4%, #d9f3e5 0, rgba(217, 243, 229, 0) 42%),
    linear-gradient(180deg, #f4faf7, #fff 62%);
}

.site-header-lite .header-inner {
  min-height: 60px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-soft);
}

.back-link::before {
  content: "←";
  font-weight: 800;
}

.back-link:hover {
  color: var(--brand);
}

.signup-main {
  padding: 24px 0 44px;
}

.signup-wrap {
  display: grid;
  gap: 24px;
  align-items: start;
}

.signup-intro h1 {
  margin: 8px 0 12px;
  font-size: clamp(26px, 6.5vw, 40px);
  line-height: 1.2;
  letter-spacing: -0.6px;
}

.signup-points {
  display: grid;
  gap: 11px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
  color: var(--ink-soft);
}

.signup-points li {
  display: flex;
  align-items: flex-start;
  gap: 9px;
}

.signup-points li span {
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 12px;
  font-weight: 800;
}

.signup-contact-note {
  margin: 18px 0 0;
  font-size: 12.5px;
  color: var(--muted);
}

/* ---------------- 开通页：表单卡片 ---------------- */
.signup-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow-md);
}

.form-head h2 {
  margin: 0 0 4px;
  font-size: 20px;
  color: var(--ink);
}

.form-head p {
  margin: 0 0 18px;
  font-size: 12.5px;
  color: var(--muted);
}

.req-mark {
  color: #c2523f;
  font-weight: 800;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 18px;
}

.field label {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink-soft);
}

.field input {
  width: 100%;
  height: 50px;
  padding: 0 14px;
  border: 1px solid #d7e5dd;
  border-radius: 11px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 16px; /* 16px 可避免 iOS 聚焦时自动放大 */
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.field input::placeholder {
  color: #a9bcb2;
}

.field input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(8, 124, 97, 0.12);
}

.field input[aria-invalid="true"] {
  border-color: #c2523f;
  background: #fff9f8;
}

.field input[aria-invalid="true"]:focus {
  box-shadow: 0 0 0 4px rgba(194, 82, 63, 0.12);
}

.field-help {
  margin: 0;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}

.field-error {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.6;
  color: #b74336;
}

.slug-preview {
  margin: 0;
  padding: 7px 10px;
  border: 1px dashed #d7e5dd;
  border-radius: 8px;
  background: #f4f9f6;
  font-size: 12px;
  line-height: 1.5;
  color: var(--ink-soft);
  word-break: break-all;
}

.slug-preview code {
  display: block;
  margin-top: 2px;
  color: var(--brand-dark);
  font-size: 12px;
  word-break: break-all;
}

.slug-status {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.6;
}

.slug-status:empty {
  display: none;
}

.slug-status[data-tone="checking"] {
  color: var(--muted);
}

.slug-status[data-tone="ok"] {
  color: #0b7a5c;
  font-weight: 700;
}

.slug-status[data-tone="occupied"] {
  color: #b74336;
  font-weight: 700;
}

.slug-status[data-tone="invalid"],
.slug-status[data-tone="error"] {
  color: #a2621c;
}

.alert {
  margin: 0 0 18px;
  padding: 12px 14px;
  border: 1px solid #f3d3cc;
  border-radius: 11px;
  background: #fdf1ef;
  color: var(--danger);
  font-size: 13.5px;
  line-height: 1.65;
}

.alert:focus {
  outline: 2px solid rgba(163, 63, 50, 0.35);
  outline-offset: 2px;
}

.alert-warn {
  border-color: #f0dcb4;
  background: #fdf6e8;
  color: #8a5c14;
}

.form-note {
  margin: 14px 0 0;
  font-size: 12px;
  line-height: 1.65;
  color: var(--muted);
}

/* ---------------- 开通页：提交成功 ---------------- */
.success-card {
  padding: 14px 4px;
  text-align: center;
}

.success-card:focus {
  outline: none;
}

.success-icon {
  width: 62px;
  height: 62px;
  margin: 4px auto 16px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 30px;
  font-weight: 800;
}

.success-card h2 {
  margin: 0 0 8px;
  font-size: 23px;
  color: var(--ink);
}

.success-lede {
  max-width: 360px;
  margin: 0 auto 20px;
  font-size: 14px;
  color: var(--ink-soft);
}

.success-meta {
  display: grid;
  gap: 10px;
  margin: 0 0 18px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f6fbf8;
  font-size: 13px;
  text-align: left;
}

.success-meta > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}

.success-meta dt {
  flex: none;
  font-size: 12.5px;
  color: var(--muted);
}

.success-meta dd {
  margin: 0;
  font-weight: 600;
  text-align: right;
  color: var(--ink);
  word-break: break-all;
}

.success-meta code {
  padding: 2px 6px;
  border-radius: 5px;
  background: #ecf6f1;
  font-size: 12px;
}

.success-hint {
  margin: 0 0 20px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--muted);
}

/* ---------------- 桌面增强 ---------------- */
@media (min-width: 900px) {
  .hero {
    padding: 54px 0 64px;
  }

  .hero-inner {
    grid-template-columns: minmax(0, 1fr) minmax(380px, 470px);
    align-items: center;
    gap: 44px;
  }

  .lede {
    font-size: 17px;
  }

  .board-card {
    transform: rotate(-2deg);
  }

  .section {
    padding: 64px 0;
  }

  .signup-main {
    padding: 44px 0 64px;
  }

  .signup-wrap {
    grid-template-columns: minmax(0, 1fr) 460px;
    gap: 48px;
  }

  .signup-card {
    padding: 28px;
  }
}

/* 尊重系统「减少动态效果」偏好 */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }

  .feature-card:hover {
    transform: none;
  }
}
