:root {
  --bg: #ece9df;
  --panel: rgba(255, 255, 255, 0.88);
  --border: #8f8973;
  --border-strong: #7d7866;
  --text: #26231d;
  --muted: #5f584d;
  --link: #1f4aa8;
  --accent: #d9d1b8;
  --accent-strong: #c7b78a;
  --notice: #fff7dc;
  --alert: #f6dfdf;
  --header-top: #fffef8;
  --header-bottom: #e8e0c8;
  --bg-gradient-mid: rgba(236, 233, 223, 0.3);
  --surface-subtle: #fbfaf4;
  --surface-soft: #f3eedf;
  --surface-emphasis: #d6c7a1;
  --menu-bg: #fffdf6;
  --menu-card: #faf7ef;
  --shadow-rgb: 94, 89, 75;
  --page-max-width: 1040px;
  --page-padding: 18px;
  --floating-home-size: 54px;
  --overlay-from: rgba(30, 18, 6, 0.18);
  --overlay-to: rgba(20, 12, 4, 0.32);
}

body[data-theme="town_slate"] {
  --panel: rgba(28, 32, 40, 0.86);
  --text: #e8eaf0;
  --muted: #8890a0;
  --border: rgba(100, 112, 135, 0.45);
  --border-strong: rgba(130, 145, 170, 0.65);
  --link: #a0b8d8;
  --accent: rgba(35, 40, 52, 0.92);
  --accent-strong: rgba(60, 70, 90, 0.85);
  --header-top: rgba(18, 22, 30, 0.93);
  --header-bottom: rgba(28, 32, 42, 0.93);
  --surface-subtle: rgba(22, 26, 35, 0.84);
  --surface-soft: rgba(35, 40, 52, 0.84);
  --surface-emphasis: rgba(60, 70, 90, 0.82);
  --menu-bg: rgba(16, 20, 28, 0.97);
  --menu-card: rgba(25, 30, 40, 0.94);
  --shadow-rgb: 10, 12, 20;
  --notice: rgba(20, 30, 55, 0.92);
  --alert: rgba(65, 12, 12, 0.92);
  --panel-heading-from: rgba(45, 52, 68, 0.96);
  --panel-heading-to: rgba(28, 34, 48, 0.96);
  --panel-heading-text: #d0d8e8;
  --panel-heading-border: rgba(100, 115, 148, 0.60);
  --overlay-from: rgba(18, 22, 38, 0.22);
  --overlay-to: rgba(10, 14, 26, 0.40);
}

/* ========================================
   Day Themes (ライト・昼間系 1〜5)
   ======================================== */

body[data-theme="day_slate"] {
  --bg: #d8dde6;
  --bg-gradient-mid: rgba(215, 224, 236, 0.4);
  --panel: rgba(236, 240, 248, 0.86);
  --text: #1e242e;
  --muted: #566070;
  --border: rgba(125, 145, 168, 0.35);
  --border-strong: rgba(98, 120, 148, 0.55);
  --link: #1e4fa0;
  --accent: rgba(212, 220, 234, 0.72);
  --accent-strong: rgba(186, 200, 220, 0.78);
  --header-top: rgba(240, 245, 252, 0.92);
  --header-bottom: rgba(218, 228, 244, 0.92);
  --surface-subtle: rgba(244, 247, 252, 0.84);
  --surface-soft: rgba(225, 232, 244, 0.84);
  --surface-emphasis: rgba(200, 214, 232, 0.82);
  --menu-bg: rgba(247, 250, 254, 0.97);
  --menu-card: rgba(236, 242, 250, 0.95);
  --shadow-rgb: 72, 86, 108;
  --notice: rgba(218, 234, 252, 0.92);
  --alert: rgba(252, 226, 226, 0.92);
  --panel-heading-from: rgba(236, 241, 250, 0.92);
  --panel-heading-to: rgba(214, 226, 244, 0.92);
  --panel-heading-text: #18222e;
  --panel-heading-border: rgba(118, 148, 182, 0.40);
  --overlay-from: rgba(195, 212, 232, 0.06);
  --overlay-to: rgba(162, 188, 215, 0.13);
}

body[data-theme="day_roof"] {
  --bg: #e6ddd2;
  --bg-gradient-mid: rgba(236, 226, 212, 0.4);
  --panel: rgba(250, 245, 238, 0.86);
  --text: #28200e;
  --muted: #6a5840;
  --border: rgba(168, 148, 115, 0.35);
  --border-strong: rgba(145, 122, 88, 0.55);
  --link: #1a4590;
  --accent: rgba(235, 224, 206, 0.72);
  --accent-strong: rgba(215, 198, 172, 0.78);
  --header-top: rgba(254, 250, 244, 0.92);
  --header-bottom: rgba(240, 230, 212, 0.92);
  --surface-subtle: rgba(254, 252, 246, 0.84);
  --surface-soft: rgba(242, 234, 218, 0.84);
  --surface-emphasis: rgba(222, 208, 185, 0.82);
  --menu-bg: rgba(255, 252, 246, 0.97);
  --menu-card: rgba(248, 242, 230, 0.95);
  --shadow-rgb: 108, 88, 60;
  --notice: rgba(224, 238, 255, 0.92);
  --alert: rgba(255, 228, 220, 0.92);
  --panel-heading-from: rgba(230, 212, 185, 0.92);
  --panel-heading-to: rgba(208, 188, 158, 0.92);
  --panel-heading-text: #241808;
  --panel-heading-border: rgba(175, 148, 108, 0.55);
  --overlay-from: rgba(235, 218, 195, 0.06);
  --overlay-to: rgba(215, 195, 165, 0.13);
}

body[data-theme="day_green"] {
  --bg: #d5e4d0;
  --bg-gradient-mid: rgba(210, 232, 205, 0.4);
  --panel: rgba(232, 246, 230, 0.86);
  --text: #182a16;
  --muted: #4a6844;
  --border: rgba(108, 152, 98, 0.35);
  --border-strong: rgba(82, 128, 70, 0.55);
  --link: #1a5820;
  --accent: rgba(205, 235, 200, 0.72);
  --accent-strong: rgba(178, 218, 170, 0.78);
  --header-top: rgba(238, 250, 235, 0.92);
  --header-bottom: rgba(215, 240, 210, 0.92);
  --surface-subtle: rgba(242, 252, 240, 0.84);
  --surface-soft: rgba(220, 242, 215, 0.84);
  --surface-emphasis: rgba(192, 228, 185, 0.82);
  --menu-bg: rgba(244, 254, 242, 0.97);
  --menu-card: rgba(230, 248, 226, 0.95);
  --shadow-rgb: 50, 88, 42;
  --notice: rgba(210, 238, 255, 0.92);
  --alert: rgba(255, 226, 220, 0.92);
  --panel-heading-from: rgba(185, 232, 175, 0.92);
  --panel-heading-to: rgba(158, 215, 145, 0.92);
  --panel-heading-text: #102010;
  --panel-heading-border: rgba(105, 168, 88, 0.55);
  --overlay-from: rgba(190, 225, 182, 0.06);
  --overlay-to: rgba(160, 205, 150, 0.13);
}

body[data-theme="day_water"] {
  --bg: #ccdde6;
  --bg-gradient-mid: rgba(205, 228, 238, 0.4);
  --panel: rgba(228, 244, 250, 0.86);
  --text: #162428;
  --muted: #426878;
  --border: rgba(82, 148, 168, 0.35);
  --border-strong: rgba(58, 125, 148, 0.55);
  --link: #0a5070;
  --accent: rgba(195, 232, 244, 0.72);
  --accent-strong: rgba(165, 215, 232, 0.78);
  --header-top: rgba(232, 250, 255, 0.92);
  --header-bottom: rgba(205, 238, 250, 0.92);
  --surface-subtle: rgba(238, 252, 255, 0.84);
  --surface-soft: rgba(210, 240, 250, 0.84);
  --surface-emphasis: rgba(178, 225, 242, 0.82);
  --menu-bg: rgba(240, 254, 255, 0.97);
  --menu-card: rgba(222, 246, 254, 0.95);
  --shadow-rgb: 40, 88, 108;
  --notice: rgba(210, 235, 255, 0.92);
  --alert: rgba(255, 226, 220, 0.92);
  --panel-heading-from: rgba(172, 225, 242, 0.92);
  --panel-heading-to: rgba(142, 208, 228, 0.92);
  --panel-heading-text: #0e2030;
  --panel-heading-border: rgba(88, 162, 188, 0.55);
  --overlay-from: rgba(182, 218, 235, 0.06);
  --overlay-to: rgba(150, 198, 220, 0.13);
}

body[data-theme="day_magic"] {
  --bg: #ddd5ea;
  --bg-gradient-mid: rgba(228, 218, 242, 0.4);
  --panel: rgba(244, 238, 254, 0.86);
  --text: #201828;
  --muted: #6248a0;
  --border: rgba(148, 115, 188, 0.35);
  --border-strong: rgba(122, 88, 168, 0.55);
  --link: #5820a0;
  --accent: rgba(228, 215, 248, 0.72);
  --accent-strong: rgba(208, 188, 238, 0.78);
  --header-top: rgba(250, 246, 255, 0.92);
  --header-bottom: rgba(235, 224, 252, 0.92);
  --surface-subtle: rgba(252, 248, 255, 0.84);
  --surface-soft: rgba(238, 228, 252, 0.84);
  --surface-emphasis: rgba(218, 200, 245, 0.82);
  --menu-bg: rgba(252, 249, 255, 0.97);
  --menu-card: rgba(244, 235, 254, 0.95);
  --shadow-rgb: 80, 48, 120;
  --notice: rgba(218, 228, 255, 0.92);
  --alert: rgba(255, 226, 220, 0.92);
  --panel-heading-from: rgba(215, 192, 248, 0.92);
  --panel-heading-to: rgba(188, 162, 232, 0.92);
  --panel-heading-text: #160e28;
  --panel-heading-border: rgba(148, 105, 215, 0.55);
  --overlay-from: rgba(210, 192, 238, 0.06);
  --overlay-to: rgba(185, 162, 220, 0.13);
}

body[data-theme="town_roof"] {
  --panel: rgba(20, 28, 38, 0.86);
  --text: #dce4f0;
  --muted: #7888a0;
  --border: rgba(80, 100, 130, 0.45);
  --border-strong: rgba(105, 130, 165, 0.65);
  --link: #88b0d8;
  --accent: rgba(25, 35, 50, 0.92);
  --accent-strong: rgba(45, 60, 82, 0.85);
  --header-top: rgba(14, 20, 30, 0.93);
  --header-bottom: rgba(22, 30, 44, 0.93);
  --surface-subtle: rgba(18, 25, 36, 0.84);
  --surface-soft: rgba(28, 38, 55, 0.84);
  --surface-emphasis: rgba(50, 68, 92, 0.82);
  --menu-bg: rgba(12, 18, 28, 0.97);
  --menu-card: rgba(20, 28, 42, 0.94);
  --shadow-rgb: 5, 10, 20;
  --notice: rgba(15, 25, 55, 0.92);
  --alert: rgba(65, 12, 12, 0.92);
  --panel-heading-from: rgba(35, 50, 72, 0.96);
  --panel-heading-to: rgba(22, 32, 50, 0.96);
  --panel-heading-text: #c8d8f0;
  --panel-heading-border: rgba(80, 110, 155, 0.60);
  --overlay-from: rgba(10, 16, 30, 0.26);
  --overlay-to: rgba(6, 10, 20, 0.44);
}

body[data-theme="town_green"] {
  --panel: rgba(14, 26, 10, 0.86);
  --text: #d8ecd0;
  --muted: #708860;
  --border: rgba(70, 110, 50, 0.45);
  --border-strong: rgba(95, 140, 68, 0.65);
  --link: #88c870;
  --accent: rgba(18, 34, 12, 0.92);
  --accent-strong: rgba(38, 62, 25, 0.85);
  --header-top: rgba(10, 20, 8, 0.93);
  --header-bottom: rgba(18, 32, 12, 0.93);
  --surface-subtle: rgba(12, 22, 8, 0.84);
  --surface-soft: rgba(22, 38, 15, 0.84);
  --surface-emphasis: rgba(42, 68, 28, 0.82);
  --menu-bg: rgba(8, 18, 6, 0.97);
  --menu-card: rgba(14, 26, 10, 0.94);
  --shadow-rgb: 5, 15, 2;
  --notice: rgba(12, 35, 10, 0.92);
  --alert: rgba(65, 12, 12, 0.92);
  --panel-heading-from: rgba(30, 55, 20, 0.96);
  --panel-heading-to: rgba(18, 36, 12, 0.96);
  --panel-heading-text: #c0e0a8;
  --panel-heading-border: rgba(70, 118, 45, 0.60);
  --overlay-from: rgba(8, 22, 5, 0.20);
  --overlay-to: rgba(5, 14, 3, 0.36);
}

body[data-theme="town_water"] {
  --panel: rgba(10, 28, 28, 0.86);
  --text: #cce8e8;
  --muted: #609090;
  --border: rgba(55, 110, 110, 0.45);
  --border-strong: rgba(75, 142, 140, 0.65);
  --link: #70c0c0;
  --accent: rgba(12, 36, 36, 0.92);
  --accent-strong: rgba(28, 68, 65, 0.85);
  --header-top: rgba(6, 20, 20, 0.93);
  --header-bottom: rgba(12, 32, 32, 0.93);
  --surface-subtle: rgba(8, 22, 22, 0.84);
  --surface-soft: rgba(16, 38, 38, 0.84);
  --surface-emphasis: rgba(32, 68, 65, 0.82);
  --menu-bg: rgba(5, 16, 16, 0.97);
  --menu-card: rgba(10, 26, 26, 0.94);
  --shadow-rgb: 2, 12, 12;
  --notice: rgba(8, 30, 35, 0.92);
  --alert: rgba(65, 12, 12, 0.92);
  --panel-heading-from: rgba(22, 55, 52, 0.96);
  --panel-heading-to: rgba(12, 36, 34, 0.96);
  --panel-heading-text: #a8d8d8;
  --panel-heading-border: rgba(55, 120, 118, 0.60);
  --overlay-from: rgba(5, 20, 20, 0.22);
  --overlay-to: rgba(3, 12, 12, 0.38);
}

body[data-theme="town_magic"] {
  --panel: rgba(20, 14, 48, 0.86);
  --text: #ddd0f8;
  --muted: #8870c0;
  --border: rgba(100, 75, 175, 0.45);
  --border-strong: rgba(130, 100, 210, 0.65);
  --link: #b090e8;
  --accent: rgba(28, 18, 62, 0.92);
  --accent-strong: rgba(55, 38, 110, 0.85);
  --header-top: rgba(14, 8, 38, 0.93);
  --header-bottom: rgba(22, 14, 55, 0.93);
  --surface-subtle: rgba(16, 10, 42, 0.84);
  --surface-soft: rgba(28, 18, 65, 0.84);
  --surface-emphasis: rgba(55, 38, 110, 0.82);
  --menu-bg: rgba(10, 6, 30, 0.97);
  --menu-card: rgba(18, 12, 48, 0.94);
  --shadow-rgb: 15, 5, 30;
  --notice: rgba(15, 10, 55, 0.92);
  --alert: rgba(65, 12, 12, 0.92);
  --panel-heading-from: rgba(45, 28, 100, 0.96);
  --panel-heading-to: rgba(28, 16, 68, 0.96);
  --panel-heading-text: #c8b0f0;
  --panel-heading-border: rgba(110, 80, 200, 0.60);
  --overlay-from: rgba(15, 5, 32, 0.24);
  --overlay-to: rgba(10, 3, 22, 0.42);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.65) 0%, var(--bg-gradient-mid) 180px, var(--bg) 180px),
    var(--bg);
  color: var(--text);
  font-family: "Verdana", "Geneva", sans-serif;
  font-size: 15px;
  line-height: 1.5;
}


a {
  color: var(--link);
}

.page {
  max-width: var(--page-max-width);
  margin: 0 auto;
  padding: var(--page-padding);
  box-sizing: border-box;
}

body.admin-dungeon-balance-page .page {
  max-width: none;
  width: 100%;
}

.site-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 16px;
  padding: 14px 18px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--header-top) 88%, transparent) 0%, color-mix(in srgb, var(--header-bottom) 88%, transparent) 100%);
  border: 1px solid var(--border-strong);
  box-shadow: 3px 3px 0 rgba(var(--shadow-rgb), 0.12);
  backdrop-filter: blur(4px);
  position: relative;
  z-index: 50;
}

.site-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-title {
  margin: 0;
  font-size: 1.5rem;
  letter-spacing: 0.03em;
}

.site-subtitle {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.site-nav {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.locale-switch-select {
  min-width: 92px;
  height: 30px;
  padding: 2px 24px 2px 8px;
  border: 1px solid var(--border-strong);
  background: var(--menu-bg);
  color: var(--text);
  font: inherit;
  line-height: 1;
  text-align-last: center;
  box-sizing: border-box;
}

.locale-switch-select option {
  background: var(--menu-bg);
  color: var(--text);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.mobile-exploration-page .site-header {
  display: none;
}

.mobile-exploration-page .page-body {
  padding-top: 0;
}

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

.inline-button-form {
  display: inline;
  margin: 0;
}

.panel {
  margin-bottom: 16px;
  padding: 16px;
  background: var(--panel);
  border: 1px solid var(--border);
  box-shadow: 3px 3px 0 rgba(var(--shadow-rgb), 0.08);
}

.panel-heading-link {
  color: inherit;
  text-decoration: none;
}

.panel-heading-link:hover {
  text-decoration: underline;
}

.panel-heading {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: -16px -16px 16px;
  padding: 8px 16px;
  background: var(--accent);
  border-bottom: 1px solid var(--border);
  font-weight: bold;
  font-size: 0.9rem;
  text-align: center;
}

.panel h2 {
  margin: 0 0 10px;
  font-size: 1.15rem;
}

.panel p:last-child {
  margin-bottom: 0;
}

.site-footer {
  margin: 24px 0 0;
  padding: 14px 12px 12px;
  background: color-mix(in srgb, var(--panel) 88%, transparent);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.82rem;
  text-align: center;
  box-shadow: 2px 2px 0 rgba(var(--shadow-rgb), 0.1);
}

.site-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 14px;
  margin-bottom: 8px;
}

.site-footer-links a {
  color: var(--text);
  font-weight: bold;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.site-footer-copy {
  margin: 0;
  color: var(--text);
  opacity: 0.85;
}

.legal-document {
  line-height: 1.8;
}

.legal-document-updated {
  margin: -2px 0 18px;
  color: var(--muted);
  font-size: 0.86rem;
}

.legal-document-section {
  margin-top: 22px;
}

.legal-document-section h3 {
  margin: 0 0 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
  font-size: 1rem;
}

.legal-document-section p,
.legal-document-section ul {
  margin: 8px 0 0;
}

.legal-document-section ul {
  padding-left: 1.35rem;
}

.legal-document-contact {
  margin-top: 24px;
  text-align: center;
}

.hero {
  background: var(--panel);
  border: 1px solid var(--border-strong);
  position: relative;
}

.hero-title {
  margin: 0 0 10px;
  font-size: 1.6rem;
}

.mypage-hero-panels {
  display: flex;
  align-items: stretch;
  gap: 10px;
}

.mypage-player-panel {
  flex: 0 0 clamp(11rem, 18%, 12rem);
  text-align: center;
  border-color: var(--border);
}

.mypage-player-panel .exploration-player-badge {
  float: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.mypage-player-panel .mypage-player-info {
  width: 100%;
  font-size: 0.92rem;
  line-height: 1.45;
}

.mypage-player-panel .mypage-player-info p {
  margin: 0 0 6px;
}

.mypage-player-panel .mypage-player-info p:last-child {
  margin-bottom: 0;
}

.mypage-player-job p {
  margin: 0;
}

.mypage-player-notices {
  display: grid;
  gap: 4px;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid color-mix(in srgb, var(--border) 76%, transparent);
}

.mypage-player-notice {
  display: block;
  padding: 1px 0;
  font-size: 0.82rem;
  line-height: 1.25;
}

.mypage-status-panel {
  border-color: var(--border);
}

.mypage-hero-panels .mypage-town-map-panel {
  flex: 1 1 0;
  min-width: 0;
}

.mypage-hero-bar {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.mypage-hero-copy {
  min-width: 0;
  flex: 1;
}

.mypage-hero-copy h2 {
  font-size: 0.8rem;
  font-weight: normal;
  color: var(--muted);
  margin: 0 0 4px;
}

.mypage-hero-copy p {
  margin: 0;
}

.mypage-stamina-badge {
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
  margin: 4px 0 0;
}


.exploration-intro-panel {
  overflow: hidden;
}

.exploration-player-badge {
  float: left;
  margin: 0 12px 10px 0;
}

.exploration-player-vitals {
  margin-top: 6px;
  font-size: 0.9rem;
  line-height: 1.4;
  text-align: left;
}

.hero-copy {
  max-width: 48rem;
}

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

.public-home-page .site-header,
.public-auth-page .site-header {
  background: rgba(20, 26, 36, 0.92);
  border-color: rgba(145, 160, 190, 0.48);
  box-shadow: 3px 3px 0 rgba(10, 12, 20, 0.22);
}

.public-home-page .site-title a,
.public-auth-page .site-title a,
.public-home-page .site-nav a,
.public-auth-page .site-nav a {
  color: #d8e4f4;
}

.public-hero-panel,
.public-loop-panel,
.public-party-panel,
.public-closing-panel,
.auth-panel,
.auth-guide-panel {
  background: rgba(18, 22, 32, 0.88);
  border-color: rgba(145, 160, 190, 0.46);
  color: #f4f0e8;
  box-shadow: 3px 3px 0 rgba(10, 12, 20, 0.22);
}

.public-hero-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(20rem, 1.04fr);
  gap: 18px;
  align-items: stretch;
  padding: 22px 18px;
}

.public-hero-copy-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.public-hero-kicker,
.auth-kicker {
  margin-bottom: 5px;
  color: #b6c5d8;
  font-size: 0.82rem;
  font-weight: 700;
}

.public-hero-title {
  color: #f1d27a;
  font-size: 2rem;
  line-height: 1.1;
}

.public-home-page .hero-copy,
.auth-heading p {
  color: #f0e6d0;
}

.public-encounter-card {
  display: grid;
  gap: 9px;
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(145, 160, 190, 0.34);
  background:
    linear-gradient(180deg, rgba(10, 14, 22, 0.30) 0%, rgba(5, 8, 14, 0.78) 100%),
    rgba(10, 14, 22, 0.50);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

.public-encounter-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 8px;
  align-items: end;
  min-height: 200px;
  padding: 6px 6px 0;
  overflow: hidden;
}

.public-combatant {
  display: grid;
  justify-items: center;
  gap: 4px;
  min-width: 0;
}

.public-combatant-image {
  width: min(165px, 100%);
  aspect-ratio: 1;
  object-fit: contain;
  filter: drop-shadow(0 10px 10px rgba(0, 0, 0, 0.44));
}

.public-combatant-enemy .public-combatant-image {
  transform: scaleX(-1);
}

.public-combatant-name {
  max-width: 100%;
  padding: 2px 7px;
  border: 1px solid rgba(145, 160, 190, 0.28);
  background: rgba(10, 14, 22, 0.70);
  color: #f4f0e8;
  font-size: 0.78rem;
  font-weight: 700;
  text-align: center;
}

.public-versus {
  align-self: center;
  color: #f1d27a;
  font-family: Georgia, serif;
  font-size: 1.15rem;
  font-weight: 700;
}

.public-hp-bar {
  width: min(8rem, 100%);
  height: 7px;
  border: 1px solid rgba(145, 160, 190, 0.35);
  background: rgba(5, 8, 14, 0.80);
}

.public-hp-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #7cc26e 0%, #e8d56a 100%);
}

.public-hp-bar-enemy span {
  background: linear-gradient(90deg, #b95454 0%, #e8d56a 100%);
}

.public-hero-log {
  display: grid;
  gap: 5px;
  padding: 9px 10px;
  border: 1px solid rgba(145, 160, 190, 0.32);
  background: rgba(5, 8, 14, 0.58);
}

.public-hero-log p {
  margin: 0;
  padding-bottom: 5px;
  border-bottom: 1px dotted rgba(145, 160, 190, 0.25);
  color: #f4f0e8;
  font-size: 0.86rem;
}

.public-hero-log p:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.public-hero-reward {
  padding: 6px 9px;
  border: 1px solid rgba(241, 210, 122, 0.28);
  background: rgba(40, 32, 18, 0.62);
  color: #f1d27a;
  font-size: 0.84rem;
  font-weight: 700;
}

.public-hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.public-hero-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 1.8rem;
  padding: 3px 8px;
  border: 1px solid rgba(145, 160, 190, 0.34);
  background: rgba(10, 14, 22, 0.46);
  color: #e6edf6;
  font-size: 0.82rem;
}

.public-home-page .action-link,
.public-auth-page .action-link,
.public-auth-page .action-button {
  border-color: rgba(145, 160, 190, 0.42);
  background: linear-gradient(180deg, rgba(28, 36, 50, 0.92) 0%, rgba(16, 22, 34, 0.94) 100%);
  color: #f4f0e8;
}

.public-home-page .action-link:hover,
.public-auth-page .action-link:hover,
.public-auth-page .action-button:hover:not(:disabled) {
  border-color: rgba(190, 205, 230, 0.62);
  background: linear-gradient(180deg, rgba(42, 52, 70, 0.96) 0%, rgba(24, 32, 48, 0.96) 100%);
}

.public-home-primary {
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.82fr);
}

.public-loop-steps {
  display: grid;
  gap: 9px;
}

.public-loop-step {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 10px;
  border: 1px solid rgba(145, 160, 190, 0.30);
  background: rgba(10, 14, 22, 0.40);
}

.public-loop-step strong {
  display: block;
  margin-bottom: 2px;
  color: #f1d27a;
}

.public-loop-step p {
  margin: 0;
  color: #f0e6d0;
}

.public-loop-index {
  display: inline-grid;
  place-items: center;
  width: 1.8rem;
  height: 1.8rem;
  border: 1px solid rgba(241, 210, 122, 0.38);
  background: rgba(40, 32, 18, 0.70);
  color: #f1d27a;
  font-weight: 700;
}

.public-preview-note {
  margin: 10px 0 0;
  color: #b6c5d8;
  font-size: 0.88rem;
}

.public-party-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
  padding: 8px;
  border: 1px solid rgba(145, 160, 190, 0.28);
  background: rgba(10, 14, 22, 0.40);
}

.public-party-image {
  width: 100%;
  max-height: 118px;
  object-fit: contain;
  filter: drop-shadow(0 8px 8px rgba(0, 0, 0, 0.42));
}

.public-party-enemy {
  transform: scaleX(-1);
}

.public-closing-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(13rem, auto);
  gap: 14px;
  align-items: start;
}

.public-closing-copy p {
  margin: 0;
  color: #f0e6d0;
}

.public-closing-actions {
  display: grid;
  gap: 8px;
  min-width: 14rem;
}

body.public-home-page {
  --page-max-width: 1500px;
  --page-padding: 8px 18px 24px;
  --overlay-from: rgba(4, 7, 12, 0.03);
  --overlay-to: rgba(4, 7, 12, 0.16);
  --public-top-bg-x: 44%;
  --public-top-bg-y: top;
  --public-sp-bg-y: -68px;
  --public-sp-cta-bottom: 25px;
  --public-top-bg-size: 100% auto;
  background:
    linear-gradient(180deg, var(--overlay-from) 0%, var(--overlay-to) 100%),
    url("/assets/site/top/lp/pc/hero-dungeon-gate-bg-d5b504d6.webp") var(--public-top-bg-x) var(--public-top-bg-y) / var(--public-top-bg-size) no-repeat #05080d;
  color: #f3ead6;
}

body.public-home-page .page {
  width: min(100%, 1500px);
}

body.public-home-page .site-header {
  margin: 0 0 10px;
  padding: 14px 24px;
  border-color: #a77a32;
  background: linear-gradient(180deg, rgba(9, 16, 24, 0.98), rgba(5, 10, 16, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(236, 205, 128, 0.12),
    0 3px 0 rgba(0, 0, 0, 0.36);
}

body.public-home-page .site-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.7rem, 2.3vw, 2.2rem);
  line-height: 1;
}

body.public-home-page .site-title a,
body.public-home-page .site-nav a {
  color: #ead29a;
  text-decoration: none;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.7);
}

body.public-home-page .site-nav {
  gap: 18px;
}

body.public-home-page .locale-switch-select {
  min-width: 112px;
  height: 40px;
  border-color: #8e6934;
  background: #0a111b;
  color: #f5ead0;
  box-shadow: inset 0 0 0 1px rgba(236, 205, 128, 0.08);
}

.public-lp-shell {
  position: relative;
  display: grid;
  gap: 16px;
  padding: 0;
  background: transparent;
}

.public-lp-hero {
  position: relative;
  z-index: 1;
  min-height: 560px;
  overflow: hidden;
  border: 0;
  background: transparent;
  box-shadow: none;
  --public-lp-hero-bg-x: 44%;
  --public-lp-hero-bg-y: top;
  --public-lp-hero-bg-size: auto 100%;
}

.public-lp-hero::before,
.public-lp-hero::after {
  content: none;
}

.public-lp-hero-top {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 64px 70px 120px;
}

.public-lp-title-card,
.public-lp-bonus-card,
.public-lp-feature,
.public-lp-stat-strip {
  background:
    linear-gradient(180deg, rgba(12, 19, 28, 0.94), rgba(5, 10, 16, 0.94));
  border: 1px solid #9f7433;
  color: #f4ead5;
  box-shadow:
    inset 0 0 0 1px rgba(236, 205, 128, 0.11),
    3px 3px 0 rgba(0, 0, 0, 0.34);
}

.public-lp-title-card {
  position: relative;
  width: min(500px, 43vw);
  min-height: 406px;
  padding: 138px 56px 42px;
  border: 0;
  background:
    url("/assets/site/top/lp/pc/title-card-frame-66a1219d.webp") center center / 100% 100% no-repeat;
  box-shadow: none;
  text-align: center;
}

.public-lp-title-card::before,
.public-lp-title-card::after {
  content: none;
}

.public-lp-title-card h2 {
  margin: 0 0 18px;
  color: #efd493;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 3rem;
  font-weight: 700;
  line-height: 0.95;
  text-shadow: 0 3px 0 rgba(0, 0, 0, 0.72);
}

.public-lp-lead {
  margin: 0 0 12px;
  color: #f4ead5;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.1rem, 1.6vw, 1.45rem);
  font-weight: 700;
}

.public-lp-copy {
  margin: 0;
  color: #e6dcc7;
  font-size: 0.95rem;
  line-height: 1.8;
}

.public-lp-bonus-card {
  width: 230px;
  margin-top: 128px;
  padding: 16px 16px 14px;
}

.public-lp-bonus-card h3 {
  margin: 0 0 10px;
  color: #efd493;
  font-size: 1rem;
  text-align: center;
}

.public-lp-bonus-row {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-top: 1px solid rgba(236, 205, 128, 0.24);
  color: #fff;
  text-align: center;
}

.public-lp-bonus-row strong {
  color: #fff;
  font-weight: 700;
}

.public-lp-cta-row {
  position: absolute;
  z-index: 2;
  left: clamp(360px, 31vw, 560px);
  right: 92px;
  bottom: 26px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.public-lp-button {
  position: relative;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 68px;
  padding: 12px 54px 12px 34px;
  border: 1px solid #af822e;
  color: #f9efd9;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.45rem, 2.2vw, 2.25rem);
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
  text-decoration: none;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.62);
  box-shadow:
    inset 0 0 0 2px rgba(255, 244, 190, 0.14),
    0 4px 0 rgba(0, 0, 0, 0.42);
}

.public-lp-button::after {
  content: "›";
  position: absolute;
  right: 22px;
  color: #fff2c6;
  font-size: 2.1rem;
  line-height: 1;
}

.public-lp-button-primary {
  background: linear-gradient(180deg, #c49a43 0%, #8c651f 100%);
}

.public-lp-button-secondary {
  border-color: #5f7790;
  background: linear-gradient(180deg, #243d56 0%, #102132 100%);
}

.public-lp-button-form {
  margin: 0;
}

.public-lp-button-form .public-lp-button {
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.public-lp-button-trial {
  border-color: #7e936b;
  background: linear-gradient(180deg, #3d684f 0%, #203b2d 100%);
}

.public-lp-button:hover {
  filter: brightness(1.08);
}

.public-lp-features {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.public-lp-feature {
  position: relative;
  display: grid;
  gap: 12px;
  min-height: 248px;
  padding: 18px 20px 20px;
  text-decoration: none;
  --public-lp-feature-image-x: 50%;
  --public-lp-feature-image-y: 50%;
}

.public-lp-feature:nth-child(1) {
  --public-lp-feature-image-x: 17%;
}

.public-lp-feature:nth-child(2) {
  --public-lp-feature-image-x: 91%;
}

.public-lp-feature:nth-child(3) {
  --public-lp-feature-image-x: 60%;
}

.public-lp-feature:hover {
  filter: brightness(1.07);
}

.public-lp-feature-heading {
  display: flex;
  align-items: center;
  gap: 12px;
}

.public-lp-feature-icon {
  display: inline-grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border: 1px solid rgba(236, 205, 128, 0.42);
  background: rgba(31, 38, 35, 0.80);
  color: #efd493;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
}

.public-lp-feature h3 {
  margin: 0;
  color: #efd493;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.45rem;
}

.public-lp-feature-picture {
  display: block;
  width: 100%;
}

.public-lp-feature-image {
  display: block;
  width: 100%;
  aspect-ratio: 2.75 / 1;
  object-fit: cover;
  object-position: var(--public-lp-feature-image-x) var(--public-lp-feature-image-y);
  border: 1px solid rgba(236, 205, 128, 0.36);
  background: #06090d;
}

.public-lp-feature p {
  margin: 0;
  padding-right: 24px;
  color: #e6dcc7;
  font-size: 0.92rem;
  line-height: 1.65;
}

.public-lp-feature-arrow {
  position: absolute;
  right: 18px;
  bottom: 16px;
  color: #f0d48a;
  font-size: 2rem;
  line-height: 1;
}

.public-lp-stat-strip {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  min-height: 82px;
  padding: 0;
}

.public-lp-stat-item {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-content: center;
  min-width: 0;
  padding: 12px 36px 12px 24px;
  border-right: 1px solid rgba(236, 205, 128, 0.24);
}

.public-lp-stat-item:last-child {
  border-right: 0;
}

.public-lp-stat-label {
  color: #d7c39a;
  font-size: 0.82rem;
}

.public-lp-stat-item strong {
  color: #efd493;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.75rem;
  line-height: 1;
  white-space: nowrap;
}

.public-lp-stat-arrow {
  position: absolute;
  right: 14px;
  top: 50%;
  color: #f0d48a;
  font-size: 1.5rem;
  transform: translateY(-50%);
}

.auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 30rem) minmax(16rem, 1fr);
  gap: 16px;
  align-items: start;
  max-width: 860px;
}

.auth-heading h2 {
  margin: 0 0 8px;
  color: #f1d27a;
  font-size: 1.55rem;
}

.auth-form {
  display: grid;
  gap: 12px;
}

.auth-field {
  display: grid;
  gap: 5px;
}

.auth-field label,
.auth-check {
  color: #e6edf6;
  font-weight: 700;
}

.auth-field-hint {
  color: #b6c5d8;
  font-size: 0.82rem;
}

.auth-input {
  width: 100%;
  box-sizing: border-box;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid rgba(145, 160, 190, 0.55);
  background: rgba(246, 242, 230, 0.96);
  color: #1f2430;
  font: inherit;
}

.auth-input:focus {
  outline: 2px solid rgba(241, 210, 122, 0.52);
  outline-offset: 1px;
}

.auth-check {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-size: 0.9rem;
}

.auth-actions {
  margin-top: 2px;
}

.trial-play-auth-action {
  margin-top: 12px;
}

.auth-submit {
  justify-content: flex-start;
}

.auth-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 14px;
}

.auth-links a {
  color: #c6d7ef;
}

.auth-guide-list {
  margin: 0;
  padding-left: 18px;
  color: #f0e6d0;
}

.auth-guide-list li + li {
  margin-top: 7px;
}

.auth-error-panel {
  padding: 10px 12px;
  border: 1px solid rgba(214, 110, 110, 0.60);
  background: rgba(65, 12, 12, 0.74);
  color: #ffe6e6;
}

.auth-error-panel ul {
  margin: 8px 0 0;
  padding-left: 18px;
}

body.public-auth-page {
  --page-max-width: 1500px;
  --page-padding: 8px 18px 24px;
  background:
    linear-gradient(180deg, rgba(4, 8, 12, 0.05), rgba(4, 8, 12, 0.48)),
    url("/assets/site/top/lp/pc/hero-dungeon-gate-bg-d5b504d6.webp") center top / cover no-repeat #05080d !important;
  color: #f8efd9;
}

body.public-auth-page .page {
  width: min(100%, 1500px);
}

body.public-auth-page .site-header {
  margin: 0 0 10px;
  padding: 14px 24px;
  border-color: #a77a32;
  background: linear-gradient(180deg, rgba(9, 16, 24, 0.98), rgba(5, 10, 16, 0.98));
  box-shadow:
    inset 0 0 0 1px rgba(236, 205, 128, 0.12),
    0 3px 0 rgba(0, 0, 0, 0.36);
}

body.public-auth-page .site-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.7rem, 2.3vw, 2.2rem);
  line-height: 1;
}

body.public-auth-page .site-title a,
body.public-auth-page .site-nav a {
  color: #ead29a;
  text-decoration: none;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.7);
}

body.public-auth-page .site-title a {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

body.public-auth-page .site-title a::before {
  content: "";
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  background: url("/assets/site/top/lp/pc/crest-emblem-7014fe92.webp") center / contain no-repeat;
  filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.72));
}

body.public-auth-page .locale-switch-select {
  min-width: 112px;
  height: 40px;
  border-color: #8e6934;
  background: #0a111b;
  color: #f5ead0;
  box-shadow: inset 0 0 0 1px rgba(236, 205, 128, 0.08);
}

body.public-auth-page .page-body {
  position: relative;
  min-height: calc(100vh - 112px);
}

body.public-auth-page .page-body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 38%, transparent 0 22%, rgba(2, 5, 9, 0.08) 42%, rgba(2, 5, 9, 0.38) 100%),
    linear-gradient(90deg, rgba(3, 6, 9, 0.46), transparent 25%, transparent 72%, rgba(3, 6, 9, 0.50));
}

body.public-auth-page .auth-shell {
  display: grid;
  grid-template-columns: minmax(22rem, 460px) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
  max-width: none;
  min-height: calc(100vh - 112px);
  padding: 66px 58px 34px;
}

body.public-auth-page .auth-panel {
  margin: 0;
  padding: 22px;
  border: 1px solid rgba(238, 203, 128, 0.72);
  background: linear-gradient(180deg, rgba(10, 18, 26, 0.96), rgba(4, 9, 14, 0.96));
  box-shadow:
    inset 0 0 0 1px rgba(238, 203, 128, 0.12),
    4px 4px 0 rgba(0, 0, 0, 0.40);
}

body.public-auth-page .auth-heading h2 {
  margin: 0 0 10px;
  color: #efd493;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
  line-height: 1.05;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.78);
}

body.public-auth-page .trial-play-registration-title {
  display: grid;
  gap: 4px;
}

body.public-auth-page .trial-play-registration-title-context {
  display: block;
  color: #d7c39a;
  font-size: 0.92rem;
  line-height: 1.2;
}

body.public-auth-page .trial-play-registration-title-main {
  display: block;
}

body.public-auth-page .auth-kicker {
  margin-bottom: 8px;
  color: #d7c39a;
  font-size: 0.82rem;
}

body.public-auth-page .auth-heading p {
  margin: 0 0 16px;
  color: #f2e5cb;
  font-weight: 700;
  line-height: 1.55;
}

body.public-auth-page .auth-form {
  gap: 13px;
}

body.public-auth-page .auth-field label,
body.public-auth-page .auth-check {
  color: #dec794;
  font-size: 0.88rem;
}

body.public-auth-page .auth-field-hint {
  color: #c9b888;
}

body.public-auth-page .auth-input {
  min-height: 45px;
  border: 1px solid rgba(238, 203, 128, 0.38);
  background: rgba(2, 7, 12, 0.82);
  color: #f8efd9;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.38);
}

body.public-auth-page .auth-submit {
  position: relative;
  justify-content: center;
  width: 100%;
  min-height: 58px;
  padding: 10px 50px 10px 22px;
  border: 1px solid #cfa44f;
  color: #fff7df;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.55rem;
  font-weight: 700;
  text-align: center;
  text-shadow: 0 3px 0 rgba(0, 0, 0, 0.62);
  background: linear-gradient(180deg, #d2a64a 0%, #8e641d 100%);
  box-shadow:
    inset 0 0 0 2px rgba(255, 244, 190, 0.14),
    0 4px 0 rgba(0, 0, 0, 0.42);
}

body.public-auth-page .auth-submit:hover:not(:disabled) {
  border-color: #e3bd63;
  background: linear-gradient(180deg, #ddb458 0%, #9d7024 100%);
}

body.public-auth-page .auth-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 16px;
}

body.public-auth-page .auth-links a {
  color: #efd493;
  font-weight: 700;
}

.auth-hero {
  max-width: 650px;
  justify-self: center;
  text-align: center;
}

.auth-hero h1 {
  margin: 0;
  color: #efd493;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(4rem, 5.6vw, 5.2rem);
  font-weight: 700;
  line-height: 0.98;
  text-shadow:
    0 4px 0 rgba(0, 0, 0, 0.78),
    0 0 14px rgba(0, 0, 0, 0.84);
}

.auth-hero-lead {
  margin: 22px 0 0;
  color: #fff1c6;
  font-size: clamp(1.45rem, 2vw, 1.9rem);
  font-weight: 700;
  line-height: 1.35;
  text-shadow: 0 3px 0 rgba(0, 0, 0, 0.78);
}

.auth-hero-copy {
  max-width: 36rem;
  margin: 16px auto 0;
  color: #fff7e8;
  font-weight: 700;
  line-height: 1.75;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.82);
}

.two-column {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 16px;
}

.delve-result-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.delve-result-main-panel,
.delve-result-summary-panel,
.delve-battle-log-panel {
  background: rgba(18, 12, 6, 0.84);
}

.delve-result-summary-panel {
  align-self: start;
}

.delve-result-title {
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(180, 140, 60, 0.34);
}

.delve-result-title h2 {
  color: #f1d27a;
  font-size: 1.28rem;
}

.admin-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.admin-form-grid label {
  display: block;
  margin: 10px 0 6px;
}

.admin-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}

.three-column {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.mypage-primary-grid {
  align-items: start;
}

.info-card {
  padding: 12px;
  border: 1px solid var(--border);
  background: #fbfaf4;
}

.info-card-locked {
  background: #f3eee3;
  opacity: 0.9;
}

.info-card h3 {
  margin: 0 0 8px;
  font-size: 1rem;
}

.info-card p,
.info-card ul {
  margin: 0;
}

.key-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.stat-box {
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--surface-soft, #fbfaf4);
}

.key-stat-progress {
  margin-top: 8px;
  margin-bottom: 0;
  height: 18px;
  position: relative;
}

.stat-label {
  display: block;
  color: var(--muted);
  font-size: 0.85rem;
}

.stat-value {
  display: block;
  font-size: 1.2rem;
  font-weight: bold;
}

.stat-ready-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #f59e0b;
  color: #fff;
  font-size: 0.65rem;
  font-weight: bold;
  margin-left: 4px;
  text-decoration: none;
  vertical-align: text-top;
  line-height: 1;
  transition: opacity 0.15s;
  animation: town-spot-badge-blink 1.4s ease-in-out infinite;
}

.quest-reward-ready {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #f59e0b;
  color: #fff;
  font-size: 0.65rem;
  font-weight: bold;
  line-height: 1;
  box-shadow: 0 1px 3px rgba(48, 44, 34, 0.18);
  flex: 0 0 auto;
}

.stat-ready-link:hover {
  opacity: 0.8;
}

.player-avatar {
  display: inline-flex;
  width: 40px;
  height: 40px;
  border-radius: 0;
  background: var(--panel);
  object-fit: cover;
  object-position: center;
  overflow: hidden;
  vertical-align: middle;
  flex: 0 0 auto;
}

.player-avatar-sprite-frame {
  align-items: center;
  justify-content: center;
  background: var(--panel);
}

.player-avatar-sprite {
  --sprite-frame-count: 1;
  --sprite-frame-width: 40px;
  --sprite-frame-height: 40px;
  --sprite-columns: 1;
  --sprite-rows: 1;
  display: block;
  width: var(--sprite-frame-width);
  height: var(--sprite-frame-height);
  background-color: transparent;
  background-position: 0 0;
  background-repeat: no-repeat;
  background-size: calc(var(--sprite-columns) * var(--sprite-frame-width)) calc(var(--sprite-rows) * var(--sprite-frame-height));
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.equipment-layer-avatar {
  --equipment-layer-avatar-size: 40px;
  position: relative;
  align-items: center;
  justify-content: center;
  background: transparent;
}

.equipment-layer-avatar.is-loading .equipment-layer-avatar-image {
  visibility: hidden;
}

.equipment-layer-avatar-image {
  position: absolute;
  top: 50%;
  left: 50%;
  display: block;
  width: var(--equipment-layer-avatar-size);
  height: var(--equipment-layer-avatar-size);
  object-fit: contain;
  transform-origin: center center;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  user-select: none;
  pointer-events: none;
}

.player-avatar-placeholder {
  align-items: center;
  justify-content: center;
  background: #e2d7bd;
  color: var(--text);
  font-weight: bold;
}

.exploration-player-avatar {
  width: 80px;
  height: 80px;
  border-radius: 0;
  background: transparent;
}

.mypage-job-portrait {
  width: 120px;
  height: 120px;
}

.profile-header {
  align-items: center;
}

.profile-header-main {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.player-name-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.text-input,
.file-input {
  width: 100%;
  max-width: 100%;
}

.radio-group {
  display: flex;
  gap: 20px;
  margin-bottom: 12px;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.quest-progress-text {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: bold;
  color: var(--text);
}

.panel-link-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 2px;
  margin-bottom: 10px;
}

.panel-inline-link {
  color: var(--link);
  text-decoration: underline;
}

.action-grid-separator {
  grid-column: 1 / -1;
  border: none;
  border-top: 1px solid var(--border);
  margin: 2px 0;
}

.action-link.action-link-primary::before,
.action-button.action-link-primary::before {
  background: linear-gradient(180deg, #6b9fd4 0%, #2d6b9b 100%);
}


.mypage-hero-copy .mypage-status-table {
  table-layout: fixed;
  width: 100%;
  margin-top: 4px;
  margin-bottom: 4px;
}

.mypage-hero-copy .mypage-status-table th {
  width: 22%;
}

.action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.action-group form,
.action-group .button_to {
  margin: 0;
}

.action-group {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.action-group-span-2 {
  grid-column: 1 / -1;
}

.action-group form {
  display: grid;
  gap: 8px;
}

.mypage-focus-card {
  margin-top: 12px;
}

.dashboard-list {
  display: grid;
  gap: 10px;
}

.dashboard-item {
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--surface-soft, #fbfaf4);
}

.dashboard-item strong,
.dashboard-item .muted {
  display: block;
}

.dashboard-item strong {
  margin-top: 2px;
}

.metrics-list {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.metrics-list .dashboard-item {
  min-height: 76px;
}

.job-catalog-list {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  align-items: start;
}

.job-catalog-item {
  display: grid;
  gap: 12px;
}

.job-catalog-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  list-style: none;
}

.job-catalog-summary::-webkit-details-marker {
  display: none;
}

.job-catalog-summary-title,
.job-catalog-summary-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.job-catalog-item-body {
  display: grid;
  gap: 12px;
}


.job-catalog-item-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.job-catalog-item-title {
  display: grid;
  gap: 4px;
}

.skill-col-index {
  display: none;
}

.job-catalog-item-actions {
  display: flex;
  gap: 8px;
  width: 100%;
}

.job-train-link {
  flex: 7;
  text-align: center;
}

.job-change-form {
  flex: 3;
}

.job-change-form .action-button {
  width: 100%;
}

.job-catalog-item-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.job-catalog-item-block {
  display: grid;
  gap: 4px;
}

.job-selection-screen {
  display: grid;
  gap: 16px;
}

.job-selection-hero {
  padding: 16px 18px;
  background: rgba(20, 28, 42, 0.88);
}

.job-selection-hero .mypage-hero-bar {
  align-items: center;
  min-height: 0;
}

.job-selection-hero .exploration-player-badge {
  flex: 0 0 auto;
}

.job-selection-hero .mypage-hero-copy {
  display: grid;
  gap: 7px;
}

.job-selection-hero h1 {
  margin: 0;
  color: #fff4c0;
  font-size: 1.45rem;
  line-height: 1.2;
}

.job-selection-hero .muted {
  margin: 0;
}

.job-selection-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.job-selection-hero-meta span {
  padding: 3px 8px;
  border: 1px solid rgba(126, 153, 199, 0.48);
  background: rgba(8, 14, 24, 0.46);
  color: #edf4ff;
  font-size: 0.84rem;
}

.job-selection-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.job-selection-main {
  display: grid;
  gap: 16px;
}

.job-selection-screen .panel {
  background: rgba(20, 28, 42, 0.88);
}

.job-selection-screen .panel h2,
.job-selection-screen .panel-heading {
  color: #edf4ff;
}

.job-catalog-panel > .tab-labels {
  margin-bottom: 10px;
}

.job-catalog-panel .tab-panels > .tab-panel > .muted {
  margin: 0 0 10px;
}

.job-catalog-panel .job-filter-tabs {
  display: grid;
  gap: 10px;
}

.job-catalog-panel .job-tab-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.job-catalog-panel .job-tab-label {
  min-height: 32px;
  padding: 5px 10px;
}

.job-selection-screen .job-catalog-list {
  grid-template-columns: 1fr;
  gap: 8px;
}

.job-catalog-item-frame {
  position: relative;
}

.job-selection-screen .job-catalog-item {
  gap: 0;
  padding: 0;
  overflow: hidden;
  border-color: rgba(126, 153, 199, 0.38);
  background: rgba(12, 18, 29, 0.58);
}

.job-selection-screen .job-catalog-item[open] {
  border-color: rgba(162, 190, 232, 0.66);
  background: rgba(10, 16, 28, 0.76);
}

.job-selection-screen .job-catalog-summary {
  min-height: 48px;
  padding: 10px 12px;
}

.job-selection-screen .job-catalog-item-frame.has-summary-action .job-catalog-summary {
  padding-right: 72px;
}

.job-selection-screen .job-catalog-summary-title strong {
  display: inline;
  margin: 0;
  color: #fff4c0;
  font-size: 1.02rem;
}

.job-selection-screen .job-catalog-summary-meta {
  justify-content: flex-end;
  color: #d8e5f8;
}

.job-catalog-summary-more {
  padding: 2px 6px;
  border: 1px solid rgba(126, 153, 199, 0.52);
  background: rgba(20, 30, 48, 0.75);
  color: #edf4ff;
  font-size: 0.74rem;
}

.job-catalog-item[open] .job-catalog-summary {
  border-bottom: 1px solid rgba(126, 153, 199, 0.36);
}

.job-catalog-item[open] .job-catalog-summary-more {
  background: rgba(52, 73, 112, 0.78);
}

.job-selection-screen .job-catalog-item-body {
  padding: 12px;
}

.job-selection-screen .job-catalog-item-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: stretch;
}

.job-selection-screen .job-catalog-item-actions .action-link,
.job-selection-screen .job-catalog-item-actions .job-change-form,
.job-selection-screen .job-catalog-item-actions .job-change-btn {
  width: 100%;
}

.job-selection-screen .job-catalog-item-actions .action-link,
.job-selection-screen .job-catalog-item-actions .job-change-btn {
  display: flex;
  min-height: 34px;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.job-summary-change-form {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: auto;
  margin: 0;
}

.job-selection-screen .job-summary-change-form .job-summary-change-btn {
  display: inline-flex;
  width: auto;
  min-height: 0;
  align-items: center;
  justify-content: center;
  padding: 2px 6px;
  border: 1px solid rgba(126, 153, 199, 0.52);
  background: rgba(20, 30, 48, 0.75);
  color: #edf4ff;
  font-size: 0.74rem;
  line-height: 1.4;
  text-align: center;
  box-shadow: none;
  gap: 0;
}

.job-selection-screen .job-summary-change-form .job-summary-change-btn::before {
  content: none;
}

.job-selection-screen .job-summary-change-form .job-summary-change-btn:hover:not(:disabled) {
  border-color: rgba(126, 153, 199, 0.72);
  background: rgba(52, 73, 112, 0.78);
  box-shadow: none;
  transform: none;
}

.job-mastery-status {
  display: grid;
  gap: 5px;
  margin-bottom: 10px;
  padding: 8px 10px;
  border: 1px solid rgba(126, 153, 199, 0.30);
  background: rgba(8, 13, 22, 0.30);
  color: #edf4ff;
}

.job-selection-screen .mypage-status-table {
  width: 100%;
  margin: 0;
  table-layout: fixed;
}

.job-selection-screen .mypage-status-table + .mypage-status-table {
  margin-top: 10px;
}

.job-selection-screen .mypage-status-table th,
.job-selection-screen .mypage-status-table td {
  border-color: rgba(126, 153, 199, 0.30);
  background: rgba(8, 13, 22, 0.30);
}

.job-selection-screen .mypage-status-table th {
  width: 7rem;
  color: #f4f0e8;
  background: rgba(8, 13, 22, 0.52);
}

.job-detail-section {
  display: grid;
  gap: 5px;
}

.job-detail-collapsible {
  display: block;
}

.job-detail-toggle {
  cursor: pointer;
  border: 1px solid rgba(193, 166, 112, 0.55);
  padding: 4px 7px;
  color: #f4f0e8;
  background: rgba(57, 42, 26, 0.82);
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.3;
}

.job-detail-toggle::-webkit-details-marker {
  display: none;
}

.job-detail-toggle::before {
  content: "▶";
  display: inline-block;
  width: 1.2em;
  color: #d7bd78;
}

.job-detail-collapsible[open] .job-detail-toggle::before {
  content: "▼";
}

.job-detail-collapsible .job-detail-table {
  margin-top: 10px;
}

.job-selection-screen .mypage-status-table + .job-detail-section {
  margin-top: 8px;
}

.job-detail-section + .job-detail-section {
  margin-top: 8px;
}

.job-detail-notes {
  margin-top: 3px;
  padding: 0 2px;
  color: #cbd8ec;
  font-size: 0.82rem;
  line-height: 1.45;
}

.job-detail-notes + .job-detail-section {
  margin-top: 14px;
}

.job-selection-screen .job-detail-table {
  width: 100%;
  margin: 0;
  table-layout: fixed;
}

.job-selection-screen .job-detail-collapsible .data-table.job-detail-table {
  margin-top: 10px;
}

.job-selection-screen .job-detail-table + .job-detail-table {
  margin-top: 8px;
}

.job-selection-screen .job-detail-table th,
.job-selection-screen .job-detail-table td {
  border-color: rgba(126, 153, 199, 0.30);
  background: rgba(8, 13, 22, 0.30);
  vertical-align: top;
}

.job-selection-screen .job-detail-table thead th {
  color: #f4f0e8;
  background: rgba(8, 13, 22, 0.58);
}

.job-selection-screen .job-detail-table .job-detail-name {
  width: 34%;
  color: #fff4c0;
  background: rgba(8, 13, 22, 0.50);
}

.job-selection-screen .job-bonus-table .job-detail-name {
  width: 52%;
}

.job-selection-screen .job-status-table .job-detail-name {
  width: 34%;
}

.job-selection-screen .job-mastery-status-table,
.job-selection-screen .job-master-rank-status-table {
  font-size: 0.88rem;
}

.job-selection-screen .job-mastery-status-table .job-detail-name,
.job-selection-screen .job-master-rank-status-table .job-detail-name {
  width: 26%;
}

.job-selection-screen .job-mastery-status-table th,
.job-selection-screen .job-mastery-status-table td,
.job-selection-screen .job-master-rank-status-table th,
.job-selection-screen .job-master-rank-status-table td {
  text-align: center;
}

.job-selection-screen .job-mastery-status-table .job-detail-name,
.job-selection-screen .job-master-rank-status-table .job-detail-name {
  text-align: left;
}

.job-selection-screen .job-detail-value,
.job-selection-screen .job-detail-cost {
  white-space: nowrap;
}

.job-selection-screen .job-detail-value-main,
.job-selection-screen .job-detail-growth {
  display: inline-block;
  max-width: 100%;
}

.job-selection-screen .job-detail-note-row th,
.job-selection-screen .job-detail-note-row td {
  color: #cbd8ec;
  background: rgba(8, 13, 22, 0.20);
}

.job-selection-screen .job-detail-table .result-badge {
  margin-right: 4px;
}

.job-current-panel {
  align-self: start;
}

.job-current-panel .quest-progress {
  margin: 10px 0 8px;
}

.job-mastery-reward-panel ul {
  margin-bottom: 0;
}

.skill-training-screen {
  display: grid;
  gap: 16px;
}

.skill-training-hero {
  padding: 16px 18px;
  background: rgba(20, 28, 42, 0.88);
}

.skill-training-hero .mypage-hero-bar {
  align-items: center;
  min-height: 0;
}

.skill-training-hero .exploration-player-badge {
  flex: 0 0 auto;
}

.skill-training-hero .mypage-hero-copy {
  display: grid;
  gap: 7px;
}

.skill-training-hero h1 {
  margin: 0;
  color: #fff4c0;
  font-size: 1.45rem;
  line-height: 1.2;
}

.skill-training-hero .muted {
  margin: 0;
}

.skill-training-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.skill-training-hero-meta span {
  padding: 3px 8px;
  border: 1px solid rgba(126, 153, 199, 0.48);
  background: rgba(8, 14, 24, 0.46);
  color: #edf4ff;
  font-size: 0.84rem;
}

.skill-training-overview {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr);
  gap: 16px;
  align-items: stretch;
}

.skill-training-screen .panel {
  background: rgba(20, 28, 42, 0.88);
}

.skill-training-screen .panel-heading {
  margin: -12px -12px 12px;
  padding: 8px 12px;
  border-bottom: 1px solid rgba(126, 153, 199, 0.50);
  background: linear-gradient(180deg, rgba(39, 50, 70, 0.96) 0%, rgba(24, 32, 48, 0.96) 100%);
  color: #edf4ff;
  font-weight: 700;
}

.skill-training-target-panel p,
.skill-training-panel p {
  margin: 0 0 9px;
}

.skill-training-target-panel p:last-child,
.skill-training-panel p:last-child {
  margin-bottom: 0;
}

.skill-training-target-panel strong,
.skill-training-sp strong {
  color: #fff4c0;
}

.skill-training-mastery-panel .mypage-status-table,
.skill-training-panel .skill-training-table {
  width: 100%;
  margin: 0;
}

.skill-training-mastery-panel .mypage-status-table {
  table-layout: fixed;
}

.skill-training-mastery-panel .mypage-status-table th,
.skill-training-mastery-panel .mypage-status-table td,
.skill-training-table th,
.skill-training-table td {
  border-color: rgba(126, 153, 199, 0.30);
  background: rgba(8, 13, 22, 0.30);
}

.skill-training-mastery-panel .mypage-status-table th {
  width: 8rem;
  color: #f4f0e8;
  background: rgba(8, 13, 22, 0.52);
}

.skill-training-table {
  border-collapse: separate;
  border-spacing: 0;
  table-layout: auto;
}

.skill-training-table thead th {
  padding: 8px 9px;
  color: #f4f0e8;
  background: rgba(8, 13, 22, 0.58);
  font-size: 0.86rem;
  line-height: 1.25;
}

.skill-training-table tbody th,
.skill-training-table tbody td {
  padding: 10px 9px;
  vertical-align: middle;
  line-height: 1.42;
}

.skill-training-table .skill-col-name strong {
  display: inline;
  margin: 0;
  color: #fff4c0;
}

.skill-training-table .result-badge {
  margin-left: 6px;
}

.skill-training-combat-table .skill-col-name {
  width: 19%;
}

.skill-training-combat-table .skill-col-effect {
  width: 29%;
}

.skill-training-combat-table .skill-col-cost {
  width: 1%;
  white-space: nowrap;
}

.skill-training-combat-table .skill-col-rank {
  width: 1%;
  white-space: nowrap;
}

.skill-training-combat-table .skill-col-next {
  width: 21%;
}

.skill-training-combat-table .skill-col-action {
  width: 1%;
  white-space: nowrap;
}

.skill-training-passive-table .skill-col-name {
  width: 24%;
}

.skill-training-passive-table .skill-col-effect {
  width: 31%;
}

.skill-training-passive-table .skill-col-rank {
  width: 1%;
  white-space: nowrap;
}

.skill-training-passive-table .skill-col-next {
  width: 20%;
}

.skill-training-passive-table .skill-col-action {
  width: 1%;
  white-space: nowrap;
}

.skill-training-passive-table .skill-col-source {
  width: 1%;
  white-space: nowrap;
}

.skill-training-table .skill-col-action form,
.skill-training-table .skill-col-action .button_to,
.skill-training-table .skill-col-action .action-button {
  width: 100%;
}

.skill-training-table .skill-col-action .action-button {
  min-height: 34px;
  padding: 6px 8px;
  font-size: 0.82rem;
  line-height: 1.2;
}

.skill-training-table .action-button:disabled {
  color: rgba(220, 229, 245, 0.52);
  border-color: rgba(126, 153, 199, 0.26);
  background: rgba(12, 18, 29, 0.44);
}

.result-title {
  margin: 0 0 8px;
  font-size: 1.35rem;
}

.result-title.injury-text {
  font-size: 0.94rem;
}

.result-copy {
  margin: 0;
}

.result-copy + .result-copy {
  margin-top: 8px;
}

.result-copy-lines {
  display: flex;
  flex-direction: column;
}

.result-copy-line {
  display: block;
}

.result-copy-line + .result-copy-line {
  margin-top: 8px;
}

.shop-result-equip-button {
  margin-bottom: 8px;
}

.shop-result-actions {
  flex-wrap: nowrap;
  margin-top: 12px;
}

.shop-result-actions form,
.shop-result-actions .button_to,
.shop-result-actions .action-link {
  flex: 1 1 50%;
}

.shop-result-actions .shop-result-equip-button {
  margin-bottom: 0;
}

.shop-accessory-replacement-table .shop-accessory-replacement-slot,
.shop-accessory-replacement-table .shop-accessory-replacement-action {
  width: 1%;
  white-space: nowrap;
}

.shop-accessory-replacement-table .shop-accessory-replacement-action form,
.shop-accessory-replacement-table .shop-accessory-replacement-action .button_to {
  display: inline-block;
  width: auto;
  margin: 0;
}

.shop-accessory-replacement-table .shop-accessory-replacement-action .action-button {
  width: auto;
  min-width: 5.5rem;
  white-space: nowrap;
}

.boss-highlight {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 10px 0 12px;
  padding: 8px 12px;
  border: 1px solid var(--border-strong);
  background: linear-gradient(180deg, #fff5f1 0%, #f7ddd6 100%);
}

.delve-result-title {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.exploration-combatants {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: end;
  margin-bottom: 14px;
  padding: 36px 16px 0;
  border: 1px solid rgba(120, 92, 48, 0.45);
  background:
    linear-gradient(180deg, rgba(12, 8, 4, 0.18) 0%, rgba(12, 8, 4, 0.38) 100%),
    url("/assets/background/buttle-ba644eb3.webp") center center / cover no-repeat;
  border-radius: 10px;
  box-shadow: inset 0 0 0 1px rgba(255, 240, 200, 0.06);
}

.exploration-combatants.exploration-combatants-boss {
  background:
    linear-gradient(180deg, rgba(18, 18, 20, 0.10) 0%, rgba(18, 18, 20, 0.28) 100%),
    url("/assets/background/buttle-boss-5f1afed4.webp") center center / cover no-repeat;
}

.exploration-combatant {
  display: grid;
  align-self: end;
  justify-items: center;
  gap: 8px;
}

.exploration-combatant-vitals-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 14px;
}

.exploration-combatant-vitals {
  display: grid;
  gap: 4px;
  width: 100%;
  max-width: 140px;
  font-weight: bold;
  justify-items: center;
  text-align: center;
  justify-self: center;
}

.dungeon-interior-bg .exploration-combatant-vitals {
  max-width: none;
  padding: 8px 10px;
  border: 1px solid rgba(180, 140, 60, 0.30);
  background: rgba(10, 14, 22, 0.62);
  color: #f0e0b0;
  font-size: 1.02rem;
}

.dungeon-interior-bg .delve-result-main-panel .result-copy {
  margin-top: 8px;
  line-height: 1.55;
}

.dungeon-interior-bg .delve-result-summary-panel .data-table {
  margin: 0;
}

.dungeon-interior-bg .delve-result-summary-panel .data-table th {
  width: 9rem;
}

.dungeon-interior-bg .delve-battle-log-panel .panel-summary {
  margin-bottom: 10px;
}

.dungeon-interior-bg .battle-log-turn {
  border-radius: 0;
}

.dungeon-interior-bg .battle-log-step {
  border-radius: 4px;
  background: rgba(10, 14, 22, 0.66);
}

.exploration-enemy-avatar {
  width: 140px;
  height: 140px;
  background: transparent;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.delve-result-title h2 {
  margin: 0;
}

.delve-progress-hero {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  border: 1px solid var(--border-strong);
  background: linear-gradient(180deg, #fffdf6 0%, #efe6c8 100%);
}

.delve-progress-hero-header,
.delve-progress-hero-main,
.delve-progress-hero-rewards {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.delve-progress-hero-rate {
  font-size: 1.5rem;
  line-height: 1;
}

.delve-progress-hero-floor {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  line-height: 1.1;
}

.delve-progress-hero-rewards span,
.delve-progress-hero-rewards strong {
  display: block;
}

.delve-progress-hero-rewards strong {
  font-size: 1.05rem;
}

.exploration-result-page {
  padding-bottom: 104px;
}

.battle-log {
  display: grid;
  gap: 10px;
}

.battle-log-turn {
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
}

.battle-log-turn-boss {
  border-color: var(--border-strong);
  background: #fff5f1;
}

.battle-log-notes {
  margin: 6px 0 8px 18px;
  padding: 0;
}

.battle-log-trait {
  padding: 8px 10px;
  border: 1px dashed var(--border);
  background: var(--surface-soft);
}

.battle-log-step {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 4px;
  padding: 8px 10px;
  border-radius: 8px;
  border: 1px solid rgba(var(--shadow-rgb), 0.10);
  background: rgba(255, 255, 255, 0.45);
}

.battle-log-step-text {
  flex: 1 1 220px;
}

.battle-log-step-player {
  border-left: 4px solid rgba(46, 95, 184, 0.55);
}

.battle-log-step-enemy {
  border-left: 4px solid rgba(163, 72, 72, 0.55);
}

.battle-log-step-first_attack,
.battle-log-step-note,
.battle-log-step-trait_activation,
.battle-log-step-rare_event {
  background: var(--surface-soft);
}

.battle-log-step-first_attack,
.battle-log-step-trait_activation,
.battle-log-step-rare_event,
.battle-log-step-critical {
  font-weight: 700;
}

.battle-log-step-critical {
  background: rgba(255, 240, 198, 0.75);
  border-color: rgba(191, 138, 42, 0.35);
}

.battle-log-step-miss,
.battle-log-step-evade {
  background: rgba(var(--shadow-rgb), 0.05);
}

.battle-log-step-rare_event {
  border-color: rgba(118, 88, 188, 0.28);
  border-top: 2px solid rgba(201, 154, 56, 0.55);
  border-bottom: 2px solid rgba(201, 154, 56, 0.55);
}

.battle-log-step-info {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.enemy-preview-list {
  display: grid;
  gap: 10px;
}

.enemy-preview-card {
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
}

.enemy-preview-header {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: baseline;
}

.enemy-preview-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 8px;
}

.enemy-preview-stats span {
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--surface-soft);
}

.result-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: stretch;
}

.result-links form,
.result-links .button_to,
.result-links .action-link {
  flex: 1 1 220px;
  margin: 0;
}

.result-links form,
.result-links .button_to {
  display: flex;
}

.result-links .action-button,
.result-links .action-link {
  display: flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
}

.result-links-secondary > * {
  flex: 1 1 220px;
}

.job-investment-actions {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  margin-bottom: 6px;
}

.job-investment-actions form,
.job-investment-actions .button_to {
  display: flex;
  flex: 0 0 auto;
  margin: 0;
}

.job-investment-actions .action-button {
  min-height: 38px;
  padding: 0 12px;
  white-space: nowrap;
}

.exploration-repeat-dock {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  width: min(720px, calc(100% - 32px));
  padding: 12px;
  border: 1px solid var(--border);
  background: rgba(245, 241, 230, 0.96);
  box-shadow: 0 8px 18px rgba(48, 44, 34, 0.18);
  z-index: 20;
}

.exploration-auto-stop-dock {
  position: fixed;
  left: 50%;
  top: 58%;
  transform: translate(-50%, -50%);
  width: min(280px, calc(100% - 48px));
  padding: 10px;
  border: 1px solid var(--border-strong);
  background: rgba(245, 241, 230, 0.98);
  box-shadow: 0 8px 18px rgba(48, 44, 34, 0.22);
  z-index: 21;
}

.exploration-auto-stop-dock .button_to,
.exploration-auto-stop-dock .action-button {
  width: 100%;
  margin: 0;
}

.exploration-repeat-dock form,
.exploration-repeat-dock .button_to {
  margin: 0;
}

.delve-start-dock-form {
  display: grid;
  gap: 10px;
}

.exploration-entrance-row {
  display: flex;
  gap: 10px;
  align-items: stretch;
}

.exploration-entrance-form {
  display: contents;
}

.exploration-entrance-row .select-input {
  flex: 0 0 auto;
  min-width: 60px;
  max-width: 90px;
  text-align: center;
}

.exploration-entrance-row .action-button-compact {
  flex: 1 1 auto;
  white-space: nowrap;
}

.exploration-repeat-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: stretch;
}

.exploration-repeat-actions > * {
  min-width: 0;
}

.exploration-repeat-actions > :only-child {
  grid-column: 1 / -1;
  width: min(320px, 100%);
  justify-self: center;
}

.exploration-repeat-actions-single > * {
  width: 100%;
}

.exploration-repeat-actions-single {
  grid-template-columns: minmax(0, min(320px, 50%));
  justify-content: center;
}

.exploration-repeat-actions form,
.exploration-repeat-actions .button_to,
.exploration-repeat-actions .action-link {
  display: flex;
  width: 100%;
}

.exploration-repeat-actions .action-button-compact {
  white-space: nowrap;
  line-height: 1.1;
}

.exploration-repeat-actions .action-link.action-button {
  align-items: center;
  justify-content: center;
  min-height: 44px;
  text-decoration: none;
}

.exploration-repeat-actions .select-input {
  text-align: center;
}

.dungeon-hub-screen {
  display: grid;
  gap: 16px;
}

.dungeon-hub-hero {
  padding: 16px 18px;
  background: rgba(18, 12, 6, 0.84);
}

.dungeon-hub-hero .mypage-hero-bar {
  align-items: center;
  min-height: 0;
}

.dungeon-hub-hero .exploration-player-badge {
  float: none;
  flex: 0 0 auto;
  margin: 0;
}

.dungeon-hub-hero .mypage-hero-copy {
  display: grid;
  gap: 7px;
}

.dungeon-hub-hero h1 {
  margin: 0;
  color: #f1d27a;
  font-size: 1.45rem;
  line-height: 1.2;
}

.dungeon-hub-hero .result-copy {
  margin: 0;
}

.dungeon-hub-hero-meta,
.dungeon-hub-hero .player-header-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.dungeon-hub-hero-meta span,
.dungeon-hub-hero .player-header-meta span {
  padding: 3px 8px;
  border: 1px solid rgba(180, 140, 60, 0.45);
  background: rgba(26, 18, 7, 0.72);
  color: #f0e0b0;
  font-size: 0.84rem;
}

.dungeon-hub-summary-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.dungeon-hub-summary-item {
  display: grid;
  gap: 4px;
  padding: 9px 11px;
  border: 1px solid rgba(180, 140, 60, 0.32);
  background: rgba(20, 13, 5, 0.50);
}

.dungeon-hub-summary-item span {
  color: #a09070;
  font-size: 0.84rem;
}

.dungeon-hub-summary-item strong {
  color: #f0e0b0;
  font-size: 1.03rem;
}

.dungeon-hub-card-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
}

.dungeon-hub-card-copy {
  display: grid;
  gap: 11px;
}

.dungeon-hub-card-copy .result-copy {
  margin: 0;
}

.dungeon-hub-state-table {
  width: 100%;
  margin: 0;
  table-layout: fixed;
}

.dungeon-hub-state-table th {
  width: 8rem;
}

.dungeon-hub-action-box {
  display: flex;
  justify-content: center;
  align-items: stretch;
  padding: 10px;
  border: 1px solid rgba(180, 140, 60, 0.32);
  background: rgba(16, 10, 4, 0.52);
}

.dungeon-hub-preview-panel {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(180, 140, 60, 0.32);
}

.dungeon-hub-preview-heading {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: baseline;
  margin-bottom: 10px;
}

.dungeon-hub-preview-heading strong {
  color: #f1d27a;
  font-size: 1.02rem;
}

.dungeon-hub-screen .enemy-preview-list > .result-copy {
  margin-bottom: 0;
}

.dungeon-hub-screen .enemy-preview-card {
  background: rgba(10, 14, 22, 0.72);
  border-color: rgba(180, 140, 60, 0.34);
}

.dungeon-hub-screen .enemy-preview-header strong {
  color: #f0e0b0;
}

.dungeon-action-grid {
  --dungeon-action-floor-width: 6.5rem;
  --dungeon-action-count-width: 6.5rem;
  --dungeon-action-button-width: 10rem;

  display: grid;
  grid-template-columns:
    var(--dungeon-action-floor-width)
    var(--dungeon-action-count-width)
    var(--dungeon-action-button-width);
  gap: 10px;
  justify-content: center;
  align-items: stretch;
  width: max-content;
  max-width: 100%;
  margin: 14px auto 0;
}

.dungeon-hub-action-grid {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(12rem, 1.15fr);
  width: min(100%, 760px);
  margin: 0;
}

.dungeon-hub-action-grid .dungeon-action-challenge-form {
  grid-column: 1 / -1;
  grid-row: 1;
}

.dungeon-hub-action-grid .dungeon-action-challenge-form,
.dungeon-hub-action-grid .dungeon-action-retry-form {
  position: relative;
  padding-bottom: 12px;
}

.dungeon-hub-action-grid .dungeon-action-challenge-form::after,
.dungeon-hub-action-grid .dungeon-action-retry-form::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  border-bottom: 1px solid rgba(180, 140, 60, 0.36);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.42);
}

.dungeon-hub-action-grid-result-mode .dungeon-action-result-mode-form {
  grid-column: 1 / -1;
  grid-row: 4;
}

.dungeon-hub-action-grid .dungeon-action-retry-form {
  display: grid;
  grid-column: 1 / -1;
  grid-row: 2;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(12rem, 1.15fr);
  gap: 10px;
}

.dungeon-hub-action-grid .dungeon-action-retry-form .dungeon-action-retry-floor {
  grid-column: 2;
  grid-row: 1;
}

.dungeon-hub-action-grid .dungeon-action-retry-form .action-button {
  grid-column: 3;
  grid-row: 1;
}

.dungeon-hub-action-grid .dungeon-batch-reexplore-form {
  grid-column: 1 / -1;
  grid-row: 3;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(12rem, 1.15fr);
}

.dungeon-hub-action-grid .dungeon-action-batch-count {
  grid-column: 1;
  grid-row: 1;
}

.dungeon-hub-action-grid .dungeon-action-batch-floor {
  grid-column: 2;
  grid-row: 1;
}

.dungeon-hub-action-grid .dungeon-batch-reexplore-submit {
  grid-column: 3;
  grid-row: 1;
}

.dungeon-hub-action-grid .dungeon-batch-reexplore-submit {
  min-height: 38px;
}

.dungeon-action-form,
.dungeon-batch-reexplore-form {
  margin: 0;
}

.dungeon-action-form {
  display: flex;
  width: 100%;
}

.dungeon-action-grid .select-input {
  width: 100%;
  min-width: 0;
  max-width: none;
  color: #4a2a08;
  text-align: center;
}

.dungeon-action-grid.dungeon-hub-action-grid .select-input {
  background: rgba(10, 14, 22, 0.86);
  border-color: rgba(180, 140, 60, 0.46);
  color: #e8d9b8;
}

.dungeon-action-grid.dungeon-hub-action-grid .select-input option {
  background: #10141c;
  color: #e8d9b8;
}

.dungeon-action-grid .action-button-compact {
  width: 100%;
  min-width: 0;
  justify-content: center;
  text-align: center;
}

.dungeon-action-grid .action-button-compact::before {
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: 14px;
  align-self: auto;
}

.dungeon-action-retry-floor {
  grid-column: 1;
  grid-row: 1;
}

.dungeon-action-retry-form {
  grid-column: 2;
  grid-row: 1;
}

.dungeon-action-challenge-form {
  grid-column: 3;
  grid-row: 1;
}

.dungeon-batch-reexplore-form {
  display: grid;
  grid-column: 1 / -1;
  grid-row: 2;
  grid-template-columns:
    var(--dungeon-action-floor-width)
    var(--dungeon-action-count-width)
    var(--dungeon-action-button-width);
  gap: 10px;
  align-items: stretch;
  width: 100%;
}

.dungeon-batch-reexplore-submit {
  width: 100%;
}

@media (max-width: 520px) {
  .dungeon-action-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    width: min(320px, 100%);
  }

  .dungeon-action-challenge-form {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .dungeon-hub-action-grid .dungeon-action-challenge-form,
  .dungeon-hub-action-grid .dungeon-action-retry-form {
    padding-bottom: 10px;
  }

  .dungeon-action-retry-floor {
    grid-column: 1;
    grid-row: 2;
  }

  .dungeon-action-retry-form {
    display: grid;
    grid-column: 1 / -1;
    grid-row: 2;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
  }

  .dungeon-hub-action-grid .dungeon-action-retry-form {
    grid-column: 1 / -1;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .dungeon-hub-action-grid .dungeon-action-retry-form .dungeon-action-retry-floor {
    grid-column: 1;
  }

  .dungeon-hub-action-grid .dungeon-action-retry-form .action-button {
    grid-column: 2;
  }

  .dungeon-batch-reexplore-form {
    grid-column: 1 / -1;
    grid-row: 3;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .dungeon-hub-action-grid .dungeon-action-batch-floor {
    grid-column: 1;
    grid-row: 1;
  }

  .dungeon-hub-action-grid .dungeon-action-batch-count {
    grid-column: 2;
    grid-row: 1;
  }

  .dungeon-hub-action-grid .dungeon-batch-reexplore-submit {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .dungeon-hub-action-grid .dungeon-batch-reexplore-form {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
}

.floating-home-button {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: calc(max(16px, env(safe-area-inset-bottom)) + 72px + var(--floating-home-size) + 8px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--floating-home-size);
  height: var(--floating-home-size);
  border-radius: 8px;
  border: 1px solid rgba(110, 130, 170, 0.58);
  background: rgba(16, 22, 34, 0.86);
  color: #dbe7f6;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
  z-index: 19;
  text-decoration: none;
  transition:
    transform 120ms ease,
    box-shadow 120ms ease,
    border-color 120ms ease;
}

.floating-home-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.55);
  border-color: rgba(150, 175, 215, 0.82);
  background: rgba(24, 34, 50, 0.92);
}

.floating-home-button:active {
  transform: translateY(0);
}

body[data-theme^="day_"] .floating-home-button {
  background: var(--panel);
  border-color: var(--border-strong);
  color: var(--text);
}

body[data-theme^="day_"] .floating-home-button:hover {
  background: color-mix(in srgb, var(--panel) 90%, white);
  border-color: var(--border-strong);
  box-shadow: 0 6px 20px rgba(var(--shadow-rgb), 0.25);
}
@media (min-width: 1200px) {
  .floating-home-button {
    right: max(
      16px,
      calc((((100vw - var(--page-max-width)) / 2) + var(--page-padding) - var(--floating-home-size)) / 2)
    );
  }
}

@media (min-width: 681px) {
  .interior-page:not(.mobile-exploration-page) .floating-home-button,
  .interior-page:not(.mobile-exploration-page) .floating-nav-menu .mypage-hamburger-button {
    width: 44px;
    height: 44px;
    opacity: 0.78;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.34);
  }

  .interior-page:not(.mobile-exploration-page) .floating-home-button:hover,
  .interior-page:not(.mobile-exploration-page) .floating-nav-menu .mypage-hamburger-button:hover {
    opacity: 1;
  }

  .interior-page:not(.mobile-exploration-page) .floating-home-button-icon,
  .interior-page:not(.mobile-exploration-page) .floating-menu-button-icon {
    font-size: 18px;
  }

  .interior-page:not(.mobile-exploration-page) .floating-home-button {
    bottom: calc(max(16px, env(safe-area-inset-bottom)) + 72px + 44px + 8px);
  }

  .interior-page:not(.mobile-exploration-page) .floating-nav-menu {
    bottom: calc(max(16px, env(safe-area-inset-bottom)) + 72px);
  }
}


.floating-home-button-icon {
  font-size: 22px;
  line-height: 1;
}

/* floating nav menu (interior pages) */
.floating-nav-menu {
  display: none;
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: calc(max(16px, env(safe-area-inset-bottom)) + 72px);
  z-index: 50;
}

.interior-page:not(.mobile-exploration-page) .floating-nav-menu {
  display: block;
}

@media (min-width: 1200px) {
  .floating-nav-menu {
    right: max(
      16px,
      calc((((100vw - var(--page-max-width)) / 2) + var(--page-padding) - var(--floating-home-size)) / 2)
    );
  }
}

.floating-nav-menu .mypage-hamburger-menu {
  display: inline-block;
  position: relative;
}

.floating-nav-menu .mypage-hamburger-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--floating-home-size);
  height: var(--floating-home-size);
  min-width: unset;
  border-radius: 8px;
  border: 1px solid rgba(110, 130, 170, 0.58);
  background: rgba(16, 22, 34, 0.86);
  color: #dbe7f6;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
  padding: 0;
  transition:
    transform 120ms ease,
    box-shadow 120ms ease,
    border-color 120ms ease;
}

.floating-nav-menu .mypage-hamburger-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.55);
  border-color: rgba(150, 175, 215, 0.82);
  background: rgba(24, 34, 50, 0.92);
}

.floating-nav-menu .mypage-hamburger-button::after {
  display: none;
}

.floating-nav-menu .mypage-hamburger-button .floating-menu-button-icon {
  display: block;
  width: auto;
  height: auto;
  background: none;
}

.floating-nav-menu .mypage-hamburger-button .floating-menu-badge {
  display: flex;
  width: 16px;
  height: 16px;
  background: #f59e0b;
}

body[data-theme^="day_"] .floating-nav-menu .mypage-hamburger-button {
  background: var(--panel);
  border-color: var(--border-strong);
  color: var(--text);
}

body[data-theme^="day_"] .floating-nav-menu .mypage-hamburger-button:hover {
  background: color-mix(in srgb, var(--panel) 90%, white);
  border-color: var(--border-strong);
  box-shadow: 0 6px 20px rgba(var(--shadow-rgb), 0.25);
}

.floating-nav-menu .mypage-hamburger-sheet {
  top: auto;
  bottom: calc(100% + 8px);
}

.floating-menu-button-icon {
  font-size: 22px;
  line-height: 1;
}

.floating-menu-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 999px;
  background: #f59e0b;
  color: #fff;
  font-size: 0.65rem;
  font-weight: bold;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
  pointer-events: none;
  animation: town-spot-badge-blink 1.4s ease-in-out infinite;
}

.floating-menu-badge[hidden],
.mypage-sp-ready-badge[hidden] {
  display: none !important;
}

.interior-page .site-header {
  display: none;
}

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

.pending-rewards-note {
  margin-top: 8px;
  margin-bottom: 0;
  font-size: 0.82rem;
  text-align: right;
}

.section-heading {
  margin: 0 0 10px;
  font-size: 1rem;
}

.section-heading-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.section-heading-row .section-heading {
  margin: 0;
}

.section-subheading {
  margin: 16px 0 8px;
  font-size: 0.95rem;
}

.result-badge {
  display: inline-block;
  padding: 2px 8px;
  border: 1px solid var(--border);
  background: #f3f0e4;
  font-size: 0.8rem;
  white-space: nowrap;
}

.result-badge-positive {
  background: #e4f0df;
}

.result-badge-negative {
  background: #f4dddd;
}

.batch-result-highlights {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 8px 0 12px;
  padding: 6px 8px;
  border: 1px solid var(--border);
  background: #eee7d2;
  font-size: 0.82rem;
}

.batch-result-highlights-title {
  font-weight: bold;
  color: var(--text);
}

.batch-result-highlight {
  display: inline-block;
  padding: 1px 6px;
  border: 1px solid var(--border);
  background: #f8f3df;
  color: var(--text);
  white-space: nowrap;
}

.batch-result-highlight-loss {
  border-color: #b05a4f;
  background: #f4dddd;
  color: #6c241d;
}

.batch-result-highlight-level {
  border-color: #a98a2e;
  background: #f3e8bd;
  color: #5c4410;
}

.batch-result-highlight-item {
  border-color: #4f8a78;
  background: #dcece3;
  color: #1f5647;
}

.result-badge-important {
  box-shadow: inset 0 0 0 1px rgba(120, 70, 20, 0.22);
  font-weight: bold;
}

.result-badge-level-up {
  border-color: #a98a2e;
}

.result-badge-item {
  border-color: #4f8a78;
}

.quest-board-compact {
  display: grid;
  grid-template-columns: minmax(150px, 0.7fr) minmax(240px, 1.7fr) minmax(120px, 0.5fr);
  align-items: center;
  gap: 10px;
  min-height: 42px;
}

.quest-board-claim {
  display: flex;
  align-items: center;
  gap: 8px;
  grid-column: 2 / -1;
}

.quest-board-claim .button_to {
  margin: 0;
}

.quest-board-claim .action-button {
  min-width: 10rem;
  justify-content: center;
  text-align: center;
}

.quest-title-link {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 4px 8px;
  border-left: 3px solid var(--accent-strong);
  font-weight: bold;
  text-decoration: none;
  min-width: 0;
  color: var(--text);
  background: rgba(var(--shadow-rgb), 0.10);
}

.quest-title-link:hover {
  text-decoration: underline;
}

.quest-board-description {
  font-size: 0.84rem;
  color: color-mix(in srgb, var(--text) 78%, var(--muted) 22%);
  line-height: 1.35;
}

.quest-board-reward {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  padding: 5px 8px;
  border: 1px solid rgba(154, 110, 34, 0.45);
  border-radius: 4px;
  background: rgba(80, 56, 18, 0.12);
  color: var(--text);
  line-height: 1.25;
}

.quest-reward-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.quest-board-progress {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 80px;
}

.quest-board-progress .quest-progress {
  flex: 1;
  margin-bottom: 0;
}

.quest-progress {
  width: 100%;
  height: 10px;
  margin-bottom: 6px;
  border: 1px solid var(--border);
  background: #d8d4c4;
}

.quest-progress-bar {
  height: 100%;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.42) 0%, rgba(255,255,255,0) 55%, rgba(0,0,0,0.14) 100%),
    linear-gradient(90deg, #d4921a 0%, #64b020 100%);
  box-shadow: 0 0 5px rgba(180, 130, 10, 0.45);
}

.log-row-positive {
  background: #f8fcf5;
}

.log-row-negative {
  background: #fdf5f5;
}

.flash {
  margin: 0 0 16px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--notice);
}

.flash-alert {
  background: var(--alert);
}

.injury-text {
  color: #9b2c2c;
  font-weight: 600;
  text-decoration: none;
}

.injury-text:hover {
  text-decoration: underline;
}

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

.data-table th,
.data-table td {
  padding: 8px 10px;
  border: 1px solid var(--border);
  text-align: left;
}

.data-table th {
  width: 30%;
  background: color-mix(in srgb, var(--accent) 50%, white);
  font-size: 0.9rem;
}

.data-table td.numeric {
  text-align: right;
  white-space: nowrap;
}

.data-table .select-input {
  width: 100%;
  box-sizing: border-box;
  padding: 4px 6px;
}

.admin-job-unlock-table {
  width: 100% !important;
  min-width: 100%;
  max-width: none;
  table-layout: auto !important;
}

.admin-job-unlock-table th,
.admin-job-unlock-table td {
  width: auto;
  white-space: nowrap;
}

.admin-job-unlock-table .select-input {
  width: auto;
  min-width: max-content;
}

body.admin-page .data-table.admin-job-unlock-table:has(thead),
body.admin-page .table-scroll > table.admin-job-unlock-table {
  width: 100% !important;
  min-width: 100%;
  max-width: none;
  table-layout: auto !important;
}

.table-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.table-scroll > table {
  width: max-content;
  min-width: 720px;
  border-collapse: collapse;
}

.table-scroll th,
.table-scroll td {
  padding: 8px 10px;
  border: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.table-scroll th {
  background: color-mix(in srgb, var(--accent) 50%, white);
  font-size: 0.9rem;
}

.shop-col-effect,
.shop-col-effect-compare,
.shop-col-description,
.shop-col-compare {
  min-width: 12rem;
  vertical-align: top;
}

.shop-col-effect,
.shop-col-effect-compare {
  min-width: 14rem;
}

.shop-col-description {
  min-width: 16rem;
}

.compare-positive {
  color: #3b82f6;
}

.item-enhancement-rank,
.alchemy-enhanced-effect {
  color: #3b82f6;
  font-weight: 700;
}

.compare-negative {
  color: #ef4444;
}

.compare-warning {
  color: #b45309;
}

.shop-col-equippable {
  text-align: center;
  white-space: nowrap;
}

.equippable-yes {
  color: #16a34a;
  font-weight: bold;
}

.equippable-current {
  color: #16a34a;
  font-weight: bold;
}

.equippable-no {
  color: #dc2626;
}

.shop-equippable-label {
  display: none;
}

.shop-buy-price {
  display: none;
}

.equipment-count-label {
  display: none;
}

.shop-filters {
  display: flex;
  gap: 1rem;
  margin-top: 0.75rem;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.shop-filters label {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  cursor: pointer;
  font-size: 0.875rem;
}

.shop-wallet-panel {
  background: rgba(24, 31, 43, 0.86);
}

.shop-wallet-panel .key-stats {
  grid-template-columns: minmax(0, 1fr);
  width: 100%;
  margin-bottom: 0;
}

.shop-wallet-panel .stat-box {
  background: rgba(9, 13, 20, 0.38);
  border-color: rgba(156, 172, 206, 0.28);
}

.shop-gold-value {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  max-width: 100%;
}

.shop-wallet-panel .stat-value {
  overflow-wrap: anywhere;
  word-break: break-word;
  line-height: 1.18;
}

.shop-gold-amount {
  min-width: 0;
  overflow-wrap: anywhere;
}

.shop-gold-unit {
  flex: 0 0 auto;
}

.shop-price-value {
  flex-wrap: nowrap;
  justify-content: flex-end;
  white-space: nowrap;
}

.shop-price-value .shop-gold-amount {
  overflow-wrap: normal;
}

.shop-effect-compare-block {
  display: grid;
  gap: 5px;
  line-height: 1.35;
}

.shop-compare-line {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding-top: 5px;
  border-top: 1px solid rgba(156, 172, 206, 0.20);
}

.shop-effect-compare-label {
  color: #b8c3d7;
  font-size: 0.78rem;
  font-weight: 700;
}

.alchemy-item-table {
  table-layout: auto;
}

.alchemy-item-table .alchemy-col-name,
.alchemy-item-table .alchemy-col-effect {
  width: auto;
}

.alchemy-rules-example {
  color: #fff;
}

.alchemy-rule-table th:first-child,
.alchemy-rule-table .alchemy-rule-kind,
.alchemy-item-table th:nth-child(2),
.alchemy-item-table th:nth-child(3),
.alchemy-item-table th:nth-child(4),
.alchemy-item-table .alchemy-col-target,
.alchemy-item-table .alchemy-col-smithing,
.alchemy-item-table .alchemy-col-alchemy,
.alchemy-item-table .alchemy-col-price,
.alchemy-item-table .alchemy-col-lock,
.alchemy-item-table .alchemy-col-action {
  width: 1%;
  white-space: nowrap;
}

.alchemy-item-table .alchemy-col-target,
.alchemy-item-table .alchemy-col-smithing,
.alchemy-item-table .alchemy-col-alchemy {
  min-width: 3rem;
  text-align: center;
}

.alchemy-item-table .alchemy-col-lock {
  text-align: center;
}

.alchemy-item-table .alchemy-col-action form,
.alchemy-item-table .alchemy-col-action .button_to {
  display: inline-block;
  width: auto;
  margin: 0;
}

.alchemy-item-table .alchemy-col-action .action-button {
  width: auto;
  min-width: 5.5rem;
  white-space: nowrap;
}

.shop-board-panel {
  background: rgba(24, 31, 43, 0.88);
  margin-bottom: 18px;
}

.shop-board-heading {
  justify-content: space-between;
  gap: 10px;
}

.shop-board-count {
  color: #b8c3d7;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0;
  white-space: nowrap;
}

.shop-board-description {
  margin-top: 0;
}

.shop-board-panel .tab-labels,
.shop-board-panel .job-tab-labels {
  gap: 6px;
}

.shop-board-panel .tab-label,
.shop-board-panel .job-tab-label {
  border-radius: 3px;
  background: rgba(15, 20, 30, 0.82);
  border-color: rgba(156, 172, 206, 0.34);
  color: #b8c3d7;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.shop-board-panel .tab-label.is-active,
.shop-board-panel .job-tab-label.is-active {
  background: linear-gradient(180deg, rgba(57, 70, 96, 0.96) 0%, rgba(27, 37, 56, 0.96) 100%);
  border-color: rgba(196, 210, 238, 0.58);
  color: #f1f4fb;
}

.shop-board-panel .shop-filters {
  padding: 7px 9px;
  border: 1px solid rgba(156, 172, 206, 0.20);
  background: rgba(6, 10, 18, 0.26);
}

.shop-board-panel .shop-filters label {
  color: #d1d8e8;
}

.shop-board-panel .shop-filters input {
  accent-color: #8ea85f;
}

.shop-board-panel .shop-table {
  background: rgba(10, 14, 22, 0.18);
}

.shop-board-panel .shop-table th {
  padding: 6px 10px;
  background: rgba(7, 11, 18, 0.58);
  color: #cfd8ea;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
}

.shop-board-panel .shop-table td {
  vertical-align: middle;
}

.shop-board-panel .shop-col-equippable,
.shop-board-panel .shop-col-price,
.shop-board-panel .shop-col-buy,
.shop-board-panel .sell-col-count,
.shop-board-panel .sell-col-price,
.shop-board-panel .sell-col-status,
.shop-board-panel .sell-col-sell {
  width: 1%;
  white-space: nowrap;
}

.shop-board-panel .shop-item-trigger-name,
.shop-board-panel .sell-col-name {
  color: #f4f0e8;
  font-weight: 700;
}

.shop-board-panel .shop-col-price,
.shop-board-panel .sell-col-price {
  color: #f0eadc;
  font-weight: 700;
}

.shop-board-panel .action-button {
  border-radius: 2px;
}

.shop-board-panel .shop-row-equipped {
  background: rgba(52, 64, 86, 0.36);
  box-shadow: inset 3px 0 0 rgba(164, 184, 224, 0.74);
}

.shop-row-equipped {
  background: color-mix(in srgb, var(--accent) 10%, var(--surface) 90%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 40%, transparent);
}

.shop-item-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  max-width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.shop-item-trigger-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shop-item-detail-chip,
.shop-item-detail-link {
  border: 1px solid rgba(126, 153, 199, 0.62);
  background: rgba(20, 28, 43, 0.82);
  color: #dbe7f6;
  font-weight: 700;
}

.shop-item-detail-chip {
  flex: 0 0 auto;
  padding: 1px 5px;
  font-size: 0.72rem;
  line-height: 1.35;
}

.shop-item-detail-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 5px 10px;
  font: inherit;
  cursor: pointer;
}

.shop-item-trigger:hover .shop-item-detail-chip,
.shop-item-detail-link:hover {
  border-color: rgba(196, 210, 238, 0.82);
  color: #fff;
}

.shop-item-dialog {
  width: min(32rem, calc(100vw - 2rem));
  max-width: 32rem;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #000;
  color: #fff;
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.28);
}

.shop-item-dialog::backdrop {
  background: rgba(15, 23, 42, 0.48);
}

.shop-item-dialog-body {
  padding: 1rem 1.1rem;
  background: #000;
  border-radius: 6px;
}

.shop-item-dialog-copy {
  min-width: 0;
}

.shop-item-dialog-copy strong {
  display: block;
  writing-mode: horizontal-tb;
  word-break: keep-all;
  line-height: 1.45;
}

.shop-item-dialog-description {
  margin: 0.9rem 0 0;
  line-height: 1.6;
}

.shop-item-dialog-details {
  display: grid;
  gap: 0.65rem;
  margin-top: 0.9rem;
}

.shop-item-dialog-detail-section {
  padding-top: 0.65rem;
  border-top: 1px solid rgba(156, 172, 206, 0.32);
}

.shop-item-dialog-detail-section h3 {
  margin: 0 0 0.35rem;
  color: #d9e4f2;
  font-size: 0.82rem;
  letter-spacing: 0;
}

.shop-item-dialog-detail-section ul {
  display: grid;
  gap: 0.2rem;
  margin: 0;
  padding-left: 1rem;
  color: #f4f0e8;
  line-height: 1.45;
}

.shop-item-dialog-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 1rem;
}

.shop-result-equip-dialog {
  width: min(42rem, calc(100vw - 2rem));
  max-width: 42rem;
}

.shop-result-equip-dialog-body {
  display: grid;
  gap: 0.9rem;
}

.shop-result-equip-dialog-item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 0.9rem;
  align-items: center;
}

.shop-result-equip-dialog-thumb {
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border: 1px solid rgba(175, 130, 46, 0.58);
  background: rgba(255, 244, 190, 0.08);
}

.shop-result-equip-dialog-image {
  width: 58px;
  height: 58px;
  object-fit: contain;
  image-rendering: pixelated;
}

.shop-result-equip-dialog-thumb-placeholder span {
  color: #f6df9a;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.9rem;
  font-weight: 700;
  line-height: 1;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.78);
}

.shop-result-equip-dialog-copy {
  min-width: 0;
}

.shop-result-equip-dialog-copy strong {
  display: block;
  color: #f6df9a;
  font-size: 1.1rem;
  line-height: 1.35;
}

.shop-result-equip-dialog-details {
  display: grid;
  gap: 0.65rem;
}

.shop-result-equip-dialog-details p {
  margin: 0;
  color: #f4f0e8;
  line-height: 1.55;
}

.shop-result-equip-dialog-replacements {
  display: grid;
  gap: 0.65rem;
}

.shop-result-equip-dialog-replacements .muted {
  margin: 0;
}

.shop-result-equip-dialog-actions {
  display: flex;
  gap: 0.65rem;
  justify-content: flex-end;
  align-items: stretch;
}

.shop-result-equip-dialog-actions form,
.shop-result-equip-dialog-actions .button_to {
  margin: 0;
}

.shop-result-equip-dialog-actions .action-button {
  min-width: 8rem;
}

.shop-item-dialog .shop-item-dialog-close {
  width: auto;
  min-width: 0;
  flex: 0 0 auto;
  align-self: flex-end;
  justify-content: center;
  padding-inline: 14px;
}

.action-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  width: 100%;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, var(--surface-soft) 0%, var(--surface-subtle) 100%);
  color: var(--text);
  padding: 11px 14px;
  cursor: pointer;
  font: inherit;
  text-align: left;
  overflow: visible;
  box-shadow: 2px 2px 0 rgba(var(--shadow-rgb), 0.08);
  transition:
    transform 120ms ease,
    box-shadow 120ms ease,
    border-color 120ms ease,
    background 120ms ease;
}

.action-button::before {
  content: "";
  width: 4px;
  align-self: stretch;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--accent-strong) 0%, var(--border-strong) 100%);
  flex-shrink: 0;
}

.action-link::before {
  content: "";
  width: 4px;
  align-self: stretch;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--accent-strong) 0%, var(--border-strong) 100%);
  flex-shrink: 0;
}

.action-button-admin::before,
.action-link-admin::before {
  background: linear-gradient(180deg, #d47070 0%, #9b2d2d 100%);
}

.action-button:hover:not(:disabled) {
  border-color: var(--border-strong);
  background: linear-gradient(180deg, var(--surface-emphasis) 0%, var(--surface-soft) 100%);
  box-shadow: 3px 3px 0 rgba(var(--shadow-rgb), 0.12);
  transform: translateY(-1px);
}

.action-button:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: 1px 1px 0 rgba(var(--shadow-rgb), 0.08);
}

.action-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.action-button-compact {
  min-height: 40px;
  padding: 8px 12px;
  font-size: 0.95rem;
}

.action-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  width: 100%;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, var(--surface-soft) 0%, var(--surface-subtle) 100%);
  color: var(--text);
  padding: 11px 14px;
  text-decoration: none;
  text-align: left;
  overflow: visible;
  box-shadow: 2px 2px 0 rgba(var(--shadow-rgb), 0.08);
  transition:
    transform 120ms ease,
    box-shadow 120ms ease,
    border-color 120ms ease,
    background 120ms ease;
}

.action-link:hover {
  border-color: var(--border-strong);
  background: linear-gradient(180deg, var(--surface-emphasis) 0%, var(--surface-soft) 100%);
  box-shadow: 3px 3px 0 rgba(var(--shadow-rgb), 0.12);
  transform: translateY(-1px);
}

.action-link:active {
  transform: translateY(0);
  box-shadow: 1px 1px 0 rgba(var(--shadow-rgb), 0.08);
}

.inline-log-link {
  color: var(--text);
  text-decoration: underline;
}

.text-link {
  color: var(--text);
  text-decoration: underline;
}

.equipment-layer-adjustment-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 16px;
  align-items: start;
}

.equipment-layer-adjustment-preview-pane,
.equipment-layer-adjustment-control-pane {
  min-width: 0;
}

.equipment-layer-adjustment-toolbar,
.equipment-layer-adjustment-control-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.equipment-layer-adjustment-toolbar label,
.equipment-layer-adjustment-control-grid label {
  display: grid;
  gap: 4px;
  font-size: 0.85rem;
  font-weight: 700;
}

.equipment-layer-adjustment-toggle-field {
  display: grid;
  gap: 4px;
  font-size: 0.85rem;
  font-weight: 700;
}

.equipment-layer-adjustment-toggle-control {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 41px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--menu-bg);
  color: var(--text);
  font: inherit;
  line-height: 1.2;
}

.equipment-layer-adjustment-toggle-control input {
  flex: 0 0 auto;
  margin: 0;
}

.equipment-layer-adjustment-viewport {
  max-width: 100%;
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--border);
  background-color: #1d1d1d;
}

.equipment-layer-adjustment-viewport.is-bg-checker {
  background-color: #d8d8d8;
  background-image:
    linear-gradient(45deg, #f2f2f2 25%, transparent 25%),
    linear-gradient(-45deg, #f2f2f2 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #f2f2f2 75%),
    linear-gradient(-45deg, transparent 75%, #f2f2f2 75%);
  background-position: 0 0, 0 8px, 8px -8px, -8px 0;
  background-size: 16px 16px;
}

.equipment-layer-adjustment-viewport.is-bg-black {
  background: #050505;
}

.equipment-layer-adjustment-viewport.is-bg-white {
  background: #f8f8f0;
}

.equipment-layer-adjustment-viewport.is-bg-green {
  background: #00ff00;
}

.equipment-layer-adjustment-stage {
  position: relative;
  transform-origin: top left;
}

.equipment-layer-adjustment-image {
  position: absolute;
  inset: 0 auto auto 0;
  display: block;
  image-rendering: pixelated;
  user-select: none;
}

.equipment-layer-adjustment-image[hidden] {
  display: none;
}

.equipment-layer-adjustment-image.is-hidden {
  display: none !important;
}

.equipment-layer-adjustment-layer {
  transform-origin: center center;
}

.equipment-layer-adjustment-base {
  z-index: 0;
}

.equipment-layer-adjustment-right {
  z-index: 1;
}

.equipment-layer-adjustment-left {
  z-index: 4;
}

.equipment-layer-adjustment-body {
  z-index: 2;
}

.equipment-layer-adjustment-face {
  z-index: 3;
}

.equipment-layer-adjustment-head {
  z-index: 4;
}

.equipment-layer-adjustment-control-section {
  margin-bottom: 14px;
}

.equipment-layer-adjustment-control-section h5 {
  margin: 0 0 8px;
  color: var(--text);
  font-size: 0.95rem;
}

.equipment-layer-adjustment-file-note {
  margin-top: 8px;
  word-break: break-all;
}

.equipment-layer-adjustment-actions {
  margin: 12px 0 16px;
}

.equipment-layer-adjustment-output {
  display: grid;
  gap: 8px;
  margin: 0;
}

.equipment-layer-adjustment-output div {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.equipment-layer-adjustment-output dt {
  color: var(--muted);
  font-weight: 700;
}

.equipment-layer-adjustment-output dd {
  margin: 0;
  min-width: 0;
}

.equipment-layer-adjustment-output code {
  display: block;
  padding: 6px 8px;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
  color: var(--text);
  white-space: pre-wrap;
  word-break: break-word;
}

@media (max-width: 820px) {
  .equipment-layer-adjustment-layout {
    grid-template-columns: 1fr;
  }

  .equipment-layer-adjustment-toolbar,
  .equipment-layer-adjustment-control-grid {
    grid-template-columns: 1fr;
  }
}


.select-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: var(--menu-bg);
  color: var(--text);
  font: inherit;
}

.select-input::placeholder {
  color: var(--muted);
  opacity: 1;
}

.select-input option {
  background: var(--menu-bg);
  color: var(--text);
}

.select-input:disabled {
  background: color-mix(in srgb, var(--menu-bg) 82%, var(--border) 18%);
  color: var(--muted);
  opacity: 1;
}

.select-input.field-modified {
  background: #fff8e1;
  color: #3a2600;
  border-color: #f0a500;
}

.admin-textarea {
  width: 100%;
  min-height: 160px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  font: inherit;
  resize: vertical;
}

.support-form-input {
  box-sizing: border-box;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: #fff;
  color: #18222e;
  font: inherit;
}

.support-reply-email-options {
  display: grid;
  gap: 6px;
  margin: 6px 0;
}

.support-reply-email-option {
  display: flex;
  align-items: center;
  gap: 6px;
}

.inline-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
}

.list-plain {
  margin: 0;
  padding-left: 18px;
}

.collapsible-panel {
  padding-top: 0;
}

.panel-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin: 0 -16px;
  padding: 14px 16px;
  list-style: none;
  cursor: pointer;
}

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

.collapsible-panel[open] .panel-summary {
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.mypage-detail-menu .dashboard-list {
  display: grid;
  gap: 12px;
}

.mypage-detail-menu .dashboard-item {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #faf7ef;
}

.mypage-detail-menu .action-link {
  align-self: flex-start;
}

.mypage-status-table {
  margin-bottom: 16px;
}

.status-screen {
  display: grid;
  gap: 16px;
}

.status-screen .player-page-header {
  margin-bottom: 0;
}

.status-panel {
  background: rgba(24, 31, 43, 0.88);
}

.status-screen .panel-heading {
  background: linear-gradient(180deg, rgba(39, 50, 70, 0.96) 0%, rgba(24, 32, 48, 0.96) 100%);
  border-bottom-color: rgba(126, 153, 199, 0.54);
  color: #edf4ff;
}

.status-screen .mypage-status-table {
  width: 100%;
  margin: 0;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
}

.status-screen .mypage-status-table th,
.status-screen .mypage-status-table td {
  border-color: rgba(126, 153, 199, 0.32);
  background: rgba(10, 15, 24, 0.34);
}

.status-screen .mypage-status-table th {
  width: 7.5rem;
  color: #f4f0e8;
  font-size: 0.84rem;
  letter-spacing: 0;
  background: rgba(12, 19, 31, 0.62);
}

.status-screen .mypage-status-table td {
  color: #edf4ff;
  font-size: 0.95rem;
  line-height: 1.45;
}

.status-screen .mypage-status-table td > div:first-child {
  color: #fff4c0;
  font-size: 1.08rem;
  font-weight: 700;
}

.status-screen .mypage-status-table .muted {
  color: #aebbd0;
}

.status-screen .quest-progress {
  height: 9px;
  margin-top: 5px;
  border: 1px solid rgba(245, 211, 86, 0.32);
  background: rgba(5, 9, 16, 0.64);
}

.status-screen .quest-progress-bar {
  background: linear-gradient(90deg, #d99a2b 0%, #c9d84a 100%);
}

.status-stats-panel .mypage-status-table tbody {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.status-stats-panel .mypage-status-table tr {
  display: grid;
  grid-template-columns: 6rem minmax(0, 1fr);
  min-width: 0;
  border: 1px solid rgba(126, 153, 199, 0.28);
  background: rgba(8, 13, 22, 0.34);
}

.status-stats-panel .mypage-status-table th,
.status-stats-panel .mypage-status-table td {
  display: block;
  border: 0;
}

.status-stats-panel .mypage-status-table th {
  display: flex;
  align-items: flex-start;
  padding: 10px 9px;
  border-right: 1px solid rgba(126, 153, 199, 0.24);
}

.status-stats-panel .mypage-status-table td {
  min-width: 0;
  padding: 10px 11px;
}

.status-stats-panel .mypage-status-table tr:nth-child(3),
.status-stats-panel .mypage-status-table tr:nth-child(5),
.status-stats-panel .mypage-status-table tr:nth-child(6),
.status-stats-panel .mypage-status-table tr:nth-child(7),
.status-stats-panel .mypage-status-table tr:nth-child(8) {
  grid-template-columns: 6rem minmax(0, 1fr);
}

.status-subgrid {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 16px;
}

.status-job-panel .mypage-status-table,
.status-equipment-panel .mypage-status-table {
  table-layout: auto;
}

.status-job-panel .mypage-status-table th,
.status-equipment-panel .mypage-status-table th {
  width: 7rem;
}

.status-equipment-panel p {
  margin: 10px 0 0;
  padding: 9px 11px;
  border: 1px solid rgba(126, 153, 199, 0.30);
  background: rgba(10, 15, 24, 0.34);
  line-height: 1.45;
}

.equipment-screen {
  display: grid;
  gap: 16px;
}

.equipment-screen .player-page-header {
  margin-bottom: 0;
}

.equipment-panel {
  background: rgba(24, 31, 43, 0.88);
}

.equipment-screen .panel-heading {
  background: linear-gradient(180deg, rgba(39, 50, 70, 0.96) 0%, rgba(24, 32, 48, 0.96) 100%);
  border-bottom-color: rgba(126, 153, 199, 0.54);
  color: #edf4ff;
}

.equipment-current-table {
  width: 100%;
  margin: 0;
  table-layout: fixed;
}

.equipment-current-table th,
.equipment-current-table td {
  border-color: rgba(126, 153, 199, 0.32);
  background: rgba(10, 15, 24, 0.34);
  vertical-align: middle;
}

.equipment-current-table th {
  width: 7.5rem;
  color: #f4f0e8;
  background: rgba(12, 19, 31, 0.62);
}

.equipment-current-table .equipment-current-item {
  color: #edf4ff;
}

.equipment-current-table .equipment-current-item strong {
  color: #fff4c0;
}

.equipment-current-identity,
.equipment-item-identity {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.equipment-current-copy,
.equipment-item-copy {
  min-width: 0;
}

.equipment-current-table .equipment-current-action {
  width: 11rem;
}

.equipment-current-table .equipment-current-action form,
.equipment-current-table .equipment-current-action .action-button {
  width: 100%;
}

.equipment-inventory-description {
  margin: 0 0 12px;
}

.equipment-screen .equipment-table-buy {
  table-layout: auto;
  width: 100%;
}

.equipment-screen .equipment-table-buy th {
  white-space: nowrap;
}

.equipment-screen .equipment-table-buy th:nth-child(1),
.equipment-screen .equipment-table-buy .shop-col-name {
  width: 15rem;
}

.equipment-screen .equipment-table-buy th:nth-child(3),
.equipment-screen .equipment-table-buy .equipment-col-count {
  width: 1%;
  text-align: center;
  white-space: nowrap;
}

.equipment-screen .equipment-table-buy th:nth-child(4),
.equipment-screen .equipment-table-buy .equipment-col-actions {
  width: 1%;
  white-space: nowrap;
}

.equipment-screen .equipment-table-buy .shop-col-name strong {
  color: #fff4c0;
}

.equipment-screen .equipment-table-buy .shop-col-name .shop-cell-value,
.equipment-screen .equipment-table-buy .equipment-col-actions .shop-cell-value {
  min-height: 100%;
}

.equipment-screen .equipment-table-buy .shop-col-name .shop-cell-value {
  display: flex;
  align-items: center;
}

.equipment-screen .equipment-detail-toggle {
  margin-top: 6px;
  padding-top: 6px;
  border-color: rgba(126, 153, 199, 0.26);
}

.equipment-screen .equipment-col-actions .shop-cell-value {
  display: grid;
  align-content: center;
  gap: 6px;
}

.equipment-screen .equipment-col-actions .action-button {
  width: 100%;
  min-width: 0;
  justify-content: center;
}

.equipment-screen .equipment-action-status {
  display: block;
  text-align: center;
}

.mypage-sp-actions-panel {
  display: none;
}

.mypage-sp-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.mypage-sp-actions-stack:has(.mypage-sp-actions-disclosure[open]) .mypage-sp-quick-actions {
  display: none;
}

.mypage-sp-quick-btn {
  flex: 1 1 calc(50% - 4px);
  white-space: nowrap;
}

.mypage-sp-actions-disclosure {
  position: relative;
}

.mypage-sp-actions-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 96px;
  overflow: visible;
  cursor: pointer;
  list-style: none;
}

.mypage-sp-actions-toggle::-webkit-details-marker {
  display: none;
}

.mypage-sp-actions-toggle::after {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-left: 8px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
}

details[open] .mypage-sp-actions-toggle::after {
  transform: rotate(225deg);
  margin-top: 4px;
}

.mypage-sp-ready-badge {
  position: absolute;
  top: -7px;
  right: -8px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #f59e0b;
  color: #fff;
  font-size: 0.62rem;
  font-weight: bold;
  line-height: 1.1;
  box-shadow: 0 2px 6px rgba(48, 44, 34, 0.18);
}

.mypage-sp-actions-sheet {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

.mypage-hamburger-menu {
  display: block;
  position: relative;
}

.site-hamburger-menu {
  flex-shrink: 0;
}

.mypage-hamburger-button {
  display: inline-flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  gap: 0;
  min-width: 92px;
  height: 30px;
  padding: 2px 8px;
  border: 1px solid var(--border-strong);
  border-radius: 0;
  background: var(--panel);
  color: var(--text);
  font: inherit;
  cursor: pointer;
  list-style: none;
  box-sizing: border-box;
  text-align: center;
}

.mypage-hamburger-button::-webkit-details-marker {
  display: none;
}

.mypage-hamburger-button::after {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-right: 1.5px solid var(--text);
  border-bottom: 1.5px solid var(--text);
  transform: rotate(45deg);
  margin-bottom: 3px;
  flex-shrink: 0;
}

details[open] .mypage-hamburger-button::after {
  transform: rotate(225deg);
  margin-bottom: -3px;
}

.mypage-hamburger-button span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
}

.mypage-hamburger-button strong {
  margin-left: 0;
  line-height: 1;
  font-size: 0.95rem;
  font-weight: 400;
}

.mypage-hamburger-sheet {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 30;
  width: min(320px, calc(100vw - 56px));
  padding: 12px;
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  background: var(--menu-bg);
  box-shadow: 3px 3px 0 rgba(var(--shadow-rgb), 0.12);
}

.mypage-hamburger-title {
  margin: 0 0 10px;
  font-weight: 700;
}

.mypage-hamburger-sheet .dashboard-list {
  display: grid;
  gap: 10px;
}

.mypage-hamburger-sheet .dashboard-item {
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--menu-card);
}

.mypage-hamburger-sheet .action-link {
  align-self: flex-start;
}

.mypage-hamburger-sheet .action-grid-separator {
  margin: 6px 0 2px;
  border-top: 2px solid color-mix(in srgb, var(--accent-strong) 28%, var(--border));
}

.category-tabs {
  display: grid;
  gap: 12px;
}

.tab-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tab-label {
  appearance: none;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.tab-panels {
  display: grid;
}

.tab-panel {
  display: none;
}

.tab-label.is-active {
  border-color: var(--border-strong);
  background: var(--accent);
  color: var(--text);
}

.tab-panel.is-active {
  display: block;
}

.quest-list-panel {
  background: rgba(24, 31, 43, 0.88);
  margin-bottom: 72px;
}

.quest-list-heading {
  justify-content: space-between;
  gap: 10px;
}

.quest-list-count {
  color: #b8c3d7;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0;
  white-space: nowrap;
}

.quest-list-panel .tab-labels {
  gap: 6px;
}

.quest-list-panel .tab-label {
  border-radius: 3px;
  background: rgba(15, 20, 30, 0.82);
  border-color: rgba(156, 172, 206, 0.34);
  color: #b8c3d7;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.quest-list-panel .tab-label.is-active {
  background: linear-gradient(180deg, rgba(57, 70, 96, 0.96) 0%, rgba(27, 37, 56, 0.96) 100%);
  border-color: rgba(196, 210, 238, 0.58);
  color: #f1f4fb;
}

.quest-category-tabs {
  gap: 8px;
}

.quest-category-labels {
  padding: 6px;
  border: 1px solid rgba(156, 172, 206, 0.20);
  background: rgba(6, 10, 18, 0.26);
}

.quest-list-panel .quest-category-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 6px 9px;
  font-size: 0.82rem;
}

.quest-category-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.6em;
  padding: 0 5px;
  border: 1px solid rgba(156, 172, 206, 0.26);
  background: rgba(5, 8, 14, 0.58);
  color: #d8deec;
  font-size: 0.74rem;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}

.quest-table {
  table-layout: fixed;
  font-size: 0.94rem;
  background: rgba(10, 14, 22, 0.18);
}

.quest-table th,
.quest-table td {
  vertical-align: middle;
}

.quest-table thead th {
  padding: 6px 10px;
  background: rgba(7, 11, 18, 0.58);
  color: #cfd8ea;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-align: center;
}

.quest-table .quest-col-main {
  width: auto;
}

.quest-table .quest-col-progress {
  width: 96px;
}

.quest-table .quest-col-reward {
  width: 158px;
}

.quest-table .quest-col-status {
  width: 88px;
  text-align: center;
}

.quest-row-active {
  background: rgba(52, 64, 86, 0.36);
  box-shadow: inset 3px 0 0 rgba(164, 184, 224, 0.74);
}

.quest-title-line {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 2px;
  min-width: 0;
}

.quest-title {
  color: #f4f0e8;
  line-height: 1.25;
}

.quest-category-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 4.8em;
  padding: 1px 6px;
  border: 1px solid rgba(158, 174, 206, 0.34);
  background: rgba(12, 18, 28, 0.52);
  color: #bfc8dc;
  font-size: 0.75rem;
  line-height: 1.45;
  white-space: nowrap;
}

.quest-period {
  display: inline-block;
  margin: 0 0 1px;
  color: #b8c3d7;
  font-size: 0.82rem;
}

.quest-description {
  display: block;
  color: #b3bac8;
  line-height: 1.42;
}

.quest-table .quest-progress {
  height: 12px;
  margin: 0 0 4px;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,0.05) 0 1px, transparent 1px 8px),
    rgba(0, 0, 0, 0.55);
  border-color: rgba(180, 196, 226, 0.18);
}

.quest-table .quest-progress-bar {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.34) 0%, rgba(255,255,255,0) 58%, rgba(0,0,0,0.18) 100%),
    linear-gradient(90deg, #7f9a50 0%, #c6b15e 100%);
  box-shadow: 0 0 5px rgba(142, 168, 95, 0.34);
}

.quest-table .quest-progress-text {
  display: block;
  position: static;
  inset: auto;
  z-index: auto;
  color: #c6cedd;
  font-size: 0.78rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
  text-align: center;
}

.quest-table .quest-reward-label {
  color: #f0eadc;
  line-height: 1.35;
}

.quest-status-label {
  display: inline-block;
  min-width: 4em;
  padding: 2px 6px;
  border: 1px solid rgba(156, 172, 206, 0.26);
  background: rgba(12, 18, 28, 0.40);
  color: #b8c3d7;
  font-size: 0.82rem;
  line-height: 1.35;
}

.quest-status-claimed {
  color: #d9d0ae;
  border-color: rgba(198, 177, 94, 0.34);
}

.quest-col-status .button_to,
.quest-claim-button {
  width: 100%;
}

.quest-claim-button {
  padding: 6px 8px;
  font-size: 0.82rem;
}

.job-filter-tabs {
  display: grid;
  gap: 10px;
}

.job-tab-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.job-tab-label {
  appearance: none;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--muted);
  font-size: 13px;
  cursor: pointer;
}

.job-tab-panels {
  display: grid;
}

.job-tab-panel {
  display: none;
}

.job-tab-label.is-active {
  border-color: var(--border-strong);
  background: var(--surface-emphasis);
  color: var(--text);
}

.job-tab-panel.is-active {
  display: block;
}

.sp-panel-chevron {
  display: none;
}

@media (min-width: 641px) {
  .shop-table-buy {
    table-layout: auto;
  }

  .shop-table-buy th {
    width: auto;
    white-space: nowrap;
  }

  .shop-table-buy th:nth-child(1),
  .shop-table-buy .shop-col-name {
    width: 14rem;
  }

  .shop-table-buy th:nth-child(2),
  .shop-table-buy .shop-col-equippable {
    width: 1%;
    text-align: center;
  }

  .shop-table-buy .shop-col-equippable .shop-cell-value {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .shop-table-buy th:nth-child(4),
  .shop-table-buy .shop-col-price {
    width: 1%;
    white-space: nowrap;
  }
  
    .shop-table-buy th:nth-child(5),
    .shop-table-buy .shop-col-buy {
      width: 1%;
      white-space: nowrap;
    }

  .shop-table-buy td.shop-col-description {
    display: none;
  }

  .shop-table-buy .shop-col-name .shop-cell-value {
    white-space: nowrap;
  }

  .shop-item-trigger {
    text-decoration: underline dotted color-mix(in srgb, var(--accent) 55%, transparent);
    text-underline-offset: 0.18em;
  }

  .shop-item-trigger:hover {
    color: var(--accent-strong, var(--accent));
  }

  .equipment-screen .equipment-table-buy,
  .equipment-screen .equipment-table-buy tbody {
    display: block;
    width: 100%;
  }

  .equipment-screen .equipment-table-buy thead {
    display: none;
  }

  .equipment-screen .equipment-table-buy tr {
    display: grid;
    grid-template-columns: minmax(11rem, 0.9fr) minmax(0, 1.55fr) 3.5rem 10rem;
    grid-template-areas: "name effect count actions";
    gap: 0;
    margin-bottom: 8px;
    border: 1px solid rgba(126, 153, 199, 0.30);
    background: rgba(8, 13, 22, 0.34);
  }

  .equipment-screen .equipment-table-buy td {
    display: block;
    min-width: 0;
    border: 0;
    border-left: 1px solid rgba(126, 153, 199, 0.24);
    padding: 0;
  }

  .equipment-screen .equipment-table-buy td:first-child {
    border-left: 0;
  }

  .equipment-screen .equipment-table-buy td::before {
    display: none;
  }

  .equipment-screen .equipment-table-buy .shop-col-name {
    grid-area: name;
    width: auto;
  }

  .equipment-screen .equipment-table-buy .equipment-col-effect-compare {
    grid-area: effect;
    width: auto;
  }

  .equipment-screen .equipment-table-buy .equipment-col-count {
    grid-area: count;
    width: auto;
    align-self: stretch;
  }

  .equipment-screen .equipment-table-buy .equipment-col-count .shop-cell-value {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
  }

  .equipment-screen .equipment-table-buy .equipment-col-actions {
    grid-area: actions;
    width: auto;
  }
}

@media (min-width: 641px) {
  .equipment-screen .equipment-table-buy {
    display: table;
  }

  .equipment-screen .equipment-table-buy thead {
    display: table-header-group;
  }

  .equipment-screen .equipment-table-buy tbody {
    display: table-row-group;
  }

  .equipment-screen .equipment-table-buy tr {
    display: table-row;
    margin-bottom: 0;
    border: 0;
    background: transparent;
  }

  .equipment-screen .equipment-table-buy th,
  .equipment-screen .equipment-table-buy td {
    display: table-cell;
    border: 1px solid rgba(126, 153, 199, 0.32);
    padding: 0;
    vertical-align: middle;
  }

  .equipment-screen .equipment-table-buy th {
    padding: 6px 10px;
  }

  .equipment-screen .equipment-table-buy td:first-child {
    border-left: 1px solid rgba(126, 153, 199, 0.32);
  }
}

@media (max-width: 640px) {
  .shop-wallet-panel .key-stats {
    width: 100%;
  }

  .shop-board-panel {
    margin-bottom: 18px;
  }

  .shop-sell-panel {
    margin-bottom: 160px;
  }

  .shop-board-heading {
    align-items: center;
  }

  .shop-board-count {
    font-size: 0.72rem;
  }

  .shop-board-panel .tab-labels,
  .shop-board-panel .job-tab-labels {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 5px;
  }

  .shop-board-panel .tab-label,
  .shop-board-panel .job-tab-label {
    width: 100%;
    padding: 7px 6px;
    font-size: 0.78rem;
  }

  .shop-board-panel .shop-available-tabs > .tab-labels {
    grid-template-columns: 1fr;
  }

  .shop-board-panel .shop-filters {
    gap: 9px;
    margin-bottom: 10px;
    padding: 7px 8px;
  }

  .shop-board-panel .shop-filters label {
    font-size: 0.82rem;
  }

  .sp-hidden {
    display: none;
  }

  /* SP collapsible panels */
  [data-sp-panel] > .panel-heading {
    position: relative;
    cursor: pointer;
    user-select: none;
  }

  .sp-panel-chevron {
    display: inline-block;
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    min-width: 2.35em;
    padding: 2px 5px;
    border: 1px solid rgba(110, 130, 170, 0.58);
    border-radius: 3px;
    background: rgba(16, 22, 34, 0.78);
    color: #dbe7f6;
    font-family: monospace;
    font-size: 0.72rem;
    line-height: 1.1;
    text-align: center;
    transition:
      background 0.18s ease,
      border-color 0.18s ease;
    pointer-events: none;
  }

  [data-sp-panel].is-collapsed > .panel-heading .sp-panel-chevron {
    transform: translateY(-50%);
  }

  [data-sp-panel].is-collapsed > *:not(.panel-heading) {
    display: none;
  }

  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .two-column,
  .three-column,
  .action-grid,
  .admin-preview-grid,
  .job-catalog-item-grid {
    grid-template-columns: 1fr;
  }

  .mypage-sp-actions-sheet .action-grid,
  .mypage-hamburger-sheet .action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .mypage-sp-actions-sheet .action-group-span-2 {
    grid-column: 1 / -1;
  }

  .job-catalog-item-header {
    flex-direction: column;
  }

  .job-catalog-summary {
    flex-direction: column;
    align-items: flex-start;
  }

  .job-catalog-item-actions {
    min-width: 0;
    width: 100%;
  }

  .job-selection-screen {
    gap: 14px;
  }

  .job-selection-hero {
    padding: 13px 15px;
  }

  .job-selection-hero .mypage-hero-bar {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
  }

  .job-selection-hero .exploration-player-avatar {
    width: 76px;
    height: 76px;
  }

  .job-selection-hero h1 {
    font-size: 1.2rem;
  }

  .job-selection-hero-meta {
    gap: 5px;
  }

  .job-selection-hero-meta span {
    padding: 2px 6px;
    font-size: 0.75rem;
  }

  .job-selection-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .job-selection-screen .job-catalog-summary {
    min-height: 54px;
    padding: 10px 11px;
  }

  .job-selection-screen .job-catalog-item-frame.has-summary-action .job-catalog-summary {
    padding-right: 64px;
  }

  .job-selection-screen .job-catalog-summary-meta {
    justify-content: flex-start;
    gap: 6px;
  }

  .job-selection-screen .job-catalog-item-body {
    padding: 11px;
  }

  .job-selection-screen .job-catalog-item-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .job-selection-screen .job-change-form {
    min-width: 0;
  }

  .job-summary-change-form {
    top: 12px;
    right: 10px;
  }

  .data-table th,
  .data-table td {
    display: block;
    width: 100%;
  }

  .data-table tr {
    display: block;
    margin-bottom: 8px;
    border: 1px solid var(--border);
  }

  .data-table th {
    border-bottom: 0;
  }

  .data-table td {
    border-top: 0;
  }

  .job-selection-screen .job-detail-table thead {
    display: table-header-group;
  }

  .job-selection-screen .job-detail-table tr {
    display: table-row;
    margin-bottom: 0;
    border: 0;
  }

  .job-selection-screen .job-detail-table th,
  .job-selection-screen .job-detail-table td {
    display: table-cell;
    width: auto;
    padding: 6px 4px;
    border: 1px solid rgba(126, 153, 199, 0.30);
    font-size: 0.78rem;
    line-height: 1.35;
    word-break: keep-all;
  }

  .job-selection-screen .job-detail-table .job-detail-name {
    width: 38%;
  }

  .job-selection-screen .job-detail-table .job-detail-name[data-short-label] {
    font-size: 0;
  }

  .job-selection-screen .job-detail-table .job-detail-name[data-short-label]::before {
    content: attr(data-short-label);
    font-size: 0.78rem;
  }

  .job-selection-screen .job-bonus-table .job-detail-name,
  .job-selection-screen .job-total-bonus-table .job-detail-name,
  .job-selection-screen .job-growth-bonus-table .job-detail-name,
  .job-selection-screen .job-master-bonus-table .job-detail-name {
    width: 42%;
  }

  .job-selection-screen .job-total-bonus-table td,
  .job-selection-screen .job-bonus-table td,
  .job-selection-screen .job-growth-bonus-table td,
  .job-selection-screen .job-master-bonus-table td {
    width: 29%;
  }

  .job-selection-screen .job-status-table .job-detail-name {
    width: 25%;
  }

  .job-selection-screen .job-status-table td {
    width: 37.5%;
  }

  .job-selection-screen .job-mastery-status-table th,
  .job-selection-screen .job-mastery-status-table td,
  .job-selection-screen .job-master-rank-status-table th,
  .job-selection-screen .job-master-rank-status-table td {
    padding: 5px 2px;
    font-size: 0.72rem;
  }

  .job-selection-screen .job-mastery-status-table .job-detail-name,
  .job-selection-screen .job-master-rank-status-table .job-detail-name {
    width: 22%;
  }

  .job-selection-screen .job-mastery-status-table .job-detail-name[data-short-label]::before,
  .job-selection-screen .job-master-rank-status-table .job-detail-name[data-short-label]::before {
    font-size: 0.72rem;
  }

  .job-selection-screen .job-master-rank-status-table td {
    width: auto;
  }

  .job-selection-screen .job-detail-value {
    white-space: normal;
  }

  .job-selection-screen .job-skill-detail-table .job-detail-cost {
    width: 20%;
  }

  body.admin-page {
    --page-padding: 10px;
  }

  body.admin-page .page {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  body.admin-page .panel {
    padding: 12px;
    overflow-x: auto;
  }

  body.admin-page .panel-heading {
    margin: -12px -12px 12px;
    padding: 8px 12px;
  }

  body.admin-page .admin-form-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  body.admin-page .data-table:has(thead) {
    display: table;
    width: max-content !important;
    min-width: 520px;
    max-width: none;
    table-layout: auto !important;
  }

  body.admin-page .data-table:has(thead) thead {
    display: table-header-group;
  }

  body.admin-page .data-table:has(thead) tbody {
    display: table-row-group;
  }

  body.admin-page .data-table:has(thead) tr {
    display: table-row;
    margin-bottom: 0;
    border: 0;
  }

  body.admin-page .data-table:has(thead) th,
  body.admin-page .data-table:has(thead) td {
    display: table-cell;
    width: auto;
    border: 1px solid var(--border);
    vertical-align: top;
  }

  body.admin-page .data-table:has(thead) th {
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
  }

  body.admin-page .data-table:has(thead) td {
    border-top: 1px solid var(--border);
  }

  body.admin-page .data-table:has(thead) .select-input {
    min-width: 6rem;
  }

  body.admin-page .data-table:has(thead) .action-button,
  body.admin-page .data-table:has(thead) .action-link {
    white-space: nowrap;
  }

  body.admin-page .table-scroll {
    margin-inline: -4px;
    padding-inline: 4px;
  }

  body.admin-page .table-scroll > table {
    min-width: 760px;
  }

  .data-table.skill-training-table thead {
    display: none;
  }

  .data-table.skill-training-table tr {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 4px;
    padding: 8px;
  }

  .data-table.skill-training-table .skill-col-index {
    display: block;
    flex: 0 0 100%;
    font-size: 0.75rem;
    color: var(--muted);
    border-bottom: 1px solid var(--border);
    margin-bottom: 2px;
  }

  .data-table.skill-training-table .skill-col-name {
    flex: 1;
    min-width: 0;
  }

  .data-table.skill-training-table .skill-col-action {
    flex-shrink: 0;
  }

  .data-table.skill-training-table .skill-col-effect,
  .data-table.skill-training-table .skill-col-next {
    flex: 0 0 100%;
  }

  .data-table.skill-training-table .skill-col-cost {
    display: none;
  }

  .data-table.skill-training-table .skill-col-rank {
    flex: 0 0 100%;
    font-size: 0.85rem;
    color: var(--muted);
  }

  .data-table.skill-training-table .skill-col-action form,
  .data-table.skill-training-table .skill-col-action .action-button {
    width: 100%;
  }

  .skill-training-screen {
    gap: 14px;
  }

  .skill-training-hero {
    padding: 13px 15px;
  }

  .skill-training-hero .mypage-hero-bar {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
  }

  .skill-training-hero .exploration-player-avatar {
    width: 76px;
    height: 76px;
  }

  .skill-training-hero h1 {
    font-size: 1.2rem;
  }

  .skill-training-hero-meta {
    gap: 5px;
  }

  .skill-training-hero-meta span {
    padding: 2px 6px;
    font-size: 0.75rem;
  }

  .skill-training-overview {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .skill-training-screen .panel-heading {
    margin: -12px -12px 10px;
    padding: 8px 10px;
  }

  .skill-training-mastery-panel .mypage-status-table,
  .skill-training-mastery-panel .mypage-status-table tbody,
  .skill-training-mastery-panel .mypage-status-table tr,
  .skill-training-mastery-panel .mypage-status-table th,
  .skill-training-mastery-panel .mypage-status-table td {
    display: block;
    width: auto;
  }

  .skill-training-mastery-panel .mypage-status-table tr {
    margin-bottom: 8px;
    padding: 9px 11px;
    border: 1px solid rgba(126, 153, 199, 0.30);
    background: rgba(8, 13, 22, 0.34);
  }

  .skill-training-mastery-panel .mypage-status-table th,
  .skill-training-mastery-panel .mypage-status-table td {
    padding: 0;
    border: 0;
    background: transparent;
  }

  .skill-training-mastery-panel .mypage-status-table th {
    margin-bottom: 7px;
  }

  .data-table.skill-training-table tr {
    gap: 6px;
    padding: 9px 10px;
    border-color: rgba(126, 153, 199, 0.30);
    background: rgba(8, 13, 22, 0.34);
  }

  .data-table.skill-training-table .skill-col-index {
    padding: 0 0 5px;
    border: 0;
    border-bottom: 1px solid rgba(126, 153, 199, 0.28);
    color: #b8c3d7;
  }

  .data-table.skill-training-table .skill-col-name {
    flex: 1 1 58%;
    padding: 0;
    border: 0;
    background: transparent;
  }

  .data-table.skill-training-table .skill-col-rank {
    flex: 0 0 100%;
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    padding: 7px 8px;
    border: 1px solid rgba(126, 153, 199, 0.30);
    background: rgba(8, 13, 22, 0.36);
    color: #d8e5f8;
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
  }

  .data-table.skill-training-table .skill-col-rank::before {
    content: "強化段階";
    color: #b8c3d7;
    margin-right: 2px;
  }

  .data-table.skill-training-table .skill-col-effect,
  .data-table.skill-training-table .skill-col-next {
    padding: 7px 8px;
    border: 1px solid rgba(126, 153, 199, 0.24);
    background: rgba(8, 13, 22, 0.24);
  }

  .data-table.skill-training-passive-table .skill-col-source {
    flex: 0 0 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 0.82rem;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .data-table.skill-training-passive-table .skill-col-source::before {
    content: "由来: ";
    color: #d8e5f8;
    font-weight: 700;
  }

  .data-table.skill-training-table .skill-col-action {
    flex: 0 0 100%;
    padding: 0;
    border: 0;
    background: transparent;
  }

  .data-table.skill-training-table .skill-col-action .action-button {
    min-height: 36px;
    font-size: 0.82rem;
  }

  .dungeon-hub-screen {
    gap: 14px;
  }

  .dungeon-hub-hero {
    padding: 13px 15px;
  }

  .dungeon-hub-hero .mypage-hero-bar {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
  }

  .dungeon-hub-hero .exploration-player-avatar {
    width: 76px;
    height: 76px;
  }

  .dungeon-hub-hero h1 {
    font-size: 1.2rem;
  }

  .dungeon-hub-hero-meta,
  .dungeon-hub-hero .player-header-meta {
    gap: 5px;
  }

  .dungeon-hub-hero-meta span,
  .dungeon-hub-hero .player-header-meta span {
    padding: 2px 6px;
    font-size: 0.75rem;
  }

  .dungeon-hub-summary-list,
  .dungeon-hub-card-top {
    grid-template-columns: minmax(0, 1fr);
  }

  .dungeon-hub-summary-panel {
    display: none;
  }

  .dungeon-hub-action-box {
    order: 1;
    padding: 9px;
  }

  .dungeon-hub-card-copy {
    order: 2;
  }

  .dungeon-hub-action-grid-result-mode .dungeon-action-result-mode-form {
    grid-row: 4;
  }

  .dungeon-hub-action-grid .dungeon-batch-reexplore-submit {
    grid-column: 1 / -1;
  }

  .dungeon-hub-state-table,
  .dungeon-hub-state-table tbody,
  .dungeon-hub-state-table tr,
  .dungeon-hub-state-table th,
  .dungeon-hub-state-table td {
    display: block;
    width: auto;
  }

  .dungeon-hub-state-table tr {
    margin-bottom: 8px;
    padding: 8px 10px;
    border: 1px solid rgba(180, 140, 60, 0.30);
    background: rgba(20, 13, 5, 0.42);
  }

  .dungeon-hub-state-table th,
  .dungeon-hub-state-table td {
    padding: 0;
    border: 0;
    background: transparent;
  }

  .dungeon-hub-state-table th {
    margin-bottom: 5px;
  }

  .dungeon-hub-preview-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .dungeon-hub-screen .enemy-preview-stats {
    gap: 6px;
  }

  .dungeon-hub-screen .enemy-preview-stats span {
    border-radius: 4px;
    font-size: 0.78rem;
  }

  .quest-list-panel {
    gap: 10px;
    margin-bottom: 240px;
    padding: 12px;
  }

  .quest-list-heading {
    align-items: center;
  }

  .quest-list-count {
    font-size: 0.72rem;
  }

  .quest-list-panel .tab-labels {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quest-list-panel .tab-label {
    width: 100%;
    padding: 7px 8px;
  }

  .quest-list-panel .quest-category-labels {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
    padding: 5px;
  }

  .quest-list-panel .quest-category-label {
    gap: 4px;
    padding: 6px 7px;
    font-size: 0.72rem;
  }

  .quest-category-count {
    min-width: 1.45em;
    padding: 0 4px;
    font-size: 0.68rem;
  }

  .quest-table,
  .quest-table tbody {
    display: block;
  }

  .quest-table thead {
    display: none;
  }

  .quest-table tr.quest-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px 10px;
    margin-bottom: 7px;
    padding: 8px;
    background: rgba(10, 14, 22, 0.36);
    border: 1px solid rgba(156, 172, 206, 0.28);
  }

  .quest-table tr.quest-row-active {
    box-shadow: inset 3px 0 0 rgba(164, 184, 224, 0.78);
  }

  .quest-table td {
    display: block;
    width: auto;
    padding: 0;
    border: 0;
  }

  .quest-table .quest-col-main {
    grid-column: 1 / -1;
  }

  .quest-table .quest-col-progress {
    grid-column: 1 / -1;
    width: auto;
  }

  .quest-table .quest-col-reward {
    width: auto;
    min-width: 0;
    align-self: center;
  }

  .quest-table .quest-col-status {
    width: auto;
    justify-self: end;
    align-self: center;
    text-align: right;
  }

  .quest-title-line {
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px;
  }

  .quest-category-chip {
    min-width: 0;
    flex: 0 0 auto;
  }

  .quest-description {
    font-size: 0.9rem;
  }

  .quest-table .quest-progress {
    margin-top: 2px;
  }

  .quest-table .quest-progress-text {
    text-align: left;
  }

  .quest-table .quest-reward-label {
    font-size: 0.92rem;
  }

  .quest-status-label {
    min-width: 0;
    white-space: nowrap;
  }

  .shop-table thead {
    display: none;
  }

  .shop-table,
  .shop-table tbody {
    display: block;
    width: 100%;
  }

  .shop-table tr {
    display: block;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 12px;
    border: 1px solid var(--border);
    background: var(--surface-soft, #fff);
    overflow: hidden;
  }

  .shop-table td {
    display: grid;
    grid-template-columns: 5.5rem 1fr;
    gap: 0;
    align-items: start;
    padding: 0;
    border-top: 1px solid var(--border);
  }

  .shop-table td:first-child {
    border-top: 0;
  }

  .shop-table td::before {
    content: attr(data-label);
    display: flex;
    align-items: center;
    align-self: stretch;
    padding: 8px 10px;
    border-right: 1px solid var(--border);
    background: color-mix(in srgb, var(--accent) 50%, white);
    color: var(--text);
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.2;
  }

  .shop-cell-value {
    min-width: 0;
    padding: 8px 10px;
  }

  .shop-table td.numeric {
    text-align: left;
  }

  .shop-table td.shop-col-equippable {
    text-align: left;
  }

  .shop-table td > form,
  .shop-table td > .action-button {
    width: 100%;
  }

  .shop-cell-value > form,
  .shop-cell-value > .action-button {
    width: 100%;
  }

  .shop-table-buy tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(5.5rem, auto);
    grid-template-areas:
      "name equip"
      "effect effect"
      "desc desc"
      "price buy";
    gap: 6px 8px;
    padding: 10px 12px;
  }

  .shop-table-buy td {
    display: block;
    min-width: 0;
    border: none;
    padding: 0;
  }

  .shop-table-buy td::before {
    display: none;
  }

  .shop-table-buy .shop-cell-value {
    padding: 0;
    min-width: 0;
  }

  .shop-table-buy .shop-col-name {
    grid-area: name;
    font-weight: bold;
    align-self: start;
    line-height: 1.35;
  }

  .shop-table-buy .shop-col-name .shop-cell-value {
    display: block;
  }

  .shop-table-buy .shop-col-equippable {
    grid-area: equip;
    align-self: center;
    justify-self: end;
    width: auto;
    min-width: max-content;
    white-space: nowrap;
  }

  .shop-table-buy .shop-col-equippable .shop-cell-value {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.15rem;
  }

  .shop-table-buy .shop-col-equippable .shop-equippable-label {
    display: inline;
    margin-right: 0.15rem;
    color: var(--muted);
    font-size: 0.8rem;
  }

  .shop-table-buy .shop-col-price {
    display: block;
    grid-area: price;
    align-self: center;
    justify-self: start;
    color: var(--text);
    font-weight: 700;
  }

  .shop-table-buy .shop-col-price .shop-price-value,
  .shop-table-sell .sell-col-price .shop-price-value {
    display: inline-flex;
    max-width: none;
    justify-content: flex-start;
  }

  .shop-table-buy .shop-col-price .shop-gold-amount,
  .shop-table-sell .sell-col-price .shop-gold-amount {
    flex: 0 0 auto;
    overflow: visible;
  }

    .shop-table-buy .shop-col-effect {
      grid-area: effect;
      font-size: 0.9rem;
      line-height: 1.4;
    }
  
    .shop-table-buy .shop-col-effect-compare {
      grid-area: effect;
      font-size: 0.9rem;
      line-height: 1.4;
    }
  
    .shop-table-buy .shop-col-compare {
      grid-area: compare;
    justify-self: stretch;
    text-align: left;
    font-size: 0.85rem;
    line-height: 1.4;
    color: var(--muted);
  }

  .shop-table-buy .shop-col-description {
    grid-area: desc;
    align-self: center;
    font-size: 0.85rem;
    color: var(--muted);
  }

  .shop-table-buy .shop-col-description .shop-cell-value {
    display: flex;
    align-items: center;
  }

  .shop-table-buy .shop-col-description .shop-item-detail-link {
    min-height: 32px;
    padding: 5px 8px;
    white-space: nowrap;
  }

  .shop-description-toggle {
    border-top: 1px solid var(--border);
    padding-top: 6px;
  }

  .shop-description-toggle summary {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    cursor: pointer;
    list-style: none;
    color: var(--text);
    font-size: 0.8rem;
    font-weight: 700;
  }

  .shop-description-toggle summary::-webkit-details-marker {
    display: none;
  }

  .shop-description-toggle summary::before {
    content: "+";
    color: var(--accent-strong);
    font-weight: 700;
  }

  .shop-description-toggle[open] summary::before {
    content: "-";
  }

  .shop-description-toggle > div {
    margin-top: 6px;
    line-height: 1.45;
  }

  .shop-table-buy .shop-col-buy {
    grid-area: buy;
    justify-self: stretch;
    width: 100%;
    max-width: 100%;
  }

  .shop-table-buy .shop-col-buy .shop-cell-value,
  .shop-table-buy .shop-col-buy .shop-cell-value > form,
  .shop-table-buy .shop-col-buy .button_to,
  .shop-table-buy .shop-col-buy .shop-cell-value > .action-button,
  .shop-table-buy .shop-col-buy .action-button {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    margin-top: 2px;
    justify-content: center;
    min-width: 0;
  }

  .shop-table-buy .shop-col-buy .shop-buy-price {
    display: inline;
    margin-left: auto;
  }

  .equipment-table-buy .equipment-col-count .equipment-count-label {
    display: inline;
    margin-right: 0.15rem;
    color: var(--muted);
    font-size: 0.8rem;
  }

  .shop-table-sell tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(5.5rem, auto);
    grid-template-areas:
      "name count"
      "price sell"
      "status status";
    gap: 6px 8px;
    padding: 10px 12px;
  }

  .shop-table-sell td {
    display: block;
    min-width: 0;
    border: none;
    padding: 0;
  }

  .shop-table-sell td::before {
    display: none;
  }

  .shop-table-sell .shop-cell-value {
    padding: 0;
    min-width: 0;
  }

  .shop-table-sell .sell-col-name {
    grid-area: name;
    font-weight: bold;
    align-self: center;
  }

  .shop-table-sell .sell-col-count {
    grid-area: count;
    align-self: center;
    justify-self: end;
    text-align: right;
    white-space: nowrap;
  }

  .shop-table-sell .sell-col-price {
    grid-area: price;
    align-self: center;
    justify-self: start;
    text-align: left;
    white-space: nowrap;
  }

  .shop-table-sell .sell-col-status {
    grid-area: status;
    align-self: center;
    font-size: 0.85rem;
    color: var(--muted);
  }

  .shop-table-sell .sell-col-sell {
    grid-area: sell;
    justify-self: stretch;
    width: 100%;
    max-width: 100%;
  }

  .shop-table-sell .sell-col-sell .shop-cell-value,
  .shop-table-sell .sell-col-sell .button_to,
  .shop-table-sell .sell-col-sell .action-button {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  .alchemy-rule-table thead,
  .alchemy-item-table thead {
    display: none;
  }

  .alchemy-rule-table,
  .alchemy-rule-table tbody,
  .alchemy-item-table,
  .alchemy-item-table tbody {
    display: block;
    width: 100%;
  }

  .alchemy-rule-table tr,
  .alchemy-item-table tr {
    display: block;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 12px;
    border: 1px solid var(--border);
    background: var(--surface-soft, #fff);
    overflow: hidden;
  }

  .alchemy-rule-table td,
  .alchemy-item-table td {
    display: grid;
    grid-template-columns: 5.5rem 1fr;
    gap: 0;
    align-items: start;
    padding: 0;
    border-top: 1px solid var(--border);
  }

  .alchemy-rule-table td:first-child,
  .alchemy-item-table td:first-child {
    border-top: 0;
  }

  .alchemy-rule-table td::before,
  .alchemy-item-table td::before {
    content: attr(data-label);
    display: flex;
    align-items: center;
    align-self: stretch;
    padding: 8px 10px;
    border-right: 1px solid var(--border);
    background: color-mix(in srgb, var(--accent) 50%, white);
    color: var(--text);
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.2;
  }

  .alchemy-cell-value {
    min-width: 0;
    padding: 8px 10px;
  }

  .alchemy-cell-value > form,
  .alchemy-cell-value > .action-button {
    width: 100%;
  }

  .alchemy-rule-table tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "kind"
      "effect"
      "description";
    gap: 0;
    padding: 10px 12px;
  }

  .alchemy-rule-table td {
    display: block;
    border: none;
    padding: 0;
  }

  .alchemy-rule-table td::before {
    display: none;
  }

  .alchemy-rule-kind {
    grid-area: kind;
    font-weight: 700;
    padding-bottom: 6px;
  }

  .alchemy-rule-effect {
    grid-area: effect;
    font-size: 0.9rem;
    line-height: 1.4;
    padding-bottom: 4px;
  }

  .alchemy-rule-description {
    grid-area: description;
    font-size: 0.85rem;
    line-height: 1.4;
    color: var(--muted);
  }

  .alchemy-item-table tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "name"
      "target"
      "smithing"
      "alchemy"
      "effect"
      "price"
      "lock"
      "action";
    gap: 6px 8px;
    padding: 10px 12px;
  }

  .alchemy-item-table td {
    display: block;
    border: none;
    padding: 0;
  }

  .alchemy-item-table td::before {
    display: none;
  }

  .alchemy-item-table .alchemy-cell-value {
    padding: 0;
  }

  .alchemy-item-table .alchemy-col-name {
    grid-area: name;
    font-weight: 700;
    line-height: 1.35;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(126, 153, 199, 0.24);
  }

  .alchemy-item-table .alchemy-col-price {
    grid-area: price;
    justify-self: stretch;
    align-self: start;
    min-width: 0;
    padding: 7px 8px;
    border: 1px solid rgba(126, 153, 199, 0.24);
    background: rgba(8, 13, 22, 0.24);
    text-align: left;
  }

  .alchemy-item-table .alchemy-col-target {
    grid-area: target;
    min-width: 0;
    padding: 7px 8px;
    border: 1px solid rgba(126, 153, 199, 0.24);
    background: rgba(8, 13, 22, 0.24);
    font-size: 0.85rem;
    line-height: 1.4;
    text-align: left;
    color: var(--muted);
  }

  .alchemy-item-table .alchemy-col-smithing,
  .alchemy-item-table .alchemy-col-alchemy {
    min-width: 0;
    padding: 7px 8px;
    border: 1px solid rgba(126, 153, 199, 0.24);
    background: rgba(8, 13, 22, 0.24);
    font-size: 0.9rem;
    line-height: 1.4;
    text-align: left;
  }

  .alchemy-item-table .alchemy-col-smithing {
    grid-area: smithing;
  }

  .alchemy-item-table .alchemy-col-alchemy {
    grid-area: alchemy;
  }

  .alchemy-item-table .alchemy-col-target::before,
  .alchemy-item-table .alchemy-col-smithing::before,
  .alchemy-item-table .alchemy-col-alchemy::before,
  .alchemy-item-table .alchemy-col-price::before,
  .alchemy-item-table .alchemy-col-lock::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 2px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.2;
  }

  .alchemy-item-table .alchemy-col-effect {
    grid-area: effect;
    padding: 7px 8px;
    border: 1px solid rgba(126, 153, 199, 0.24);
    background: rgba(8, 13, 22, 0.24);
    font-size: 0.9rem;
    line-height: 1.4;
  }

  .alchemy-item-table .alchemy-col-lock {
    grid-area: lock;
    align-self: center;
    padding: 7px 8px;
    border: 1px solid rgba(126, 153, 199, 0.24);
    background: rgba(8, 13, 22, 0.20);
    font-size: 0.85rem;
    line-height: 1.4;
    color: var(--muted);
  }

  .alchemy-item-table .alchemy-col-lock .alchemy-cell-value {
    display: flex;
    align-items: center;
  }

  .alchemy-item-table .alchemy-col-action {
    grid-area: action;
    align-self: center;
    justify-self: stretch;
    width: auto;
    min-width: 0;
  }

  .alchemy-item-table .alchemy-col-action .alchemy-cell-value {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
  }

  .alchemy-item-table .alchemy-col-action .button_to,
  .alchemy-item-table .alchemy-col-action form,
  .alchemy-item-table .alchemy-col-action .action-button {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
  }

  .alchemy-item-table .alchemy-col-action .action-button {
    width: 100%;
  }

  .mypage-hero-copy .mypage-status-table {
    table-layout: auto;
    border-top: 1px solid var(--border);
  }

  .mypage-hero-copy .mypage-status-table th {
    width: auto;
  }

  .mypage-hero-copy .mypage-status-table tbody {
    display: grid;
    grid-template-columns: auto 1fr;
  }

  .mypage-hero-copy .mypage-status-table tr {
    display: contents;
  }

  .mypage-hero-copy .mypage-status-table tr.sp-hidden {
    display: none;
  }

  .mypage-hero-copy .mypage-status-table th,
  .mypage-hero-copy .mypage-status-table td {
    display: block;
    border-top: 0;
    border-bottom: 1px solid var(--border);
  }

  .mypage-hero-copy .mypage-status-table th {
    border-right: 0;
  }

  .mypage-hero-copy .mypage-status-table td {
    border-left: 0;
  }

  .result-links,
  .hero-actions,
  .inline-links {
    flex-direction: column;
  }

  .public-hero-title {
    font-size: 1.65rem;
  }

  .public-hero-panel,
  .public-loop-panel,
  .public-party-panel,
  .public-closing-panel,
  .auth-panel,
  .auth-guide-panel {
    padding: 14px;
  }

  .public-hero-panel {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .public-encounter-card {
    padding: 10px;
  }

  .public-encounter-stage {
    min-height: 154px;
    gap: 5px;
    padding-inline: 0;
  }

  .public-combatant-image {
    width: min(126px, 100%);
  }

  .public-combatant-name {
    padding-inline: 5px;
    font-size: 0.7rem;
  }

  .public-hp-bar {
    width: min(6.4rem, 100%);
  }

  .public-hero-log p {
    font-size: 0.8rem;
  }

  .public-party-image {
    max-height: 92px;
  }

  .public-hero-tags {
    gap: 6px;
  }

  .public-home-primary,
  .public-closing-panel {
    grid-template-columns: 1fr;
  }

  .public-loop-step {
    gap: 8px;
    padding: 9px;
  }

  .public-closing-actions {
    min-width: 0;
  }

  .auth-shell {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .auth-heading h2 {
    font-size: 1.35rem;
  }

  .auth-links {
    display: grid;
    grid-template-columns: 1fr;
  }

  .result-links form,
  .result-links .button_to,
  .result-links .action-link,
  .result-links-secondary > * {
    flex: 0 0 auto;
  }

  .result-links .action-button,
  .result-links .action-link {
    min-height: 40px;
    padding-top: 9px;
    padding-bottom: 9px;
  }

  .shop-result-actions {
    flex-direction: row;
  }

  .shop-result-actions form,
  .shop-result-actions .button_to,
  .shop-result-actions .action-link {
    flex: 1 1 50%;
  }

  .exploration-result-page {
    padding-bottom: 124px;
  }

  .exploration-repeat-dock {
    bottom: 12px;
    width: calc(100% - 24px);
    padding: 8px 10px;
  }

  .floating-home-button {
    right: max(12px, env(safe-area-inset-right));
    bottom: calc(max(12px, env(safe-area-inset-bottom)) + 68px + 50px + 8px);
    width: 50px;
    height: 50px;
  }

  .floating-home-button-icon {
    font-size: 20px;
  }

  .floating-nav-menu {
    right: max(12px, env(safe-area-inset-right));
    bottom: calc(max(12px, env(safe-area-inset-bottom)) + 68px);
  }

  .floating-nav-menu .mypage-hamburger-button {
    width: 50px;
    height: 50px;
  }

  .floating-menu-button-icon {
    font-size: 20px;
  }

  .exploration-repeat-actions {
    gap: 8px;
  }

  .exploration-repeat-actions-single {
    grid-template-columns: minmax(0, 50%);
  }

  .exploration-repeat-dock .action-button-compact {
    width: 100%;
    min-height: 34px;
    padding: 6px 8px;
    font-size: 0.8rem;
    white-space: nowrap;
    line-height: 1;
  }

  .panel-summary {
    flex-direction: column;
    align-items: flex-start;
  }

  .quest-board-compact .quest-title-link {
    width: 100%;
  }

  .quest-board-compact {
    grid-template-columns: minmax(0, 1fr);
    gap: 7px;
  }

  .quest-board-description {
    width: 100%;
  }

  .quest-board-progress {
    width: 100%;
    min-width: 0;
  }

  .quest-board-claim {
    display: grid;
    width: 100%;
    grid-column: auto;
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    gap: 8px;
    text-align: center;
  }

  .quest-board-claim .button_to,
  .quest-board-claim .action-button,
  .quest-board-reward {
    width: 100%;
  }

  .quest-board-claim .result-badge {
    display: none;
  }

  .mypage-hero-panels {
    flex-direction: column;
  }

  .mypage-player-panel,
  .mypage-status-panel {
    flex: none;
    width: 100%;
  }

  .status-screen {
    gap: 14px;
  }

  .status-screen .player-page-header {
    padding: 14px 16px;
  }

  .status-stats-panel .mypage-status-table,
  .status-stats-panel .mypage-status-table tbody,
  .status-job-panel .mypage-status-table,
  .status-job-panel .mypage-status-table tbody,
  .status-equipment-panel .mypage-status-table,
  .status-equipment-panel .mypage-status-table tbody {
    display: block;
  }

  .status-stats-panel .mypage-status-table tbody {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }

  .status-screen .mypage-status-table tr {
    display: block;
    margin: 0 0 8px;
    border: 1px solid rgba(126, 153, 199, 0.30);
    background: rgba(8, 13, 22, 0.34);
  }

  .status-stats-panel .mypage-status-table tr {
    display: block;
  }

  .status-screen .mypage-status-table th,
  .status-screen .mypage-status-table td {
    display: block;
    width: auto;
    border: 0;
    padding: 9px 11px;
  }

  .status-screen .mypage-status-table th {
    border-bottom: 1px solid rgba(126, 153, 199, 0.22);
    background: rgba(12, 19, 31, 0.68);
  }

  .status-screen .mypage-status-table td {
    font-size: 0.94rem;
  }

  .status-screen .mypage-status-table td > div:first-child {
    font-size: 1.02rem;
  }

  .status-subgrid {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .equipment-screen {
    gap: 14px;
  }

  .equipment-screen .player-page-header {
    padding: 14px 16px;
  }

  .equipment-current-table,
  .equipment-current-table tbody,
  .equipment-current-table tr,
  .equipment-current-table th,
  .equipment-current-table td {
    display: block;
    width: auto;
  }

  .equipment-current-table tr {
    margin-bottom: 8px;
    padding: 9px 11px;
    border: 1px solid rgba(126, 153, 199, 0.30);
    background: rgba(8, 13, 22, 0.34);
  }

  .equipment-current-table th,
  .equipment-current-table td {
    padding: 0;
    border: 0;
    background: transparent;
  }

  .equipment-current-table th {
    margin-bottom: 7px;
  }

  .equipment-current-table .equipment-current-action {
    margin-top: 9px;
  }

  .equipment-current-table .equipment-current-action .action-button {
    min-height: 34px;
  }

  .equipment-screen .equipment-table-buy tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "name count"
      "effect effect"
      "actions actions";
    gap: 7px 10px;
    padding: 10px 12px;
  }

  .equipment-screen .equipment-table-buy .shop-col-name {
    grid-area: name;
  }

  .equipment-screen .equipment-table-buy .equipment-col-effect-compare {
    grid-area: effect;
  }

  .equipment-screen .equipment-table-buy .equipment-col-count {
    grid-area: count;
    align-self: start;
    justify-self: end;
    width: auto;
    color: var(--text);
    font-weight: 700;
  }

  .equipment-screen .equipment-table-buy .equipment-col-actions {
    grid-area: actions;
    justify-self: stretch;
    width: auto;
  }

  .equipment-screen .equipment-table-buy .equipment-col-actions .shop-cell-value {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 6px;
  }

  .equipment-screen .equipment-table-buy .equipment-col-actions .shop-cell-value > div {
    min-width: 0;
  }

  .equipment-screen .equipment-table-buy .equipment-col-actions .action-button {
    width: auto;
    min-width: 7rem;
    min-height: 34px;
  }

  .mypage-hero-bar {
    flex-direction: column;
    align-items: center;
  }

  .mypage-hero-bar .exploration-player-badge {
    float: none;
    margin: 0 0 8px;
    text-align: center;
  }

  .mypage-hero-bar .mypage-hero-copy {
    width: 100%;
  }

  .mypage-player-panel .exploration-player-badge {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 10px;
    text-align: left;
  }

  .mypage-player-panel .mypage-player-info {
    flex: 1;
    min-width: 0;
  }

  .mypage-job-portrait {
    width: 140px;
    height: 140px;
    flex-shrink: 0;
  }

  .site-header {
    align-items: flex-start;
  }

  .site-header-actions {
    width: 100%;
    display: block;
  }

  .site-nav {
    width: 100%;
    min-width: 0;
    justify-content: space-between;
    flex-wrap: nowrap;
    gap: 8px;
  }

  .site-user-badge {
    width: 100%;
    justify-content: center;
  }

  .mypage-hamburger-sheet {
    right: 0;
    width: min(320px, calc(100vw - 24px));
    max-width: calc(100vw - 24px);
  }


  .mypage-actions-panel {
    display: none;
  }

  .mypage-sp-actions-panel {
    display: none;
  }

  .mypage-sp-quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }

  .mobile-exploration-page .delve-result-title {
    flex-direction: column;
    align-items: flex-start;
  }

  .mobile-exploration-page .delve-result-title h2,
  .mobile-exploration-page .delve-result-title .result-badge {
    width: 100%;
  }

  .mobile-exploration-page .exploration-combatants {
    gap: 12px;
    padding: 28px 10px 0;
  }

  .mobile-exploration-page .exploration-combatant-vitals {
    max-width: 120px;
    font-size: 0.95rem;
  }

  .mobile-exploration-page .exploration-combatant-vitals-row {
    gap: 10px;
  }

  .mobile-exploration-page .delve-result-main-panel .result-copy {
    font-size: 0.94rem;
  }

  .mobile-exploration-page .delve-battle-log-panel .panel-summary {
    padding: 10px 12px;
  }
}

.deep-dungeon-enemy-editor {
  display: grid;
  gap: 0.75rem;
}

.deep-dungeon-enemy-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.deep-dungeon-enemy-item {
  display: grid;
  grid-template-columns: 7fr 3fr;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--border);
  background: var(--surface-subtle);
}

.deep-dungeon-enemy-item > span {
  min-width: 0;
  overflow-wrap: anywhere;
}

/* ========================================
   Town Theme: Mypage
   ======================================== */

.action-link-icon {
  font-size: 1.05em;
  flex-shrink: 0;
  width: 1.4em;
  text-align: center;
  line-height: 1;
}

/* Quest notice board */
.quest-board-panel {
  background: var(--notice);
  border-left: 4px solid var(--accent-strong);
}

/* Player / status panel headings */
.mypage-player-panel .panel-heading,
.mypage-status-panel .panel-heading {
  background: linear-gradient(180deg, var(--surface-emphasis) 0%, var(--accent) 100%);
  border-bottom-color: var(--border-strong);
}

/* Town facility board: main actions panel */
.mypage-actions-panel {
  background: var(--surface-soft);
  border: 2px solid var(--border-strong);
}


.mypage-actions-panel .action-link.action-link-primary {
  background: linear-gradient(180deg, #e4f0f8 0%, #c8def0 100%);
  border-color: #5a8ab8;
}

.mypage-actions-panel .action-link.action-link-primary:hover {
  background: linear-gradient(180deg, #eef6fc 0%, #d4e8f8 100%);
}

.mypage-actions-panel .action-link.action-link-primary::before {
  background: linear-gradient(180deg, #6b9fd4 0%, #2d6b9b 100%);
}

/* ========================================
   Professional Polish: Mypage Town
   ======================================== */

/* Panel heading: flanking decoration lines */
.panel-heading:not(.panel-summary)::before,
.panel-heading:not(.panel-summary)::after {
  content: "";
  flex: 1;
  height: 1px;
  background: currentColor;
  opacity: 0.2;
  flex-shrink: 0;
  min-width: 8px;
}

.panel-heading:not(.panel-summary)::before {
  margin-right: 8px;
}

.panel-heading:not(.panel-summary)::after {
  margin-left: 8px;
}

/* Panel depth: layered shadow */
.panel {
  box-shadow:
    3px 3px 0 rgba(var(--shadow-rgb), 0.08),
    0 1px 8px rgba(var(--shadow-rgb), 0.05);
}

/* Quest board: warm flanking gradient */
.quest-board-panel .panel-heading {
  background: linear-gradient(90deg, var(--accent-strong) 0%, var(--notice) 50%, var(--accent-strong) 100%);
  border-bottom-color: var(--accent-strong);
}

/* Player panel: theme-driven card bg */
.mypage-player-panel {
  background: linear-gradient(160deg, var(--surface-subtle) 0%, var(--surface-soft) 100%);
}

/* Portrait: subtle depth shadow */
.mypage-job-portrait {
  box-shadow: 0 3px 10px rgba(var(--shadow-rgb), 0.22);
}

/* Player name: prominent */
.mypage-player-info > p.muted:first-child {
  color: var(--text);
  font-weight: bold;
  font-size: 0.95rem;
  margin: 0 0 4px;
}

/* Job section: visual separator */
.mypage-player-job {
  margin: 6px 0 4px;
  padding: 6px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

/* Status panel: subtle tint */
.mypage-status-panel {
  background: color-mix(in srgb, var(--surface-subtle) 86%, var(--panel) 14%);
}

/* Status table: label vs value distinction */
.mypage-hero-copy .mypage-status-table {
  background: rgba(var(--shadow-rgb), 0.10);
  border-color: color-mix(in srgb, var(--border) 70%, var(--text) 30%);
  font-size: 0.95rem;
}

.mypage-hero-copy .mypage-status-table > tbody > tr > th {
  color: color-mix(in srgb, var(--text) 66%, var(--muted) 34%);
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0;
  background: rgba(var(--shadow-rgb), 0.14);
}

.mypage-hero-copy .mypage-status-table > tbody > tr > td {
  font-weight: 700;
  color: var(--text);
  background: rgba(var(--shadow-rgb), 0.06);
  text-shadow: 0 1px 2px rgba(var(--shadow-rgb), 0.26);
}

.mypage-hero-copy .mypage-status-table > tbody > tr:nth-child(-n+3) > td {
  color: #fff4c0;
}

.mypage-hero-copy .mypage-status-table > tbody > tr:nth-child(even) {
  background: rgba(var(--shadow-rgb), 0.08);
}

/* ========================================
   Town Themes ダーク (共通パネルルール)
   ======================================== */

body[data-theme^="town_"]:not(.dungeon-entrance-bg):not(.dungeon-interior-bg) .panel {
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9), 0 0 8px rgba(0, 0, 0, 0.6);
}

body[data-theme^="town_"] .quest-progress {
  background: rgba(0, 0, 0, 0.45);
  border-color: rgba(255, 255, 255, 0.08);
}

body[data-theme^="town_"] .result-badge {
  background: rgba(40, 46, 62, 0.88);
  border-color: rgba(120, 135, 168, 0.50);
  color: #c8d0e2;
}

body[data-theme^="town_"] .result-badge-positive {
  background: rgba(18, 52, 22, 0.88);
  border-color: rgba(60, 148, 70, 0.50);
  color: #a8d898;
}

body[data-theme^="town_"] .result-badge-negative {
  background: rgba(62, 14, 14, 0.88);
  border-color: rgba(178, 58, 48, 0.50);
  color: #f0a898;
}

body[data-theme^="town_"]:not(.dungeon-entrance-bg):not(.dungeon-interior-bg) .panel-heading {
  background: linear-gradient(180deg, var(--panel-heading-from) 0%, var(--panel-heading-to) 100%);
  color: var(--panel-heading-text);
  border-bottom: 2px solid var(--panel-heading-border);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
  letter-spacing: 0.07em;
}

/* ========================================
   Day Themes ライト (共通パネルルール)
   ======================================== */

body[data-theme^="day_"]:not(.dungeon-entrance-bg):not(.dungeon-interior-bg) .panel-heading {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.30) 0%, rgba(180, 210, 240, 0.24) 100%);
  color: var(--panel-heading-text);
  border-bottom: 2px solid var(--panel-heading-border);
  letter-spacing: 0.07em;
}

body[data-theme^="day_"] .quest-board-panel {
  background: var(--panel);
  border-left: 1px solid var(--border);
}

body[data-theme^="day_"] .quest-board-panel .panel-heading {
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.30) 0%, rgba(180, 210, 240, 0.24) 100%);
  border-bottom-color: var(--panel-heading-border);
}

body[data-theme^="day_"] .data-table th {
  background: color-mix(in srgb, var(--accent) 25%, transparent);
}

body[data-theme="town_slate"] .data-table th {
  background: transparent;
}

/* ========================================
   Dungeon Entrance Screen
   ======================================== */

body.dungeon-entrance-bg,
body.dungeon-interior-bg {
  --panel: rgba(18, 12, 6, 0.82);
  --text: #e8d9b8;
  --muted: #a09070;
  --border: rgba(180, 140, 60, 0.4);
  --border-strong: rgba(200, 160, 70, 0.6);
  --link: #d4a84a;
  --header-top: rgba(10, 6, 2, 0.85);
  --header-bottom: rgba(20, 12, 4, 0.85);
  --notice: rgba(18, 38, 75, 0.92);
  --alert: rgba(75, 15, 10, 0.92);
}

body.dungeon-entrance-bg .panel-heading,
body.dungeon-interior-bg .panel-heading {
  background: linear-gradient(180deg, rgba(60, 35, 10, 0.9) 0%, rgba(40, 22, 6, 0.9) 100%);
  color: #e8c870;
  border-bottom: 2px solid rgba(180, 130, 40, 0.6);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
  letter-spacing: 0.07em;
}

body.dungeon-entrance-bg .action-button,
body.dungeon-interior-bg .action-button {
  background: linear-gradient(180deg, rgba(140, 80, 20, 0.9) 0%, rgba(100, 50, 10, 0.9) 100%);
  border-color: rgba(200, 140, 50, 0.7);
  color: #f0e0b0;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

body.dungeon-entrance-bg .action-button:hover:not(:disabled),
body.dungeon-interior-bg .action-button:hover:not(:disabled) {
  background: linear-gradient(180deg, rgba(170, 100, 30, 0.95) 0%, rgba(130, 70, 15, 0.95) 100%);
  border-color: rgba(220, 170, 70, 0.9);
}

body.dungeon-entrance-bg .action-link,
body.dungeon-interior-bg .action-link {
  color: #d4a84a;
}

body.dungeon-entrance-bg .data-table th,
body.dungeon-interior-bg .data-table th {
  background: rgba(55, 38, 12, 0.65);
  color: #a09070;
}

body.dungeon-entrance-bg .floating-home-button,
body.dungeon-interior-bg .floating-home-button {
  background: rgba(18, 12, 6, 0.82);
  border-color: rgba(180, 140, 60, 0.5);
  color: #e8c870;
}

body.dungeon-entrance-bg .exploration-repeat-dock,
body.dungeon-interior-bg .exploration-repeat-dock {
  background: rgba(18, 12, 6, 0.92);
  border-color: rgba(180, 140, 60, 0.4);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.5);
}

body.dungeon-entrance-bg .exploration-repeat-dock .select-input,
body.dungeon-interior-bg .exploration-repeat-dock .select-input {
  background: rgba(40, 28, 10, 0.90);
  border-color: rgba(180, 140, 60, 0.4);
  color: #e8d9b8;
}

body.dungeon-entrance-bg .exploration-repeat-dock .select-input option,
body.dungeon-interior-bg .exploration-repeat-dock .select-input option {
  background: #281c0a;
  color: #e8d9b8;
}

body.dungeon-interior-bg .battle-log-turn {
  background: rgba(22, 14, 5, 0.82);
  border-color: rgba(180, 140, 60, 0.25);
}

body.dungeon-interior-bg .battle-log-turn-boss {
  background: rgba(40, 10, 5, 0.85);
  border-color: rgba(200, 80, 50, 0.45);
}

body.dungeon-entrance-bg .result-badge-positive,
body.dungeon-interior-bg .result-badge-positive {
  background: rgba(30, 80, 20, 0.80);
  border-color: rgba(80, 180, 50, 0.50);
  color: #b8e8a0;
}

body.dungeon-entrance-bg .result-badge-negative,
body.dungeon-interior-bg .result-badge-negative {
  background: rgba(80, 15, 10, 0.80);
  border-color: rgba(200, 60, 40, 0.50);
  color: #f0a898;
}

body.dungeon-entrance-bg .result-badge,
body.dungeon-interior-bg .result-badge {
  border-color: rgba(180, 140, 60, 0.40);
  color: #e8d9b8;
}

body.dungeon-entrance-bg .batch-result-highlights,
body.dungeon-interior-bg .batch-result-highlights {
  background: rgba(34, 23, 8, 0.88);
  border-color: rgba(180, 140, 60, 0.45);
  color: #e8d9b8;
}

body.dungeon-entrance-bg .batch-result-highlights-title,
body.dungeon-interior-bg .batch-result-highlights-title {
  color: #e8c870;
}

body.dungeon-entrance-bg .batch-result-highlight,
body.dungeon-interior-bg .batch-result-highlight {
  background: rgba(24, 16, 6, 0.82);
  border-color: rgba(180, 140, 60, 0.42);
  color: #e8d9b8;
}

body.dungeon-entrance-bg .batch-result-highlight-loss,
body.dungeon-interior-bg .batch-result-highlight-loss {
  border-color: rgba(210, 70, 45, 0.70);
  color: #f0a898;
}

body.dungeon-entrance-bg .batch-result-highlight-level,
body.dungeon-interior-bg .batch-result-highlight-level {
  border-color: rgba(220, 170, 70, 0.72);
  color: #f1d27a;
}

body.dungeon-entrance-bg .batch-result-highlight-item,
body.dungeon-interior-bg .batch-result-highlight-item {
  border-color: rgba(90, 180, 140, 0.70);
  color: #9be0c6;
}

body.dungeon-entrance-bg .result-badge-important,
body.dungeon-interior-bg .result-badge-important {
  box-shadow: inset 0 0 0 1px rgba(230, 190, 90, 0.34);
}

body.dungeon-entrance-bg .result-badge-level-up,
body.dungeon-interior-bg .result-badge-level-up {
  border-color: rgba(220, 170, 70, 0.70);
  color: #f1d27a;
}

body.dungeon-entrance-bg .result-badge-item,
body.dungeon-interior-bg .result-badge-item {
  border-color: rgba(90, 180, 140, 0.70);
  color: #9be0c6;
}

/* ========================================
   Town Map: 建物クリック式ナビゲーション
   ======================================== */

.mypage-town-map-panel {
  --town-menu-bg: rgba(16, 22, 34, 0.90);
  --town-menu-bg-hover: rgba(24, 34, 50, 0.94);
  --town-menu-border: rgba(110, 130, 170, 0.62);
  --town-menu-border-hover: rgba(150, 175, 215, 0.82);
  --town-menu-text: #dbe7f6;
  --town-menu-shadow: rgba(0, 0, 0, 0.34);
}

.mypage-town-map-panel .panel-heading {
  background: linear-gradient(180deg, var(--town-heading-from, var(--accent-strong)) 0%, var(--town-heading-to, var(--border-strong)) 100%);
  color: var(--town-heading-text, var(--text));
  border-bottom: 2px solid var(--town-heading-border, var(--border-strong));
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
  letter-spacing: 0.07em;
}

.town-map-wrap {
  position: relative;
  line-height: 0;
  overflow: hidden;
  border-radius: 2px;
}

.town-map-img {
  width: 100%;
  height: auto;
  display: block;
}

.town-spot {
  position: absolute;
  background: transparent;
  border: 2px solid transparent;
  border-radius: 6px;
  text-decoration: none;
  transition: background 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.town-spot:hover {
  background: rgba(120, 160, 220, 0.16);
  border-color: rgba(130, 170, 230, 0.66);
  box-shadow: 0 0 14px rgba(80, 130, 210, 0.28), inset 0 0 6px rgba(160, 190, 240, 0.08);
}

.town-spot-primary:hover {
  background: rgba(100, 180, 255, 0.18);
  border-color: rgba(80, 160, 240, 0.7);
  box-shadow: 0 0 14px rgba(80, 160, 240, 0.3);
}

.town-spot-ready:hover {
  background: rgba(100, 255, 140, 0.18);
  border-color: rgba(60, 220, 100, 0.7);
  box-shadow: 0 0 14px rgba(60, 220, 100, 0.3);
}

.town-spot-label {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 8px 12px;
  background: var(--town-menu-bg);
  color: var(--town-menu-text);
  border-radius: 2px;
  font-size: 0.94rem;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
  white-space: nowrap;
  pointer-events: none;
  opacity: 1;
  border: 1px solid var(--town-menu-border);
  box-shadow:
    inset 0 0 0 1px rgba(210, 225, 255, 0.08),
    inset 0 -2px 0 rgba(0, 0, 0, 0.28),
    0 2px 6px var(--town-menu-shadow);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.60);
  z-index: 10;
}

.town-spot-label-wrap {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0;
  white-space: nowrap;
  z-index: 10;
  pointer-events: none;
}

.town-spot-label-wrap .town-spot-label {
  position: static;
  bottom: auto;
  left: auto;
  transform: none;
  z-index: auto;
}

.town-spot .town-spot-label,
.town-spot-label-wrap {
  pointer-events: auto;
}

.town-spot:hover .town-spot-label {
  background: var(--town-menu-bg-hover);
  border-color: var(--town-menu-border-hover);
  color: #f3f7ff;
}

.town-spot-label-dungeon {
  bottom: auto;
  top: 24%;
  left: auto;
  right: 3%;
  transform: none;
  pointer-events: auto;
  text-decoration: none;
}

.town-spot-label-dungeon:hover {
  background: var(--town-menu-bg-hover);
  border-color: var(--town-menu-border-hover);
  color: #f3f7ff;
  text-decoration: none;
}

.town-spot-label-main {
  min-height: 40px;
  padding: 10px 16px;
  background: linear-gradient(180deg, rgba(28, 38, 54, 0.97) 0%, rgba(15, 22, 34, 0.97) 100%);
  border-width: 2px;
  border-color: rgba(198, 158, 70, 0.78);
  color: #f0e4bd;
  box-shadow:
    inset 0 0 0 1px rgba(220, 235, 255, 0.12),
    inset 0 -3px 0 rgba(0, 0, 0, 0.34),
    0 0 0 2px rgba(10, 16, 26, 0.72),
    0 3px 12px rgba(0, 0, 0, 0.38);
}

.town-spot-label-wrap-quests {
  bottom: auto;
  top: 6%;
  left: 30%;
  transform: translateX(-50%);
}

.town-spot-label-wrap-job-selection {
  bottom: auto;
  top: 23%;
  left: 41%;
  transform: translateX(-50%);
}

.town-spot-label-wrap-skill-training {
  bottom: auto;
  top: -39%;
  left: 50%;
  transform: translateX(-50%);
}

.town-spot-label-wrap-shop {
  bottom: auto;
  top: -16%;
  left: 50%;
  transform: translateX(-50%);
}

.town-spot-label-alchemy {
  pointer-events: none;
}

.town-spot-badge--hidden {
  display: none;
  animation: none;
}

.town-spot-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 999px;
  background: #f59e0b;
  color: #fff;
  font-size: 0.65rem;
  font-weight: bold;
  line-height: 1;
  vertical-align: middle;
  margin-left: 4px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  pointer-events: none;
  animation: town-spot-badge-blink 1.4s ease-in-out infinite;
}

@keyframes town-spot-badge-blink {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.35;
    transform: scale(0.92);
  }
}

/* 街マップ下部サブアクション */
.town-map-sub-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  padding: 10px 12px;
  background: rgba(10, 15, 24, 0.58);
  border-top: 1px solid rgba(110, 130, 170, 0.32);
}

.town-map-sp-primary-actions {
  display: none;
}

.town-sp-primary-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 0;
  min-height: 42px;
  padding: 8px 10px;
  background: var(--town-menu-bg);
  color: var(--town-menu-text);
  border: 1px solid var(--town-menu-border);
  border-radius: 2px;
  text-decoration: none;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  box-shadow:
    inset 0 0 0 1px rgba(210, 225, 255, 0.08),
    inset 0 -2px 0 rgba(0, 0, 0, 0.28),
    0 2px 6px var(--town-menu-shadow);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.55);
}

.town-sp-primary-btn:hover {
  background: var(--town-menu-bg-hover);
  border-color: var(--town-menu-border-hover);
  color: #f3f7ff;
  text-decoration: none;
}

.town-sp-primary-btn-main {
  background: linear-gradient(180deg, rgba(28, 38, 54, 0.97) 0%, rgba(15, 22, 34, 0.97) 100%);
  border-width: 2px;
  border-color: rgba(198, 158, 70, 0.78);
  color: #f0e4bd;
}

.town-sp-primary-icon {
  flex: 0 0 auto;
  font-size: 1.05em;
  line-height: 1;
}

.town-sp-primary-label {
  min-width: 0;
  overflow-wrap: anywhere;
}

.town-sub-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 32px;
  padding: 6px 12px;
  background: color-mix(in srgb, var(--town-menu-bg) 82%, transparent);
  color: var(--town-menu-text);
  border: 1px solid rgba(110, 130, 170, 0.52);
  border-radius: 2px;
  font-size: 0.85rem;
  line-height: 1.15;
  text-decoration: none;
  cursor: pointer;
  text-align: center;
  transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
  white-space: nowrap;
  box-shadow:
    inset 0 0 0 1px rgba(210, 225, 255, 0.06),
    inset 0 -1px 0 rgba(0, 0, 0, 0.24);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.52);
}

.town-sub-btn:hover {
  background: var(--town-menu-bg-hover);
  border-color: var(--town-menu-border-hover);
  color: #f3f7ff;
  text-decoration: none;
}

.town-sub-btn-form {
  font-family: inherit;
  line-height: inherit;
}

.town-sub-btn-admin {
  border-color: rgba(120, 100, 60, 0.35);
  color: #b0a070;
}

.town-sub-icon {
  font-size: 1.1em;
  line-height: 1;
}

/* PC: town map を表示、元のグリッドを非表示 */
.mypage-actions-panel {
  display: none;
}

/* SP: town map ラベルに頼らず、大きめの2列導線を主にする */
@media (max-width: 680px) {
  .mypage-home-page .floating-home-button,
  body.mypage-home-page.interior-page:not(.mobile-exploration-page) .floating-nav-menu {
    display: none;
  }

  .town-map-sp-primary-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 10px 8px 2px;
    background: rgba(10, 15, 24, 0.56);
    border-top: 1px solid rgba(110, 130, 170, 0.32);
  }

  .town-sp-primary-btn-main {
    grid-column: 1 / -1;
  }

  .town-spot-label {
    display: none;
    font-size: 0.75rem;
    padding: 12px 7px;
  }

  .town-spot-label-wrap {
    display: none;
  }

  .town-spot-label-dungeon {
    top: 1%;
    right: 26%;
  }

  .town-spot-quests .town-spot-label-wrap {
    left: 26%;
  }

  .town-spot-label-wrap-shop {
    top: -11%;
    left: 120%;
    transform: translateX(-50%);
  }

  .town-spot-label-wrap-job-selection {
    top: 31%;
    left: 24%;
    transform: translateX(-50%);
  }

  .town-spot-label-wrap-skill-training {
    bottom: auto;
    top: 117%;
    left: 50%;
    transform: translateX(-50%);
  }

  .town-spot-label-alchemy {
    bottom: auto;
    top: 106%;
  }

  .town-map-sub-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
    padding: 8px 8px;
  }

  .town-sub-btn-sp-duplicate {
    display: none;
  }

  .town-sub-btn {
    justify-content: center;
    min-height: 38px;
    font-size: 0.82rem;
    padding: 7px 9px;
  }
}

@media (max-width: 1180px) {
  body.public-home-page {
    --page-padding: 8px 12px 20px;
  }

  .public-lp-hero {
    min-height: 520px;
  }

  .public-lp-hero-top {
    padding: 58px 42px 112px;
  }

  .public-lp-title-card {
    width: min(420px, 48vw);
    min-height: 368px;
    padding: 124px 38px 36px;
  }

  .public-lp-bonus-card {
    width: 210px;
  }

  .public-lp-cta-row {
    left: 320px;
    right: 42px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .public-lp-button {
    min-height: 62px;
    font-size: clamp(1.25rem, 2.1vw, 1.8rem);
  }
}

@media (max-width: 900px) {
  body.public-home-page:not(.mobile-exploration-page) {
    --public-top-bg-y: var(--public-sp-bg-y);
    --public-top-bg-size: auto 760px;
    background:
      linear-gradient(180deg, var(--overlay-from) 0%, var(--overlay-to) 100%),
      url("/assets/site/top/lp/sp/hero-dungeon-gate-bg-16d5e3a1.webp") var(--public-top-bg-x) var(--public-top-bg-y) / var(--public-top-bg-size) no-repeat #05080d !important;
  }

  body.public-home-page {
    overflow-x: hidden;
  }

  body.public-home-page .page {
    padding-inline: 6px;
  }

  body.public-home-page .site-header {
    flex-direction: row;
    align-items: center;
    padding: 8px 12px;
    gap: 10px;
  }

  body.public-home-page .site-header-actions {
    display: flex;
    width: auto;
    gap: 8px;
    min-width: 0;
  }

  body.public-home-page .site-nav {
    width: auto;
    gap: 10px;
    min-width: 0;
  }

  body.public-home-page .site-title a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
  }

  body.public-home-page .site-title a::before {
    content: "";
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    background: url("/assets/site/top/lp/pc/crest-emblem-7014fe92.webp") center / contain no-repeat;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.72));
  }

  .public-lp-shell {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  .public-lp-hero {
    order: 1;
    min-height: 540px;
    border: 1px solid rgba(167, 122, 50, 0.72);
    background: transparent;
  }

  .public-lp-hero-top {
    display: block;
    padding: 36px 18px 0;
  }

  .public-lp-title-card {
    position: relative;
    top: -16px;
    width: min(100%, 430px);
    min-height: 310px;
    margin-inline: auto;
    padding: 98px 38px 34px;
    background:
      url("/assets/site/top/lp/pc/title-card-frame-66a1219d.webp") center center / 100% 100% no-repeat;
    color: #f4ead5;
    text-shadow: none;
  }

  .public-lp-title-card h2 {
    margin-bottom: 10px;
    font-size: clamp(1.95rem, 8vw, 2.35rem);
    overflow-wrap: anywhere;
  }

  .public-lp-lead {
    margin-bottom: 8px;
    color: #f4ead5;
    font-size: clamp(1rem, 4.2vw, 1.2rem);
    text-shadow: none;
  }

  .public-lp-copy {
    max-width: 18rem;
    margin-inline: auto;
    color: #e6dcc7;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1.62;
  }

  .public-lp-bonus-card {
    display: none;
  }

  .public-lp-cta-row {
    left: 22px;
    right: 22px;
    bottom: var(--public-sp-cta-bottom);
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
  }

  .public-lp-cta-row .public-lp-button::after {
    content: none;
  }

  .public-lp-button {
    min-height: 58px;
    padding: 10px 22px;
    font-size: clamp(1.35rem, 6.6vw, 1.95rem);
  }

  .public-lp-features {
    order: 3;
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .public-lp-feature {
    min-height: 0;
  }

  .public-lp-feature-image {
    aspect-ratio: 2.2 / 1;
  }

  .public-lp-stat-strip {
    order: 2;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .public-lp-stat-item {
    min-height: 66px;
    border-bottom: 1px solid rgba(236, 205, 128, 0.24);
  }

  .public-lp-stat-item:nth-child(2n) {
    border-right: 0;
  }
}

@media (max-width: 520px) {
  body.public-home-page .site-title {
    font-size: 1.1rem;
  }

  body.public-home-page .site-title a::before {
    width: 34px;
    height: 34px;
  }

  body.public-home-page .site-nav a {
    display: none;
  }

  body.public-home-page .locale-switch {
    display: block;
  }

  body.public-home-page .locale-switch-select {
    min-width: 108px;
    height: 40px;
  }

  body.public-home-page .site-nav {
    justify-content: flex-end;
  }

  .public-lp-hero {
    min-height: 450px;
  }

  .public-lp-hero-top {
    padding: 24px 14px 0;
  }

  .public-lp-title-card {
    width: min(100%, 340px);
    min-height: 262px;
    padding: 82px 30px 30px;
  }

  .public-lp-title-card h2 {
    margin-bottom: 8px;
    font-size: clamp(1.85rem, 8vw, 2.05rem);
  }

  .public-lp-lead {
    margin-bottom: 6px;
    font-size: clamp(0.92rem, 4.8vw, 1.1rem);
  }

  .public-lp-copy {
    max-width: 15.5rem;
    font-size: clamp(0.72rem, 3.35vw, 0.82rem);
    line-height: 1.54;
  }

  .public-lp-cta-row {
    left: 22px;
    right: 22px;
  }

  .public-lp-button {
    min-height: 58px;
    padding-inline: 18px;
    font-size: clamp(0.9rem, 4vw, 1.08rem);
  }

  .public-lp-feature {
    grid-template-columns: minmax(0, 0.43fr) minmax(0, 1fr);
    gap: 10px 14px;
    min-height: 130px;
    padding: 10px;
  }

  .public-lp-feature-heading {
    grid-column: 2;
    gap: 9px;
    align-self: end;
  }

  .public-lp-feature-icon {
    width: 2rem;
    height: 2rem;
    font-size: 0.78rem;
  }

  .public-lp-feature h3 {
    font-size: clamp(1.3rem, 6vw, 1.65rem);
  }

  .public-lp-feature-picture {
    grid-column: 1;
    grid-row: 1 / span 2;
    height: 100%;
    min-height: 112px;
  }

  .public-lp-feature-image {
    height: 100%;
    min-height: 112px;
    aspect-ratio: auto;
  }

  .public-lp-feature p {
    grid-column: 2;
    align-self: start;
    padding-right: 22px;
    font-size: clamp(0.82rem, 3.8vw, 0.98rem);
    line-height: 1.58;
  }

  .public-lp-stat-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    min-height: 118px;
  }

  .public-lp-stat-item {
    min-height: 58px;
    padding: 8px 10px;
    border-right: 0;
    border-bottom: 1px solid rgba(236, 205, 128, 0.20);
    text-align: center;
  }

  .public-lp-stat-item:nth-child(4) {
    grid-column: span 2;
  }

  .public-lp-stat-item:nth-last-child(-n + 2) {
    border-bottom: 0;
  }

  .public-lp-stat-label {
    font-size: 0.68rem;
    line-height: 1.25;
  }

  .public-lp-stat-item strong {
    font-size: clamp(1.1rem, 4.7vw, 1.42rem);
    line-height: 1.15;
    white-space: normal;
  }

  .public-lp-stat-arrow {
    display: none;
  }
}

@media (max-width: 900px) {
  body.public-auth-page {
    --page-padding: 0 0 24px;
    --public-auth-sp-bg-y: 0px;
    overflow-x: hidden;
    background:
      linear-gradient(180deg, rgba(4, 8, 12, 0.04) 0%, rgba(4, 8, 12, 0.20) 46%, rgba(4, 8, 12, 0.88) 100%),
      url("/assets/site/top/lp/sp/hero-dungeon-gate-bg-16d5e3a1.webp") center var(--public-auth-sp-bg-y) / auto 760px no-repeat #05080d !important;
  }

  body.public-auth-page .page {
    width: 100%;
  }

  body.public-auth-page .site-header {
    flex-direction: row;
    align-items: center;
    margin: 0;
    min-height: 82px;
    padding: 10px 16px;
    border-inline: 0;
    border-top: 0;
  }

  body.public-auth-page .site-header-actions {
    display: flex;
    width: auto;
    min-width: 0;
    align-items: center;
    gap: 12px;
  }

  body.public-auth-page .site-header-actions::after {
    content: "≡";
    display: inline-grid;
    place-items: center;
    width: 54px;
    height: 48px;
    border: 1px solid rgba(238, 203, 128, 0.66);
    background: rgba(5, 10, 16, 0.86);
    color: #f7ead0;
    font-size: 2rem;
    line-height: 1;
    box-shadow: inset 0 0 0 1px rgba(238, 203, 128, 0.10);
  }

  body.public-auth-page .site-title {
    font-size: clamp(1.35rem, 6vw, 2.35rem);
  }

  body.public-auth-page .site-title a {
    gap: 8px;
  }

  body.public-auth-page .site-title a::before {
    width: 42px;
    height: 42px;
  }

  body.public-auth-page .site-nav {
    width: auto;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 0;
  }

  body.public-auth-page .site-nav a {
    display: none;
  }

  body.public-auth-page .locale-switch {
    display: block;
  }

  body.public-auth-page .locale-switch-select {
    min-width: 118px;
    height: 48px;
    font-size: 1rem;
  }

  body.public-auth-page .page-body {
    min-height: calc(100vh - 82px);
  }

  body.public-auth-page .auth-shell {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 82px);
    padding: 44px 28px 28px;
  }

  body.public-auth-page .auth-hero {
    display: none;
  }

  body.public-auth-page .auth-hero h1 {
    font-size: clamp(3.35rem, 11vw, 4.6rem);
  }

  body.public-auth-page .auth-hero-lead {
    margin-top: 16px;
    font-size: clamp(1.35rem, 5.3vw, 1.85rem);
  }

  body.public-auth-page .auth-hero-copy {
    margin-top: 14px;
    font-size: clamp(1rem, 3.8vw, 1.32rem);
    line-height: 1.72;
  }

  body.public-auth-page .auth-panel {
    order: 2;
    width: 100%;
    padding: 22px 24px;
  }

  body.public-auth-page .auth-heading h2 {
    font-size: clamp(2rem, 7.2vw, 2.6rem);
    text-align: center;
  }

  body.public-auth-page .auth-heading p,
  body.public-auth-page .auth-kicker {
    text-align: center;
  }

  body.public-auth-page .auth-field label,
  body.public-auth-page .auth-check {
    font-size: 1rem;
  }

  body.public-auth-page .auth-input {
    min-height: 58px;
    font-size: 1.15rem;
  }

  body.public-auth-page .auth-submit {
    min-height: 76px;
    font-size: clamp(1.6rem, 7vw, 2.15rem);
  }
}

@media (max-width: 520px) {
  body.public-auth-page {
    background-size: auto 650px !important;
  }

  body.public-auth-page .site-header {
    min-height: 66px;
    padding: 8px 12px;
  }

  body.public-auth-page .site-title {
    font-size: 1.08rem;
  }

  body.public-auth-page .site-title a::before {
    width: 34px;
    height: 34px;
  }

  body.public-auth-page .locale-switch-select {
    min-width: 108px;
    height: 40px;
  }

  body.public-auth-page .site-header-actions::after {
    width: 42px;
    height: 40px;
    font-size: 1.7rem;
  }

  body.public-auth-page .auth-shell {
    min-height: calc(100vh - 66px);
    padding: 36px 14px 22px;
  }

  body.public-auth-page .auth-hero h1 {
    font-size: clamp(2.75rem, 11vw, 3.55rem);
  }

  body.public-auth-page .auth-hero-lead {
    font-size: clamp(1.18rem, 5.2vw, 1.5rem);
  }

  body.public-auth-page .auth-hero-copy {
    font-size: clamp(0.9rem, 3.7vw, 1.05rem);
  }

  body.public-auth-page .auth-panel {
    padding: 18px;
  }

  body.public-auth-page .auth-heading h2 {
    font-size: clamp(1.8rem, 8vw, 2.2rem);
  }

  body.public-auth-page .auth-submit {
    min-height: 64px;
    padding-inline: 18px 42px;
    font-size: clamp(1.28rem, 6vw, 1.65rem);
  }
}

body.public-auth-page.interior-page .site-header {
  display: flex;
}
