:root {
  color-scheme: light;
  --bg: #f4f7fb;
  --surface: #ffffff;
  --surface-2: #eef4ff;
  --ink: #152033;
  --muted: #5f6c80;
  --line: #dbe3ee;
  --brand: #2c5fe5;
  --brand-dark: #1d45b8;
  --accent: #0b7a72;
  --accent-soft: #e8f7f4;
  --danger: #b42318;
  --warning: #9a5b00;
  --shadow: 0 18px 48px rgba(29, 45, 76, 0.09);
  --radius: 20px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 8% 0%, rgba(44, 95, 229, 0.08), transparent 28rem),
    var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

img { max-width: 100%; height: auto; }
a { color: var(--brand-dark); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

.wrap { width: min(1160px, calc(100% - 32px)); margin-inline: auto; }
.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
.skip-link {
  position: fixed;
  left: 16px;
  top: 12px;
  z-index: 100;
  transform: translateY(-160%);
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  border-bottom: 1px solid rgba(219, 227, 238, 0.92);
  background: rgba(244, 247, 251, 0.9);
  backdrop-filter: blur(16px);
}
.nav {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 850;
  text-decoration: none;
  letter-spacing: -0.02em;
}
.brand img { width: 40px; height: 40px; }
.brand small { display: block; color: var(--muted); font-size: 11px; font-weight: 600; letter-spacing: 0; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: #46546a; font-size: 14px; font-weight: 700; text-decoration: none; }
.nav-actions { display: flex; align-items: center; gap: 10px; }

.compact-hero { padding: 42px 0 20px; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 32px;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--accent);
  font-size: 13px;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #1fa67a; box-shadow: 0 0 0 5px rgba(31, 166, 122, 0.12); }
h1, h2, h3 { line-height: 1.18; letter-spacing: -0.035em; }
h1 { margin: 10px 0 12px; font-size: clamp(34px, 5vw, 58px); }
.hero-copy { max-width: 760px; margin: 0; color: var(--muted); font-size: clamp(16px, 1.8vw, 19px); }
.privacy-note {
  min-width: 230px;
  padding: 14px 16px;
  border: 1px solid #bfe4dc;
  border-radius: 16px;
  background: var(--accent-soft);
  color: #0a635c;
  font-size: 13px;
  font-weight: 750;
}

.section { padding: 30px 0; }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 18px; }
.section-head h2 { margin: 0 0 5px; font-size: clamp(25px, 3vw, 34px); }
.section-head p { margin: 0; color: var(--muted); }
.filter-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.filter-button {
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: #48566c;
  font-weight: 750;
}
.filter-button[aria-pressed="true"] { border-color: var(--brand); background: var(--brand); color: #fff; }
.tool-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.tool-card {
  min-height: 132px;
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  box-shadow: 0 4px 16px rgba(29, 45, 76, 0.04);
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}
.tool-card:hover { transform: translateY(-3px); border-color: #93aceb; box-shadow: var(--shadow); }
.tool-card[aria-pressed="true"] { border-color: var(--brand); background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--brand); }
.tool-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  margin-bottom: 13px;
  border-radius: 10px;
  background: #edf2ff;
  color: var(--brand-dark);
  font-size: 18px;
  font-weight: 900;
}
.tool-card strong { display: block; margin-bottom: 4px; font-size: 16px; }
.tool-card small { display: block; color: var(--muted); line-height: 1.45; }

.workspace {
  margin: 18px 0 22px;
  padding: clamp(18px, 3vw, 30px);
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.workspace-head { display: flex; justify-content: space-between; align-items: start; gap: 20px; }
.workspace-head h2 { margin: 3px 0 0; font-size: 27px; }
.workspace-kicker { color: var(--brand); font-size: 12px; font-weight: 850; text-transform: uppercase; letter-spacing: 0.08em; }
.button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 13px;
  font-weight: 800;
  text-decoration: none;
}
.button-primary { background: var(--brand); color: #fff; box-shadow: 0 9px 20px rgba(44, 95, 229, 0.2); }
.button-primary:hover { background: var(--brand-dark); }
.button-secondary { border-color: var(--line); background: var(--surface); color: var(--ink); }
.button:disabled { cursor: not-allowed; opacity: 0.55; }
.drop-zone {
  position: relative;
  min-height: 172px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  margin-top: 20px;
  padding: 24px;
  border: 2px dashed #aab7ca;
  border-radius: 18px;
  background: #f8fafc;
  text-align: center;
}
.drop-zone.is-dragging { border-color: var(--brand); background: var(--surface-2); }
.drop-zone input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.drop-zone b { font-size: 18px; }
.drop-zone p { margin: 0; color: var(--muted); }
.drop-symbol { color: var(--brand); font-size: 31px; line-height: 1; }
.file-list { display: grid; gap: 8px; margin-top: 14px; }
.file-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 12px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 12px; }
.file-row b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-row small { color: var(--muted); }
.file-type { padding: 4px 8px; border-radius: 999px; background: #edf2ff; color: #304da4; font-size: 11px; font-weight: 850; }
.remove-file { width: 36px; height: 36px; border: 0; border-radius: 10px; background: #fff0ee; color: var(--danger); font-weight: 900; }
.options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 16px; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: #fbfcfe; }
.field { display: grid; gap: 7px; }
.field-full { grid-column: 1 / -1; }
.field label, .field legend { color: #26354b; font-size: 14px; font-weight: 800; }
.field input, .field select, .field textarea { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #c7d1df; border-radius: 11px; background: #fff; color: var(--ink); }
.field textarea { min-height: 86px; resize: vertical; }
.hint { color: var(--muted); font-size: 12px; line-height: 1.5; }
.warning { padding: 11px 13px; border-radius: 11px; background: #fff6e5; color: #7b4a00; font-size: 12px; }
.workspace-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 13px; margin-top: 18px; }
.status { color: var(--muted); font-size: 14px; }
.status.is-error { color: var(--danger); }
.result-panel { display: none; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 16px; padding: 16px; border: 1px solid #bfe4dc; border-radius: 16px; background: var(--accent-soft); }
.result-panel.is-visible { display: grid; }
.result-metric small { display: block; color: #41716c; }
.result-metric strong { font-size: 20px; }

.ad-reservation {
  min-height: 112px;
  display: grid;
  place-items: center;
  margin: 30px 0;
  padding: 18px;
  border: 1px dashed #aeb9c9;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.5);
  color: var(--muted);
  text-align: center;
}
.ad-reservation strong { display: block; color: #46546a; font-size: 13px; }
.ad-reservation small { font-size: 12px; }

.feature-grid, .faq-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.feature-card, .faq-card { padding: 20px; border: 1px solid var(--line); border-radius: 17px; background: var(--surface); }
.feature-card h3, .faq-card h3 { margin: 8px 0 7px; font-size: 18px; }
.feature-card p, .faq-card p { margin: 0; color: var(--muted); font-size: 14px; }
.feature-mark { color: var(--accent); font-weight: 900; }
.support-panel { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: center; padding: 26px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); }
.support-panel h2 { margin: 0 0 8px; }
.support-panel p { max-width: 680px; margin: 0; color: var(--muted); }
.qr-row { display: flex; gap: 14px; }
.qr-item { width: 126px; text-align: center; }
.qr-frame { width: 126px; height: 126px; display: grid; place-items: center; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.qr-frame img { width: 112px; height: 112px; object-fit: contain; }
.qr-item b { display: block; margin-top: 6px; font-size: 12px; }

.site-footer { margin-top: 44px; border-top: 1px solid var(--line); background: #edf1f7; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 32px; padding: 34px 0; }
.footer-grid h2, .footer-grid h3 { margin: 0 0 8px; font-size: 15px; }
.footer-grid p { margin: 0; color: var(--muted); font-size: 13px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.footer-links a { color: #48566c; font-size: 13px; }
.footer-bottom { padding: 13px 0 22px; color: var(--muted); font-size: 12px; }

.info-main { padding: 48px 0; }
.info-shell { display: grid; grid-template-columns: minmax(0, 760px) 260px; gap: 48px; align-items: start; }
.info-article { padding: clamp(22px, 4vw, 42px); border: 1px solid var(--line); border-radius: 24px; background: var(--surface); box-shadow: var(--shadow); }
.info-article h1 { margin-top: 0; font-size: clamp(32px, 5vw, 48px); }
.info-article h2 { margin-top: 34px; font-size: 24px; }
.info-article h3 { margin-top: 24px; font-size: 18px; }
.info-article p, .info-article li { color: #47566c; }
.info-article li + li { margin-top: 8px; }
.updated { color: var(--muted); font-size: 13px; }
.info-aside { position: sticky; top: 96px; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.info-aside h2 { margin: 0 0 8px; font-size: 16px; }
.info-aside a { display: block; padding: 7px 0; color: #48566c; font-size: 14px; }
.notice { padding: 14px 16px; border-left: 4px solid var(--accent); border-radius: 10px; background: var(--accent-soft); color: #155e58; }
.error-page { min-height: 70vh; display: grid; place-items: center; text-align: center; }
.error-code { color: var(--brand); font-size: clamp(70px, 15vw, 150px); font-weight: 900; line-height: 1; }

:focus-visible { outline: 3px solid #f0a830; outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

@media (max-width: 920px) {
  .nav-links { display: none; }
  .hero-grid, .support-panel { grid-template-columns: 1fr; }
  .privacy-note { width: fit-content; min-width: 0; }
  .tool-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .feature-grid, .faq-grid { grid-template-columns: 1fr 1fr; }
  .info-shell { grid-template-columns: 1fr; }
  .info-aside { position: static; }
}

@media (max-width: 680px) {
  .wrap { width: min(100% - 22px, 1160px); }
  .nav { min-height: 62px; }
  .brand small { display: none; }
  .compact-hero { padding-top: 30px; }
  .section-head { align-items: start; flex-direction: column; }
  .tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tool-card { min-height: 124px; padding: 14px; }
  .workspace { padding: 15px; border-radius: 18px; }
  .workspace-head { align-items: center; }
  .options { grid-template-columns: 1fr; padding: 14px; }
  .field-full { grid-column: auto; }
  .file-row { grid-template-columns: minmax(0, 1fr) auto; }
  .file-type { display: none; }
  .result-panel, .feature-grid, .faq-grid, .footer-grid { grid-template-columns: 1fr; }
  .qr-row { width: 100%; justify-content: center; }
  .footer-grid { gap: 22px; }
}

@media (max-width: 390px) {
  .brand span { font-size: 14px; }
  .nav-actions { gap: 6px; }
  .tool-card small { font-size: 11px; }
  .workspace-actions .button { width: 100%; }
}

/* Shared PocketPlay family styling: sturdy navy outlines, cream panels,
   playful offset shadows, and compact three-language controls. */
:root {
  --bg: #b7dcff;
  --surface: #fffdf0;
  --surface-2: #fff7d9;
  --ink: #10243e;
  --muted: #51667a;
  --line: #10243e;
  --brand: #3268ee;
  --brand-dark: #214eaf;
  --accent: #28776f;
  --accent-soft: #d9f2e9;
  --cream-deep: #fff7d9;
  --lime: #bde85c;
  --yellow: #ffd568;
  --pink: #f5b9cf;
  --blue: #b7dcff;
  --mint: #98dcd3;
  --panel-shadow: 6px 7px 0 rgba(16, 36, 62, 0.18);
  --shadow: 6px 7px 0 rgba(16, 36, 62, 0.18);
}

body {
  overflow-x: hidden;
  background-color: var(--bg);
  background-image:
    linear-gradient(rgba(16, 36, 62, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 36, 62, 0.055) 1px, transparent 1px);
  background-size: 40px 40px;
  color: var(--ink);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", "PingFang SC", "Microsoft YaHei", monospace;
  font-synthesis: none;
}

.site-header {
  position: relative;
  top: auto;
  border: 0;
  background: transparent;
  backdrop-filter: none;
}

.nav {
  min-height: 78px;
  margin-top: 14px;
  padding: 10px 16px;
  border: 3px solid var(--ink);
  border-radius: 19px;
  background: var(--surface);
  box-shadow: var(--panel-shadow);
}

.brand { font-size: 21px; letter-spacing: -0.04em; }
.brand img { width: 48px; height: 48px; border-radius: 10px; }
.brand small { color: var(--muted); font-size: 10px; }
.nav-links { gap: 5px; }
.nav-links a { padding: 9px 11px; border-radius: 10px; color: var(--ink); font-size: 13px; }
.nav-links a:hover { background: var(--cream-deep); }

.language-switch {
  display: flex;
  gap: 3px;
  margin-left: 8px;
  padding-left: 10px;
  border-left: 2px solid #d7d9cb;
}

.language-switch button {
  min-width: 38px;
  min-height: 38px;
  padding: 5px 7px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.language-switch button:hover { background: var(--cream-deep); }
.language-switch button.is-active { background: var(--ink); color: #fff; }

.compact-hero { padding: 26px 0 10px; }
.hero-grid {
  padding: clamp(24px, 4vw, 42px);
  border: 3px solid var(--ink);
  border-radius: 24px;
  outline: 1px dashed rgba(16, 36, 62, 0.42);
  outline-offset: -10px;
  background: var(--surface);
  box-shadow: 8px 9px 0 rgba(16, 36, 62, 0.18);
}

.eyebrow { color: var(--accent); }
.eyebrow::before { background: #e4aa32; box-shadow: 0 0 0 4px rgba(228, 170, 50, 0.18); }
h1, h2, h3 { color: var(--ink); font-weight: 900; }
h1 { letter-spacing: -0.065em; }
.hero-copy { color: var(--muted); font-weight: 650; }
.privacy-note {
  padding: 13px 15px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  background: var(--yellow);
  color: var(--ink);
  box-shadow: 3px 4px 0 rgba(16, 36, 62, 0.16);
}

.section { padding: 24px 0; }
.section-head p { color: var(--muted); font-weight: 650; }
.filter-row { gap: 10px; }
.filter-button {
  min-height: 43px;
  border: 3px solid var(--ink);
  border-radius: 13px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: 3px 4px 0 rgba(16, 36, 62, 0.16);
}
.filter-button[aria-pressed="true"] {
  transform: translate(2px, 2px);
  border-color: var(--ink);
  background: var(--yellow);
  color: var(--ink);
  box-shadow: 1px 2px 0 rgba(16, 36, 62, 0.16);
}

.tool-grid { gap: 14px; }
.tool-card {
  min-height: 136px;
  border: 3px solid var(--ink);
  border-radius: 16px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: 4px 5px 0 rgba(16, 36, 62, 0.16);
}
.tool-card:hover { transform: translate(2px, 2px); border-color: var(--ink); box-shadow: 2px 3px 0 rgba(16, 36, 62, 0.16); }
.tool-card[aria-pressed="true"] { border-color: var(--ink); background: var(--surface-2); box-shadow: inset 0 0 0 2px var(--brand), 4px 5px 0 rgba(16, 36, 62, 0.16); }
.tool-icon { border: 2px solid var(--ink); border-radius: 9px; background: var(--blue); color: var(--ink); }
.tool-card:nth-child(5n + 2) .tool-icon { background: var(--lime); }
.tool-card:nth-child(5n + 3) .tool-icon { background: var(--yellow); }
.tool-card:nth-child(5n + 4) .tool-icon { background: var(--pink); }
.tool-card:nth-child(5n + 5) .tool-icon { background: var(--mint); }
.tool-card small { color: var(--muted); font-weight: 650; }

.workspace {
  border: 3px solid var(--ink);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: 7px 8px 0 rgba(16, 36, 62, 0.18);
}
.workspace-kicker { color: var(--accent); }
.button {
  border: 3px solid var(--ink);
  border-radius: 12px;
  box-shadow: 3px 4px 0 rgba(16, 36, 62, 0.18);
}
.button:hover:not(:disabled) { transform: translate(1px, 1px); box-shadow: 2px 3px 0 rgba(16, 36, 62, 0.18); }
.button-primary, .button-primary:hover { background: var(--lime); color: var(--ink); }
.button-secondary { border-color: var(--ink); background: var(--surface); color: var(--ink); }
.drop-zone { border: 3px dashed var(--ink); border-radius: 16px; background: #f7fbff; }
.drop-zone.is-dragging { border-color: var(--ink); background: var(--blue); }
.file-row { border: 2px solid var(--ink); background: #fff; }
.file-type { border: 1px solid var(--ink); background: var(--blue); color: var(--ink); }
.options { border: 2px solid var(--ink); background: #fffdf7; }
.field input, .field select, .field textarea { border: 2px solid var(--ink); }
.warning { border: 1px solid #ae7800; background: #fff0b6; color: #634300; }
.result-panel { border: 2px solid var(--ink); background: var(--mint); }

.ad-reservation {
  border: 3px dashed var(--ink);
  border-radius: 17px;
  background: rgba(255, 253, 240, 0.82);
  color: var(--muted);
}
.ad-reservation strong {
  width: fit-content;
  margin: 0 auto 5px;
  padding: 5px 8px;
  border: 2px solid var(--ink);
  border-radius: 8px;
  background: var(--yellow);
  color: var(--ink);
}

.feature-card, .faq-card, .support-panel {
  border: 3px solid var(--ink);
  background: var(--surface);
  box-shadow: 4px 5px 0 rgba(16, 36, 62, 0.16);
}
.feature-card:nth-child(2) { background: #f3ffe0; }
.feature-card:nth-child(3) { background: #fff1f6; }
.feature-card p, .faq-card p, .support-panel p { color: var(--muted); font-weight: 600; }
.qr-frame { border: 3px solid var(--ink); background: #fff; box-shadow: 3px 4px 0 rgba(16, 36, 62, 0.16); }

.site-footer { border: 0; background: transparent; }
.footer-grid {
  margin-top: 24px;
  padding: 28px;
  border: 3px solid var(--ink);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: 6px 7px 0 rgba(16, 36, 62, 0.18);
}
.footer-grid p, .footer-links a, .footer-bottom { color: var(--muted); font-weight: 650; }
.footer-bottom { padding-top: 20px; }

.info-article, .info-aside {
  border: 3px solid var(--ink);
  background: var(--surface);
  box-shadow: 6px 7px 0 rgba(16, 36, 62, 0.18);
}
.info-article p, .info-article li, .info-aside a { color: var(--muted); font-weight: 600; }
.notice { border: 2px solid var(--ink); border-left-width: 8px; background: var(--mint); color: var(--ink); }
.error-code { color: var(--brand-dark); text-shadow: 5px 6px 0 rgba(16, 36, 62, 0.14); }

@media (max-width: 680px) {
  .nav { min-height: 66px; padding: 8px 10px; border-radius: 15px; }
  .brand { font-size: 16px; }
  .brand img { width: 42px; height: 42px; }
  .language-switch { gap: 1px; margin-left: auto; padding-left: 7px; }
  .language-switch button { min-width: 33px; min-height: 35px; padding: 4px; font-size: 11px; }
  .hero-grid { padding: 24px 20px; border-radius: 18px; }
  .privacy-note { width: 100%; }
  .tool-card { min-height: 128px; }
  .footer-grid { padding: 22px; }
}
