/* Quarphin — site styles (CIS v4.2). One light theme by design; every colour is explicit.
   Electric blue #1D7AED is for marks, buttons and large type only (4.15:1 on white);
   small blue text on light ground uses #0954AE (7.26:1). Group navy #11335D for the
   hero and footer bands. Latin type: Outfit (OFL). Traditional Chinese: Noto Sans TC (OFL). */
:root {
  --blue: #1D7AED;
  --blue-ink: #0954AE;
  --navy: #11335D;
  --navy-2: #0C2748;
  --ink: #0E1B2B;
  --muted: #4C5B6C;
  --faint: #6E7681;
  --line: #DCE3EB;
  --soft: #F3F6FA;
  --paper: #FFFFFF;
  --on-navy: #FFFFFF;
  --on-navy-muted: rgba(255, 255, 255, 0.72);
  --ok: #0F6E56;
  --ok-bg: #E1F5EE;
  --wip: #854F0B;
  --wip-bg: #FAEEDA;
  --later: #3C3489;
  --later-bg: #EEEDFE;
  --radius: 10px;
  --wrap: 1120px;
  --font: "Outfit", "Noto Sans TC", "PingFang TC", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font);
  font-size: 17px; line-height: 1.65; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--blue-ink); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 3px solid var(--blue); outline-offset: 2px; border-radius: 6px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: 20px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; text-wrap: balance; margin: 0; }
h2 { font-size: clamp(28px, 4vw, 40px); font-weight: 600; }
h3 { font-size: 20px; font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0; }

/* ---------- nav ---------- */
.nav { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: rgba(255,255,255,0.96);
  border-bottom: 1px solid var(--line); backdrop-filter: saturate(1.4); }
.nav .wrap { display: flex; align-items: center; gap: 20px; height: 64px; }
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--ink); flex: none; }
.brand img { width: 34px; height: auto; }
.wordmark { font-family: "Outfit", sans-serif; font-weight: 600; font-size: 22px; letter-spacing: -0.01em; }
.nav .links { display: flex; align-items: center; gap: 22px; margin-left: auto; }
.nav .links a { color: var(--ink); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav .links a:hover { color: var(--blue-ink); }
.lang { display: flex; gap: 2px; border: 1px solid var(--line); border-radius: 999px; padding: 2px; }
.lang a { font-size: 13px !important; padding: 3px 9px; border-radius: 999px; color: var(--muted) !important; }
.lang a[aria-current="true"] { background: var(--navy); color: #fff !important; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px;
  padding: 0 20px; border-radius: 999px; font: inherit; font-size: 15px; font-weight: 600;
  text-decoration: none; cursor: pointer; border: 1px solid transparent; white-space: nowrap; }
.btn-primary { background: var(--blue); color: #fff !important; }
.btn-primary:hover { background: #1568D1; }
.btn-quiet { border-color: var(--line); color: var(--ink) !important; background: #fff; }
.btn-quiet:hover { border-color: var(--blue-ink); }
.navtoggle, .navburger { display: none; }

/* ---------- hero ---------- */
.hero { background: var(--navy); color: var(--on-navy); padding-block: 72px 80px; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: 56px; align-items: center; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.hero .eyebrow { color: var(--on-navy-muted); }
.hero h1 { font-size: clamp(40px, 6.4vw, 72px); font-weight: 600; margin: 14px 0 10px; }
.hero h1 .imm { color: #7DB4F7; }
.layers { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0 0 22px; padding: 0; list-style: none; font-size: 15px; }
.layers a { color: var(--on-navy-muted); text-decoration: none; }
.layers a b { color: #fff; font-weight: 600; }
.layers a:hover b { text-decoration: underline; }
.lede { font-size: 19px; color: var(--on-navy-muted); max-width: 40em; }
.check { margin-top: 30px; background: #fff; color: var(--ink); border-radius: 16px; padding: 18px; max-width: 620px; }
.check h2 { font-size: 22px; letter-spacing: -0.01em; }
.check .sub { margin: 4px 0 14px; font-size: 15px; color: var(--muted); }
.check .fields { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.check .site { grid-column: 1 / -1; }
.check .go { grid-column: 1 / -1; }
.check label { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 4px; }
.check input { width: 100%; height: 46px; border: 1px solid #B9C5D2; border-radius: var(--radius); padding: 0 12px;
  font: inherit; font-size: 16px; color: var(--ink); background: #fff; }
/* The area picker looks like the inputs beside it — a native select at 13px next to 46px fields read as broken. */
.check select { width: 100%; height: 46px; border: 1px solid #B9C5D2; border-radius: var(--radius); padding: 0 36px 0 12px;
  font: inherit; font-size: 16px; color: var(--ink); background: #fff; appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%234C5B6C' stroke-width='2'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; }
.check select:invalid, .check select option[value=""] { color: var(--faint); }
.check input:focus, .check select:focus { border-color: var(--blue); outline: none; box-shadow: 0 0 0 3px rgba(29,122,237,0.25); }
.check .go { height: 48px; font-size: 16px; }
.check .meta { margin-top: 10px; font-size: 13px; color: var(--faint); }
.check .linklike { background: none; border: 0; padding: 0; font: inherit; font-size: 13px; color: var(--blue-ink);
  text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.check .err { color: #A32D2D; font-size: 13px; margin-top: 8px; }
.check.is-soon .go { background: var(--soft); color: var(--muted) !important; cursor: default; opacity: 1; }
.check .soon .notify { font-weight: 600; white-space: nowrap; }
.check .soon { margin-top: 12px; padding: 12px 14px; border-radius: var(--radius); background: var(--soft);
  font-size: 15px; color: var(--ink); }
.hero .second { display: inline-block; margin-top: 18px; color: #fff; font-weight: 600; }

.agent { background: var(--navy-2); border: 1px solid rgba(255,255,255,0.14); border-radius: 18px; padding: 20px; }
.agent .top { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--on-navy-muted); margin-bottom: 14px; }
.agent .tag { background: rgba(255,255,255,0.1); padding: 3px 10px; border-radius: 999px; }
.agent .q { font-size: 15px; color: var(--on-navy-muted); }
.agent .q b { color: #fff; font-weight: 500; }
.agent .a { margin-top: 12px; background: #fff; color: var(--ink); border-radius: 12px; padding: 14px 16px; font-size: 15px; }
.agent .pick { margin-top: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; }
.agent .pick b { display: block; font-size: 16px; }
.agent .pick span { color: var(--muted); font-size: 14px; }
.agent .others { margin-top: 8px; color: var(--faint); font-size: 14px; }
.agent .src { margin-top: 12px; font-size: 12.5px; color: var(--on-navy-muted); }

/* ---------- sections ---------- */
section.block { padding-block: 88px; }
section.block.alt { background: var(--soft); }
.head { max-width: 46em; margin-bottom: 36px; }
.layer-no { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: var(--blue-ink); margin-bottom: 10px; }
.layer-no i { font-style: normal; display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
  background: var(--blue); color: #fff; font-size: 13px; }
.head p { margin-top: 14px; font-size: 18px; color: var(--muted); }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 22px; display: flex; flex-direction: column; gap: 10px; }
.card p { color: var(--muted); font-size: 16px; }
.status { align-self: flex-start; font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: 999px; }
.status.ok { background: var(--ok-bg); color: var(--ok); }
.status.wip { background: var(--wip-bg); color: var(--wip); }
.status.later { background: var(--later-bg); color: var(--later); }

.monitor { margin-top: 20px; background: #fff; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.monitor .mhead { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 18px; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.monitor table { width: 100%; border-collapse: collapse; font-size: 15px; }
.monitor th, .monitor td { text-align: left; padding: 11px 18px; border-bottom: 1px solid var(--line); vertical-align: top; }
.monitor th { font-size: 12.5px; color: var(--faint); font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; }
.monitor tr:last-child td { border-bottom: 0; }
.monitor .y { color: var(--ok); font-weight: 600; }
.monitor .n { color: var(--faint); }
.monitor .foot { padding: 12px 18px; font-size: 13px; color: var(--faint); background: var(--soft); }
.tablewrap { overflow-x: auto; }

.eras { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.era { border-top: 3px solid var(--line); padding-top: 14px; }
.era.now { border-top-color: var(--blue); }
.era .when { font-size: 13px; font-weight: 600; color: var(--faint); letter-spacing: 0.04em; }
.era.now .when { color: var(--blue-ink); }
.era h3 { font-size: 18px; margin: 6px 0 8px; }
.era p { font-size: 15px; color: var(--muted); }
.era sup a { text-decoration: none; }
.sources { margin-top: 22px; font-size: 13px; color: var(--faint); }
.sources a { color: var(--faint); }

.standard { background: var(--navy); color: #fff; border-radius: 18px; padding: 36px; display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 32px; align-items: center; }
.standard h2 { font-size: clamp(24px, 3vw, 32px); }
.standard p { color: var(--on-navy-muted); font-size: 17px; }
.standard ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.standard li { background: rgba(255,255,255,0.08); border-radius: 10px; padding: 12px 14px; font-weight: 500; }

.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.plan { border: 1px solid var(--line); border-radius: 16px; padding: 26px; display: flex; flex-direction: column; gap: 12px; background: #fff; }
.plan.featured { border: 2px solid var(--blue); }
.plan .price { font-size: 34px; font-weight: 600; letter-spacing: -0.02em; }
.plan .price small { font-size: 15px; color: var(--muted); font-weight: 500; }
.plan ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 15.5px; display: grid; gap: 6px; }
.plan .btn { margin-top: auto; }
.plan .fine { margin: -4px 0 0; font-size: 13px; color: var(--faint); }
.plans-note { margin-top: 16px; font-size: 14px; color: var(--faint); }

.faq { max-width: 820px; }
.faq details { border-bottom: 1px solid var(--line); padding: 16px 0; }
.faq summary { cursor: pointer; font-weight: 600; font-size: 18px; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--blue-ink); font-weight: 500; }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin-top: 10px; color: var(--muted); }

.contact { text-align: center; }
.contact p { color: var(--muted); max-width: 36em; margin: 12px auto 22px; }

/* ---------- footer ---------- */
footer { background: var(--navy); color: var(--on-navy-muted); padding-block: 44px; font-size: 14px; }
footer .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 32px; }
footer .brand { color: #fff; }
/* Lockup: mark on the left spanning both lines; "BY SHARESMILE" tucked under the wordmark,
   right-aligned to its right edge (CIS v4.2 endorsement, J 2026-09-24). The 5px margin leaves
   0.18em of clear space under the "p" descender — the same as brand/vector (BY_CLEAR_EM). */
.lockup { gap: 10px; align-items: center; }
.lockup img { width: 44px; }
.lockup-text { display: inline-flex; flex-direction: column; align-items: flex-end; line-height: 1; }
.lockup .wordmark { font-size: 26px; line-height: 1; }
.by { margin-top: 5px; font-size: 10.5px; letter-spacing: 0.16em; font-weight: 600; line-height: 1;
  color: rgba(255,255,255,0.62); white-space: nowrap; }
footer a { color: #fff; }
footer .legal { line-height: 1.6; }

/* ---------- plain pages (legal, 404) ---------- */
.plain { padding-block: 64px 88px; }
.plain .wrap { max-width: 820px; }
.plain h1 { font-size: clamp(32px, 5vw, 44px); font-weight: 600; margin-bottom: 8px; }
.plain h2 { font-size: 24px; margin: 36px 0 10px; }
.plain h3 { font-size: 17px; margin: 22px 0 6px; }
.plain p, .plain li { color: var(--muted); }
.plain .updated { color: var(--faint); font-size: 14px; margin-bottom: 28px; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero .wrap { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .cards, .plans { grid-template-columns: minmax(0, 1fr); }
  .eras { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .standard { grid-template-columns: minmax(0, 1fr); padding: 26px; }
  footer .wrap { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 860px) {
  .navburger { display: inline-flex; margin-left: auto; width: 44px; height: 44px; align-items: center; justify-content: center;
    border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-size: 20px; }
  .nav .links { display: none; position: absolute; top: 64px; left: 0; right: 0; background: #fff; flex-direction: column;
    align-items: flex-start; gap: 14px; padding: 18px 20px 22px; border-bottom: 1px solid var(--line); }
  .navtoggle:checked ~ .links { display: flex; }
}
@media (max-width: 620px) {
  body { font-size: 16px; }
  .hero { padding-block: 48px 56px; }
  .check .fields { grid-template-columns: minmax(0, 1fr); }
  .check .site, .check .go { grid-column: auto; }
  .check .go { width: 100%; }
  .eras { grid-template-columns: minmax(0, 1fr); }
  section.block { padding-block: 64px; }
}

/* ---------- free check result ---------- */
.result { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 14px; display: grid; gap: 10px; }
.result-head { font-size: 20px; font-weight: 600; }
.result-head.is-none { color: #A32D2D; }
.result-head.is-found { color: var(--ok); }
.result-best { font-weight: 600; color: var(--blue-ink); }
.result-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.result-table th, .result-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.result-table th { font-size: 12px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.05em; }
.result-table td.y { color: var(--ok); font-weight: 600; white-space: nowrap; }
.result-table td.n { color: var(--faint); white-space: nowrap; }
.result-sub { font-size: 15px; margin: 4px 0 0; }
.result-others { margin: 0; padding-left: 18px; color: var(--ink); font-size: 15px; }
.result-note, .result-msg { font-size: 13px; color: var(--faint); }
.result-msg { font-size: 15px; color: var(--ink); }
.result .btn { justify-self: start; }
.check .go:disabled { opacity: 0.6; cursor: progress; }

.rr-score { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.rr-score b { font-size: 26px; letter-spacing: -0.02em; }
.rr-grade { font-weight: 600; color: var(--blue-ink); }
.rr-gaps { margin: 0; padding-left: 18px; display: grid; gap: 8px; font-size: 15px; }
.rr-gaps span { display: block; color: var(--muted); font-size: 14px; }
.rr-warn { color: var(--wip); font-size: 14px; }

/* Guides: one question per page, prose width, nothing else competing. */
.article { padding-block: 56px 72px; }
.article .wrap { max-width: 46em; }
.article h1 { font-size: clamp(30px, 4.4vw, 44px); font-weight: 600; margin: 10px 0 12px; text-wrap: balance; }
.article .lede { font-size: 19px; color: var(--muted); margin-bottom: 28px; }
.article p { font-size: 17px; line-height: 1.7; margin: 0 0 18px; }
.article h2 { font-size: 22px; margin: 36px 0 12px; }
.article .crumbs { font-size: 14px; color: var(--muted); margin-bottom: 18px; }
.article .crumbs a { color: inherit; }
.article .refs { padding-left: 20px; font-size: 15px; color: var(--muted); display: grid; gap: 8px; }
.article .refs a { word-break: break-all; }
.article .meta { font-size: 14px; color: var(--faint); }
.guide-list { list-style: none; padding: 0; display: grid; gap: 14px; margin: 0 0 32px; }
.guide-list li { border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; background: #fff; }
.guide-list a { font-weight: 600; font-size: 18px; }
.guide-list p { margin: 6px 0 0; color: var(--muted); font-size: 15.5px; }
