:root {
  --blue: #4a90e2; --blue-dark: #347dcc; --blue-soft: #eaf4ff; --orange: #ff8968;
  --orange-soft: #fff0e9; --page: #f5f8fb; --surface: #fff; --text: #243746; --font-extra: 0px;
  --muted: #8393a0; --line: #e2e8ed; --danger: #d95757;
  font-family: "PingFang SC", "Microsoft YaHei", Arial, sans-serif; color: var(--text); background: #e9eef2;
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html[data-font-size="large"] { --font-extra: 2px; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html[data-font-size="larger"] { --font-extra: 4px; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; background: #e9eef2; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }

.app-shell { width: min(100%, 430px); min-height: 100svh; margin: auto; overflow: hidden; background: var(--page); box-shadow: 0 0 40px rgb(29 57 78 / 10%); }
.screen { display: none; min-height: 100svh; }
.screen.is-active { display: block; animation: screen-in 180ms ease-out; }
.brand-header, .page-header { position: sticky; top: 0; z-index: 20; height: calc(58px + env(safe-area-inset-top)); padding: env(safe-area-inset-top) 18px 0; display: flex; align-items: center; justify-content: space-between; background: rgb(255 255 255 / 96%); border-bottom: 1px solid #eef2f5; }
.brand-logo { width: 145px; height: 40px; display: flex; align-items: center; }
.brand-logo img { width: 100%; height: auto; display: block; }
.language-button { min-height: 29px; padding: 4px 11px; border: 1px solid #c9def5; border-radius: 16px; background: #f7fbff; color: var(--blue-dark); font-size: calc(10px + var(--font-extra)); font-weight: 650; }
.font-size-button { position: fixed; z-index: 25; right: max(14px, calc((100vw - 430px) / 2 + 14px)); bottom: calc(104px + env(safe-area-inset-bottom)); min-width: 76px; height: 42px; padding: 0 12px; display: flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid #b8d7f7; border-radius: 21px; background: rgb(255 255 255 / 96%); color: var(--blue-dark); font-size: calc(12px + var(--font-extra)); font-weight: 700; box-shadow: 0 5px 16px rgb(45 94 139 / 15%); }
.font-size-button::before { content: "字号"; font-size: calc(10px + var(--font-extra)); font-weight: 600; }
html[lang="en"] .font-size-button::before { content: "Text"; }
.page-header { display: grid; grid-template-columns: 34px 1fr 34px; padding-inline: 13px; }
.page-header h1 { margin: 0; text-align: center; font-size: calc(16px + var(--font-extra)); }
.back-link { width: 34px; height: 34px; padding: 0 0 3px; border: 0; background: transparent; color: var(--blue); font-family: Arial, sans-serif; font-size: calc(28px + var(--font-extra)); font-weight: 400; line-height: 1; }
.page-content { padding: 16px 16px calc(102px + env(safe-area-inset-bottom)); }
.home-content { padding-top: 12px; }

.hero-card { border-radius: 22px; color: #fff; }
.blue-hero { padding: 26px 22px 22px; background: linear-gradient(145deg, #448fe4, #5099ea); box-shadow: 0 13px 30px rgb(57 131 214 / 18%); }
.hero-card p { margin: 0 0 12px; font-size: calc(10px + var(--font-extra)); font-weight: 700; letter-spacing: .04em; opacity: .88; }
.hero-card h1 { margin: 0; white-space: pre-line; font-size: calc(25px + var(--font-extra)); line-height: 1.35; letter-spacing: -.02em; }
.hero-card > span { display: block; margin-top: 12px; font-size: calc(11px + var(--font-extra)); line-height: 1.65; opacity: .88; }
.hero-tags { margin-top: 19px; display: flex; gap: 8px; }
.hero-tags i { min-width: 72px; padding: 6px 9px; text-align: center; border-radius: 14px; background: rgb(255 255 255 / 20%); font-size: calc(9px + var(--font-extra)); font-style: normal; }
h2 { margin: 0; color: var(--text); font-size: calc(16px + var(--font-extra)); }
.content-section { margin-top: 11px; }
.flow-section h2 { margin-bottom: 12px; }
.process-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.process-grid article { min-height: 93px; padding: 14px 8px; display: grid; place-content: center; gap: 7px; text-align: center; border-radius: 12px; background: #eef5fc; }
.process-grid b { color: var(--blue); font-size: calc(10px + var(--font-extra)); }
.process-grid strong { white-space: pre-line; font-size: calc(11px + var(--font-extra)); line-height: 1.55; }
.white-card { margin-top: 14px; padding: 17px; border: 1px solid var(--line); border-radius: 15px; background: var(--surface); box-shadow: 0 5px 16px rgb(50 80 102 / 4%); }
.service-includes h2 { margin-bottom: 13px; }
.service-includes article { padding: 9px 0; display: flex; align-items: center; gap: 11px; }
.service-includes article + article { border-top: 1px solid #f0f3f5; }
.service-includes article > i { width: 31px; height: 31px; display: grid; flex: 0 0 auto; place-items: center; border-radius: 9px; background: var(--orange-soft); color: #e67857; font-size: calc(11px + var(--font-extra)); font-style: normal; font-weight: 700; }
.service-includes article > span { display: grid; gap: 4px; }
.service-includes strong { font-size: calc(12px + var(--font-extra)); }
.service-includes small { color: var(--muted); font-size: calc(10px + var(--font-extra)); }
.needs-section h2 { margin-bottom: 11px; }
.need-tags { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.need-tags span { padding: 7px 5px; text-align: center; border-radius: 9px; background: var(--blue-soft); color: var(--blue-dark); font-size: calc(10px + var(--font-extra)); font-weight: 650; }
.price-note { margin-top: 15px; padding: 13px 14px; white-space: pre-line; border: 1px solid #dce8f4; border-radius: 12px; background: #eef5fc; color: #758a99; font-size: calc(10px + var(--font-extra)); line-height: 1.65; }
.service-area-note { margin-top: 8px; padding: 10px 14px; overflow-wrap: anywhere; border: 1px solid #f0ddbd; border-radius: 11px; background: #fff7e9; color: #9b722f; font-size: calc(11px + var(--font-extra)); font-weight: 700; line-height: 1.5; text-align: center; }
.service-info-link { width: 100%; min-height: 43px; margin-top: 10px; padding: 0 14px; display: flex; align-items: center; justify-content: space-between; border: 0; border-radius: 11px; background: #fff; color: #657b8b; font-size: calc(11px + var(--font-extra)); }
.service-info-link i { color: var(--blue); font-size: calc(22px + var(--font-extra)); font-style: normal; }

.sticky-actions { position: fixed; z-index: 18; bottom: 0; left: 50%; width: min(100%, 430px); padding: 11px 16px max(12px, env(safe-area-inset-bottom)); display: grid; grid-template-columns: 1fr 1fr; gap: 11px; border-top: 1px solid #e6edf2; background: rgb(255 255 255 / 96%); backdrop-filter: blur(12px); transform: translateX(-50%); }
.sticky-actions button { min-height: 58px; display: grid; place-content: center; gap: 4px; border-radius: 13px; font-size: calc(11px + var(--font-extra)); font-weight: 700; }
.sticky-actions strong { font-size: calc(14px + var(--font-extra)); }
.primary-action { border: 0; background: var(--blue); color: #fff; box-shadow: 0 8px 20px rgb(74 144 226 / 20%); }
.custom-action { border: 1px solid var(--orange); background: #fff; color: var(--orange); }

.form-screen { padding-bottom: calc(100px + env(safe-area-inset-bottom)); }
.form-screen form { padding: 12px 12px 24px; }
.booking-summary { min-height: 100px; padding: 18px 18px; display: grid; grid-template-columns: 1fr auto; align-items: end; }
.booking-summary { color: #fff; }
.booking-summary > span { grid-column: 1 / -1; color: #fff; font-size: calc(10px + var(--font-extra)); opacity: 1; }
.booking-summary > strong { font-size: calc(24px + var(--font-extra)); }
.booking-summary > small { white-space: pre-line; text-align: right; font-size: calc(10px + var(--font-extra)); line-height: 1.6; }
.form-card { margin-top: 12px; padding: 15px 16px 4px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.form-card h2 { padding-bottom: 9px; }
.form-row { position: relative; min-height: 48px; display: grid; grid-template-columns: minmax(112px, auto) 1fr; align-items: center; border-top: 1px solid #f0f3f5; font-size: calc(11px + var(--font-extra)); }
.form-row > span, .form-row > label, .field-label { color: #354a59; font-weight: 600; }
.form-row input, .form-row select, .form-row textarea, .appointment-date-row button { width: 100%; min-width: 0; padding: 11px 14px; border: 0; outline: 0; background: transparent; color: #667b8b; text-align: right; font-size: calc(11px + var(--font-extra)); }
.form-row input::placeholder, .form-row textarea::placeholder { color: #a1adb6; }
.form-row select { appearance: none; background: linear-gradient(45deg, transparent 50%, #9aa9b3 50%) calc(100% - 7px) 50% / 5px 5px no-repeat; padding-right: 17px; }
.birthdate-selects { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.form-row .birthdate-selects select { padding-inline: 4px 11px; text-align: center; }
.form-row textarea { min-height: 72px; resize: vertical; text-align: left; line-height: 1.6; }
.form-row-column { grid-template-columns: 1fr; padding-top: 11px; }
.form-row-column input, .form-row-column textarea { margin-top: 3px; padding-inline: 0; text-align: left; }
.form-row small[data-error], .slot-field > small, .field-error { grid-column: 1 / -1; display: block; color: var(--danger); font-size: calc(9px + var(--font-extra)); }
.appointment-date-row { grid-template-columns: auto 1fr; }
.appointment-date-row button { display: flex; justify-content: flex-end; gap: 9px; align-items: center; }
.appointment-date-row button i { color: #9caab4; font-size: calc(18px + var(--font-extra)); font-style: normal; }
.slot-field { margin: 0; padding: 13px 0 11px; border: 0; border-top: 1px solid #f0f3f5; }
.slot-field legend { padding: 0 0 10px; color: #354a59; font-size: calc(11px + var(--font-extra)); font-weight: 600; }
.slot-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.slot-options label { min-width: 0; }
.slot-options input { position: absolute; opacity: 0; pointer-events: none; }
.slot-options span { min-height: 59px; padding: 9px 4px; display: grid; place-content: center; gap: 4px; border: 1px solid #dfe7ed; border-radius: 10px; text-align: center; color: #546b7b; }
.slot-options strong { font-size: calc(10px + var(--font-extra)); }
html[lang="en"] .slot-options strong { display: grid; gap: 2px; }
.slot-options i { font-style: normal; }
.slot-options b { color: var(--orange); font-weight: 700; }
.slot-options small { font-size: calc(8px + var(--font-extra)); color: #8797a3; }
.slot-options input:checked + span { border-color: #9bc6f3; background: #f2f8ff; color: var(--blue-dark); box-shadow: inset 0 0 0 1px #b7d9f8; }
.hospital-field { grid-template-columns: minmax(112px, auto) 1fr; }
.hospital-autocomplete { position: relative; min-width: 0; }
.hospital-suggestions { position: absolute; z-index: 30; top: calc(100% + 6px); right: 0; width: min(290px, 78vw); max-height: 240px; overflow-y: auto; border: 1px solid #d9e5ee; border-radius: 12px; background: #fff; box-shadow: 0 14px 30px rgb(40 70 91 / 18%); }
.hospital-suggestion { width: 100%; padding: 11px 12px; display: grid; gap: 3px; border: 0; border-bottom: 1px solid #eef2f5; background: #fff; color: var(--text); text-align: left; }
.hospital-suggestion span { color: var(--muted); font-size: calc(9px + var(--font-extra)); }
.hospital-suggestion strong { font-size: calc(11px + var(--font-extra)); }
.hospital-suggestion small { color: var(--muted); font-size: calc(9px + var(--font-extra)); }
.hospital-suggestion:hover, .hospital-suggestion.is-active { background: var(--blue-soft); color: var(--blue-dark); }
.hospital-suggestion-empty, .hospital-search-state { padding: 15px; color: var(--muted); text-align: center; font-size: calc(10px + var(--font-extra)); }
.addon-list { border-top: 1px solid #f0f3f5; }
.addon-item { min-height: 60px; padding: 9px 0; display: grid; grid-template-columns: 20px 1fr auto; gap: 9px; align-items: center; border-bottom: 1px solid #f0f3f5; font-size: calc(11px + var(--font-extra)); }
.addon-item > span { display: grid; gap: 3px; }
.addon-item small { color: var(--muted); font-size: calc(8px + var(--font-extra)); line-height: 1.45; }
.addon-item b { color: var(--blue); font-size: calc(10px + var(--font-extra)); }
.empty-options { color: var(--muted); font-size: calc(10px + var(--font-extra)); }
.privacy-row { margin: 13px 2px 0; display: flex; align-items: flex-start; gap: 7px; color: #8796a1; font-size: calc(9px + var(--font-extra)); line-height: 1.6; }
.privacy-row input { margin-top: 1px; accent-color: var(--blue); }
.privacy-copy { display: flex; flex-wrap: wrap; column-gap: 3px; }
.privacy-copy label { cursor: pointer; }
.privacy-copy a { color: var(--blue-dark); font-weight: 650; text-decoration: underline; text-underline-offset: 2px; }
.form-message { min-height: 18px; padding: 6px 2px 0; color: var(--danger); font-size: calc(10px + var(--font-extra)); }
.submit-bar { position: fixed; z-index: 19; bottom: 0; left: 50%; width: min(calc(100% - 24px), 406px); padding: 10px 0 max(10px, env(safe-area-inset-bottom)); background: var(--page); transform: translateX(-50%); }
.submit-bar button { width: 100%; min-height: 52px; border: 0; border-radius: 12px; background: var(--blue); color: #fff; font-weight: 700; box-shadow: 0 9px 20px rgb(74 144 226 / 21%); }
.submit-bar strong { margin-left: 4px; }
.submit-bar > small { display: block; margin-top: 5px; color: #728491; font-size: calc(9px + var(--font-extra)); line-height: 1.4; text-align: center; }
.submit-bar button:disabled { opacity: .58; cursor: wait; }

.custom-content { padding-top: 12px; }
.orange-hero { padding: 24px 20px; background: linear-gradient(145deg, #ff8d6b, #ff8561); box-shadow: 0 13px 28px rgb(255 128 91 / 17%); }
.orange-hero p { margin-top: 11px; margin-bottom: 18px; font-weight: 400; line-height: 1.7; }
.orange-hero > strong { font-size: calc(18px + var(--font-extra)); }
.custom-process h2 { margin-bottom: 8px; }
.custom-process article { padding: 10px 0; display: flex; align-items: center; gap: 12px; }
.custom-process article > i { width: 30px; height: 30px; display: grid; flex: 0 0 auto; place-items: center; border-radius: 50%; background: #edf6ff; color: var(--blue); font-size: calc(9px + var(--font-extra)); font-style: normal; font-weight: 700; }
.custom-process article > span { display: grid; gap: 4px; }
.custom-process strong { font-size: calc(11px + var(--font-extra)); }
.custom-process small { color: var(--muted); font-size: calc(9px + var(--font-extra)); }
.qr-card { margin: 17px auto 0; padding: 18px; text-align: center; border: 1px solid var(--line); border-radius: 17px; background: #fff; }
.qr-card p { margin: 7px 0 12px; color: var(--muted); font-size: calc(10px + var(--font-extra)); }
.qr-card img { width: 146px; height: 146px; padding: 7px; border: 1px dashed #bbdaf8; border-radius: 12px; background: #f4f9ff; }
.qr-card small { display: block; margin-top: 8px; color: var(--blue); font-size: calc(9px + var(--font-extra)); }

.info-content { padding-top: 12px; }
.compact-hero { padding-block: 23px; }
.prose-card h2, .cancellation-card h2 { margin-bottom: 10px; }
.visit-stage-card h2 { margin: -17px -17px 12px; padding: 10px 17px; border-radius: 14px 14px 0 0; background: var(--blue); color: #fff; }
.prose-card p, .prose-card li { margin: 0; color: #70828f; font-size: calc(10px + var(--font-extra)); line-height: 1.75; }
.prose-card p + p { margin-top: 8px; }
.prose-card ol { margin: 0; padding-left: 18px; }
.service-boundary { margin-top: 14px; padding: 16px; border: 1px solid #c9def5; border-radius: 15px; background: #f2f8ff; }
.service-boundary strong { color: var(--blue-dark); font-size: calc(12px + var(--font-extra)); }
.service-boundary p { margin: 7px 0 0; white-space: pre-line; color: #657b8b; font-size: calc(9px + var(--font-extra)); line-height: 1.75; }
.cancel-table { display: grid; grid-template-columns: 1fr 1.3fr; border: 1px solid #c9def5; font-size: calc(9px + var(--font-extra)); }
.cancel-table > * { min-height: 35px; padding: 8px; display: grid; align-items: center; border-right: 1px solid #c9def5; border-bottom: 1px solid #c9def5; }
.cancel-table > *:nth-child(2n) { border-right: 0; }
.cancel-table > *:nth-last-child(-n+2) { border-bottom: 0; }
.cancel-table b { background: var(--blue); color: #fff; }
.cancel-table span { color: #657b8b; }
.cancel-note { margin: 10px 0 0; color: #657b8b; font-size: calc(9px + var(--font-extra)); line-height: 1.6; }

@keyframes screen-in { from { opacity: 0; transform: translateY(4px); } }
@media (max-width: 360px) {
  .page-content { padding-inline: 11px; }
  .hero-card h1 { font-size: calc(22px + var(--font-extra)); }
  .brand-header { padding-inline: 13px; }
  .sticky-actions { padding-inline: 11px; }
  .form-screen form { padding-inline: 9px; }
  .submit-bar { width: calc(100% - 18px); }
}
@media (prefers-reduced-motion: reduce) { .screen.is-active { animation: none; } }
