/* Public website palette and typography shared by both presentations. */
:root {
  color-scheme: light;
  --ui-ink: #292e2c;
  --ui-muted: #5d6561;
  --ui-tint: #e8efeb;
  --ui-line: #dcdedb;
  --ui-accent: #395e50;
  --ui-paper: #fff;
  --ui-bg: #f7f7f5;
  --bg: var(--ui-bg); --panel: var(--ui-paper); --surface: #f1f3f1;
  --text: var(--ui-ink); --muted: var(--ui-muted); --soft: var(--ui-muted);
  --line: var(--ui-line); --accent: var(--ui-accent); --focus: #507967;
  --action-bg: var(--ui-tint); --action-edge: #c6d4ca; --action-ink: #304f41;
  --ui-font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}
body, body.policy-page, .hx-bar, .hx-trail { font-family: var(--ui-font); color: var(--ui-ink); }
body:has(.hx-bar) { background-color: var(--ui-bg); }
:where(main, dialog) :is(h1, h2, h3) { text-wrap: pretty; }
button, select, input, textarea { font-family: inherit; }
.hx-bar { background: #fafbf9; border-color: var(--ui-line); }
html[data-site-view="desktop"] .hx-bar { background: rgb(250 251 249 / .95); }
.hx-bar .hx-brand { font-size: 1.2rem; font-weight: 680; letter-spacing: -.025em; color:var(--ui-ink); }
.hx-brand > svg { width:22px; height:22px; stroke:#a96c63; }
.hx-primary a, .hx-trail span[aria-current] { color: var(--ui-muted); }
.hx-primary a[aria-current] { color: var(--ui-ink); border-bottom-color: #80968a; }
.hx-actions :is(.header-cta,.header-account) { border-color:transparent; border-radius:999px; background:transparent; color:var(--ui-accent); font-weight:550; }
.hx-trail a { color:var(--ui-accent); }
.hx-trail a:hover, .hx-primary a:hover { color:var(--ui-ink); }
html[data-site-view="mobile"] .hx-primary {
  background:rgb(251 251 249 / .97); border-color:var(--ui-line); border-radius:0;
}
html[data-site-view="mobile"] .hx-primary a { color:var(--ui-muted); border-radius:0; }
html[data-site-view="mobile"] .hx-primary a[aria-current] { background:transparent; color:var(--ui-accent); font-weight:700; }
html[data-site-view="mobile"] .hx-primary a[aria-current] svg {
  background:var(--ui-tint); border-radius:9px; box-shadow:0 0 0 3px var(--ui-tint); stroke-width:2;
}
body .site-footer:not(.home-footer) { color:var(--ui-muted); background:#f0f1ef; border-color:var(--ui-line); }
body .site-footer .footer-brand { color:var(--ui-ink); }
body .site-footer a:hover { text-decoration:underline; text-underline-offset:3px; }
body .button.button-primary, body .button.button-primary:hover:not(:disabled) {
  color:var(--action-ink); border:1px solid var(--action-edge); background:var(--ui-tint); box-shadow:none;
}
body .button.button-primary:hover:not(:disabled) { background:#dde8e1; }
body .button.button-outline { color:var(--ui-accent); background:var(--ui-paper); border-color:#cbd2cd; }
body .button:hover:not(:disabled) { transform:none; }
body .toast:not([hidden]), #toastRegion .toast {
  background:#f2f5f2; color:#314e41; border:1px solid #bfcfc4; box-shadow:0 4px 16px #28372d12;
}
:is(.hx-policy, #voice-picker, #history-dialog, #continuous-dialog, #camera-dialog, #checkout-dialog) {
  background-color:var(--ui-paper); border:1px solid var(--ui-line); color:var(--ui-ink);
}
dialog::backdrop { background:rgb(46 51 49 / .22); }
:where(main,dialog) input:not([type="checkbox"],[type="radio"],[type="range"],[type="file"]):focus-visible,
:where(main,dialog) textarea:focus-visible { outline:2px solid var(--focus); outline-offset:2px; }

html[data-site-view="mobile"] :is(main, dialog) :is(textarea, select, input:not([type]), input[type="text"], input[type="tel"], input[type="email"], input[type="password"], input[type="number"], input[type="search"]) {
  font-size: max(16px, 1em);
}

main.login-main .login-card { background:var(--ui-paper); border:1px solid var(--ui-line); border-radius:20px; box-shadow:0 4px 25px #30363105; }
main.login-main #login-title, .studio-page .page-heading h1, .policy-copy h1 {
  color:var(--ui-ink); font-weight:670; letter-spacing:-.035em; line-height:1.2; font-size:clamp(1.9rem,3.1vw,2.75rem);
}
main.login-main .login-subtitle, .login-card .login-consent { color:var(--ui-muted); }
main.login-main .login-switch, .studio-page .studio-nav { background:#eff1ee; border-color:var(--ui-line); }
main.login-main .login-switch button[aria-pressed=true], .studio-page .studio-nav a[aria-current] {
  background:white; border-color:#d4dad4; color:var(--ui-ink); font-weight:650; box-shadow:0 1px 4px #222a2410;
}
.login-card .password-entry, .login-card #auth-phone, .login-card #auth-code, .login-card #auth-password,
.studio-page .studio-panels :is(input:not([type=checkbox]), select, textarea) {
  border-color:#bbc4be; color:var(--ui-ink); background-color:#fdfefd;
}
.login-card .login-consent a, .studio-panels summary, .policy-copy a { color:var(--ui-accent); }
.studio-page .studio-panels .section-card, .studio-page .studio-entry {
  border-radius:18px; border-color:var(--ui-line); background:var(--ui-paper);
}
.studio-page .studio-panels label { font-weight:560; color:var(--ui-ink); }
.studio-page .studio-panels label:has(#consent) {
  display:flex; align-items:flex-start; gap:8px; font-weight:400; color:var(--ui-muted); line-height:1.55; font-size:14px;
}
.studio-page #consent { flex:none; margin:4px 0 0; }
.studio-panels #sample { padding:5px 9px 5px 5px; font-size:14px; }
.studio-panels #sample::file-selector-button {
  min-height:34px; padding:4px 13px; margin-inline-end:10px; border:0; border-radius:6px;
  background:#edf0ed; color:var(--ui-accent); font:inherit; cursor:pointer;
}
.studio-panels #new-profile summary { display:flex; align-items:center; gap:9px; list-style:none; }
.studio-panels #new-profile summary::-webkit-details-marker { display:none; }
.studio-panels #new-profile summary::before {
  content:""; display:block; width:7px; height:7px; border:solid currentColor; border-width:0 1.5px 1.5px 0; transform:rotate(-45deg);
}
.studio-panels #new-profile[open] summary::before { transform:rotate(45deg); }
body.policy-page { padding-inline:0; }
.policy-page .policy-copy { width:min(43rem,calc(100% - 40px)); padding-block:clamp(20px,4vw,48px) 36px; }
.policy-copy nav[aria-label="常用条款"] { border-radius:12px; background:#eff1ee; }
.policy-copy h2 { color:var(--ui-ink); letter-spacing:-.015em; }
.policy-copy small { color:var(--ui-muted); }
#voice-picker .picker-actions, .hx-policy-heading { border-color:var(--ui-line); }

.renewal-page .customer.shell { max-width:38rem; width:calc(100% - 32px); margin:clamp(24px,6vw,80px) auto; }
.renewal-page .card.login-panel {
  padding:clamp(20px,4vw,36px); border:1px solid var(--ui-line); border-radius:16px; color:var(--ui-ink); background:var(--ui-paper); box-shadow:none;
}
.renewal-page .card h1 { margin-top:0; letter-spacing:-.03em; font-size:clamp(24px,3vw,32px); }
.renewal-page .hint { color:var(--ui-muted); }
.renewal-return { display:inline-flex; align-items:center; min-height:44px; color:var(--ui-accent); text-underline-offset:3px; }
