/* IQ WORLD RANKING — ダークネイビー × ゴールド。左右は論理プロパティ（inline-start/end）で書き、RTL に対応する */
:root {
  --bg: #070f24;
  --bg-2: #0b1530;
  --panel: #101d3d;
  --panel-2: #142449;
  --line: #22355f;
  --text: #e9eefb;
  --muted: #9fb0d3;
  --gold: #d4af37;
  --gold-2: #f3d77a;
  --blue: #4c8dff;
  --blue-2: #8db7ff;
  --ok: #3ecf8e;
  --warn: #f5b84b;
  --err: #ff6b6b;
  --silver: #c9d1df;
  --bronze: #d08a52;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .35);
  --font: "Segoe UI", "Hiragino Sans", "Noto Sans JP", "Noto Sans", "PingFang SC", "Microsoft YaHei", "Malgun Gothic", "Noto Sans Thai", "Noto Sans Arabic", "Noto Sans Devanagari", system-ui, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font); color: var(--text); line-height: 1.65; font-size: 16px;
  background: radial-gradient(1200px 600px at 80% -10%, rgba(76, 141, 255, .14), transparent 60%),
              radial-gradient(900px 500px at -10% 10%, rgba(212, 175, 55, .08), transparent 60%), var(--bg);
  min-height: 100vh;
}
a { color: var(--blue-2); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 3px solid var(--gold-2); outline-offset: 2px; border-radius: 4px; }
img, svg { max-width: 100%; }
.container { width: 100%; max-width: 1180px; margin-inline: auto; padding-inline: 16px; }
.skip-link { position: absolute; inset-inline-start: -9999px; top: 0; background: var(--gold); color: #000; padding: 8px 12px; z-index: 100; }
.skip-link:focus { inset-inline-start: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ヘッダー */
.site-header { position: sticky; top: 0; z-index: 30; background: rgba(7, 15, 36, .86); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 16px; min-height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 600; letter-spacing: .06em; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 32px; height: 32px; color: var(--blue-2); }
.brand-text b { color: var(--gold); }
.main-nav { display: flex; align-items: center; gap: 18px; margin-inline-start: auto; flex-wrap: wrap; }
.main-nav a { color: var(--text); font-size: 15px; }
.lang-switch { position: relative; }
.btn, .tab { white-space: nowrap; }
.lang-switch summary { white-space: nowrap; list-style: none; cursor: pointer; display: flex; align-items: center; gap: 6px; padding: 6px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); font-size: 14px; }
.lang-switch summary::-webkit-details-marker { display: none; }
.lang-switch ul { position: absolute; inset-inline-end: 0; top: calc(100% + 6px); margin: 0; padding: 6px; list-style: none; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); max-height: 60vh; overflow: auto; min-width: 180px; z-index: 40; }
.lang-switch li a { display: block; padding: 7px 10px; border-radius: 8px; color: var(--text); }
.lang-switch li a:hover, .lang-switch li a[aria-current] { background: var(--panel-2); text-decoration: none; }
.sub-nav { border-bottom: 1px solid var(--line); background: var(--bg-2); }
.sub-nav-inner { display: flex; gap: 18px; overflow-x: auto; padding-block: 8px; font-size: 14px; white-space: nowrap; }
.sub-nav a { color: var(--muted); }
.inline { display: inline; margin: 0; }
.link-btn { background: none; border: 0; color: var(--muted); cursor: pointer; font: inherit; padding: 0; }
.link-btn:hover { color: var(--text); text-decoration: underline; }

.main { padding-block: 28px 64px; min-height: 60vh; }
.site-footer { border-top: 1px solid var(--line); background: var(--bg-2); padding-block: 28px; color: var(--muted); font-size: 14px; }
.footer-inner nav { display: flex; gap: 18px; flex-wrap: wrap; margin-block: 10px; }
.footer-inner a { color: var(--muted); }
/* 協力（Wresport）のロゴ：白地のロゴなので白い台の上に置く */
.footer-partner { display: inline-block; background: #fff; border-radius: 10px; padding: 8px 14px; margin-bottom: 12px; line-height: 0; transition: transform .15s; }
.footer-partner:hover { transform: translateY(-2px); }
.footer-partner img { width: 200px; max-width: 100%; height: auto; }
/* サイトの一番下のバナー */
.footer-banner { max-width: 1100px; margin: 22px auto 0; padding-inline: 16px; }
.footer-banner img { display: block; width: 100%; height: auto; border-radius: 12px; }
.disclaimer { max-width: 820px; }

/* 共通部品 */
h1, h2, h3 { line-height: 1.3; margin-block: 0 .6em; }
h1 { font-size: clamp(26px, 4vw, 38px); }
h2 { font-size: clamp(20px, 2.6vw, 26px); }
h3 { font-size: 18px; }
.lead { color: var(--muted); font-size: 17px; max-width: 760px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.card { background: linear-gradient(180deg, var(--panel), var(--bg-2)); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card + .card { margin-top: 18px; }
.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.stack > * + * { margin-top: 18px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 20px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; transition: transform .12s ease, background .2s ease; }
.btn:hover { text-decoration: none; background: #1a2d59; }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-gold { background: linear-gradient(135deg, var(--gold), #b38b1d); color: #1a1405; border-color: transparent; }
.btn-gold:hover { background: linear-gradient(135deg, var(--gold-2), var(--gold)); }
.btn-blue { background: linear-gradient(135deg, var(--blue), #2e64d6); border-color: transparent; color: #fff; }
.btn-lg { min-height: 56px; font-size: 18px; padding-inline: 32px; border-radius: 14px; }
.btn-sm { min-height: 36px; padding: 6px 14px; font-size: 14px; }
.btn-danger { background: #5b1d27; border-color: #8c2c3b; }
.alert { padding: 12px 16px; border-radius: 12px; margin-bottom: 18px; border: 1px solid; }
.alert-ok { background: rgba(62, 207, 142, .12); border-color: rgba(62, 207, 142, .5); }
.alert-error { background: rgba(255, 107, 107, .12); border-color: rgba(255, 107, 107, .5); }
.alert-warn { background: rgba(245, 184, 75, .12); border-color: rgba(245, 184, 75, .5); }
.alert-info { background: rgba(76, 141, 255, .12); border-color: rgba(76, 141, 255, .45); }
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--panel-2); border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.badge-gold { color: #1a1405; background: var(--gold); border-color: transparent; }
.badge-blue { color: #fff; background: #2e64d6; border-color: transparent; }
.badge-warn { color: #1a1405; background: var(--warn); border-color: transparent; }
.fi { border-radius: 3px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .12); }

/* フォーム */
form.stack label, .field label { display: block; font-weight: 600; margin-bottom: 6px; }
.field { margin-bottom: 16px; }
input[type=text], input[type=password], input[type=number], input[type=search], input[type=file], select, textarea {
  width: 100%; min-height: 46px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line); background: #0a1430; color: var(--text); font: inherit;
}
textarea { min-height: 120px; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); outline: none; box-shadow: 0 0 0 3px rgba(76, 141, 255, .25); }
.hint { color: var(--muted); font-size: 13px; margin-top: 4px; }
.check { display: flex; gap: 10px; align-items: flex-start; }
.check input { width: 20px; height: 20px; margin-top: 3px; }
.auth-card { max-width: 480px; margin-inline: auto; }

/* トップ */
.hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 32px; align-items: center; padding-block: 24px 40px; }
.hero h1 { font-size: clamp(32px, 5.4vw, 56px); letter-spacing: .01em; }
.hero h1 .gold { background: linear-gradient(90deg, var(--gold-2), var(--gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }
.globe { position: relative; aspect-ratio: 1; max-width: 420px; margin-inline: auto; width: 100%; }
.globe svg { width: 100%; height: 100%; }
.globe .orbit { animation: spin 60s linear infinite; transform-origin: 50% 50%; }
@keyframes spin { to { transform: rotate(360deg); } }
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px; text-align: center; }
.stat b { display: block; font-size: 26px; color: var(--gold-2); font-variant-numeric: tabular-nums; }
.stat span { color: var(--muted); font-size: 13px; }

/* 表彰台 */
.podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; gap: 14px; align-items: end; margin-block: 18px 6px; }
.podium-item { text-align: center; padding: 18px 10px; border-radius: 16px; border: 1px solid var(--line); background: var(--panel); position: relative; }
.podium-item .medal { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; margin: -40px auto 8px; font-weight: 800; color: #1b1405; box-shadow: var(--shadow); }
.podium-1 { padding-block: 28px; border-color: var(--gold); box-shadow: 0 0 0 1px rgba(212, 175, 55, .4), 0 20px 40px rgba(212, 175, 55, .15); }
.podium-1 .medal { background: radial-gradient(circle at 30% 30%, #fff3c4, var(--gold)); width: 54px; height: 54px; }
.podium-2 .medal { background: radial-gradient(circle at 30% 30%, #fff, var(--silver)); }
.podium-3 .medal { background: radial-gradient(circle at 30% 30%, #ffd9bd, var(--bronze)); }
.podium-name { font-weight: 700; margin-top: 4px; word-break: break-all; }
.podium-score { font-size: 28px; font-weight: 800; color: var(--gold-2); font-variant-numeric: tabular-nums; }

/* ランキング表 */
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { padding: 12px 14px; text-align: start; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { background: var(--bg-2); color: var(--muted); font-size: 13px; font-weight: 600; position: sticky; top: 0; }
tbody tr:hover { background: rgba(76, 141, 255, .06); }
td.num, th.num { text-align: end; }
.rank-cell { font-weight: 800; width: 64px; }
.rank-1 td { background: linear-gradient(90deg, rgba(212, 175, 55, .22), transparent 70%); }
.rank-2 td { background: linear-gradient(90deg, rgba(201, 209, 223, .16), transparent 70%); }
.rank-3 td { background: linear-gradient(90deg, rgba(208, 138, 82, .18), transparent 70%); }
.top10 .rank-cell { color: var(--gold-2); }
tr.me td { background: rgba(76, 141, 255, .1); }
tr.me td:first-child { box-shadow: inset 3px 0 0 var(--blue); }
[dir=rtl] tr.me td:first-child { box-shadow: inset -3px 0 0 var(--blue); }
.delta-up { color: var(--ok); } .delta-down { color: var(--err); } .delta-same { color: var(--muted); }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.tab { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.tab[aria-current=page] { background: var(--blue); color: #fff; border-color: transparent; }
.tab:hover { text-decoration: none; color: var(--text); }
.filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; margin-bottom: 14px; align-items: end; }
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }
.pagination a, .pagination span { min-width: 40px; min-height: 40px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 10px; color: var(--text); padding-inline: 8px; }
.pagination [aria-current] { background: var(--blue); border-color: transparent; }

/* 結果 */
.score-hero { text-align: center; padding-block: 18px; }
.score-hero .iq { font-size: clamp(64px, 12vw, 112px); font-weight: 800; line-height: 1; color: var(--gold-2); text-shadow: 0 0 28px rgba(212, 175, 55, .35); font-variant-numeric: tabular-nums; animation: rise .8s ease both; }
/* 透明度は変えない（アニメーションが止まっても数字が必ず見えるように） */
@keyframes rise { from { transform: translateY(10px) scale(.96); } to { transform: none; } }
.ci { color: var(--muted); }
.kpi { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 12px; }
.kpi div { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 14px; }
.kpi b { display: block; font-size: 24px; font-variant-numeric: tabular-nums; }
.kpi span { color: var(--muted); font-size: 13px; }
.bar { height: 10px; background: #0a1430; border-radius: 999px; overflow: hidden; border: 1px solid var(--line); }
.bar > i { display: block; height: 100%; background: linear-gradient(90deg, var(--blue), var(--blue-2)); border-radius: 999px; }
.chart-box { position: relative; height: 300px; }
.nodata { display: grid; place-items: center; min-height: 160px; color: var(--muted); border: 1px dashed var(--line); border-radius: 12px; text-align: center; padding: 16px; }
.title-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: linear-gradient(135deg, rgba(212, 175, 55, .25), rgba(212, 175, 55, .08)); border: 1px solid rgba(212, 175, 55, .55); color: var(--gold-2); font-weight: 600; font-size: 14px; margin: 3px; }
.title-chip.expired { opacity: .55; border-style: dashed; filter: grayscale(.6); }

/* 受験画面（集中モード：装飾を最小限に） */
.focus-mode .main { padding-top: 12px; }
.test-shell { max-width: 860px; margin-inline: auto; }
.test-top { display: flex; align-items: center; gap: 12px; position: sticky; top: 60px; background: var(--bg); padding-block: 10px; z-index: 5; }
.progress { flex: 1; height: 8px; border-radius: 999px; background: #0a1430; border: 1px solid var(--line); overflow: hidden; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--gold-2)); transition: width .3s ease; }
.timer { font-variant-numeric: tabular-nums; font-weight: 700; min-width: 72px; text-align: end; }
.timer.low { color: var(--warn); }
.q-prompt { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 18px; margin-block: 12px 16px; }
.q-figure { background: #fff; border-radius: 14px; padding: 10px; display: flex; justify-content: center; margin-bottom: 16px; }
.q-figure img { max-height: 46vh; width: auto; }
.options { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }
.options.text-options { grid-template-columns: 1fr; }
.option { display: flex; align-items: center; gap: 12px; padding: 12px 14px; min-height: 56px; border-radius: 14px; border: 2px solid var(--line); background: var(--panel); color: var(--text); cursor: pointer; font: inherit; text-align: start; transition: border-color .15s ease, background .15s ease; }
.option:hover { border-color: var(--blue); }
.option[aria-pressed=true] { border-color: var(--gold); background: rgba(212, 175, 55, .12); }
.option .key { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--panel-2); font-weight: 800; }
.option img { background: #fff; border-radius: 10px; width: 100%; max-width: 160px; height: auto; }
.option.has-img { flex-direction: column; }
.test-actions { display: flex; gap: 12px; margin-top: 18px; justify-content: space-between; flex-wrap: wrap; }
.test-actions .btn { flex: 1; min-width: 140px; }
.net-status { position: fixed; inset-inline: 16px; bottom: 16px; z-index: 50; }
.skeleton { background: linear-gradient(90deg, var(--panel) 25%, var(--panel-2) 50%, var(--panel) 75%); background-size: 200% 100%; animation: shimmer 1.4s infinite; border-radius: 12px; min-height: 160px; }
@keyframes shimmer { to { background-position: -200% 0; } }

.prose { max-width: 820px; }
.prose h2 { margin-top: 1.6em; }
.code-box { font-family: ui-monospace, Consolas, monospace; font-size: clamp(20px, 5vw, 30px); letter-spacing: .08em; text-align: center; background: #0a1430; border: 2px dashed var(--gold); border-radius: 14px; padding: 18px; user-select: all; word-break: break-all; }
.ad-slot { margin-block: 22px; min-height: 0; text-align: center; }
/* 毎日の世界同時チャレンジ・サバイバル */
.play-shell { max-width: 860px; margin-inline: auto; }
.play-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.play-title { font-weight: 800; }
.play-status { font-variant-numeric: tabular-nums; letter-spacing: .5px; }
.play-timebar { height: 6px; border-radius: 4px; background: var(--panel-2); overflow: hidden; margin-bottom: 12px; }
.play-timebar i { display: block; height: 100%; width: 100%; background: var(--gold); transition: width .25s linear; }
.play-timebar i.low { background: var(--warn); }
.play-figure { background: #fff; border-radius: 14px; padding: 10px; display: flex; justify-content: center; margin-bottom: 16px; overflow-x: auto; }
.play-figure svg { max-width: 100%; height: auto; max-height: 46vh; }
.opt-figure { background: #fff; border-radius: 10px; width: 100%; display: flex; justify-content: center; padding: 4px; }
.opt-figure svg { width: 100%; max-width: 160px; height: auto; }
.opt-text { font-size: 17px; }
#play-card { position: relative; }
.play-flash { position: absolute; inset: 0; display: grid; place-items: center; font-size: 34px; font-weight: 900; border-radius: inherit; background: rgba(11, 21, 48, .72); }
.play-flash.ok { color: #7ee2a1; }
.play-flash.ng { color: #ff8a8a; }
.play-hero { max-width: 760px; margin-inline: auto; margin-bottom: 18px; }
.play-squares { display: flex; gap: 8px; margin-block: 8px; }
.play-squares .sq { width: 46px; height: 46px; border-radius: 10px; display: grid; place-items: center; font-weight: 900; font-size: 20px; color: #0b1530; }
.play-squares .sq.ok { background: #5fd38d; }
.play-squares .sq.ng { background: #ff7b7b; }
.play-big { font-size: 28px; font-weight: 900; margin: 6px 0; }
.play-share-text { background: var(--panel-2); border-radius: 10px; padding: 10px 12px; white-space: pre-wrap; font-size: 15px; }
/* 脳のタイプ */
.brain-card { margin-top: 18px; }
.brain-head { display: flex; gap: 18px; align-items: center; }
.brain-mascot { width: 140px; height: 140px; border-radius: 18px; flex: none; object-fit: cover; box-shadow: 0 6px 24px rgba(0, 0, 0, .35); }
.brain-name { font-size: 28px; margin: 2px 0 6px; color: var(--gold); }
.brain-axes { display: grid; gap: 8px; margin-block: 14px 8px; }
.brain-axis { display: grid; grid-template-columns: 80px 1fr 44px; align-items: center; gap: 10px; }
.brain-axis .bar { height: 10px; border-radius: 6px; background: var(--panel-2); overflow: hidden; }
.brain-axis .bar i { display: block; height: 100%; background: var(--blue); }
.brain-axis.top .bar i { background: var(--gold); }
.brain-axis b { text-align: end; font-variant-numeric: tabular-nums; }
@media (max-width: 560px) { .brain-head { flex-direction: column; text-align: center; } .brain-mascot { width: 120px; height: 120px; } }
/* シェア */
.share-kind { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-block: 12px; }
.share-buttons { display: flex; flex-wrap: wrap; gap: 8px; margin-block: 14px; }
.share-btn { min-height: 40px; }
.share-x { background: #000; color: #fff; }
.share-facebook { background: #1877f2; color: #fff; }
.share-line { background: #06c755; color: #fff; }
.share-whatsapp { background: #25d366; color: #0b1530; }
.share-telegram { background: #229ed9; color: #fff; }
.share-copy { border: 1px dashed var(--muted); }
.share-list { list-style: none; padding: 0; margin: 8px 0; }
.share-list li { padding: 4px 0; border-bottom: 1px solid rgba(255, 255, 255, .06); }
.share-list li[data-state="granted"] { color: #7ee2a1; }
.share-list li[data-state="pending"] { color: var(--muted); }
.share-copy-out { word-break: break-all; }
.share-toast { position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%); z-index: 50; background: #1f6f43; color: #fff; padding: 12px 18px; border-radius: 10px; box-shadow: 0 6px 24px rgba(0, 0, 0, .35); max-width: calc(100vw - 32px); }
/* 336px 幅の広告が狭い画面の余白に収まらないので、スマホでは画面幅いっぱいに広げる（はみ出し・横スクロールを防ぐ） */
@media (max-width: 420px) { .ad-slot { margin-inline: calc(50% - 50vw); } }
.ad-label { font-size: 11px; color: var(--muted); }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .globe { max-width: 260px; order: -1; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .main-nav { display: none; }            /* スマホは下部ナビで同じ機能を提供 */
  .lang-switch { margin-inline-start: auto; }
  .lang-switch summary span { max-width: 6.5em; overflow: hidden; text-overflow: ellipsis; }
  .brand-text { font-size: 15px; }
  .filters { grid-template-columns: 1fr 1fr; }
  .podium { grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
  .podium-score { font-size: 20px; }
  th, td { padding: 10px 10px; }
  .hide-sm { display: none; }
  .test-top { top: 60px; }
  .q-prompt { font-size: 17px; }
}
/* スマートフォン：片手で届く下部ナビ */
.bottom-nav { display: none; }
@media (max-width: 860px) {
  .bottom-nav { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; inset-inline: 0; bottom: 0; z-index: 40; background: rgba(11, 21, 48, .96); backdrop-filter: blur(8px); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
  .bottom-nav a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 2px; color: var(--muted); font-size: 11px; min-height: 56px; text-align: center; }
  .bottom-nav a:hover { text-decoration: none; color: var(--text); }
  .bottom-nav svg { width: 24px; height: 24px; fill: currentColor; }
  .bottom-nav .bn-main svg { width: 34px; height: 34px; fill: var(--gold); margin-top: -12px; filter: drop-shadow(0 4px 10px rgba(212, 175, 55, .4)); }
  .bottom-nav span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
  body:not(.focus-mode) .site-footer { padding-bottom: 90px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* 不正対策：問題文の選択・コピーをしにくくする／人間確認／報告 */
.no-copy { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.human-box { display: flex; justify-content: center; min-height: 65px; margin: 8px 0; }
.human-box[hidden] { display: none; }
.report-box { max-width: 640px; margin: 24px auto 0; }
.report-box summary { cursor: pointer; }

/* ハイレベルモード */
.high-level-check { margin-bottom: 12px; padding: 10px 12px; border: 1px solid var(--gold, #d4af37); border-radius: 10px; }
.high-hero { margin-top: 18px; text-align: center; border: 1px solid var(--gold, #d4af37); }
.high-hero .iq { font-size: clamp(48px, 10vw, 84px); font-weight: 800; color: var(--gold, #d4af37); line-height: 1.1; }

/* よくある質問 */
.faq details { border-top: 1px solid rgba(255,255,255,.08); padding: 10px 0; }
.faq summary { cursor: pointer; font-weight: 700; }
.faq details p { margin: 8px 0 0; color: var(--muted, #a9b4cc); }
