/* 韻で検索.com の見た目。値は見本（orders/first-build/mock/html）のまま。スマホが先、1096px から PC。
   色はライトだけ（端末がダークでも明るいまま）。決まった文言の線の画像は .g（mask と currentColor）。 */

:root {
  color-scheme: only light;
  --green: #0f5a47;
  --ground: #f1f5f2;
  --surface: #ffffff;
  --ink: #14181b;
  --ink-2: #5a636a;
  --ink-3: #8a949b;
  --ink-off: #98a1a8;
  --line: #e2e6e9;
  --control: #d3dade;
  --ad-line: #c9d1d6;
  --off-ground: #f6f8f7;
  --vowel-line: #cc5c85;
  --vowel-ink: #b8456f;
  --kana-line: #0e7c8a;
  --kana-ink: #0b6e7a;
  --yellow: #fff59d;
  --yellow-line: #e3d24f;
  --blue: #b3e5fc;
  --blue-line: #4fc3f7;
  --on-green: rgba(255, 255, 255, 0.86);
  --scrim: rgba(20, 24, 27, 0.38);
  --shadow-float: 0 6px 18px rgba(20, 24, 27, 0.18);
  --shadow-sheet: 0 10px 28px rgba(20, 24, 27, 0.18);
  --font: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
  --pad: 12px;
  --edge: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--ground);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

button:disabled {
  cursor: default;
}

:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

/* ---- 決まった文言の線の画像 ---- */
.g {
  position: relative;
  display: inline-block;
  flex: none;
  height: var(--gs, var(--g0));
  width: calc(var(--gw) * var(--gs, var(--g0)));
  vertical-align: middle;
  background-color: currentColor;
  -webkit-mask: var(--gm) center / 100% 100% no-repeat;
  mask: var(--gm) center / 100% 100% no-repeat;
}

.vh,
.g > .vh {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ---- 紙のざらつき ---- */
.grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: var(--grain);
  background-size: 128px 128px;
}

/* ---- 緑の帯・ヘッダー ---- */
.band {
  position: relative;
  overflow: hidden;
  background: var(--green);
}

.band-gap {
  height: 22px;
}

.site-header {
  position: relative;
  height: 56px;
  padding: 0 var(--edge);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-link {
  display: block;
  line-height: 0;
}

.logo {
  position: relative;
  display: block;
}

.logo > img,
.logo > .ink {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
}

.logo .ink {
  background-image: var(--grain);
  background-size: 128px 128px;
  -webkit-mask: var(--logo-mask) 0 0 / 100% 100% no-repeat;
  mask: var(--logo-mask) 0 0 / 100% 100% no-repeat;
}

.logo-small {
  width: 139.24px;
  height: 32.77px;
  margin-left: -13.47px;
  top: -3.29px;
}

.app-link {
  position: relative;
  height: 28px;
  padding: 0 12px;
  border: 1px solid #ffffff;
  border-radius: 999px;
  display: flex;
  align-items: center;
  color: #ffffff;
}

.crumbs {
  position: relative;
  padding: 2px var(--edge) 0;
}

.crumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin: 0;
  padding: 0;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.82);
}

.crumbs a {
  color: var(--on-green);
}

.band h1 {
  position: relative;
  margin: 8px var(--edge) 0;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1.45;
  color: var(--on-green);
  text-wrap: balance;
  overflow-wrap: anywhere;
}

.band .lead {
  position: relative;
  margin: 8px var(--edge) 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--on-green);
}

.band .lead br.pc-join {
  display: inline;
}

.app-head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 12px var(--edge) 0;
}

.app-head img {
  display: block;
  box-sizing: content-box;
  width: 64px;
  height: 64px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  flex: none;
}

.app-head .names {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.app-head h1 {
  margin: 0;
  font-size: 26px;
  line-height: 1.4;
}

.app-head .platforms {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
}

/* ---- 中身 ---- */
.content {
  position: relative;
  width: 100%;
  padding: 14px var(--pad) 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.column {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.card {
  padding: 16px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.card h2 {
  margin: 0;
  line-height: 0;
}

.card p {
  margin: 0;
  font-size: 15px;
  line-height: 1.9;
  word-break: auto-phrase;
}

.card ul.dots {
  margin: 0;
  padding: 0 0 0 20px;
  font-size: 15px;
  line-height: 1.9;
}

.card .note-en {
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-2);
}

.link-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.link-list li + li {
  border-top: 1px solid var(--line);
}

.link-list a {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 15px;
  color: var(--ink);
}

.link-list a > svg {
  color: var(--green);
  flex: none;
}

.table-card {
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  overflow: hidden;
}

.table-card table {
  width: 100%;
  border-collapse: collapse;
}

.table-card th {
  padding: 10px 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-2);
  text-align: left;
  border-bottom: 1px solid var(--line);
}

.table-card td {
  padding: 12px;
  font-size: 16px;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}

.table-card tr:last-child td {
  border-bottom: 0;
}

.table-card td:first-child {
  font-weight: 600;
}

.table-card .num {
  font-weight: 700;
}

.table-card .aside {
  font-size: 12px;
  color: var(--ink-2);
  margin-left: 4px;
}

.table-card td.plain {
  font-weight: 400;
}

.table-card .mono {
  font-size: 12px;
  font-family: ui-monospace, Menlo, monospace;
  word-break: break-all;
}

/* ---- ボタン ---- */
.btn-primary {
  width: 100%;
  height: 48px;
  border-radius: 12px;
  border: 0;
  background: var(--green);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.btn-outline {
  height: 52px;
  border-radius: 12px;
  border: 2px solid var(--green);
  background: var(--surface);
  color: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-quiet {
  height: 48px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid var(--control);
  background: var(--surface);
  color: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex: none;
}

.btn-small-outline {
  height: 44px;
  padding: 0 20px;
  border-radius: 12px;
  border: 2px solid var(--green);
  background: var(--surface);
  color: var(--green);
  display: flex;
  align-items: center;
}

.pill {
  height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--control);
  background: var(--surface);
  color: var(--ink);
  display: flex;
  align-items: center;
  flex: none;
}

.pill.toggle {
  color: var(--ink-2);
}

.pill.toggle[aria-pressed="true"] {
  border: 1.5px solid var(--green);
  padding: 0 11.5px;
  color: var(--green);
}

.pill.menu-pill {
  padding: 0 10px 0 12px;
  gap: 3px;
}

.pill.menu-pill.chosen {
  border: 1.5px solid var(--green);
  padding: 0 9.5px 0 11.5px;
  gap: 8px;
}

.pill.menu-pill .chev {
  display: flex;
}

.pill.menu-pill.chosen .chev {
  margin-left: -4px;
}

.pill .dot-label {
  display: flex;
  align-items: center;
  gap: 4px;
}

.dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 999px;
  flex: none;
}

.dot-a {
  background: var(--yellow);
  border: 1px solid var(--yellow-line);
}

.dot-b {
  background: var(--blue);
  border: 1px solid var(--blue-line);
}

.pill.export {
  padding: 0 12px 0 10px;
  gap: 5px;
  color: var(--green);
}

.pill.export .g {
  color: var(--ink);
}

/* ---- 検索の箱 ---- */
.finder {
  padding: 15px;
  border-radius: 14px;
  background: var(--surface);
  border: 2px solid var(--green);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.finder h2 {
  margin: 0;
  height: 20px;
  display: flex;
  align-items: center;
  color: var(--green);
}

.search-field {
  height: 50px;
  border-radius: 12px;
  border: 2px solid var(--green);
  background: var(--surface);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 4px 0 12px;
  color: var(--green);
}

.search-field > svg {
  flex: none;
}

.search-field input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: none;
  padding: 0;
  font-size: 18px;
  font-weight: 500;
  color: var(--ink);
  background: transparent;
  border-radius: 0;
  -webkit-appearance: none;
  appearance: none;
}

.search-field input::placeholder {
  color: var(--ink-3);
  font-weight: 400;
  opacity: 1;
}

.search-field .clear {
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}

.search-field .clear[hidden] {
  display: none;
}

.finder-rule {
  height: 1px;
  background: var(--line);
}

.mora-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.blocks {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  min-width: 0;
  touch-action: none;
}

.block {
  position: relative;
  width: 44px;
  height: 54px;
  border-radius: 9px;
  border: 1px solid transparent;
  background: transparent;
  padding: 0;
  font-size: 19px;
  font-weight: 400;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  -webkit-user-select: none;
  user-select: none;
}

.block.vowel {
  border-color: var(--vowel-line);
  color: var(--vowel-ink);
}

.block.exact {
  border-color: var(--kana-line);
  color: var(--kana-ink);
  font-size: 22px;
  font-weight: 700;
}

.block.exact.long {
  font-size: 17px;
}

.block .frame {
  position: absolute;
  left: 0;
  top: 0;
}

.block .frame-l,
.mini-blocks .frame-l {
  display: none;
}

.block.ignored {
  color: var(--ink-off);
  font-size: 22px;
  font-weight: 700;
}

.block.selected {
  background: #e8f1ee;
  box-shadow: 0 0 0 2px var(--green);
}

.count-cluster {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex: none;
}

.count-cluster[hidden] {
  display: none;
}

.count-label {
  font-size: 13px;
  color: var(--ink-2);
  white-space: nowrap;
}

.count-label b {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
}

.count-buttons {
  display: flex;
  gap: 6px;
}

.step {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid var(--control);
  background: var(--surface);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.step:disabled {
  border-color: var(--line);
  background: transparent;
  color: var(--ink-off);
}

.finder-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: -2px;
  min-height: 32px;
  color: var(--ink-2);
}

.finder-foot .text-button {
  height: 32px;
  padding: 0 4px;
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  color: var(--green);
}

.finder-foot .text-button:disabled {
  color: var(--ink-off);
}

.finder-foot .text-button[hidden],
.finder-foot .hint[hidden] {
  display: none;
}

.notice {
  margin: 10px 0 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: var(--ink-2);
}

/* ---- 検索の画面（トップと検索した後） ---- */
.search-wrap {
  position: relative;
  padding: 14px var(--pad) 0;
}

.hero,
.top-guide,
.bird {
  display: none;
}

.search-main {
  position: relative;
  padding: 0 var(--pad);
}

.results-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 18px 0 12px;
}

.results-head[hidden] {
  display: none;
}

.count-row {
  display: flex;
  justify-content: center;
}

.result-count {
  font-size: 14px;
  color: var(--ink-2);
}

.result-count b {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
}

.tools-row {
  display: flex;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.anchor {
  position: relative;
}


.state-empty {
  margin: 18px 0 0;
  display: flex;
  justify-content: center;
  color: var(--ink-2);
}

.state-box {
  margin-top: 16px;
  padding: 18px 16px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  color: var(--ink);
}

.state-box[hidden],
.state-empty[hidden],
.state-slot:empty {
  display: none;
}

.head-pills {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.count-row .anchor.export-pc,
.tools-row[hidden],
.anchor[hidden] {
  display: none;
}

.more-wrap {
  margin-top: 14px;
}

.more-wrap[hidden] {
  display: none;
}

.rows.loading {
  opacity: 0.45;
  transition: opacity 0.12s;
}

/* ---- 結果の行 ---- */
.rows {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.row {
  padding: 4px 4px 14px 14px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.row-top {
  position: relative;
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
}

.reading {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.16em;
  color: var(--green);
  overflow-wrap: anywhere;
  min-width: 0;
}

.seal {
  flex: none;
}

.row-spacer {
  flex: 1;
}

.vote,
.row .menu {
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: var(--ink-2);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  flex: none;
}

.vote[aria-pressed="true"] {
  color: var(--green);
}

.vote[aria-pressed="true"] .thumb {
  fill: var(--green);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding-right: 10px;
}

.chip {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  max-width: 100%;
  padding: 5px 10px;
  border-radius: 8px;
  border: 1px solid var(--control);
  background: var(--surface);
  font-size: 17px;
  font-weight: 500;
  line-height: 24px;
  color: var(--ink);
  text-align: left;
  overflow-wrap: anywhere;
}

.chip .pos {
  font-size: 10.5px;
  font-weight: 400;
  color: var(--ink-2);
  white-space: nowrap;
}

.chip.hl-a {
  border-color: var(--yellow-line);
  background: var(--yellow);
}

.chip.hl-b {
  border-color: var(--blue-line);
  background: var(--blue);
}

.chip.extra {
  display: none;
}

.chips.expanded .chip.extra {
  display: inline-flex;
}

.more-chips {
  height: 32px;
  padding: 0 6px;
  border: 0;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  color: var(--green);
}

/* ---- アプリの小さな紹介 ---- */
.search-side .promo,
.promo[hidden] {
  display: none;
}

.promo {
  margin: 28px 4px 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
}

.promo img {
  display: block;
  box-sizing: content-box;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border: 1px solid var(--line);
  flex: none;
}

.promo .names {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  flex: 1;
}

.promo .names .sub {
  color: var(--ink-2);
}

.promo .store {
  color: var(--green);
}

.promo.plain {
  margin: 6px 4px 0;
  padding-top: 0;
  border-top: 0;
}

/* ---- 広告の枠 ---- */
.ad-slot {
  margin: 0;
  height: 100px;
  border-radius: 12px;
  border: 1px dashed var(--ad-line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--ink-3);
}

/* ---- 入口のページ ---- */
.facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 16px;
  margin: 0;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.facts > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.facts dt {
  margin: 0;
  line-height: 0;
  color: var(--ink-2);
}

.facts dd {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.facts dd a {
  color: var(--green);
  font-weight: 700;
}

.page-actions {
  display: flex;
  gap: 8px;
}

.page-actions .grow {
  flex: 1;
  min-width: 0;
}

.section-head {
  margin: 0 4px 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-head .count {
  font-size: 13px;
  color: var(--ink-2);
}

.entry-section {
  margin-top: 8px;
}

.word-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.word-chip {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid var(--control);
  background: var(--surface);
  font-size: 16px;
  font-weight: 500;
  color: var(--green);
}

/* ---- ガイド ---- */
.try-box {
  padding: 12px;
  border-radius: 12px;
  border: 2px solid var(--green);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.try-box h3 {
  margin: 0;
  line-height: 0;
  color: var(--green);
}

.try-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.mini-blocks {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  min-width: 0;
}

.mini-blocks .block {
  cursor: default;
}

/* ---- アプリの紹介のページ ---- */
.store-buttons {
  display: flex;
  gap: 8px;
}

.store-buttons > a {
  flex: 1;
  min-width: 0;
}

/* ---- 困ったとき ---- */
.notfound-wrap {
  position: relative;
  padding: 0 var(--pad);
}

/* ---- フッター ---- */
.site-footer {
  position: relative;
  overflow: hidden;
  margin-top: auto;
  background: var(--green);
  color: #ffffff;
}

.footer-gap {
  height: 22px;
  flex: none;
}

.foot {
  position: relative;
  padding: 14px var(--edge) 18px;
  font-size: 11px;
  line-height: 1.7;
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.has-to-top .foot {
  padding-bottom: 84px;
}

.foot-fold {
  flex: 1;
  min-width: 0;
}

.foot-fold summary {
  padding: 4px 0;
  list-style: none;
  cursor: pointer;
}

.foot-fold summary::-webkit-details-marker {
  display: none;
}

.foot-fold summary .mark {
  display: inline-block;
  font-size: 9px;
  margin-right: 6px;
  position: relative;
  top: -1px;
  transition: transform 0.15s;
}

.foot-fold[open] summary .mark {
  transform: rotate(90deg);
}

.foot-body {
  padding: 6px 0 4px 15px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: rgba(255, 255, 255, 0.86);
}

.foot-body p {
  margin: 0;
}

.foot-body a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.foot-links {
  display: flex;
  gap: 14px;
  flex: none;
}

.foot-links a {
  padding: 4px 0;
}

/* ---- いちばん上へ・お知らせ ---- */
.to-top {
  position: fixed;
  right: 16px;
  bottom: calc(16px + env(safe-area-inset-bottom));
  z-index: 3;
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--green);
  box-shadow: var(--shadow-float);
  display: flex;
  align-items: center;
  justify-content: center;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(80px + env(safe-area-inset-bottom));
  z-index: 60;
  transform: translateX(-50%);
  max-width: calc(100vw - 32px);
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(20, 24, 27, 0.88);
  color: #ffffff;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}

.toast.shown {
  opacity: 1;
}

/* ---- 下から出る板（スマホ）・小窓（PC） ---- */
.sheet {
  position: fixed;
  inset: auto 0 0 0;
  margin: 0;
  width: 100%;
  max-width: 100%;
  max-height: 85vh;
  padding: 0;
  border: 0;
  border-radius: 18px 18px 0 0;
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sheet);
  overflow: auto;
}

.sheet::backdrop {
  background: var(--scrim);
}

.sheet-body {
  padding: 12px 16px calc(28px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.sheet-bar {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) 72px;
  align-items: center;
}

.sheet-bar h2 {
  margin: 0;
  display: flex;
  justify-content: center;
  line-height: 0;
}

.sheet-bar .side {
  height: 44px;
  padding: 0 4px;
  border: 0;
  background: none;
  display: flex;
  align-items: center;
  color: var(--green);
}

.sheet-bar .side.end {
  justify-content: flex-end;
}

.sheet-note {
  margin: -6px 0 0;
  display: flex;
  justify-content: center;
  color: var(--ink-2);
}

.pos-choices {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pos-choice {
  min-width: 100px;
  height: 52px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid var(--control);
  background: var(--surface);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.pos-choice:disabled {
  border-color: var(--line);
  background: var(--off-ground);
  color: var(--ink-off);
}

.pos-choice.hl-a {
  border: 1.5px solid var(--yellow-line);
  background: var(--yellow);
}

.pos-choice.hl-b {
  border: 1.5px solid var(--blue-line);
  background: var(--blue);
}

.pos-choice .check {
  display: none;
}

.pos-choice[aria-pressed="true"] .check {
  display: flex;
}

.sheet .clear-all {
  align-self: center;
  height: 44px;
  padding: 0 12px;
  border: 0;
  background: none;
  display: flex;
  align-items: center;
  color: var(--green);
}

.sheet .clear-all:disabled {
  color: var(--ink-off);
}

.radio-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--line);
}

.radio-list label {
  min-height: 54px;
  padding: 0 4px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}

.radio-list input {
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--green);
  flex: none;
}

.radio-list .with-dots {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sheet .primary-wrap {
  margin-top: 4px;
}

.sheet .progress {
  margin: 0;
  text-align: center;
  font-size: 13px;
  color: var(--ink-2);
}

.menu-list {
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--line);
}

.menu-list > button {
  min-height: 54px;
  padding: 0 4px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--ink);
  text-align: left;
}

.menu-list > button[aria-checked="true"] .check {
  color: var(--green);
}

.menu-list > button .check {
  display: flex;
  color: transparent;
}

.menu-list .choice-text {
  font-size: 16px;
  font-weight: 500;
  overflow-wrap: anywhere;
}

.sheet-title-text {
  margin: 0;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  overflow-wrap: anywhere;
}

/* 条件を選ぶ板 */
.cond-target {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.cond-target .mini {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: center;
}

.cond-target .mini span {
  width: 22px;
  height: 27px;
  border-radius: 5px;
  border: 1px solid var(--line);
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-3);
}

.cond-target .mini span.target {
  border: 1.5px solid var(--green);
  color: var(--green);
  font-weight: 600;
}

.cond-target .which {
  margin: 0;
  font-size: 13px;
  color: var(--ink-2);
}

.cond-target .warn {
  margin: 0;
  font-size: 12px;
  color: var(--vowel-ink);
  text-align: center;
}

.cond-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cond-section h3 {
  margin: 0;
  line-height: 0;
  color: var(--ink-2);
}

.cond-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.cond-choice {
  width: 52px;
  height: 52px;
  border-radius: 10px;
  border: 1px solid var(--control);
  background: var(--surface);
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  position: relative;
}

.cond-choice.vowel {
  color: var(--vowel-ink);
}

.cond-choice.exact {
  color: var(--kana-ink);
  font-weight: 700;
}

.cond-choice[aria-pressed="true"].vowel {
  border: 2px solid var(--vowel-line);
  background: #fbeef3;
}

.cond-choice[aria-pressed="true"].exact {
  border: 2px solid var(--kana-line);
  background: #e7f4f5;
}

.cond-choice.wild {
  border: 0;
  background: transparent;
}

.cond-choice.wild svg {
  position: absolute;
  inset: 0;
}

.cond-choice.wild[aria-pressed="true"] rect {
  stroke: var(--green);
}

.cond-kana {
  height: 48px;
  border-radius: 12px;
  border: 2px solid var(--kana-line);
  padding: 0 12px;
  font-size: 18px;
  font-weight: 500;
  width: 100%;
  max-width: 220px;
  outline: none;
  background: var(--surface);
  -webkit-appearance: none;
  appearance: none;
}

/* ---- 広い画面（PC） ---- */
@media (min-width: 600px) and (max-width: 1095px) {
  .narrow-center,
  .search-wrap,
  .search-main,
  .content,
  .notfound-wrap,
  .band-inner {
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
  }

  .site-header {
    max-width: 640px;
    margin: 0 auto;
    width: 100%;
  }
}

@media (min-width: 1096px) {
  :root {
    --pad: 24px;
  }

  .site-header {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    height: 64px;
    padding: 0 24px;
  }

  .logo-small {
    width: 149.42px;
    height: 35.17px;
    margin-left: -14.45px;
    top: -3.53px;
  }

  .app-link {
    height: 30px;
    padding: 0 14px;
  }

  .band-inner {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 8px 24px 30px;
  }

  .band-inner .crumbs {
    padding: 0;
  }

  .band-inner h1 {
    margin: 10px 0 0;
    font-size: 32px;
  }

  .band-inner .lead {
    margin: 10px 0 0;
    font-size: 15px;
  }

  .band .lead br.pc-join {
    display: none;
  }

  .band-gap {
    display: none;
  }

  .app-head {
    gap: 18px;
    margin: 14px 0 0;
  }

  .app-head img {
    width: 80px;
    height: 80px;
    border-radius: 18px;
  }

  .app-head .names {
    gap: 4px;
  }

  .app-head h1 {
    margin: 0;
    font-size: 32px;
    line-height: 1.35;
  }

  .app-head .platforms {
    font-size: 14px;
  }

  .content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 24px 24px 32px;
    gap: 14px;
  }

  .content > .column {
    max-width: 760px;
    display: flex;
    flex-direction: column;
    gap: 14px;
  }

  .content.app-content > .column {
    max-width: 640px;
  }

  .store-buttons {
    max-width: 420px;
  }

  .facts {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .facts.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .page-actions {
    width: 456px;
  }

  .row {
    padding: 4px 4px 14px 16px;
  }

  .rows {
    gap: 10px;
  }

  .finder {
    padding: 18px;
    gap: 14px;
  }

  .finder h2 {
    height: 22px;
  }

  .finder .g-title {
    --gs: 18px;
  }

  .app-link .g-app {
    --gs: 15.6px;
  }

  .search-field {
    height: 54px;
    gap: 10px;
    padding: 0 6px 0 14px;
  }

  .search-field input {
    font-size: 20px;
  }

  .blocks {
    gap: 8px;
  }

  .finder .block {
    width: 48px;
    height: 58px;
    border-radius: 10px;
    font-size: 20px;
  }

  .finder .block.exact,
  .finder .block.ignored {
    font-size: 24px;
  }

  .finder .block.exact.long {
    font-size: 19px;
  }

  .finder .block .frame-s {
    display: none;
  }

  .finder .block .frame-l {
    display: block;
  }

  /* 検索した後：左に検索の箱、右に結果 */
  .search-layout {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    padding: 24px 24px 32px;
    display: grid;
    grid-template-columns: 460px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
  }

  .search-side {
    display: flex;
    flex-direction: column;
    gap: 16px;
  }

  .search-wrap {
    padding: 0;
  }

  .notice {
    margin: -4px 0 0;
  }

  .search-main {
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
  }

  .results-head {
    align-items: stretch;
    padding: 0;
    gap: 10px;
  }

  .results-head .count-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    min-height: 36px;
  }


  .result-count b {
    font-size: 20px;
  }

  .pill-row,
  .tools-row {
    justify-content: flex-start;
  }

  .head-pills {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
  }

  .head-pills > .pill-row,
  .head-pills > .tools-row {
    display: contents;
  }

  .head-pills > .tools-row[hidden] > * {
    display: none;
  }

  .count-row .anchor.export-pc {
    display: block;
  }

  .count-row .anchor.export-pc[hidden],
  .tools-row .anchor.export-phone {
    display: none;
  }

  .more-wrap {
    margin-top: 0;
  }

  .search-side .promo.side {
    display: flex;
    margin: 4px 4px 0;
    padding-top: 0;
    border-top: 0;
  }

  .is-top .search-side .promo.side,
  .search-main > .promo {
    display: none;
  }

  .search-wrap {
    display: flex;
    flex-direction: column;
    gap: 16px;
  }

  .is-top .search-wrap {
    display: block;
  }

  .is-top .search-side {
    gap: 0;
  }

  .state-slot:empty {
    display: none;
  }

  .foot {
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 24px 26px;
  }

  .has-to-top .foot {
    padding-bottom: 26px;
  }

  .to-top {
    display: none;
  }

  .notfound-wrap {
    max-width: 480px;
    margin: 0 auto;
    padding: 24px;
  }

  .notfound-wrap .state-box {
    margin-top: 0;
  }

  /* 小窓（PC）：ボタンのすぐ下 */
  .sheet.popover {
    position: absolute;
    inset: auto;
    top: calc(100% + 8px);
    left: 0;
    right: auto;
    bottom: auto;
    width: 360px;
    max-height: none;
    border-radius: 14px;
    border: 1px solid var(--line);
    overflow: visible;
    z-index: 5;
  }

  .sheet.popover.at-end {
    left: auto;
    right: 0;
    width: 320px;
  }

  .sheet.popover::backdrop {
    background: transparent;
  }

  .sheet.popover .sheet-body {
    padding: 14px 16px 16px;
    gap: 12px;
  }

  .sheet.popover .sheet-bar {
    display: flex;
    justify-content: flex-start;
  }

  .sheet.popover .sheet-bar .side {
    display: none;
  }

  .sheet.popover .sheet-note {
    justify-content: flex-start;
    margin: -4px 0 0;
  }

  .sheet.popover .pos-choices {
    justify-content: flex-start;
  }

  .sheet.popover .clear-all {
    align-self: flex-start;
    height: 40px;
    padding: 0;
  }

  .sheet.popover .sheet-bar h2 {
    justify-content: flex-start;
  }

  .sheet.popover.export-pop .radio-list {
    border-top: 1px solid var(--line);
  }

  .sheet.popover .primary-wrap {
    margin-top: 0;
  }
}

/* ---- トップ（まだ探していないとき）：画面全体が緑の地 ---- */
.is-top {
  background: var(--green);
}

.is-top .page-grain {
  display: block;
}

.page-grain {
  display: none;
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: var(--grain);
  background-size: 128px 128px;
}

.is-top .band {
  background: transparent;
  overflow: visible;
}

.is-top .band > .grain {
  display: none;
}

.is-top .site-header {
  justify-content: flex-end;
}

.is-top .site-header .logo-link {
  display: none;
}

.is-top .hero {
  display: block;
  position: relative;
  margin: 60px 0 0 9px;
  line-height: 0;
}

.hero .logo {
  width: 340px;
  height: 80px;
}

.is-top .search-wrap {
  margin-top: 56px;
  padding: 0 var(--pad);
}

.is-top .bird {
  display: block;
  position: absolute;
  right: 55px;
  top: -40px;
  width: 58px;
  height: 42.4px;
  z-index: 2;
  opacity: 0.5;
  pointer-events: none;
}

.is-top .finder {
  padding: 14px;
  border: 1.5px solid var(--yellow);
}

.is-top .notice {
  margin: 12px 0 0;
  color: #ffffff;
  opacity: 0.85;
}

.is-top .top-guide {
  display: block;
  position: relative;
  padding: 0 var(--pad);
}

.top-guide .lead-line {
  margin: 22px 0 0;
  display: flex;
  justify-content: center;
  color: #ffffff;
}

.top-guide .links {
  margin: 10px 0 0;
  display: flex;
  justify-content: center;
  gap: 28px;
}

.top-guide .links a {
  display: flex;
  padding: 4px 0;
  border-bottom: 2px solid var(--yellow);
  color: #ffffff;
}

.is-top .search-main,
.is-top .footer-gap {
  display: none;
}

.is-top .site-footer {
  background: transparent;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  overflow: visible;
}

.is-top .site-footer > .grain {
  display: none;
}

.is-top .to-top {
  display: none;
}

.is-top .foot {
  padding-bottom: 18px;
}

@media (min-width: 600px) and (max-width: 1095px) {
  .is-top .hero {
    display: flex;
    justify-content: center;
    margin-left: 0;
  }
}

@media (min-width: 1096px) {
  .is-top .search-layout {
    display: block;
    max-width: none;
    padding: 0;
  }

  .is-top .hero {
    margin: 44px 0 0;
    display: flex;
    justify-content: center;
  }

  .hero .logo {
    width: 600px;
    height: 141.21px;
    left: -28.6px;
  }

  .is-top .search-wrap {
    width: min(640px, calc(100% - 48px));
    margin: 52px auto 0;
    padding: 0;
  }

  .is-top .bird {
    right: 99px;
  }

  .is-top .finder {
    padding: 18px;
    border-radius: 16px;
    gap: 14px;
  }

  .is-top .notice {
    margin: 14px 0 0;
  }

  .is-top .top-guide {
    width: min(640px, calc(100% - 48px));
    margin: 0 auto;
    padding: 0 0 25px;
  }

  .top-guide .lead-line {
    margin-top: 24px;
  }

  .is-top .foot {
    padding-bottom: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
