/* SBTI static content pages — shared styles */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --pri: #5F33E1;
  --pri-soft: #F4F0FF;
  --ink: #24252C;
  --ink-2: #374151;
  --muted: #6E6A7C;
  --line: #EFF0F7;
}
html { scroll-behavior: smooth; }
body {
  font-family: "Pretendard Variable", "Pretendard", "Noto Sans JP", "Noto Sans TC", system-ui, sans-serif;
  background: #fff;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  line-height: 1.7;
}

/* top bar */
.top-bar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.back-btn {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  background: var(--pri); border-radius: 10px;
  border: none; cursor: pointer; text-decoration: none; flex-shrink: 0;
}
.back-btn svg { display: block; }
.top-bar-title { font-size: 16px; font-weight: 700; color: var(--ink); }
.top-bar .spacer { flex: 1; }
/* Language switcher — mirrors the SPA's LanguageSwitch component */
.lang-switch { position: relative; flex-shrink: 0; }
.lang-switch .lang-btn {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 6px 10px; border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.06); background: rgba(255,255,255,0.85);
  box-shadow: 0 4px 14px rgba(0,0,0,0.08); cursor: pointer;
  font: 600 11px/1 "Lexend Deca", system-ui; color: var(--ink); user-select: none;
}
.lang-switch .lang-btn:hover { background: #fff; }
.lang-switch .globe { font-size: 13px; line-height: 1; }
.lang-switch .lang-code { letter-spacing: 0.06em; }
.lang-switch .caret { font-size: 9px; opacity: 0.6; margin-left: 2px; }
.lang-switch .lang-menu {
  position: absolute; top: 100%; right: 0; margin-top: 6px; min-width: 140px;
  background: #fff; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.12);
  overflow: hidden; padding: 4px; display: none; z-index: 20;
}
.lang-switch.open .lang-menu { display: block; }
.lang-switch .lang-item {
  display: block; width: 100%; text-align: left; text-decoration: none;
  padding: 9px 12px; border-radius: 8px; font: 500 13px/1 "Lexend Deca", system-ui; color: var(--ink);
}
.lang-switch .lang-item:hover { background: var(--line); }
.lang-switch .lang-item.is-active { background: var(--pri-soft); color: var(--pri); font-weight: 700; }

/* layout */
.wrap { max-width: 720px; margin: 0 auto; padding: 8px 20px 80px; }
.hero { padding: 28px 0 8px; }
.hero .eyebrow { font-size: 13px; font-weight: 700; color: var(--pri); letter-spacing: .02em; }
.hero h1 { font-size: 30px; font-weight: 800; line-height: 1.25; margin: 8px 0 12px; letter-spacing: -.01em; }
.hero .lead { font-size: 16px; color: var(--ink-2); }

.section { margin-top: 36px; }
.section h2 {
  font-size: 21px; font-weight: 800; margin-bottom: 14px; letter-spacing: -.01em;
  display: flex; align-items: center; gap: 10px;
}
.section h2::before { content: ""; width: 5px; height: 20px; background: var(--pri); border-radius: 3px; }
.section h3 { font-size: 16px; font-weight: 700; margin: 20px 0 8px; }
.section p { font-size: 15px; color: var(--ink-2); margin-bottom: 12px; }
.section ul, .section ol { margin: 0 0 12px 20px; }
.section li { font-size: 15px; color: var(--ink-2); margin-bottom: 6px; }
a { color: var(--pri); }

.callout {
  margin: 18px 0; padding: 16px 18px;
  background: var(--pri-soft); border-left: 4px solid var(--pri);
  border-radius: 12px; font-size: 14px; color: var(--ink); line-height: 1.65;
}

/* tables */
.tbl { width: 100%; border-collapse: collapse; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; font-size: 14px; margin: 6px 0 16px; }
.tbl th { background: var(--pri-soft); padding: 11px 13px; font-weight: 700; color: var(--pri); text-align: left; }
.tbl td { padding: 11px 13px; color: var(--ink-2); vertical-align: top; border-top: 1px solid var(--line); }

/* type grid */
.type-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-top: 8px; }
.type-card {
  display: flex; align-items: center; gap: 12px;
  padding: 14px; border: 1px solid var(--line); border-radius: 14px;
  text-decoration: none; color: var(--ink); transition: box-shadow .15s, transform .15s;
}
.type-card:hover { box-shadow: 0 8px 24px rgba(95,51,225,.12); transform: translateY(-2px); }
.type-card .emoji { font-size: 30px; line-height: 1; flex-shrink: 0; }
.type-card .code { font-size: 13px; font-weight: 800; color: var(--pri); }
.type-card .nm { font-size: 14px; font-weight: 600; }

/* type detail */
.type-head { display: flex; align-items: center; gap: 16px; margin: 22px 0 10px; }
.type-head .emoji { font-size: 56px; line-height: 1; }
.type-head .code { font-size: 14px; font-weight: 800; color: var(--pri); }
.type-head h1 { font-size: 28px; font-weight: 800; margin: 2px 0 4px; }
.type-head .slogan { font-size: 15px; color: var(--muted); font-style: italic; }
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 4px; }
.tag { font-size: 13px; font-weight: 600; padding: 6px 12px; border-radius: 999px; }
.tag.good { background: #E8F5E9; color: #1B7A2E; }
.tag.bad { background: #FDECEC; color: #C0392B; }
.bar-row { display: flex; align-items: center; gap: 12px; margin: 8px 0; }
.bar-row .lab { width: 48px; font-size: 14px; font-weight: 700; color: var(--ink); flex-shrink: 0; }
.bar { flex: 1; height: 10px; background: var(--line); border-radius: 999px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--pri); border-radius: 999px; }
.bar-row .lvl { width: 40px; text-align: right; font-size: 13px; font-weight: 600; color: var(--muted); flex-shrink: 0; }

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 13px 22px; background: var(--pri); color: #fff;
  font-size: 15px; font-weight: 700; border-radius: 12px; text-decoration: none;
}
.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 13px 22px; background: var(--pri-soft); color: var(--pri);
  font-size: 15px; font-weight: 700; border-radius: 12px; text-decoration: none;
}

/* site footer */
.site-footer {
  margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line);
  text-align: center;
}
.site-footer nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; margin-bottom: 14px; }
.site-footer nav a { font-size: 13px; color: var(--muted); text-decoration: none; }
.site-footer nav a:hover { color: var(--pri); }
.site-footer .copy { font-size: 12px; color: var(--muted); }
