:root {
  --bg: #f1efea;
  --panel: #fcfbf8;
  --panel-2: #e9e6df;
  --line: #d6d0c5;
  --ink: #1c1e1d;
  --text: #1c1e1d;
  --soft: #434745;
  --muted: #706b63;
  --accent: #0b7d75;
  --accent-ink: #ffffff;
  --highlight: #ffd66b;
  --shadow: 0 1px 0 rgba(28, 30, 29, 0.05), 0 8px 20px -12px rgba(28, 30, 29, 0.25);
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.75 system-ui, -apple-system, 'Segoe UI', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

.muted {
  color: var(--muted);
}

/* ---------- header / footer ---------- */

.site-header {
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: rgba(241, 239, 234, 0.88);
  backdrop-filter: blur(8px);
  z-index: 10;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 60px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 800;
  font-size: 18px;
}

.logo:hover {
  text-decoration: none;
}

/* "JimaxLab / 사이트 이름" brand on the tool sites */
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.logo-sep {
  color: var(--line);
  font-size: 22px;
  font-weight: 300;
}

.logo.sub {
  font-weight: 700;
  font-size: 17px;
  white-space: nowrap;
}

.nav {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.nav a {
  color: var(--soft);
  padding: 6px 12px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 15px;
}

.nav a:hover,
.nav a[aria-current='page'] {
  background: var(--panel-2);
  color: var(--text);
  text-decoration: none;
}

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 72px;
  padding: 32px 0 24px;
  font-size: 14px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-inner p {
  margin: 4px 0 0;
  max-width: 520px;
}

.footer-nav {
  display: flex;
  gap: 16px;
}

.footer-nav a {
  color: var(--soft);
}

.copyright {
  margin-top: 20px;
  font-size: 13px;
}

/* ---------- buttons ---------- */

.button {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 700;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid var(--accent);
}

.button:hover {
  text-decoration: none;
  filter: brightness(1.08);
}

.button.ghost {
  background: transparent;
  color: var(--accent);
}

.text-link {
  font-weight: 600;
}

/* ---------- home ---------- */

.hero {
  padding: 72px 0 32px;
}

.eyebrow {
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 14px;
  margin: 0 0 8px;
}

.hero h1 {
  font-size: clamp(32px, 5.4vw, 52px);
  line-height: 1.2;
  margin: 0;
  letter-spacing: -0.02em;
}

.lead {
  color: var(--soft);
  font-size: 18px;
  max-width: 680px;
}

.hero-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.section {
  margin-top: 56px;
}

.section h2 {
  font-size: 24px;
  margin: 0 0 6px;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.tool-card {
  box-shadow: var(--shadow);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 20px;
  display: flex;
  flex-direction: column;
}

.tool-card h3 {
  margin: 8px 0 6px;
  font-size: 19px;
}

.tool-card h3 a {
  color: var(--text);
}

.tool-card p {
  margin: 0 0 10px;
  color: var(--soft);
  font-size: 15px;
}

.tool-card .why {
  background: var(--panel-2);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
}

.tool-card .why strong {
  display: block;
  color: var(--accent);
  font-size: 13px;
}

.tool-card.dev {
  border-style: dashed;
  background: transparent;
}

.tool-card.dev h3,
.tool-card.dev p {
  opacity: 0.75;
}

.tags .dev-badge {
  color: var(--accent);
  border-color: var(--accent);
  font-weight: 700;
}

.tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.tags span {
  font-size: 12px;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 1px 8px;
}

.card-actions {
  margin-top: auto;
  padding-top: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-actions .button {
  padding: 7px 16px;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.post-list,
.changelog {
  list-style: none;
  padding: 0;
  margin: 12px 0;
}

.post-list li,
.changelog li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.changelog li {
  justify-content: flex-start;
}

.changelog .muted,
.post-list .muted {
  white-space: nowrap;
  font-size: 14px;
}

.notice {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 24px 28px;
}

.notice ul {
  margin: 8px 0 0;
  padding-left: 20px;
  color: var(--soft);
}

/* ---------- notes / articles ---------- */

.page-head {
  padding: 56px 0 8px;
}

.page-head h1 {
  margin: 0;
  font-size: 36px;
}

.note-list {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 12px;
}

.note-list li {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px 22px;
}

.note-list h2 {
  margin: 0;
  font-size: 20px;
  color: var(--text);
}

.note-list p {
  margin: 6px 0;
  color: var(--soft);
}

.article {
  max-width: 760px;
  margin: 0 auto;
  padding-top: 48px;
}

.article h1 {
  font-size: clamp(28px, 4.4vw, 38px);
  line-height: 1.3;
  margin: 4px 0 6px;
  letter-spacing: -0.01em;
}

.article .meta {
  margin: 0 0 28px;
  font-size: 14px;
}

.article h2 {
  font-size: 23px;
  margin: 40px 0 10px;
  padding-top: 8px;
}

.article p,
.article li {
  color: var(--soft);
}

.article strong {
  color: var(--text);
}

.article ul,
.article ol {
  padding-left: 22px;
}

.article li {
  margin: 4px 0;
}

.breadcrumb {
  margin: 0;
  font-size: 14px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0 8px;
  font-size: 15px;
  display: block;
  overflow-x: auto;
}

th,
td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

th {
  color: var(--text);
  background: var(--panel);
  white-space: nowrap;
}

td {
  color: var(--soft);
}

code,
kbd {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1px 6px;
  font-size: 0.9em;
}

.cta {
  margin-top: 36px;
}

.more {
  max-width: 760px;
  margin: 56px auto 0;
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

.more h2 {
  margin: 0;
  font-size: 18px;
}

.contact-box {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 20px;
  font-size: 18px;
  font-weight: 700;
}

@media (max-width: 720px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
    padding: 10px 0;
    gap: 6px;
  }

  .nav a {
    padding: 4px 10px;
  }

  .hero {
    padding-top: 40px;
  }

  .two-col {
    grid-template-columns: 1fr;
  }

  .site-header {
    position: static;
  }
}

/* ---------- home: categories ---------- */

.cat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.cat-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  font-weight: 600;
}

.cat-chip span {
  font-size: 12px;
  font-weight: 400;
  color: var(--muted);
}

.cat-chip:hover {
  border-color: var(--accent);
  text-decoration: none;
}

.category {
  margin-top: 36px;
  scroll-margin-top: 80px;
}

.category-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
}

.category-head h3 {
  margin: 0;
  font-size: 20px;
}

.category-head p {
  margin: 0;
}

.category .tool-grid {
  margin-top: 16px;
}

.tool-card .features {
  list-style: none;
  padding: 0;
  margin: 0 0 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tool-card .features a {
  display: inline-block;
  font-size: 13px;
  padding: 3px 10px;
  border-radius: 8px;
  background: var(--panel-2);
  color: var(--text);
}

.tool-card .features a:hover {
  color: var(--accent);
  text-decoration: none;
}

/* ---------- ad slots: collapsed when AdSense has nothing to show ---------- */

.ad-box {
  margin: 32px 0;
}

.ad-label {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 4px;
}

.ad-box:has(ins[data-ad-status='unfilled']) {
  display: none;
}

/* ---------- warm, outlined, a little playful ---------- */

.site-header {
  border-bottom: 1.5px solid var(--line);
}

.nav a[aria-current='page'] {
  background: var(--ink);
  color: var(--bg);
}

.button {
  border-radius: 999px;
  border-width: 1.5px;
}

.button.ghost {
  border-color: var(--ink);
  color: var(--ink);
}

.button.ghost:hover {
  background: var(--ink);
  color: var(--bg);
}

.mark {
  background: linear-gradient(transparent 62%, var(--highlight) 62%, var(--highlight) 92%, transparent 92%);
  padding: 0 4px;
}

.tool-card {
  border: 1.5px solid var(--line);
  border-radius: 18px;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.tool-card:not(.dev):hover {
  transform: translateY(-3px);
  border-color: var(--ink);
}

.tool-card.dev {
  border: 1.5px dashed var(--line);
  box-shadow: none;
}

.tags span {
  border-width: 1.5px;
  color: var(--soft);
}

.cat-chip {
  border: 1.5px solid var(--line);
  background: var(--panel);
}

.cat-chip:hover {
  border-color: var(--ink);
}

th {
  background: var(--panel-2);
}

/* ---------- mini games ---------- */

.game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.game-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--panel);
  border: 1.5px solid var(--line);
  border-radius: 18px;
  padding: 16px 18px;
  color: var(--text);
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.game-card:hover {
  text-decoration: none;
  transform: translateY(-3px);
  border-color: var(--ink);
}

.game-emoji {
  flex: none;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--panel-2);
  font-size: 28px;
}

.game-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.game-text strong {
  font-size: 17px;
}

.game-text > span:not(.tags) {
  color: var(--soft);
  font-size: 14px;
  line-height: 1.6;
}

.game-page {
  max-width: 760px;
  margin: 0 auto;
  padding-top: 40px;
}

.game-page h1 {
  font-size: clamp(28px, 4.4vw, 38px);
  margin: 4px 0 4px;
}

.game-page .lead {
  margin: 0 0 20px;
  font-size: 16px;
}

.game-guide {
  padding-top: 8px;
}

/* reaction test */

.rt-pad {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 300px;
  padding: 24px;
  border-radius: 22px;
  border: 1.5px solid var(--ink);
  background: var(--panel);
  color: var(--ink);
  text-align: center;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
  transition: background 0.08s;
}

.rt-title {
  font-size: clamp(30px, 6vw, 48px);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.rt-sub {
  font-size: 15px;
  opacity: 0.85;
}

.rt-pad[data-state='wait'] {
  background: #e5484d;
  color: #fff;
  border-color: #e5484d;
}

.rt-pad[data-state='go'] {
  background: #30a46c;
  color: #fff;
  border-color: #30a46c;
}

.rt-pad[data-state='early'] {
  background: #ffd66b;
}

.rt-pad[data-state='result'],
.rt-pad[data-state='done'] {
  background: #e7f3f1;
  border-color: var(--accent);
}

.rt-rounds {
  list-style: none;
  padding: 0;
  margin: 14px 0 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}

.rt-rounds li {
  text-align: center;
  padding: 8px 4px;
  border-radius: 12px;
  border: 1.5px solid var(--ink);
  background: var(--panel);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.rt-rounds li.empty {
  border: 1.5px dashed var(--line);
  color: var(--muted);
  font-weight: 400;
}

.rt-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
  padding: 16px;
  border-radius: 18px;
  background: var(--panel);
  border: 1.5px solid var(--line);
  text-align: center;
}

.rt-summary[hidden] {
  display: none;
}

.rt-summary div {
  display: flex;
  flex-direction: column;
}

.rt-summary strong {
  font-size: 24px;
}

.rt-summary p,
.rt-summary button {
  grid-column: 1 / -1;
  margin: 0;
  justify-self: center;
  cursor: pointer;
}

.rt-best {
  text-align: center;
  font-size: 14px;
  margin: 10px 0 0;
}

/* moon smash */

.moon-hud {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.moon-hud strong {
  font-size: 20px;
}

.moon-hpbar {
  height: 8px;
  border-radius: 999px;
  background: var(--panel-2);
  margin: 8px 0 10px;
  overflow: hidden;
}

.moon-hpbar span {
  display: block;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #ffb35c, #ffd66b);
  border-radius: inherit;
  transition: width 0.12s;
}

.moon-stage {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  background: radial-gradient(circle at 50% 30%, #2b3160, #141833 70%);
  border: 1.5px solid var(--ink);
}

.moon-stage canvas {
  display: block;
  width: 100%;
  height: min(70vw, 460px);
  touch-action: none;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
}

.moon-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 20px;
  text-align: center;
  color: #fff6dc;
  background: rgba(20, 24, 51, 0.62);
  backdrop-filter: blur(2px);
}

.moon-overlay[hidden] {
  display: none;
}

.moon-overlay p {
  margin: 0;
}

.moon-big {
  font-size: clamp(26px, 5vw, 36px);
  font-weight: 800;
}

.moon-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 14px;
}

.moon-actions .button {
  cursor: pointer;
  font: inherit;
  font-weight: 700;
}

.moon-overlay .button.ghost {
  border-color: #fff6dc;
  color: #fff6dc;
}

@media (max-width: 720px) {
  .rt-pad {
    min-height: 240px;
  }

  .moon-hud {
    font-size: 13px;
  }
}

#games {
  scroll-margin-top: 80px;
}

/* ---------- game rankings ---------- */

.rk-form-box {
  margin-top: 14px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1.5px solid var(--accent);
  background: #e7f3f1;
}

.rk-form-box[hidden],
.rk-board[hidden] {
  display: none;
}

.rk-offer {
  margin: 0 0 10px;
  font-weight: 600;
}

.rk-form {
  display: flex;
  gap: 8px;
}

.rk-form input {
  flex: 1;
  min-width: 0;
  font: inherit;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  background: var(--panel);
}

.rk-form .button {
  cursor: pointer;
  font: inherit;
  font-weight: 700;
}

.rk-msg {
  margin: 8px 0 0;
  font-size: 13px;
}

.rk-msg.err {
  color: #d13438;
}

.rk-board {
  margin-top: 18px;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1.5px solid var(--line);
  background: var(--panel);
}

.rk-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
}

.rk-head h2 {
  margin: 0;
  font-size: 19px;
}

.rk-head span {
  font-size: 13px;
}

.rk-note {
  margin: 10px 0 0;
  padding: 8px 12px;
  border-radius: 12px;
  background: #fff4d1;
}

.rk-list {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
}

.rk-list li {
  display: grid;
  grid-template-columns: 34px 1fr auto auto;
  gap: 10px;
  align-items: center;
  padding: 7px 8px;
  border-bottom: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
}

.rk-list li.me {
  background: #fff4d1;
  border-radius: 10px;
}

.rk-pos {
  text-align: center;
  font-weight: 700;
}

.rk-nick {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rk-detail {
  font-size: 13px;
}

.rk-more {
  margin-top: 10px;
  border: 0;
  background: none;
  color: var(--accent);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.rk-empty {
  margin: 10px 0 0;
}

/* ---------- share card dialog ---------- */

.share-dialog {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(20, 24, 30, 0.6);
  backdrop-filter: blur(3px);
}

.share-box {
  position: relative;
  width: min(440px, 100%);
  max-height: calc(100vh - 32px);
  overflow: auto;
  background: var(--panel);
  border: 1.5px solid var(--ink);
  border-radius: 22px;
  padding: 16px;
}

.share-box img {
  display: block;
  width: 100%;
  border-radius: 14px;
}

.share-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-top: 14px;
}

.share-actions .button {
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  padding: 8px 16px;
}

.share-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 0;
  background: var(--ink);
  color: var(--bg);
  font-size: 16px;
  cursor: pointer;
}

/* ---------- menu picker (/menu/) and recipes ---------- */

.mp {
  margin: 8px 0 40px;
}

.mp-filters {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px 20px 6px;
  box-shadow: var(--shadow);
}

.mp-group {
  border: 0;
  margin: 0 0 14px;
  padding: 0;
  min-width: 0;
}

.mp-group legend {
  font-weight: 800;
  margin-bottom: 8px;
  padding: 0;
}

.mp-group legend .muted {
  font-weight: 400;
  font-size: 0.85em;
  margin-left: 4px;
}

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

.mp-chip,
.mp-alt {
  font: inherit;
  font-size: 0.95rem;
  background: var(--bg);
  color: var(--ink);
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 6px 14px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
}

.mp-chip:hover,
.mp-alt:hover {
  border-color: var(--ink);
}

.mp-chip:active,
.mp-alt:active {
  transform: scale(0.96);
}

.mp-chip[aria-pressed='true'] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
  font-weight: 700;
}

.mp-count {
  margin: 4px 0 10px;
  font-size: 0.9rem;
}

.mp-count span {
  font-weight: 800;
  color: var(--accent);
}

.mp-reset {
  font: inherit;
  background: none;
  border: 0;
  padding: 0;
  color: var(--accent);
  cursor: pointer;
  text-decoration: underline;
}

.mp-roll {
  display: block;
  width: 100%;
  margin: 18px 0;
  padding: 16px;
  font-size: 1.2rem;
  font-weight: 800;
}

.mp-roll:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  font-size: 1rem;
}

.mp-result {
  background: var(--panel);
  border: 2.5px solid var(--ink);
  border-radius: 20px;
  padding: 24px;
  box-shadow: var(--shadow);
}

.mp-result[hidden] {
  display: none;
}

.mp-pick {
  display: flex;
  align-items: center;
  gap: 20px;
}

.mp-emoji {
  font-size: 84px;
  line-height: 1;
  flex: none;
}

.mp-label {
  margin: 0;
}

.mp-name {
  margin: 0;
  font-size: 2.1rem;
  line-height: 1.25;
}

.mp-name::after {
  content: none;
}

.mp-note {
  margin: 4px 0 6px;
  color: var(--soft);
}

.mp-tags {
  margin: 0;
}

.mp-result.spinning .mp-name,
.mp-result.spinning .mp-emoji {
  filter: blur(0.6px);
  opacity: 0.75;
}

.mp-result.spinning .mp-note,
.mp-result.spinning .mp-tags,
.mp-result.spinning .mp-label {
  visibility: hidden;
}

.mp-result.landed .mp-pick {
  animation: mp-land 0.45s cubic-bezier(0.2, 1.6, 0.4, 1);
}

@keyframes mp-land {
  from {
    transform: scale(0.85);
  }
  to {
    transform: scale(1);
  }
}

.mp-actions,
.recipe-share {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0 0;
}

.mp-near {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px dashed var(--line);
}

.mp-near label {
  font-weight: 800;
}

.mp-near-row {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  flex-wrap: wrap;
}

.mp-near-row input {
  flex: 1 1 180px;
  min-width: 0;
  font: inherit;
  padding: 8px 12px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--ink);
}

.mp-near-hint {
  font-size: 0.85rem;
  margin: 6px 0 0;
}

.mp-others {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.mp-others p {
  margin: 0 4px 0 0;
  width: 100%;
  font-size: 0.9rem;
}

.recipe-links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.recipe-links li {
  margin: 0;
}

.recipe-links a {
  display: inline-block;
  padding: 4px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
}

.article .recipe-meta,
.recipe-meta {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  font-weight: 700;
}

.recipe-meta li {
  margin: 0;
}

.recipe-ingredients {
  columns: 2 220px;
}

.recipe-steps li {
  margin-bottom: 10px;
}

.recipe-tip {
  background: var(--panel);
  border-left: 4px solid var(--highlight);
  border-radius: 8px;
  padding: 12px 16px;
}

@media (max-width: 520px) {
  .mp-result {
    padding: 18px;
  }
  .mp-emoji {
    font-size: 60px;
  }
  .mp-name {
    font-size: 1.7rem;
  }
  .mp-pick {
    gap: 14px;
  }
}

/* ---------- visitor recipes (/menu/share/, /menu/r/) ---------- */

.recipe-mine {
  margin: 28px 0;
  padding: 18px 20px;
  border: 2px dashed var(--line);
  border-radius: 14px;
}

.recipe-mine p {
  margin-top: 0;
}

.rs-form {
  display: grid;
  gap: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 32px;
  box-shadow: var(--shadow);
}

.rs-form[hidden] {
  display: none;
}

.rs-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.rs-form label {
  display: grid;
  gap: 4px;
  font-weight: 800;
}

.rs-form label .muted {
  font-weight: 400;
  font-size: 0.85em;
}

.rs-form input,
.rs-form select,
.rs-form textarea {
  font: inherit;
  font-weight: 400;
  width: 100%;
  padding: 8px 12px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--ink);
}

.rs-form textarea {
  resize: vertical;
  line-height: 1.6;
}

.rs-msg {
  margin: 0;
  font-size: 0.9rem;
}

.rs-msg.err {
  color: #c0392b;
  font-weight: 700;
}

.rs-from {
  margin: 0;
}

.rv-new {
  background: #fff4cf;
  border-radius: 10px;
  padding: 10px 14px;
  font-weight: 700;
}

.rv-note {
  margin-top: 28px;
  font-size: 0.85rem;
}

.rv-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 10px;
}

.rv-list a {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 12px;
  align-items: center;
  padding: 12px 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--ink);
}

.rv-list a:hover {
  border-color: var(--ink);
  text-decoration: none;
}

.rv-emoji {
  grid-row: span 2;
  font-size: 32px;
}

.rv-list .muted {
  font-size: 0.85rem;
}

@media (max-width: 520px) {
  .rs-row {
    grid-template-columns: 1fr;
  }
}
