:root {
  --ink: #30393b;
  --muted: #707b7c;
  --coral: #ef6555;
  --paper: #fffcf7;
  --line: #eae6de;
  --yellow: #f8cf65;
  --mint: #d7ece3;
  --lavender: #e5dff3;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font:
    15px/1.8 ui-rounded,
    "Hiragino Maru Gothic ProN",
    "Noto Sans JP",
    system-ui,
    sans-serif;
}
a {
  color: inherit;
  text-decoration: none;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #357c75;
  outline-offset: 4px;
}
header {
  height: 100px;
  max-width: 1440px;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6%;
  gap: 25px;
}
.brand {
  display: flex;
  gap: 9px;
  align-items: center;
  font-size: 31px;
  color: var(--coral);
  font-weight: 900;
  letter-spacing: 0.07em;
  line-height: 1.15;
}
.brand span {
  display: block;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-top: 10px;
}
nav.main-navigation {
  display: flex;
  gap: 32px;
  font-weight: 700;
}
nav.main-navigation a {
  padding: 10px 0;
  position: relative;
}
nav.main-navigation a.active {
  color: var(--coral);
}
nav.main-navigation a.active:after {
  content: "";
  position: absolute;
  bottom: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--coral);
  left: 50%;
}
.saved {
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 8px 20px;
  font-size: 13px;
  background: white;
}
main {
  max-width: 1260px;
  padding: 28px 40px 70px;
  margin: auto;
  min-height: 65vh;
}
.hero {
  background: #f6e9d7;
  border-radius: 30px;
  min-height: 390px;
  padding: 45px 55px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  align-items: center;
  position: relative;
  overflow: hidden;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 0.15em;
  font-weight: 800;
  color: #a47f54;
}
.hero h1 {
  font-size: clamp(34px, 4.2vw, 55px);
  line-height: 1.5;
  letter-spacing: 0.04em;
  margin: 15px 0;
}
.hero h1 em {
  font-style: normal;
  color: var(--coral);
}
.hero p {
  color: #79746b;
  font-size: 14px;
}
.hero-art {
  height: 300px;
  position: relative;
  display: grid;
  place-items: center;
}
.hero-art:before {
  content: "";
  position: absolute;
  width: 250px;
  height: 250px;
  border: 1px dashed #c9bca5;
  border-radius: 50%;
}
.hero-art .mascot {
  width: 220px;
  z-index: 1;
  transform: rotate(-8deg);
}
.bubble {
  position: absolute;
  background: white;
  border-radius: 20px;
  padding: 8px 18px;
  z-index: 2;
  font-size: 12px;
  font-weight: 800;
}
.bubble.first {
  top: 15px;
  right: 0;
  transform: rotate(8deg);
}
.bubble.second {
  bottom: 20px;
  left: 0;
  transform: rotate(-7deg);
}
.torii {
  position: absolute;
  font-size: 95px;
  right: -5px;
  bottom: 0;
  opacity: 0.7;
}
.search {
  display: flex;
  gap: 8px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 8px;
  max-width: 780px;
  margin: 24px auto;
}
.search input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: none;
  padding: 10px 15px;
  outline-offset: 0;
}
.primary {
  background: var(--coral);
  color: white;
  border: 0;
  border-radius: 10px;
  padding: 10px 23px;
  font-weight: 700;
}
.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 15px;
  margin: 35px 0 18px;
}
.section-head h2 {
  font-size: 23px;
  margin: 0;
}
.section-head small,
.muted {
  color: var(--muted);
  font-size: 12px;
}
.section-head a {
  font-size: 12px;
  color: var(--muted);
}
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.entry {
  border-radius: 20px;
  padding: 26px 25px;
  display: flex;
  align-items: center;
  gap: 18px;
  transition: transform 0.2s;
}
.entry:hover,
.card:hover {
  transform: translateY(-4px);
}
.entry:nth-child(1) {
  background: #f9ded4;
}
.entry:nth-child(2) {
  background: var(--mint);
}
.entry:nth-child(3) {
  background: var(--lavender);
}
.entry .icon {
  font-size: 36px;
}
.entry h3 {
  font-size: 19px;
  margin: 0;
}
.entry small {
  font-size: 11px;
}
.entry b {
  margin-left: auto;
}
.card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  transition: transform 0.2s;
  position: relative;
}
.card-body {
  padding: 21px;
}
.card h3 {
  font-size: 18px;
  margin: 5px 0;
}
.card p {
  font-size: 12px;
  color: var(--muted);
  margin: 7px 0;
}
.card-art {
  height: 150px;
  background: #f7e9cf;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.card-art .mascot {
  width: 125px;
  height: 130px;
}
.card:nth-child(3n + 2) .card-art {
  background: #dcebe4;
}
.card:nth-child(3n + 3) .card-art {
  background: #e6e2ef;
}
.card-art.shrine {
  font-size: 75px;
  background: linear-gradient(150deg, #e0ebe0, #eaf2e5);
}
.tag {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 8px;
  background: #f6f3ed;
  font-size: 10px;
  color: #85725b;
}
.card .heart,
.shrine-header-photo>.shrine-like-icon,
.map-favorite-action>.shrine-like-icon {
  position: absolute;
  right: 12px;
  top: 12px;
  background: #fffc;
  border: 0;
  border-radius: 50%;
  font-size: 21px;
  width: 38px;
  height: 38px;
  line-height: 38px;
  color: var(--coral);
  z-index: 2;
}
.page-head {
  padding: 20px 0;
}
.page-head h1 {
  font-size: 34px;
  margin: 5px 0;
}
.page-head p {
  color: var(--muted);
  font-size: 14px;
}
.filters {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 15px 0 25px;
}
.filters select {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: white;
  padding: 10px;
  max-width: 100%;
}
.list-search {
  margin: 0;
  max-width: none;
}
.notice {
  background: #f3eee5;
  padding: 13px 18px;
  border-radius: 10px;
  color: #7d7466;
  font-size: 12px;
  margin: 18px 0;
}
.empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--muted);
}
.detail-hero {
  display: flex;
  gap: 30px;
  align-items: center;
  background: #f6e9d7;
  padding: 35px;
  border-radius: 24px;
  margin: 20px 0;
}
.detail-hero .mascot {
  width: 140px;
  flex-shrink: 0;
}
.detail-hero h1 {
  font-size: 32px;
  margin: 5px 0;
}
.detail-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 24px;
}
.panel {
  border: 1px solid var(--line);
  background: white;
  border-radius: 18px;
  padding: 25px;
  margin-bottom: 20px;
}
.panel h2 {
  font-size: 19px;
  margin-top: 0;
}
.panel p {
  font-size: 14px;
}
.link-row {
  display: flex;
  justify-content: space-between;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  gap: 10px;
}
.source {
  display: block;
  border-bottom: 1px solid var(--line);
  padding: 15px 0;
  overflow-wrap: anywhere;
}
.source strong {
  font-size: 14px;
  color: #487e6d;
}
.source small {
  display: block;
  color: var(--muted);
  font-size: 11px;
}
.back {
  font-size: 12px;
  color: var(--muted);
}
.pill-button,
.secondary {
  border: 1px solid var(--line);
  background: white;
  border-radius: 10px;
  padding: 8px 16px;
}
.selected {
  background: var(--ink);
  color: white;
}
.story {
  font-size: 17px !important;
  line-height: 2.2;
}
.story-no {
  font-size: 50px;
  color: #b69b7d;
}
.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin: 30px;
}
.graph-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: white;
  touch-action: pan-x pan-y;
}
.graph {
  display: block;
  min-width: 700px;
  width: 100%;
  height: 450px;
}
.graph text {
  font-size: 13px;
  fill: var(--ink);
}
.graph path {
  stroke: #b8c6bb;
  stroke-width: 2;
  fill: none;
}
.graph a rect {
  fill: #f6ead1;
  stroke: #e0d3bd;
}
.graph a:hover rect {
  fill: #f8cf65;
}
.admin-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 25px;
}
.admin-menu select {
  width: 100%;
  padding: 12px;
}
.admin-list {
  max-height: 400px;
  overflow: auto;
}
.admin-list button {
  display: block;
  width: 100%;
  text-align: left;
  background: white;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 10px;
  overflow-wrap: anywhere;
}
.admin-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  font-size: 12px;
}
.field input,
.field textarea,
.field select {
  width: 100%;
  border: 1px solid #d8ded7;
  border-radius: 8px;
  padding: 9px;
  background: white;
}
.field textarea {
  min-height: 80px;
}
.span-all {
  grid-column: 1/-1;
}
.errors {
  color: #b34039;
}
.login {
  max-width: 440px;
  margin: 60px auto;
}
.login input {
  width: 100%;
  padding: 12px;
  margin: 15px 0;
  border: 1px solid var(--line);
}
footer {
  border-top: 1px solid var(--line);
  max-width: 1180px;
  margin: auto;
  padding: 35px 40px;
  display: flex;
  gap: 20px;
  align-items: center;
  flex-wrap: wrap;
}
footer .brand {
  font-size: 25px;
}
footer p,
footer > a:last-child {
  font-size: 12px;
  color: var(--muted);
}
footer small {
  font-size: 10px;
  color: var(--muted);
  margin-left: auto;
}
#toast {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: white;
  padding: 10px 25px;
  border-radius: 25px;
  display: none;
  z-index: 50;
  white-space: nowrap;
}
#toast.show {
  display: block;
}
.mascot {
  overflow: visible;
}
.results-heading {
  font-size: 20px;
  margin: 30px 0 15px;
}
.toolbar {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin: 20px 0;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
.count {
  font-weight: 700;
  color: var(--coral);
}
@media (max-width: 760px) {
  header {
    height: 85px;
    padding: 0 20px;
  }
  .brand {
    font-size: 26px;
  }
  .saved {
    font-size: 12px;
    padding: 7px 12px;
  }
  nav.main-navigation {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 66px;
    background: #fffef9f5;
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--line);
    justify-content: space-around;
    gap: 0;
    align-items: center;
    z-index: 30;
    font-size: 12px;
  }
  nav.main-navigation a {
    padding: 15px 8px;
  }
  main {
    padding: 15px 18px 45px;
  }
  .hero {
    padding: 28px 25px;
    grid-template-columns: 1fr;
    min-height: 0;
  }
  .hero h1 {
    font-size: 35px;
  }
  .hero p {
    max-width: 230px;
  }
  .hero-art {
    height: 160px;
    position: absolute;
    right: -48px;
    bottom: 10px;
    width: 200px;
    opacity: 0.75;
  }
  .hero-art .mascot {
    width: 135px;
  }
  .hero-art:before {
    width: 150px;
    height: 150px;
  }
  .bubble,
  .torii {
    display: none;
  }
  .hero-copy {
    z-index: 2;
  }
  .hero .eyebrow {
    font-size: 9px;
  }
  .search {
    margin: 18px 0;
  }
  .search input {
    font-size: 13px;
    padding: 8px;
  }
  .primary {
    padding: 10px 15px;
    font-size: 13px;
  }
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .entry-grid {
    grid-template-columns: 1fr;
  }
  .entry {
    padding: 20px;
  }
  .card-body {
    padding: 15px;
  }
  .card h3 {
    font-size: 15px;
  }
  .card-art {
    height: 125px;
  }
  .card p {
    font-size: 11px;
  }
  .section-head h2 {
    font-size: 20px;
  }
  .section-head small {
    font-size: 10px;
  }
  .detail-grid,
  .admin-layout {
    grid-template-columns: 1fr;
  }
  .detail-hero {
    padding: 23px;
    gap: 15px;
  }
  .detail-hero h1 {
    font-size: 23px;
  }
  .detail-hero .mascot {
    width: 85px;
  }
  .detail-hero .primary {
    font-size: 11px;
  }
  .page-head h1 {
    font-size: 28px;
  }
  .panel {
    padding: 20px;
  }
  .admin-form {
    grid-template-columns: 1fr;
  }
  .admin-list {
    max-height: 160px;
  }
  footer {
    padding: 25px 20px 95px;
    gap: 12px;
  }
  footer small {
    margin: 0;
  }
  #toast {
    bottom: 80px;
  }
  .story-grid {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* Interactive shrine map */
#app.map-page {
  max-width: 1500px;
  padding: 24px 28px;
}
.map-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.map-heading h1 {
  font-size: clamp(20px, 2.4vw, 30px);
  margin: 5px 0;
}
.map-shell {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  height: 72vh;
  min-height: 570px;
  border: 1px solid #eaded5;
  border-radius: 24px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 12px 36px #6b493414;
}
.map-sidebar {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 18px;
  gap: 12px;
  z-index: 2;
  box-shadow: 4px 0 15px #503b1910;
}
.map-search {
  display: flex;
  border: 1px solid #dddad5;
  border-radius: 14px;
  overflow: hidden;
  background: #faf8f4;
  flex-shrink: 0;
}
.map-search input {
  min-width: 0;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 13px;
  font: inherit;
}
.map-search button {
  border: 0;
  background: transparent;
  padding: 8px 15px;
  font-size: 26px;
  color: #ad4c40;
}
.map-filter {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.map-filter button {
  font: inherit;
  font-size: 12px;
  background: #fff;
  border: 1px solid #e7e1dc;
  padding: 8px;
  border-radius: 10px;
  cursor: pointer;
}
.map-filter button.active {
  background: #fff0e7;
  border-color: #ed8b65;
  color: #9b3b28;
}
.map-filter small {
  font-size: 10px;
  opacity: 0.75;
}
.map-sync,
.map-result-count {
  font-size: 11px;
  line-height: 1.6;
  margin: 0;
  color: #777;
}
.map-sync a {
  color: #9b3b28;
}
.map-list {
  overflow: auto;
  flex: 1;
  min-height: 0;
}
.map-list-item {
  display: flex;
  align-items: center;
  gap: 9px;
  text-align: left;
  width: 100%;
  border: 0;
  border-bottom: 1px solid #eee8e2;
  background: #fff;
  padding: 14px 4px;
  cursor: pointer;
  color: #34373a;
}
.map-list-item:hover,
.map-list-item.chosen {
  background: #fff5ee;
}
.map-list-item strong {
  font-size: 13px;
  display: block;
}
.map-list-item small {
  display: block;
  font-size: 10px;
  line-height: 1.5;
  color: #84817b;
  margin-top: 3px;
}
.map-list-symbol {
  font-size: 22px;
  flex-shrink: 0;
}
.visit-label {
  font-size: 10px;
  white-space: nowrap;
  margin-left: auto;
}
.unvisited {
  color: #647e9a;
}
.visited {
  color: #197c5b;
}
.want {
  color: #dc6547;
}
.map-source {
  font-size: 10px;
  color: #85817a;
  line-height: 1.65;
  border-top: 1px solid #eee;
  padding-top: 10px;
}
.map-source a {
  text-decoration: underline;
}
.map-more {
  font-size: 11px;
  text-align: center;
  color: #777;
}
.map-stage {
  position: relative;
  min-width: 0;
  background: #e5ece8;
}
#shrine-map {
  height: 100%;
  width: 100%;
  z-index: 0;
  font-family: inherit;
}
.map-key {
  position: absolute;
  top: 16px;
  left: 16px;
  display: flex;
  gap: 14px;
  background: #fffef8f5;
  padding: 10px 15px;
  border-radius: 12px;
  box-shadow: 0 3px 14px #3332;
  font-size: 12px;
  pointer-events: none;
  z-index: 1;
}
.map-cluster-icon span {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff9ec;
  border: 5px solid #eea888;
  border-radius: 50%;
  font-size: 12px;
  font-weight: bold;
  color: #8c4b39;
  box-shadow: 0 3px 9px #3332;
}
.map-pin {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 34px;
  border-radius: 50% 50% 50% 3px;
  transform: rotate(-15deg);
  background: #647e9a;
  color: white;
  border: 2px solid white;
  font-size: 19px;
  font-weight: bold;
  box-shadow: 0 3px 8px #3335;
}
.map-pin.visited {
  background: #218466;
  color: white;
}
.map-pin.want {
  background: #e27653;
  color: white;
}
.map-pin.chosen {
  outline: 3px solid #f6cb67;
}
.map-detail {
  position: absolute;
  bottom: 30px;
  right: 18px;
  width: min(390px, calc(100% - 36px));
  max-height: 65%;
  overflow: auto;
  z-index: 2;
  background: #fffefa;
  border: 1px solid #eee0d3;
  border-radius: 20px;
  padding: 20px;
  box-shadow: 0 8px 35px #3333;
}
.map-detail h2 {
  font-size: 21px;
  margin: 10px 24px 8px 0;
}
.map-detail p {
  font-size: 12px;
  line-height: 1.7;
  margin: 7px 0;
}
.map-detail small {
  font-size: 10px;
  display: block;
  line-height: 1.5;
}
.map-status-buttons {
  display: flex;
  gap: 6px;
  margin: 16px 0 8px;
}
.map-status-buttons button {
  flex: 1;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 11px 3px;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.map-status-buttons button.selected {
  background: #fff0dc;
  border-color: #dd9861;
  font-weight: bold;
}
.map-status-buttons button:disabled {
  opacity: 0.5;
  cursor: wait;
}
.map-detail-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 11px;
  margin: 12px 0;
  color: #92503b;
}
.map-detail-links a {
  text-decoration: underline;
}
.map-banner {
  position: absolute;
  left: 15px;
  right: 55px;
  top: 65px;
  background: #fff4d4;
  padding: 10px;
  border-radius: 10px;
  font-size: 12px;
  z-index: 2;
}
.leaflet-control-attribution {
  font-size: 10px !important;
}
@media (max-width: 760px) {
  #app.map-page {
    padding: 16px 12px;
  }
  .map-heading {
    gap: 7px;
    margin-bottom: 12px;
  }
  .map-heading h1 {
    font-size: 18px;
  }
  .map-heading .secondary {
    font-size: 11px;
    padding: 9px;
    white-space: nowrap;
  }
  .map-heading .eyebrow {
    font-size: 9px;
  }
  .map-shell {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 0;
    border-radius: 18px;
    overflow: visible;
  }
  .map-sidebar {
    display: contents;
  }
  .map-search {
    margin: 12px 12px 0;
    order: 0;
  }
  .map-filter {
    order: 1;
    grid-template-columns: repeat(4, 1fr);
    padding: 8px 12px;
  }
  .map-filter button {
    font-size: 10px;
    padding: 7px 2px;
  }
  .map-filter small {
    display: block;
  }
  .map-sync {
    order: 2;
    padding: 0 12px 10px;
  }
  .map-stage {
    order: 3;
    height: 58vh;
    min-height: 380px;
  }
  .map-key {
    font-size: 10px;
    gap: 10px;
    top: 10px;
    left: 10px;
    padding: 8px;
  }
  .map-result-count {
    order: 4;
    padding: 12px 14px 0;
  }
  .map-list {
    order: 5;
    max-height: 270px;
    padding: 0 14px;
  }
  .map-source {
    order: 6;
    margin: 10px 14px;
  }
  .map-detail {
    bottom: 24px;
    right: 10px;
    width: calc(100% - 20px);
    padding: 15px;
    max-height: 70%;
  }
  nav.main-navigation a {
    font-size: 11px;
    padding: 10px 5px;
  }
}

/* Edge-to-edge map workspace with a neutral gray palette. */
body.map-layout { background:#f3f3f3; }
body.map-layout footer {display:none}
#app.map-page {max-width:none;width:100%;padding:0;margin:0}
.map-page > div {height:calc(100dvh - 100px);display:flex;flex-direction:column}
.map-heading {padding:12px 24px;margin:0;flex-shrink:0;background:#fafafa}
.map-heading h1 {font-size:20px}.map-heading .eyebrow {color:#777;font-size:9px}
.map-shell {flex:1;min-height:0;height:auto;border-radius:0;border:0;box-shadow:none;grid-template-columns:310px minmax(0,1fr)}
.map-stage {background:#e5e5e5}
#shrine-map .leaflet-tile-pane {filter:grayscale(1)}
.map-search {background:#f5f5f5;border-color:#ddd}.map-search button,.map-sync a {color:#555}
.map-filter button.active {background:#e6e6e6;border-color:#777;color:#333}
.map-list-item:hover,.map-list-item.chosen {background:#efefef}
.map-cluster-icon span {background:#fafafa;border-color:#aaa;color:#333}
.map-pin {background:#b1b1b1;color:#222;border-color:#fff}
.map-pin.visited {background:#454545;color:white}.map-pin.want {background:#f8f8f8;color:#222;border-color:#555}.map-pin.chosen {outline-color:#333}
.map-key,.map-detail {background:#fffffff5;border-color:#ddd}
.map-status-buttons button.selected {background:#e5e5e5;border-color:#555}
.map-page .unvisited,.map-page .visited,.map-page .want,.map-detail-links {color:#555}
.map-page .map-pin.visited {color:white}.map-page .map-pin.want {color:#222}
.map-deity-label {font-size:12px;display:flex;flex-direction:column;gap:6px;color:#555}
.map-deity-label select {font:inherit;padding:10px;border:1px solid #ccc;border-radius:10px;background:#fafafa;max-width:100%}
.map-deity-note {font-size:10px;line-height:1.5;color:#888;margin:0}
@media(max-width:760px){
 .map-page > div {height:calc(100dvh - 140px);min-height:500px}
 .map-heading {padding:10px 12px}.map-heading h1 {font-size:15px}.map-heading .eyebrow {display:none}
 .map-shell {display:flex;flex-direction:column;overflow:hidden;min-height:0}
 .map-search {margin:8px 10px 0}.map-filter {padding:6px 10px}.map-sync {padding:0 10px 6px}
 .map-deity-label {order:2;padding:0 10px;flex-direction:row;align-items:center;font-size:11px;gap:8px}.map-deity-label select {flex:1;min-width:0;padding:7px}
 .map-deity-note {order:2;padding:3px 10px;font-size:9px}.map-stage {flex:1;height:auto;min-height:180px}
 .map-list,.map-result-count,.map-source {display:none}.map-sidebar {display:contents}
 .map-detail {max-height:85%;bottom:25px}
}
@media(max-width:760px){.map-source {display:block;order:6;max-height:38px;overflow:auto;margin:3px 10px;font-size:8px;flex-shrink:0}}
.card .wish-button {margin:0 18px 18px;width:calc(100% - 36px)}
.wish-button[aria-pressed="true"] {background:#fff0e7;border-color:#d98066;color:#984c38}
.saved-tabs {display:flex;gap:8px;flex-wrap:wrap;margin:20px 0}.saved-tabs .active {background:#fa6657;color:#fff;border-color:#fa6657}
.detail-hero .wish-button {margin-left:8px}.link-row {gap:12px;flex-wrap:wrap}

/* Warm map palette aligned with the site's paper, coral and mint colors. */
body.map-layout {background:var(--paper)}
.map-heading {background:var(--paper)}
.map-heading .eyebrow {color:#9c8976}
.map-stage {background:#cfe4e2}
#shrine-map .leaflet-tile-pane {filter:grayscale(.35) sepia(.14)}
.map-search {background:#faf6ef;border-color:var(--line)}
.map-search button,.map-sync a {color:#ab6050}
.map-filter button.active {background:#fff0e6;border-color:#db9b80;color:#92503d}
.map-list-item:hover,.map-list-item.chosen {background:#fff4e9}
.map-cluster-icon span {background:#fffaf0;border-color:#e5a88b;color:#88523d}
.map-pin {background:#a48f7a;color:white;border-color:#fffcf7}
.map-pin.visited {background:#43866f;color:white}
.map-pin.want {background:#ed8065;color:white;border-color:#fffcf7}
.map-pin.chosen {outline-color:#f2c55f}
.map-key,.map-detail {background:#fffcf7f5;border-color:#e8ddcd}
.map-status-buttons button.selected {background:#fff0dd;border-color:#d59a6b}
.map-page .unvisited {color:#9a826d}.map-page .visited {color:#397d65}.map-page .want {color:#ce684d}
.map-page .map-pin,.map-page .map-pin.visited,.map-page .map-pin.want {color:white}
.map-detail-links {color:#a75f49}
.map-deity-label select {background:#fffcf7;border-color:#ded5c9}

/* Open, paper-colored pages and an account destination. */
.hero {background:transparent;border-radius:0;padding:35px 15px;min-height:420px;overflow:visible}
.hero-art:before {display:none}
.hero-crowd {height:370px;display:grid;grid-template-columns:repeat(3,1fr);gap:0;align-content:center}
.hero-crowd .hero-character {position:relative;display:flex;align-items:center;justify-content:center}
.hero-crowd .mascot {width:150px;max-width:100%;transform:none}
.hero-crowd .hero-character:nth-child(2n) {transform:translateY(20px) rotate(5deg)}
.hero-crowd .hero-character:nth-child(3n+1) {transform:rotate(-6deg)}
.detail-hero {background:transparent;padding:24px 0;margin-bottom:32px}
.detail-grid {gap:48px}
.detail-grid .panel {background:transparent;border:0;border-radius:0;padding:0;margin-bottom:36px}
.detail-grid .panel h2 {margin:0 0 14px}.detail-grid .panel p {line-height:2;margin:10px 0}
.detail-grid .source,.detail-grid .link-row {border:0;padding:12px 0}
.detail-grid .notice {background:#f5efe5;border:0}
.wish-button,.wish-button[aria-pressed="true"] {background:#eae0d1;color:#705d47;border:0}
.wish-button:hover {background:#dfd0bc}.wish-button[aria-pressed="true"] {background:#d9c8ad}
.account-nav-icon {width:24px;height:24px;display:block}
.account-profile {display:flex;align-items:center;gap:24px;padding:25px 0 40px}
.account-profile h2 {margin:0}.account-profile p {color:var(--muted)}
.account-avatar {display:grid;place-items:center;width:82px;height:82px;border-radius:50%;background:#eee4d5;flex-shrink:0}
.account-avatar svg {width:40px;height:40px}
.account-shortcuts {display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin:0 0 45px}
.account-shortcuts a {background:#f3eadc;border-radius:18px;padding:20px;color:#705b47}
.account-shortcuts strong {font-size:30px;display:block}
#app[aria-busy="true"] {cursor:progress}
body:before {content:"";position:fixed;top:0;left:0;width:0;height:3px;background:var(--coral);z-index:2000;opacity:0}
body.route-loading:before {width:80%;opacity:1;transition:width 8s cubic-bezier(.1,.8,.2,1)}
.initial-shell {display:grid;gap:20px;padding:50px 0}
.initial-shell div {height:80px;background:#f2eadf;border-radius:16px;animation:soft-pulse 1.2s ease-in-out infinite alternate}
.initial-shell div:first-child {height:220px}
@keyframes soft-pulse {to{opacity:.5}}
@media(prefers-reduced-motion:reduce){.initial-shell div {animation:none}}
@media(max-width:760px){.hero {padding:15px 0;min-height:0}.hero-crowd {height:auto;min-height:260px;margin:0;grid-template-columns:repeat(3,1fr)}.hero-crowd .mascot {width:110px}.hero-copy {grid-row:auto}.detail-grid {gap:24px}.detail-hero {padding:16px 0}.account-shortcuts {gap:7px}.account-shortcuts a {padding:12px;font-size:11px}.account-profile {gap:15px}.account-profile h2 {font-size:19px}}
.spirit-character {overflow:visible;filter:none}.hero-crowd .spirit-character {width:165px}
.card-art:has(.spirit-character) {background:transparent}
.character-note {color:#978b7c;font-size:11px;line-height:1.8;margin:0 0 24px}
.map-filter-total {font-size:13px;color:#785b42;background:#f7efe4;padding:7px 10px;border-radius:9px;margin:0;flex-shrink:0}
.map-deity-source {display:block;font-size:11px;color:#9b6651;margin:7px 0;text-decoration:underline}
@media(max-width:760px){.map-filter-total {order:2;margin:3px 10px;font-size:11px;padding:5px 9px}.hero-crowd .spirit-character {width:110px}}

/* Account collection: stationary global nav and attached paper-colored tabs. */
.account-heading {display:flex;justify-content:space-between;align-items:center;gap:20px;margin:24px 0 38px}
.account-heading h1 {font-size:32px;line-height:1.4;margin:0}
.account-name {font-size:13px;color:var(--muted);display:block;margin-top:8px}
.account-login {display:flex;align-items:center;gap:8px;font-size:12px;color:#796d5e;padding:10px 0}
.account-login svg {width:21px;height:21px}
.saved-collection {margin:0 0 48px}
.collection-tabs {display:flex;align-items:flex-end;gap:5px;border-bottom:1px solid #dfd1bd;padding:0 0 0 8px}
.collection-tab {display:block;flex:0 1 200px;text-align:center;padding:17px 12px 15px;border-radius:14px 14px 0 0;background:#eae0d1;color:#8c7963;font-size:14px;font-weight:700;position:relative;top:1px;border:1px solid transparent;border-bottom:1px solid #dfd1bd;transition:background .15s,color .15s}
.collection-tab:hover {background:#e4d5c0;color:#705b43}
.collection-tab.selected {background:var(--paper);color:#a85d43;border-color:#dfd1bd;border-bottom-color:var(--paper);padding-top:21px}
.collection-content {background:transparent;min-height:280px;padding:32px 8px 20px}
.saved-empty {text-align:center;color:#9b8c7a;font-size:13px;padding:72px 15px;margin:0}
.saved-login {font-size:12px;color:#a16b4e;margin:0 0 20px}
.saved-deity-grid {display:grid;grid-template-columns:repeat(auto-fill,minmax(145px,1fr));gap:28px 24px;padding:12px 0}
.saved-deity {text-align:center;min-width:0}.saved-deity a {display:block}
.saved-deity .mascot {width:140px;max-width:100%;height:auto;margin:0 auto 10px;display:block}
.saved-deity h2 {font-size:14px;line-height:1.6;margin:0 0 6px;font-weight:700}
.saved-remove {border:0;background:transparent;padding:5px 0;color:#ab9986;font-size:11px;white-space:nowrap;cursor:pointer}
.saved-remove:hover {color:var(--coral)}
.saved-shrine-list {list-style:none;padding:0;margin:0}
.saved-shrine-list li {display:flex;align-items:center;justify-content:space-between;gap:20px;padding:21px 4px;border-bottom:1px solid #e9e0d3;background:transparent}
.saved-shrine-name {font-size:15px;line-height:1.7;font-weight:500}
.saved-row-actions {display:flex;align-items:center;gap:24px;flex-shrink:0}
.saved-row-actions a {font-size:11px;color:#927859}
.saved-archive {font-size:11px;color:#9c8b77;display:inline-block;margin:16px 8px}
.page-head {margin:24px 0 30px}.page-head h1 {margin:0}
.hero-copy h1 {margin-top:0}
@media(max-width:760px){
 .account-heading {margin:20px 0 28px;gap:12px}.account-heading h1 {font-size:25px}.account-login {font-size:11px}
 .collection-tabs {gap:3px;padding-left:0}.collection-tab {flex:1;min-width:0;font-size:11px;padding:13px 3px 11px;border-radius:10px 10px 0 0}.collection-tab.selected {padding-top:16px}
 .collection-content {padding:20px 0;min-height:230px}.saved-deity-grid {grid-template-columns:repeat(2,minmax(0,1fr));gap:24px 16px}.saved-deity .mascot {width:125px}.saved-deity h2 {font-size:13px}
 .saved-shrine-list li {gap:12px;padding:19px 2px}.saved-shrine-name {font-size:13px}.saved-row-actions {gap:14px}.saved-row-actions a,.saved-remove {font-size:10px}
 .page-head {margin:20px 0 24px}
}

/* JINJYA centered wordmark and a compact secondary navigation row. */
header {height:152px;max-width:none;display:flex;flex-direction:column;justify-content:center;gap:9px;padding:13px 24px 0}
header .brand {display:flex;flex-direction:column;align-items:center;gap:7px;line-height:1.1;text-align:center}
header .brand strong {font-size:30px;letter-spacing:.16em;display:flex;align-items:baseline;gap:12px;font-weight:850}
header .brand .brand-kana {font-size:11px;letter-spacing:.12em;display:inline-block;margin:0;color:#a97c68;font-weight:600}
header .brand .brand-copy {font-size:11px;letter-spacing:.16em;margin:0;color:#857561;font-weight:500}
nav.main-navigation {gap:36px;justify-content:center;font-size:12px}
nav.main-navigation a {padding:12px 0}
header .account-nav-icon {width:21px;height:21px}
.entry .icon {display:flex;align-items:center;justify-content:center;flex-shrink:0}
.entry-icon {width:38px;height:38px;display:block}
.entry:nth-child(1) .entry-icon {color:#c67b65}.entry:nth-child(2) .entry-icon {color:#76a18c}.entry:nth-child(3) .entry-icon {color:#9d8cb5}
.card-art.shrine .entry-icon {width:72px;height:72px;color:#ba8a6a}
.myth-text-list {width:100%}
.myth-text-item {display:grid;grid-template-columns:40px minmax(0,1fr) 28px;gap:20px;padding:30px 0;border-bottom:1px solid #e5dccf}
.myth-text-item:last-child {border-bottom:0}
.myth-text-number {font-size:12px;letter-spacing:.08em;color:#b39573;padding-top:7px}
.myth-text-item h2 {font-size:21px;line-height:1.6;margin:0 0 9px;font-weight:650}
.myth-text-item p {font-size:14px;line-height:1.95;color:#83796a;margin:0 0 13px;max-width:760px}
.myth-read {font-size:12px;color:#a16f51}.myth-save {background:transparent;border:0;color:#b59b84;padding:6px;font-size:23px;align-self:start}
.myth-save[aria-pressed="true"] {color:var(--coral)}
.map-page > div {height:calc(100dvh - 152px)}
@media(max-width:760px){
 header {height:98px;padding:10px 18px;gap:0;justify-content:center}
 header .brand strong {font-size:27px;gap:9px}header .brand .brand-kana {font-size:10px}header .brand .brand-copy {font-size:10px;margin-top:3px}
 nav.main-navigation {gap:0;justify-content:space-around;font-size:11px;padding-bottom:env(safe-area-inset-bottom,0px);height:calc(66px + env(safe-area-inset-bottom,0px))}
 nav.main-navigation a {padding:14px 5px}
 .map-page > div {height:calc(100dvh - 164px - env(safe-area-inset-bottom,0px))}
 .entry-icon {width:31px;height:31px}
 .myth-text-item {grid-template-columns:24px minmax(0,1fr) 24px;gap:12px;padding:24px 0}
 .myth-text-item h2 {font-size:17px}.myth-text-item p {font-size:13px}.myth-text-number {font-size:10px;padding-top:5px}
 body {padding-bottom:calc(66px + env(safe-area-inset-bottom,0px))}
}

/* Compact name/reading pairs and notes collected after the page content. */
.name-reading {display:block;font-size:11px;font-weight:400;line-height:1.4;letter-spacing:.04em;color:#9b8b77;margin:3px 0 12px}
.card-body h3 {margin-bottom:0}.card-body .name-reading {margin:2px 0 12px}
.detail-hero h1 {margin-bottom:0}.detail-hero .name-reading {font-size:13px;margin:4px 0 21px}
.link-row .name-reading,.saved-shrine-name .name-reading {margin:2px 0 0;font-size:10px}
.saved-deity {border:1px solid var(--line);border-radius:18px;padding:18px 12px 12px}
.saved-deity h2 {margin-bottom:0}.saved-deity .name-reading {margin:3px 0 8px;font-size:10px}
.page-notes {margin:45px 0 15px;padding-top:18px;border-top:1px solid var(--line);color:#9a8e7e;font-size:10px;line-height:1.8}
.page-notes p {margin:4px 0}
header .brand strong {flex-direction:column;align-items:center;gap:3px}
header .brand .brand-kana {font-size:9px;letter-spacing:.1em;line-height:1.3}
header .brand {gap:6px}header {height:164px}
.hero {display:flex;flex-direction:column;text-align:center;gap:22px;padding:32px 0 35px;min-height:0}
.hero h1 {font-size:clamp(30px,3.5vw,44px);line-height:1.6;margin:0}
.hero-crowd {height:auto;min-height:0;display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:12px;margin:0}
.hero-crowd .hero-character {width:76px;transform:none!important}
.hero-crowd .spirit-character {width:76px}
.section-more {display:flex;justify-content:center;margin:24px 0 42px}.section-more .secondary {min-width:210px;text-align:center;padding:12px 24px;background:#eee2d1;border:0;color:#806345}
/* A single paper palette for map controls, with clear status colors on pins. */
.map-page > div {height:calc(100dvh - 164px)}
.map-heading {padding:10px 22px;background:var(--paper);border-top:1px solid var(--line)}.map-heading h1 {font-size:17px;margin:0}.map-heading .secondary {font-size:11px;padding:7px 14px;background:#eee4d5;border:0;color:#806c52}
.map-shell {grid-template-columns:300px minmax(0,1fr)}
.map-sidebar {padding:15px;gap:10px;background:var(--paper);border-right:1px solid #e6ddcf;box-shadow:none}
.map-search {border-radius:10px;background:#f2ebdf;border-color:transparent}.map-search input {padding:10px;font-size:12px}.map-search button {font-size:22px;color:#8b775f}
.map-filter {gap:6px}.map-filter button {background:transparent;border:1px solid #e5dac9;border-radius:8px;color:#8b7b66;padding:7px;font-size:11px}
.map-filter button.active {background:#e9ddc9;border-color:#d2bfa2;color:#745d41}
.map-filter small {font-size:10px;margin-left:3px}
.map-deity-label {gap:5px;color:#8d7b64;font-size:11px}.map-deity-label select {padding:9px;border-color:#e0d3bf;background:transparent;border-radius:8px;font-size:12px}
.map-filter-total {background:transparent;padding:0 0 9px;border-radius:0;border-bottom:1px solid #e7decf;color:#7b6548;font-weight:600;font-size:12px}
.map-sync,.map-result-count {font-size:10px;color:#a0917d}.map-sync a {color:#9b7a57}
.map-list-item {background:transparent;padding:12px 0;border-color:#e9e0d4}.map-list-item:hover,.map-list-item.chosen {background:#f0e7d9}
.map-list-item strong {font-size:12px}.map-list-item small {font-size:9px;margin-top:5px}.map-list-item small.map-kana {margin-top:1px}
.map-source {border-color:#e9e0d4;font-size:9px;color:#a39786;line-height:1.7;padding-top:7px}.map-source details {margin-top:4px}.map-source summary {cursor:pointer}.map-source p {margin:5px 0}
.map-detail {border-radius:14px;padding:18px;box-shadow:0 6px 24px #66513b20}.map-detail h2 {margin-bottom:0}.map-detail .name-reading {margin:2px 0 10px;font-size:11px}
@media(max-width:760px){
 header {height:108px}.map-page > div {height:calc(100dvh - 174px - env(safe-area-inset-bottom,0px))}
 header .brand strong {gap:2px}header .brand .brand-kana {font-size:9px}
 .hero {padding:20px 0 28px;gap:16px}.hero-crowd {gap:5px}.hero-crowd .hero-character,.hero-crowd .spirit-character {width:47px}
 .hero h1 {font-size:29px}.saved-deity {padding:12px 8px 8px}.saved-deity .mascot {width:106px}
 .map-heading {padding:8px 12px}.map-heading h1 {font-size:15px}.map-search {margin:8px 10px 0}
 .map-filter {grid-template-columns:repeat(4,1fr);padding:6px 10px}.map-filter button {padding:6px 2px;font-size:10px}.map-filter small {display:inline;margin-left:2px;font-size:9px}
 .map-deity-label {padding:0 10px;gap:8px}.map-deity-label select {padding:6px;font-size:11px}
 .map-filter-total {padding:4px 10px 6px;margin:0;border:0;font-size:11px}.map-sync {padding:0 10px 5px;font-size:9px}
 .map-source {max-height:52px;margin:3px 10px;font-size:8px;overflow:auto}.map-source details[open] {background:var(--paper)}
 .map-detail {padding:14px}.map-detail h2 {font-size:19px}
}
.map-result-count {display:none}
.rally-courses {display:grid;gap:22px}.rally-course {border:1px solid #e4d7c3;border-radius:18px;overflow:hidden}
.rally-course summary {display:flex;gap:18px;align-items:center;list-style:none;padding:25px;cursor:pointer;background:#f4ecdf}.rally-course summary::-webkit-details-marker{display:none}
.rally-course-no {font-size:13px;color:#af9470}.rally-title {flex:1;min-width:0}.rally-title strong {font-size:19px;display:block}.rally-progress-line {display:flex;gap:12px;align-items:center;margin-top:12px;font-size:12px;color:#947e60}
.rally-progress-line progress {width:180px;height:6px;accent-color:#8eaa83;border:0;border-radius:9px;overflow:hidden;background:#e4d9c6}.rally-progress-line progress::-webkit-progress-bar{background:#e4d9c6}.rally-progress-line progress::-webkit-progress-value{background:#8eaa83;border-radius:9px}
.rally-expand {font-size:22px;color:#aa8c62}.rally-course[open] .rally-expand {font-size:0}.rally-course[open] .rally-expand:after{content:'−';font-size:22px}
.rally-stops {list-style:none;padding:0 25px;margin:0}.rally-stops li {display:flex;align-items:center;gap:15px;border-bottom:1px solid #e9e0d3;padding:18px 0}.rally-stops li:last-child{border:0}
.rally-stamp {display:grid;place-items:center;width:38px;height:38px;border:1px dashed #d6c5aa;border-radius:50%;color:#b5a183;font-size:12px;flex-shrink:0}.rally-stops .visited .rally-stamp{border:0;background:#dce9d7;color:#58764e;font-size:22px}
.rally-stop-name {flex:1;min-width:0}.rally-stop-name>a:first-child{font-size:14px}.rally-stop-name small{display:block;font-size:10px;color:#9f907d;margin-top:2px}.rally-source {display:block;font-size:9px;color:#ad9a81;margin-top:5px}
.rally-map {font-size:11px;color:#9b8060;white-space:nowrap}.rally-visit {padding:9px 15px;font-size:11px;color:#887052;background:#ede0cb;border:0;border-radius:8px;white-space:nowrap}.rally-visit[aria-pressed="true"]{background:#dce9d7;color:#58764e}.rally-visit:disabled{opacity:.5}
.rally-medal{display:grid;justify-items:center;color:#ae8a42;flex-shrink:0}.rally-medal svg{width:47px;height:47px}.rally-medal small{font-size:8px;font-weight:800;letter-spacing:.08em}
.rally-theme-note {padding:0 25px 20px;margin:0;font-size:10px;color:#a18f75}.rally-signin{margin-bottom:25px}.rally-signin a {font-size:12px;background:#eee3d1;border:0}
.rally-home-link {display:flex;align-items:center;justify-content:space-between;padding:22px 26px;margin:20px 0 35px;background:#eee4d2;border-radius:16px;color:#8c7252}.rally-home-link span{font-size:12px}
nav.main-navigation {gap:30px}
@media(max-width:760px){nav.main-navigation {gap:0}nav.main-navigation a{font-size:10px}.rally-course summary{padding:18px 14px;gap:10px}.rally-title strong{font-size:16px}.rally-course-no{font-size:10px}.rally-progress-line progress{width:100px}.rally-progress-line{font-size:10px}.rally-stops{padding:0 14px}.rally-stops li{gap:9px;flex-wrap:wrap}.rally-stamp{width:30px;height:30px}.rally-stop-name>a:first-child{font-size:12px}.rally-map{font-size:10px}.rally-visit{font-size:10px;padding:8px}.rally-theme-note{padding:0 14px 16px}.rally-home-link{padding:18px;gap:12px}.rally-home-link span{font-size:10px}.entry-grid {grid-template-columns:1fr 1fr}}

/* Keep the character row in document flow on narrow screens. */
.hero .hero-crowd {position:relative;inset:auto;width:100%;max-width:100%;opacity:1;box-sizing:border-box}
.hero-copy {min-width:0;max-width:100%}
.shrine-map-button {display:inline-flex;margin-left:8px;margin-top:8px}
@media(max-width:760px){
 .hero .hero-crowd {position:static;width:100%;flex:0 0 auto;justify-content:center;gap:5px}
 .hero-crowd .hero-character {flex:0 1 47px;min-width:0}
 .hero h1 {font-size:clamp(23px,7vw,29px);overflow-wrap:anywhere}
 .detail-hero .shrine-map-button {margin-left:0}
}
.entry-grid {grid-template-columns:repeat(2,minmax(0,1fr))}
@media(max-width:760px){
 .entry-grid {grid-template-columns:minmax(0,1fr)}
 .entry>div {min-width:0}
 .hero .hero-crowd {display:grid;grid-template-columns:repeat(6,minmax(0,1fr));max-width:360px;justify-items:center}
 .hero-crowd .hero-character,.hero-crowd .spirit-character {width:100%;max-width:47px}
}

/* Rally: fixed numbering and a separate impression for each visit. */
.rally-stops li {display:grid;grid-template-columns:24px minmax(0,1fr) auto;gap:16px;min-height:94px}
.rally-number,.rally-stops .visited .rally-number {font-size:12px;font-variant-numeric:tabular-nums;color:#ac987b;align-self:center}
.rally-stop-actions {display:flex;align-items:center;gap:12px}
.rally-web {font-size:10px;font-weight:700;letter-spacing:.05em;padding:8px 12px;background:#eee3d1;color:#8b7252;border-radius:7px;white-space:nowrap}
.rally-map {display:grid;place-items:center;width:32px;height:40px;color:#947c5e}
.rally-map svg {width:22px;height:22px}
.rally-visit,.rally-visit[aria-pressed="true"] {display:grid;place-items:center;width:60px;height:60px;padding:0;flex:none;border:1px dashed #d9cbb6;border-radius:50%;background:transparent;color:#cc7960;cursor:pointer}
.rally-visit[aria-pressed="true"] {border-color:transparent}
.rally-visit svg {width:60px;height:60px;transform:rotate(-9deg)}
.rally-visit:focus-visible,.rally-map:focus-visible {outline:2px solid #c98f69;outline-offset:4px}
.rally-visit:hover {background:#f6eee2}
.saved-visited-mark {font-size:11px;color:#76906b;white-space:nowrap}

/* An edge-to-edge map with compact floating controls. */
.map-page-title {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.map-shell {position:relative;display:block;overflow:hidden}
.map-stage {position:absolute;inset:0;height:100%;min-height:0}
.map-sidebar {position:relative;z-index:3;width:300px;height:100%;box-sizing:border-box;display:flex;flex-direction:column;background:#fffcf7f5;box-shadow:2px 0 15px #69543a10}
.map-deity-label {display:flex;flex-direction:column;align-items:stretch;width:100%;min-width:0;white-space:nowrap;box-sizing:border-box}
.map-deity-label select {display:block;flex:none;width:100%;max-width:100%;min-width:0;white-space:nowrap;box-sizing:border-box}
.map-shrine-icon .map-pin {display:block;width:32px;height:40px;box-sizing:border-box;padding:0;transform:none;border:0;border-radius:0;outline:0;background:transparent;box-shadow:none;filter:drop-shadow(0 2px 3px #4e3c4130);--pin-color:#aa9279}
.map-shrine-icon .map-pin.visited {--pin-color:#548b75}
.map-shrine-icon .map-pin.want {--pin-color:#e08b70}
.map-shrine-icon .map-pin.chosen {filter:drop-shadow(0 0 3px #d49343) drop-shadow(0 2px 4px #4e3c4130)}
.map-pin svg {display:block;width:32px;height:40px;overflow:visible}
.map-pin-shape {fill:var(--pin-color);stroke:#fffcf7;stroke-width:2;stroke-linejoin:round}
.map-pin-symbol {fill:none;stroke:#fff;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.map-cluster-icon,.google-shrine-overlay {box-sizing:border-box;min-width:0;min-height:0;line-height:1}
.map-cluster-icon span {box-sizing:border-box;aspect-ratio:1;line-height:1}
.map-detail {padding:22px;max-width:360px;border:0;border-radius:18px;background:#fffcf7;box-shadow:0 5px 28px #584b3020}
.map-detail .tag {padding:0;background:transparent;color:#a18b6c;font-size:10px}
.map-detail h2 {font-size:21px;margin:10px 25px 0 0;line-height:1.4}
.map-detail p {color:#9b8b77;font-size:11px}
.map-detail .map-status-buttons {gap:6px;margin:18px 0 12px}
.map-status-buttons button {border-radius:8px;background:#f7f1e8;border:1px solid transparent;color:#967d60;padding:11px 5px;white-space:nowrap}
.map-status-buttons button.selected {border-color:#c9ae8b;background:#eee2cd;color:#7a6245}
.map-detail-links {display:flex;border-top:1px solid #eee3d2;padding-top:12px;margin-top:10px}
.map-detail-links a {display:block;text-align:center;width:100%;color:#9a7051;font-size:12px}
#map-save-message:empty {display:none}
@media(max-width:760px){
 .rally-stops li {gap:8px;grid-template-columns:18px minmax(0,1fr);padding:16px 0}
 .rally-number {grid-column:1;grid-row:1/3;align-self:start;padding-top:4px;font-size:10px}
 .rally-stop-name {grid-column:2;grid-row:1}.rally-stop-name small {white-space:normal}
 .rally-stop-actions {grid-column:2;grid-row:2;justify-content:flex-end;gap:12px}
 .rally-visit,.rally-visit[aria-pressed="true"],.rally-visit svg {width:52px;height:52px}
 .rally-web {padding:8px 10px}
 .collection-tabs {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px}
 .collection-tab,.collection-tab.selected {font-size:11px;white-space:nowrap;padding:13px 6px}
 .map-page>div {height:calc(100dvh - 174px - env(safe-area-inset-bottom,0px));min-height:0}
 .map-shell {display:block;min-height:0;flex:1}
 .map-sidebar {position:absolute;top:8px;left:8px;width:calc(100% - 16px);height:auto;padding:9px;gap:6px;border:0;border-radius:12px;box-shadow:0 2px 12px #66543f20}
 .map-search {margin:0;min-height:34px}.map-search input{padding:7px 10px}.map-search button{padding:3px 12px}
 .map-filter {padding:0;gap:4px}.map-filter button {padding:5px 2px}
 .map-deity-label {padding:0;gap:0;font-size:0;order:0}.map-deity-label select {font-size:11px;padding:7px 8px;height:33px}
 .map-filter-total {order:0;padding:0;margin:0;font-size:10px}
 .map-sync {display:none}
 .map-source {position:absolute;top:calc(100% + 5px);left:0;right:0;margin:0;padding:2px 7px;background:#fffcf7e8;border:0;border-radius:5px;max-height:19px;font-size:8px;line-height:1.5}
 .map-stage {position:absolute;inset:0;height:100%;min-height:0}
 .map-detail {bottom:24px;right:8px;width:calc(100% - 16px);max-width:360px;max-height:calc(100% - 195px);padding:16px}
 .map-detail h2 {font-size:18px}.map-detail .map-status-buttons {margin:12px 0 8px}
 .map-status-buttons button {padding:8px 3px;font-size:11px}
}

/* Map-only chrome floats over the map; control groups have no backing panel. */
body.map-layout header {position:absolute;top:0;right:0;left:320px;z-index:8;height:108px;padding:12px 14px 0;margin:0;background:transparent;pointer-events:none}
body.map-layout header .brand,body.map-layout nav.main-navigation {pointer-events:auto}
body.map-layout header .brand-copy {display:none}
body.map-layout header .brand,body.map-layout nav.main-navigation {text-shadow:0 1px 3px #fffcf7,0 0 7px #fffcf7}
body.map-layout nav.main-navigation {background:transparent;backdrop-filter:none;border:0}
body.map-layout .map-page>div {height:100dvh;min-height:0}
body.map-layout .map-sidebar {top:10px;left:10px;height:calc(100% - 20px);background:transparent;box-shadow:none;border:0;padding:5px;gap:9px}
body.map-layout .map-source,body.map-layout .map-source details[open] {background:transparent;box-shadow:none;border:0;border-radius:0}
body.map-layout .map-filter-total,body.map-layout .map-source,body.map-layout .map-deity-label,body.map-layout .map-sync,body.map-layout .map-list-item {text-shadow:0 1px 2px #fffcf7,0 0 5px #fffcf7}
body.map-layout .map-search,body.map-layout .map-deity-label select {background:var(--paper)}
body.map-layout .map-filter button {background:#fffcf7ed}
body.map-layout .map-filter button.active {background:#e9ddc9}
body.map-layout .map-list-item {background:transparent}
body.map-layout .map-list-item:hover,body.map-layout .map-list-item.chosen {background:#eee1ca99}
@media(max-width:760px){
 body.map-layout header {left:0;right:0;height:74px;padding:10px 15px 4px;justify-content:center}
 body.map-layout nav.main-navigation {background:transparent;backdrop-filter:none;border:0}
 body.map-layout .map-page>div {height:calc(100dvh - 66px - env(safe-area-inset-bottom,0px))}
 body.map-layout .map-sidebar {top:76px;left:8px;width:calc(100% - 16px);height:auto;padding:0;gap:6px;background:transparent;border-radius:0}
 body.map-layout .map-source {top:calc(100% + 4px);padding:0;max-height:19px;background:transparent}
 body.map-layout .map-detail {max-height:calc(100% - 265px)}
}
@media(min-width:1101px){body.map-layout header {left:0}}
@media(max-width:760px){
 body.map-layout .map-filter button {white-space:nowrap;font-size:9px}
 body.map-layout .map-filter small {display:block;margin:0;font-size:8px;line-height:1.2}
}

/* Reference elements are sourced editorial metadata, independent of enshrined deities. */
.map-element-label {display:flex;flex-direction:column;align-items:stretch;gap:5px;width:100%;min-width:0;font-size:11px;color:#8d7b64;white-space:nowrap;text-shadow:0 1px 2px #fffcf7,0 0 5px #fffcf7}
.map-element-label select {width:100%;max-width:100%;min-width:0;box-sizing:border-box;white-space:nowrap;padding:9px;border:1px solid #e0d3bf;border-radius:8px;background:var(--paper);font-size:12px;color:var(--ink)}
.reference-element-badge {display:inline-block;font-size:11px;line-height:1.5;background:#e6ebdc;color:#687f55;border-radius:5px;padding:4px 9px;margin:7px 0}
.reference-element-record {font-size:12px}.reference-element-record>a {color:#9a7051}.reference-element-record>small {display:block;font-size:10px;color:#a18c72}
.map-element-notes small {display:block;font-size:9px}
.map-source:has(details[open]) {max-height:180px;overflow:auto}
@media(max-width:760px){
 .map-element-label {font-size:0;gap:0;order:0}
 .map-element-label select {font-size:11px;padding:7px 8px;height:33px}
 body.map-layout .map-detail {max-height:calc(100% - 310px)}
 .map-filter-total {line-height:1.5;white-space:normal}
}
.shrine-like {background:transparent;border:0;padding:8px 0;color:#ab8c79;font-size:12px;cursor:pointer}.shrine-like.selected {color:var(--coral)}.shrine-like strong{font-weight:600;margin-left:5px}.shrine-like:disabled{opacity:.5}
.shrine-card-actions {display:flex;align-items:center;justify-content:space-between;gap:12px;padding-right:20px;flex-wrap:wrap}
.home-ranking {margin:30px 0 42px}.home-ranking h2 {font-size:22px}.home-ranking ol{list-style:none;padding:0;margin:0}.home-ranking li {display:flex;align-items:center;gap:18px;padding:17px 0;border-bottom:1px solid var(--line)}.ranking-number{width:25px;font-weight:700;color:#c59557}.home-ranking li>a {flex:1;min-width:0;font-size:14px}.home-ranking .name-reading{font-size:10px}.ranking-likes{white-space:nowrap;color:#c67d68;font-size:12px}.home-ranking .wish-button{font-size:11px;white-space:nowrap}
.rally-want-stamp{font-size:21px;line-height:1.2;color:#a99171}.rally-want-stamp small{display:block;font-size:9px}.map-status-buttons .visited.selected {background:#e3eddd;color:#658454}
@media(max-width:760px){.home-ranking li{gap:10px;flex-wrap:wrap}.home-ranking li>a{flex-basis:calc(100% - 100px)}.home-ranking li>.wish-button{margin-left:auto}.home-ranking h2{font-size:20px}.map-detail .shrine-like{padding:2px 0 6px}}
.map-detail .map-shrine-intro {font-size:12px;color:#736e61;line-height:1.7}

/* Account collections stay on one line, including on a phone. */
.collection-tabs {display:flex;flex-wrap:nowrap;align-items:flex-end;gap:5px;overflow-x:auto;padding-left:0;scrollbar-width:thin}
.collection-tab,.collection-tab.selected {flex:1 0 auto;white-space:nowrap;padding:16px 12px;font-size:13px}
.map-like-count {display:block;font-size:12px;line-height:1.6;color:#b08c76;margin:5px 0 12px}
.map-like-count strong {font-weight:500;margin-left:4px}
.map-status-buttons {display:flex;flex-wrap:nowrap}
.map-status-buttons>[data-advance-visit] {flex:1.4;min-width:0}
.map-detail .map-status-buttons>.shrine-like {flex:1;min-width:0;border:1px solid #ddcbb3;background:#f0e3d0;color:#8e7256;border-radius:8px;padding:11px 5px;font-size:12px;white-space:nowrap}
.map-detail .map-status-buttons>.shrine-like.selected {background:#f8e2d9;border-color:#dbb5a5;color:#bd705a}
.map-shrine-intro:empty {min-height:1.7em}
@media(max-width:760px){
 .collection-tabs {display:flex;gap:3px;overflow-x:auto}
 .collection-tab,.collection-tab.selected {flex:1 0 auto;padding:13px 5px;font-size:10px;letter-spacing:0}
 .map-detail .map-status-buttons>.shrine-like {font-size:11px;padding:8px 3px}
 .saved-shrine-list .shrine-like {white-space:nowrap;font-size:11px}
}
.collection-tabs {overflow-y:hidden;scrollbar-width:none}
.collection-tabs::-webkit-scrollbar {display:none}
@media(max-width:760px){.collection-tab,.collection-tab.selected {flex:1 1 auto;min-width:0;padding:13px 3px}}

/* Keep touch gestures inside the map; leave document zoom available elsewhere. */
#shrine-map {touch-action:none;overscroll-behavior:contain}
#shrine-map .leaflet-bottom.leaflet-left {bottom:20px;left:8px}
img.spirit-character {object-fit:contain;aspect-ratio:1;display:block;height:auto}
.card-art img.spirit-character {height:140px;width:140px;max-width:100%}
@media(min-width:761px){body.map-layout .map-sidebar {height:calc(100% - 135px)}}

/* Four larger characters sit under the home copy without widening the page. */
.hero .hero-crowd {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));max-width:520px;gap:12px;justify-items:center}
.hero-crowd .hero-character,.hero-crowd .spirit-character {width:100%;max-width:120px;min-width:0}
/* Character art is contained in a white field, with the complete silhouette visible. */
.card .card-art:has(img.spirit-character) {background:#fff!important;height:auto;aspect-ratio:1;padding:12px;box-sizing:border-box;overflow:visible}
.card-art img.spirit-character {width:100%;height:auto;max-width:100%;max-height:none;object-fit:contain;object-position:center}
.detail-hero:has(img.spirit-character) {background:#fff;padding:24px;border-radius:18px;overflow:visible}
.detail-hero img.spirit-character {width:220px;height:auto;max-width:100%;object-fit:contain}
.detail-hero:has(img.spirit-character) > div {flex:1;min-width:0;text-align:center}
/* Account identity and actions share a baseline, with no extra page title. */
.account-heading {margin:0 0 18px;gap:15px;align-items:center;min-height:36px}
.account-name,.account-login {font-size:12px;color:#796d5e;line-height:1.5;font-weight:400;margin:0}
.account-name {display:block;min-width:0;overflow-wrap:anywhere}
.account-login {margin-left:auto;padding:6px 0;white-space:nowrap}
.collection-tab .collection-count {display:inline-block;margin-left:6px;font-size:.85em;font-weight:500;font-variant-numeric:tabular-nums}
.saved-row-actions .saved-map {display:grid;place-items:center;width:28px;height:32px;flex:none}
.saved-map svg {display:block;width:22px;height:22px}
.saved-row-actions {gap:18px}
.saved-mark-visited {border:0;border-radius:7px;background:#e1e9dc;color:#637d59;font-size:11px;padding:8px 12px;white-space:nowrap;cursor:pointer}
.saved-mark-visited:disabled,.saved-remove:disabled {opacity:.5}
@media(max-width:760px){
 .hero .hero-crowd {max-width:390px;gap:5px}
 .hero-crowd .hero-character,.hero-crowd .spirit-character {width:100%;max-width:94px}
 .card .card-art:has(img.spirit-character) {padding:8px}
 .detail-hero:has(img.spirit-character) {padding:20px;flex-direction:column;align-items:center;gap:12px}
 .detail-hero:has(img.spirit-character) > div {width:100%}
 .detail-hero img.spirit-character {width:190px;align-self:center}
 .account-heading {margin:0 0 14px}
 .account-name,.account-login {font-size:11px}
 .collection-tab .collection-count {margin-left:3px;font-size:9px}
 .saved-shrine-list li {align-items:flex-start;flex-wrap:wrap;gap:8px}
 .saved-shrine-name {flex:1 1 100%;min-width:0}
 .saved-row-actions {margin-left:auto;gap:16px;justify-content:flex-end}
 .saved-mark-visited {font-size:10px;padding:7px 12px}
}

.sr-only {position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
/* Shrine photos use the same personal image in lists, maps and the header. */
.card .card-art.shrine {position:relative;background:#ede5d8;height:170px}
.card-art .shrine-photo {position:absolute;inset:0;width:100%;height:100%;min-width:0;min-height:0;object-fit:cover;object-position:center;display:block}
.photo-edit {display:inline-flex;align-items:center;justify-content:center;gap:6px;border:1px solid #ddd0bd;border-radius:8px;background:#fffcf7ed;color:#806c54;padding:9px 12px;font:inherit;font-size:11px;line-height:1.2;cursor:pointer}
.photo-edit svg {width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linejoin:round;flex:none}
.card>.photo-edit {position:absolute;z-index:2;top:118px;left:12px}
.card>.photo-edit span {display:none}
.shrine-card-actions {padding:12px 16px;display:grid;grid-template-columns:minmax(0,1fr);gap:8px}
.shrine-card-actions:has(.shrine-like) {grid-template-columns:minmax(0,1fr) auto}
.shrine-card-actions .wish-button {width:100%;min-width:0;margin:0}
.shrine-card-actions .shrine-like {padding:8px 0;white-space:nowrap}
.shrine-detail-header {margin:8px 0 28px}
.shrine-header-photo {position:relative;aspect-ratio:16/7;min-height:160px;background:#eae2d5;border-radius:18px;overflow:hidden}
.shrine-header-photo .photo-edit {position:absolute;right:14px;bottom:14px}
.shrine-cover-photo {display:block;width:100%;height:100%;position:absolute;inset:0;object-fit:cover;object-position:center}
.shrine-photo-empty {position:absolute;inset:0;display:grid;place-items:center;color:#a9957d;font-size:12px}
.shrine-detail-heading {padding:22px 0 0}
.shrine-detail-heading h1 {font-size:30px;margin:0 0 2px;line-height:1.5}
.shrine-location {font-size:12px;color:#948673;margin:12px 0 0}
.shrine-detail-actions {display:flex;align-items:stretch;flex-wrap:wrap;gap:10px;margin-top:20px}
.shrine-detail-actions>* {display:inline-flex;align-items:center;justify-content:center;gap:7px;margin:0;min-height:44px;box-sizing:border-box;padding:10px 18px;font-size:12px;white-space:nowrap;border-radius:9px}
.shrine-detail-actions svg {width:18px;height:18px}
.shrine-detail-actions .shrine-like {border:1px solid #decdb9;background:#f2e8d9}
.shrine-detail-grid {grid-template-columns:minmax(0,1.8fr) minmax(230px,1fr);gap:36px}
.shrine-detail-grid .panel {padding:20px 0;margin:0;border:0;border-radius:0;background:transparent}
.shrine-detail-grid .panel h2 {font-size:18px;margin:0 0 14px}
.shrine-detail-grid .link-row {padding:12px 0}
.map-user-photo {display:flex;justify-content:flex-end;flex-wrap:wrap;gap:8px;margin:0 20px 10px 0}
.map-user-photo img {width:100%;height:120px;object-fit:cover;border-radius:10px}
.map-user-photo .photo-edit {font-size:10px;padding:6px 9px}
.photo-dialog {border:0;border-radius:18px;background:var(--paper);color:var(--ink);padding:22px;width:min(500px,calc(100vw - 32px));max-height:90dvh;box-sizing:border-box;overflow:auto;box-shadow:0 16px 60px #48351c30}
.photo-dialog::backdrop {background:#3e352a66}
.photo-editor-heading {display:flex;align-items:center;justify-content:space-between;gap:12px}
.photo-editor-heading h2 {font-size:19px;margin:0}
.photo-scope {font-size:11px;color:#9b8a73;margin:8px 0 18px}
.photo-preview {aspect-ratio:16/10;background:#eae2d5;border-radius:10px;overflow:hidden;display:grid;place-items:center;color:#a18e75;font-size:12px}
.photo-preview {position:relative}
.photo-preview img {position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:center}
.photo-picker-actions {display:grid;grid-template-columns:1fr 1fr;gap:9px;margin-top:14px}
.photo-picker-actions button {border:1px solid #d8c7ae;background:#f0e5d3;color:#826a4f;border-radius:8px;padding:12px 6px;font:inherit;font-size:12px;cursor:pointer}
.photo-editor-error {font-size:11px;color:#b76855;min-height:18px;margin:10px 0}
.photo-editor-footer,.photo-editor-footer>div {display:flex;align-items:center;justify-content:space-between;gap:12px}
.photo-editor-footer button {font:inherit;font-size:11px;border:0;background:transparent;color:#9a8468;padding:10px 2px;cursor:pointer}
.photo-editor-footer .primary {background:var(--coral);color:#fff;padding:10px 22px;border-radius:8px}
.photo-dialog button:disabled {opacity:.45;cursor:wait}
/* Saved shrine rows remain one line of controls on narrow screens. */
.saved-shrine-list li {flex-wrap:nowrap;align-items:center;gap:10px}
.saved-shrine-name {flex:1 1 auto;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.saved-shrine-name .name-reading {display:none}
.saved-row-actions {flex:0 0 auto;gap:13px;margin-left:0}
@media(max-width:760px){
 .card .card-art.shrine {height:130px}.card>.photo-edit {top:85px;left:8px;padding:7px}
 .shrine-header-photo {aspect-ratio:16/10;min-height:0;border-radius:13px}
 .shrine-detail-heading h1 {font-size:24px}
 .shrine-detail-actions {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:8px;margin-top:16px}
 .shrine-detail-actions>* {min-width:0;padding:10px 6px;font-size:11px}
 .shrine-detail-actions .shrine-map-button {grid-column:1/-1;margin:0}
 .shrine-detail-grid {grid-template-columns:minmax(0,1fr);gap:12px}
 .saved-shrine-list li {padding:17px 0;gap:7px}
 .saved-row-actions {gap:9px}.saved-row-actions .saved-map {width:23px}
 .saved-mark-visited {padding:7px 8px}.saved-remove {font-size:10px}
 .shrine-card-actions {padding:10px;gap:7px}.shrine-card-actions:has(.shrine-like) {grid-template-columns:minmax(0,1fr)}
}

/* Visit buttons use the same three states in cards, details and maps. */
.wish-button,.map-status-buttons [data-advance-visit] {display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-height:42px;padding:10px 15px;border-radius:10px;border:1px solid #d8c8b2;background:#eadfcf;color:#816b55;font:inherit;font-size:12px;line-height:1.4;font-weight:600;white-space:nowrap;text-align:center;cursor:pointer;transition:background .15s,border-color .15s}
.wish-button[data-visit-status="want"],.map-status-buttons [data-advance-visit].want {background:#99664d;border-color:#99664d;color:#fff}
.wish-button[data-visit-status="visited"],.map-status-buttons [data-advance-visit].visited {background:#58734c;border-color:#58734c;color:#fff}
.wish-button:disabled {opacity:.55;cursor:wait}
.map-detail .map-status-buttons {display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:8px}
.map-detail .map-status-buttons>* {width:100%;min-width:0;margin:0}
@media(max-width:760px){.wish-button,.map-status-buttons [data-advance-visit]{font-size:11px;padding:10px 8px}}
.map-select-row {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;width:100%;min-width:0}
.map-select-row>label {min-width:0;margin:0;padding:0;display:block}
.map-select-row select {display:block;box-sizing:border-box;width:100%;max-width:100%;min-width:0;background:var(--paper);border:1px solid #e0d3bf;border-radius:8px;padding:9px 5px;color:#7c6b55;font:inherit;font-size:12px;white-space:nowrap;text-overflow:ellipsis}
@media(max-width:760px){
 input:not([type=checkbox]):not([type=radio]),textarea,select {font-size:16px!important}
 .map-select-row {gap:5px}
 .map-select-row select {padding:9px 3px;font-size:16px}
 .map-select-row .map-deity-label,.map-select-row .map-element-label,.map-select-row .map-prefecture-label {font-size:initial;order:initial}
}
.blessing-tags {display:flex;flex-wrap:wrap;gap:6px;margin:10px 0 0}
.blessing-tags span {display:inline-block;padding:4px 7px;border-radius:5px;background:#eae8d8;color:#82785c;font-size:10px;line-height:1.4}
.map-blessing-label {display:block;min-width:0}
.map-blessing-label select {box-sizing:border-box;width:100%;padding:9px;border:1px solid #e0d3bf;border-radius:8px;background:var(--paper);color:#7c6b55;font:inherit;font-size:12px}
.deity-detail-grid {grid-template-columns:minmax(0,1fr);max-width:780px;margin-inline:auto}
.detail-grid .deity-profile p {line-height:2;margin:0 0 1.4em;overflow-wrap:anywhere}
.detail-grid .deity-profile p:last-child {margin-bottom:0}
.rally-stops li {display:grid;grid-template-columns:24px minmax(0,1fr) auto;align-items:center;gap:12px;flex-wrap:nowrap}
.rally-stop-name {min-width:0}
.rally-stop-name>a:first-child {display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.rally-stop-name small {display:none}
.rally-stop-actions {display:flex;align-items:center;gap:10px;margin:0}
.rally-visit {display:grid;place-items:center;flex:none;width:54px;height:54px;padding:0}
.rally-web,.rally-map {display:inline-flex;align-items:center;justify-content:center;height:32px;box-sizing:border-box}
.rally-visit:disabled,.shrine-like:disabled,.card .heart:disabled {opacity:1}
.rally-visit svg {animation:stamp-in .16s ease-out}
@keyframes stamp-in{from{transform:rotate(-12deg) scale(1.22);opacity:.35}to{transform:rotate(-9deg) scale(1);opacity:1}}
.card .heart:active,.shrine-like:active,.wish-button:active {transform:scale(.94)}
@media(prefers-reduced-motion:reduce){.rally-visit svg{animation:none}.card .heart:active,.shrine-like:active,.wish-button:active{transform:none}}
@media(max-width:760px){
 .rally-stops {padding:0 10px}.rally-stops li {grid-template-columns:19px minmax(0,1fr) auto;gap:7px}
 .rally-stop-name>a:first-child {font-size:12px}
 .rally-stop-actions {gap:7px}.rally-visit{width:44px;height:44px}.rally-visit svg{width:42px;height:42px}
 .rally-web{font-size:9px;padding:6px}.rally-map{width:25px}
 .map-blessing-label select{font-size:16px}
}

/* Keep all three map filters aligned, including native mobile selects. */
.map-select-row #map-deity,.map-select-row #map-element,.map-select-row #map-prefecture{height:44px;font-size:16px;line-height:normal}

/* JINJYA mobile layout: explicit grid placement overrides legacy two-row rules. */
.rally-stops li {grid-template-columns:24px minmax(0,1fr) auto;align-items:center}
.rally-stops .rally-number {grid-column:1;grid-row:1;align-self:center;padding:0;line-height:1.4}
.rally-stops .rally-stop-name {grid-column:2;grid-row:1;align-self:center;line-height:1.4}
.rally-stops .rally-stop-actions {grid-column:3;grid-row:1;align-self:center;gap:8px}
.rally-web {width:36px;height:36px;padding:8px;background:transparent;border:0;border-radius:7px;color:#96816a}
.rally-web:hover {background:#eee4d5}
.external-link-icon {display:inline-block;width:18px;height:18px;vertical-align:middle;flex:none}
.rally-web .external-link-icon {width:20px;height:20px}
.card.shrine-card {display:flex;flex-direction:column;min-width:0;height:100%}
.card.shrine-card>a {display:flex;flex:1;flex-direction:column;min-width:0}
.card.shrine-card .card-art {position:relative;flex:none;width:100%;aspect-ratio:4/3;height:auto;min-height:0}
.card.shrine-card .card-body {padding:16px 15px 10px;flex:1}
.card.shrine-card h3 {font-size:17px;line-height:1.5;margin:8px 0 2px;overflow-wrap:anywhere}
.card.shrine-card .name-reading {font-size:11px;line-height:1.5;margin-top:0;min-height:1.5em}
.card.shrine-card .shrine-card-actions {margin-top:auto;padding:10px 15px 16px}
.blessing-tags {gap:2px 8px;margin-top:10px}
.blessing-tags span {padding:0;background:transparent;border:0;border-radius:0;font-size:10px;line-height:1.65;color:#968b76}
.card.shrine-card .blessing-tags {min-height:3.3em;display:block;font-size:10px}
.card.shrine-card .blessing-tags span {display:block}

.map-select-row {grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:6px}
.map-select-row .map-prefecture-label {grid-column:1;grid-row:1}
.map-select-row .map-blessing-label {grid-column:2;grid-row:1}
.map-select-row .map-deity-label {grid-column:1;grid-row:2}
.map-select-row .map-element-label {grid-column:2;grid-row:2}
.map-select-row #map-deity {display:none!important}
.map-select-row select,.map-select-row #map-deity-picker {height:42px!important;box-sizing:border-box;width:100%;min-width:0;padding:8px 10px!important;border:1px solid #e0d3bf;border-radius:8px;background:var(--paper);color:#7c6b55;font:inherit;font-size:16px!important;line-height:1.4;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:left}
#map-deity-picker {padding-right:23px!important;position:relative;cursor:pointer}
#map-deity-picker::after {content:'⌄';position:absolute;right:8px;top:9px;background:var(--paper)}
.selection-dialog {box-sizing:border-box;width:min(480px,calc(100vw - 24px));max-height:80dvh;margin:auto;border:1px solid #e4d9c8;border-radius:18px;padding:18px;background:var(--paper);color:var(--ink);box-shadow:0 12px 50px #382b2726}
.selection-dialog::backdrop {background:#33282055}
.selection-heading {display:flex;align-items:center;justify-content:space-between;margin-bottom:12px;gap:12px}
.selection-heading h2 {font-size:17px;margin:0}
.selection-options {display:flex;flex-direction:column;gap:6px;overflow-x:auto}
.selection-options>button {display:flex;align-items:center;gap:8px;min-width:100%;width:max-content;flex-shrink:0;white-space:nowrap;box-sizing:border-box;border:1px solid transparent;background:transparent;padding:14px 12px;color:#635748;font:inherit;font-size:14px;text-align:left;border-radius:10px;cursor:pointer}
.selection-options>button::before {content:'';width:14px;height:14px;border-radius:50%;border:1px solid #b9a58d;flex:none;box-sizing:border-box}
.selection-options>button[aria-pressed=true] {background:#eee4d6;border-color:#d6c5ad}
.selection-options>button[aria-pressed=true]::before {background:#b88364;box-shadow:inset 0 0 0 3px #eee4d6;border-color:#b88364}
.selection-options small {font-size:11px;color:#9a8976;white-space:nowrap}
@media(max-width:760px){
 .rally-stops li {grid-template-columns:18px minmax(0,1fr) auto;gap:6px;padding:14px 0}
 .rally-stops .rally-stop-actions {gap:4px}
 .rally-visit,.rally-visit[aria-pressed=true],.rally-visit svg {width:42px;height:42px}
 .rally-web,.rally-map {width:30px;height:36px;padding:5px}
 .card.shrine-card .card-body {padding:12px 12px 6px}
 .card.shrine-card h3 {font-size:15px}
 .card.shrine-card .name-reading {font-size:10px}
 .card.shrine-card .shrine-card-actions {padding:8px 12px 14px}
 .card.shrine-card .wish-button {width:100%;min-height:40px;padding:9px 3px;font-size:11px}
 .card.shrine-card>.photo-edit {top:auto;bottom:auto;left:8px;transform:translateY(-100%);margin-top:calc((100% - 2px)*.75 - 8px)}
 .selection-options>button {font-size:13px;padding:13px 8px;gap:6px}
 .selection-options small {font-size:10px}
}
.card.shrine-card {container-type:inline-size}
.card.shrine-card>.photo-edit {top:calc(75cqw - 42px);bottom:auto;left:8px;margin-top:0;transform:none;padding:7px}

/* Compact selectors and shrine information, shared across mobile and desktop. */
.selection-options {padding:2px;gap:8px}
.selection-options>button {min-height:48px;border-color:#e7dfd3}
.selection-dialog button:focus-visible {outline:2px solid #927b63;outline-offset:-3px;box-shadow:none}
.selection-options>button:focus:not(:focus-visible) {outline:none}
.selection-options>button[aria-pressed=true] {border-color:#bda58a;background:#eee4d6}
.map-detail {padding-top:46px}
.map-detail-title {display:flex;align-items:center;gap:12px;width:100%;margin:0 0 6px}
.map-detail .map-detail-title h2 {flex:1;min-width:0;margin:0;font-size:20px;line-height:1.4}
.map-detail-title .map-like-count {flex:none;margin:0 0 0 auto;white-space:nowrap;font-size:13px}
.map-detail .map-shrine-intro:empty,.map-detail .blessing-tags:empty,.map-detail #map-save-message:empty {display:none;margin:0;min-height:0}
.saved-mark-visited {background:transparent;color:#927b63;border:1px solid #927b63}
.filters.shrine-filters {display:grid;grid-template-columns:1fr 1fr;gap:10px;align-items:stretch;margin:16px 0 24px}
.filters.shrine-filters select {width:100%;max-width:100%;min-width:0;height:44px;box-sizing:border-box;padding:8px 12px;color:#786751;font:inherit;font-size:16px;border:1px solid #dfd5c7;border-radius:10px;background:transparent}
.filters.shrine-filters select[data-filter=deity] {grid-column:1/-1}
.filters.shrine-filters>a {grid-column:1/-1;justify-self:end;padding:7px 0;background:transparent;border:0;color:#927b63;font-size:12px}
@media(min-width:761px){.filters.shrine-filters {grid-template-columns:1fr 1fr 2fr auto}.filters.shrine-filters select[data-filter=deity],.filters.shrine-filters>a {grid-column:auto}.filters.shrine-filters>a {align-self:center}}
@media(max-width:760px){.map-detail {padding:44px 16px 16px}.map-detail .map-detail-title h2 {font-size:18px}.map-detail-title {gap:8px}}

@media(min-width:1000px){.grid.home-shrine-grid {grid-template-columns:repeat(4,minmax(0,1fr))}}
/* Same filter order as the map, with an additional shrine-name type filter. */
.filters.shrine-filters {grid-template-columns:repeat(2,minmax(0,1fr))}
.filters.shrine-filters select[data-filter=deity] {grid-column:auto}
.filters.shrine-filters>a {grid-column:auto;align-self:center}
@media(min-width:1000px){.filters.shrine-filters {grid-template-columns:repeat(5,minmax(0,1fr))}.filters.shrine-filters>a {grid-column:1/-1}}

/* Attribute hierarchy: quiet list metadata and a larger detail value. */
.shrine-card-elements {display:flex;gap:6px;flex-wrap:wrap;font-size:10px;line-height:1.65;color:#968b76;margin-top:5px}
.shrine-card-elements:empty {display:none}
.shrine-attribute-values {display:flex;gap:16px;color:#826b53;font-size:32px;font-weight:600;line-height:1.4}
.shrine-attribute-values span {display:inline-block}

/* Short character introductions, placed directly above the deity name. */
.character-tagline {
  display: block;
  margin: 0 0 4px;
  color: #8b6d52;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: .02em;
  overflow-wrap: anywhere;
}
.card-body .character-tagline + h3 { margin-top: 0; }
.detail-hero .character-tagline { font-size: 12px; margin-bottom: 6px; }
.saved-deity .character-tagline { font-size: 10px; margin-bottom: 3px; }
@media (max-width: 760px) {
  .character-tagline { font-size: 10px; letter-spacing: 0; }
  .detail-hero .character-tagline { font-size: 11px; }
}

.map-detail-title .map-shrine-detail-link {color:inherit;text-decoration:underline;text-decoration-color:#c9b7a3;text-decoration-thickness:1px;text-underline-offset:5px}
.map-detail-title .map-shrine-detail-link:hover {color:#8b6d52}
.map-detail-title .map-shrine-detail-link:focus-visible {outline:2px solid #8b6d52;outline-offset:4px;border-radius:3px}

/* Destination-shaped placeholders replace the previous page before navigation. */
.route-skeleton {padding:24px 0;min-height:70vh;overflow:hidden}
.skeleton-heading,.skeleton-search,.skeleton-picture,.skeleton-line {background:#eee8de;border-radius:12px;animation:soft-pulse 1.2s ease-in-out infinite alternate}
.skeleton-heading {width:46%;height:32px;margin:10px 0 30px}
.skeleton-search {height:60px;margin-bottom:28px}
.skeleton-grid {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px}
.skeleton-picture {height:190px}.skeleton-line {height:18px;margin:18px 0;width:85%}.skeleton-line.short {width:55%;height:12px}
.skeleton-detail .skeleton-grid {grid-template-columns:1fr}.skeleton-detail .skeleton-picture {height:320px}.skeleton-detail .skeleton-line {max-width:480px}
.skeleton-map {min-height:80vh;background:#e8e7dc;padding:24px}.skeleton-map .skeleton-grid{display:none}
.home-deities .grid {grid-template-columns:repeat(4,minmax(0,1fr))}
.rally-home-link {gap:24px;padding:32px;margin:32px 0 44px;background:#efe0c8;border:1px solid #d4b48b;box-shadow:0 5px 0 #ddc7a6;color:#735439;transition:background .15s,transform .15s}
.rally-home-link:hover {background:#e9d4b5;transform:translateY(-2px)}
.rally-home-link .rally-home-stamp {display:grid;place-items:center;flex:none;width:72px;height:72px;border:3px solid #b87959;outline:1px dashed #b87959;outline-offset:-8px;border-radius:50%;font-size:30px;color:#aa674a;transform:rotate(-12deg)}
.rally-home-copy {flex:1}.rally-home-copy strong {display:block;font-size:25px;line-height:1.5}.rally-home-copy span {display:block;font-size:13px;margin-top:6px}
.rally-home-link .rally-home-action {padding:13px 20px;background:#9a684c;color:#fffaf3;border-radius:30px;font-size:14px;white-space:nowrap}
@media(max-width:760px){.skeleton-grid,.home-deities .grid {grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.skeleton-picture{height:160px}.rally-home-link{padding:22px 18px;gap:14px;flex-wrap:wrap}.rally-home-link .rally-home-stamp{width:56px;height:56px;font-size:24px}.rally-home-copy strong{font-size:21px}.rally-home-copy span{font-size:11px}.rally-home-link .rally-home-action{margin-left:auto;font-size:12px;padding:10px 18px}}
@media(prefers-reduced-motion:reduce){.route-skeleton *{animation:none}.rally-home-link{transition:none}}

.home-myths {margin:44px 0 32px}
.home-myths .section-head h2 {display:flex;align-items:center;gap:12px}
.home-myths .entry-icon {width:30px;height:30px;color:#9a7857;flex:none}
.myth-text-item {grid-template-columns:36px minmax(0,1fr)}
@media(max-width:760px){.myth-text-item{grid-template-columns:24px minmax(0,1fr)}.home-myths .entry-icon{width:26px;height:26px}}

/* Oshi-gami discovery: isolated modal and warm, full-width home entry. */
.gacha-home-button{width:100%;display:flex;align-items:center;gap:18px;margin:16px 0 36px;padding:22px 26px;background:#eee2cc;color:#705641;border:1px solid #ddc9ab;border-radius:22px;text-align:left;box-shadow:none}
.gacha-home-symbol{font-size:36px;color:#ab7957}.gacha-home-button strong{display:block;font-size:22px}.gacha-home-button small{display:block;margin-top:4px;font-size:13px;font-weight:400}.gacha-home-button>b{margin-left:auto;font-size:24px}
.oshi-gacha-dialog{position:fixed;inset:0;margin:auto;width:min(480px,calc(100% - 32px));max-height:calc(100dvh - 40px);overflow:auto;box-sizing:border-box;padding:32px 28px;border:1px solid #dfd3c0;border-radius:28px;background:#fcfaf5;color:#373e3c;text-align:center;box-shadow:0 18px 80px #413b3230}
.oshi-gacha-dialog::backdrop{background:#443e3660;backdrop-filter:blur(4px)}
.gacha-eyebrow{color:#9b7654;font-size:13px;margin:0 0 20px;letter-spacing:.08em}.oshi-gacha-dialog h2{font-size:22px;margin:0 0 24px}.oshi-gacha-dialog h3{font-size:25px;margin:8px 0}.gacha-answers{display:grid;gap:12px}.gacha-answers button{display:flex;align-items:center;justify-content:space-between;width:100%;padding:18px;text-align:left;box-shadow:none}.gacha-stage,.gacha-result-art{height:240px;display:grid;place-items:center;margin:0 auto 12px}.oshi-gacha-dialog .spirit-character{width:240px;height:240px;max-width:100%;object-fit:contain;background:transparent}.gacha-stage img[hidden]{display:none}.gacha-loading{font-size:76px;color:#bda17b}.gacha-tagline{font-size:12px;color:#927253;margin:8px 0}.gacha-reading{font-size:14px;color:#988b7a;margin:0 0 24px}.gacha-result-actions{display:grid;gap:10px}.gacha-result-actions a,.gacha-result-actions button{display:block;width:100%;box-sizing:border-box;text-align:center}.gacha-result-actions a{padding:14px;border-radius:16px;background:#ed7562;color:white;text-decoration:none;font-weight:700}
@media(max-width:480px){.gacha-home-button{padding:18px;gap:12px}.gacha-home-button strong{font-size:20px}.oshi-gacha-dialog{padding:30px 20px 24px}.oshi-gacha-dialog h2{font-size:20px}.gacha-stage,.gacha-result-art{height:210px}.oshi-gacha-dialog .spirit-character{width:210px;height:210px}}

/* Consistent control colors, including Safari's native button text. */
button{color:inherit}
.secondary{color:#80674f}
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline-color:#ae8868}
#oshi-gacha-title:focus{outline:none}
.oshi-gacha-dialog{background:var(--paper);border-color:#dfd1bc}
.oshi-gacha-dialog .gacha-eyebrow{font-weight:700;color:#9d795b}
.oshi-gacha-dialog .gacha-answers button{background:#eee4d4;border:1px solid #ddcbb3;border-radius:18px;color:#795d46;justify-content:center;text-align:center;font-weight:600;min-height:62px;transition:background .15s,transform .15s}
.oshi-gacha-dialog .gacha-answers button:hover{background:#e8d8c1}
.oshi-gacha-dialog .gacha-answers button:active{transform:scale(.98)}
.oshi-gacha-dialog .gacha-result-actions .secondary{background:#eee4d4;color:#795d46;border-color:#ddcbb3}
.gacha-home-button{position:relative;min-height:220px;padding:28px 32px;overflow:hidden;background:#f1e3c9;gap:14px;isolation:isolate}
.gacha-home-copy{flex:1;min-width:0;position:relative;z-index:1}.gacha-home-button strong{font-size:28px;letter-spacing:.04em}.gacha-home-button small{font-size:13px;line-height:1.7}.gacha-home-cta{display:inline-block;border-radius:30px;background:#9c6d50;color:#fffaf1;padding:8px 24px;margin-top:16px;font-size:13px;font-weight:700}
.gacha-home-art{display:flex;align-items:end;justify-content:center;flex:0 1 48%;min-width:0;align-self:center}.gacha-home-art .spirit-character{width:36%;height:190px;object-fit:contain;max-width:none;background:none;margin:0 -2%;filter:drop-shadow(0 8px 0 #d9c2a029)}.gacha-home-art .spirit-character:nth-child(2){height:215px;transform:translateY(-6px)}
.account-book-title{font-size:27px;line-height:1.4;margin:0 0 12px;color:var(--coral);font-weight:800}
.visited-prefecture{margin:0 0 30px}.visited-prefecture>h2{display:flex;align-items:center;gap:10px;font-size:19px;color:#80674f;margin:8px 0 15px}.visited-prefecture>h2>span{font-size:12px;font-weight:400;color:#a18d76}.visited-prefecture .shrine-card-actions .saved-remove{width:100%;padding:8px;border:1px solid #dacbb7;border-radius:10px;color:#8e7156;background:transparent}
@media(max-width:600px){.gacha-home-button{min-height:220px;padding:24px 14px;display:flex;flex-direction:column;gap:0;text-align:center}.gacha-home-button strong{font-size:24px}.gacha-home-button small{font-size:11px}.gacha-home-copy{flex:none}.gacha-home-art{flex:none;width:min(270px,90%);height:115px;order:-1;margin-top:-12px}.gacha-home-art .spirit-character{height:115px;width:36%}.gacha-home-art .spirit-character:nth-child(2){height:130px;transform:translateY(-2px)}.gacha-home-cta{margin-top:10px;padding:6px 24px}.account-book-title{font-size:24px}.visited-prefecture>h2{font-size:17px}}

/* Compact map controls: search and result count remain visible when collapsed. */
body.map-layout .map-sidebar {height:auto;max-height:calc(100% - 145px);overflow:visible;display:flex;flex-direction:column;gap:6px}
.map-controls {order:1;width:100%;min-width:0;color:#806c56}
.map-controls>summary {list-style:none;cursor:pointer;background:var(--paper);border:1px solid #dfd2be;border-radius:12px;padding:8px 14px;font-size:14px;width:fit-content;text-shadow:none}
.map-controls>summary::-webkit-details-marker {display:none}
.map-controls>summary:focus-visible {outline:2px solid #a57d60;outline-offset:2px}
.map-controls-body {display:flex;flex-direction:column;gap:10px;margin-top:6px;padding:12px;background:#fcfaf4f5;border:1px solid #e5dac8;border-radius:14px;max-height:42dvh;overflow:auto}
body.map-layout .map-controls .map-source {display:block;position:static;max-height:none;padding:0;font-size:10px;line-height:1.5;overflow:visible}
body.map-layout .map-controls .map-select-row {order:0}
body.map-layout .map-controls .map-filter {order:1}
body.map-layout .map-controls .map-source {order:2}
body.map-layout .map-controls .map-filter small {display:inline;margin-left:3px}
body.map-layout .map-filter-total {order:2;margin:0;font-size:11px}
body.map-layout .map-search {order:0;height:42px;min-height:42px}
body.map-layout .map-search input {font-size:16px;padding:8px 12px}
body.map-layout .map-list,body.map-layout .map-result-count {display:none}
body.map-layout .map-shrine-intro {white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%;line-height:1.6}
@media(max-width:760px){
 body.map-layout .map-sidebar {top:72px;max-height:none}
 body.map-layout .map-detail {max-height:calc(100% - 195px)}
 body.map-layout .map-controls .map-filter button {font-size:11px;padding:8px 3px}
 body.map-layout .map-controls .map-filter small {font-size:10px}
}

/* Clear sits beside the disclosure, without toggling it. */
.map-control-bar {position:relative;order:1;width:100%;min-width:0}
.map-control-bar .map-controls>summary {max-width:calc(100% - 124px);box-sizing:border-box}
.map-clear-filters {position:absolute;top:0;right:0;min-height:38px;padding:8px 12px;border:1px solid #cbbbA4;border-radius:12px;background:var(--paper);color:#806c56;font:inherit;font-size:13px;line-height:20px;cursor:pointer}
.map-clear-filters[hidden] {display:none!important}
.map-clear-filters:focus-visible {outline:2px solid #a57d60;outline-offset:2px}
.map-clear-filters:hover {background:#efe6d7}

/* Notebook tabs: centered counts and a baseline interrupted by the active tab. */
.saved-collection .collection-tabs {position:relative;isolation:isolate;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));align-items:stretch;gap:5px;padding:0 18px;border:0;overflow:visible}
.saved-collection .collection-tabs::before {content:"";position:absolute;left:0;right:0;bottom:0;height:1px;background:#dfd1bd;z-index:0}
.saved-collection .collection-tab,.saved-collection .collection-tab.selected {position:relative;z-index:1;top:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;min-width:0;padding:16px 6px 12px;font-size:13px;line-height:1.5;border:1px solid transparent;border-bottom-color:#dfd1bd}
.saved-collection .collection-tab.selected {background:var(--paper);border-color:#dfd1bd;border-bottom-color:var(--paper)}
.saved-collection .collection-tab .collection-count {display:block;margin:0;text-align:center;font-size:12px;line-height:1.2;font-weight:500}
@media(max-width:760px){
 .saved-collection .collection-tabs {padding:0 8px;gap:3px}
 .saved-collection .collection-tab,.saved-collection .collection-tab.selected {padding:13px 2px 10px;font-size:10px}
 .saved-collection .collection-tab .collection-count {font-size:11px}
}

.shrine-prefecture-group {margin:26px 0}
.shrine-prefecture-group>h2 {font-size:17px;color:#8c7963;margin:0;padding:0 0 10px;border-bottom:1px solid #dfd1bd}
.shrine-prefecture-group ul {list-style:none;margin:0;padding:0}
.shrine-prefecture-group li {display:flex;align-items:center;gap:16px;padding:17px 2px;border-bottom:1px solid #e8e0d3}
.shrine-text-main {flex:1;min-width:0}
.shrine-text-name {color:var(--ink);font-weight:700;font-size:17px}
.shrine-text-name:hover {color:#a85d43}
.shrine-text-main .name-reading {font-size:11px;margin:3px 0 0}
.shrine-text-meta {display:flex;flex-wrap:wrap;gap:3px 12px;margin-top:6px;font-size:11px;line-height:1.6;color:#8c7963}
.shrine-text-list .heart {position:static;flex:0 0 40px;width:40px;height:40px;border:0;background:transparent;padding:5px;display:grid;place-items:center}
.kojiki-story .story-deity-link {color:#a85d43;text-decoration:underline;text-decoration-color:#cba68f;text-underline-offset:3px}
.kojiki-story .story-deity-link:hover {color:#7b4d35;text-decoration-thickness:2px}

.account-corner {position:fixed;top:14px;right:max(16px,env(safe-area-inset-right));z-index:100;display:grid;place-items:center;width:44px;height:44px;border-radius:50%;color:#876f58;background:#fffcf7ec;pointer-events:auto;text-decoration:none}
.account-corner .account-nav-icon {width:25px;height:25px}
.account-corner.active,.account-corner:hover {color:#dc766a;background:#f7e5db}
.account-corner:focus-visible {outline:2px solid #aa7c60;outline-offset:3px}
.account-save-burst {position:absolute;inset:0;pointer-events:none;color:#df7a83}
.account-save-burst i {position:absolute;left:50%;top:50%;display:block;font-style:normal;font-size:40px;line-height:1;color:#df7a83;animation:account-heart-pop 1s ease-in-out both;transform-origin:center}
@keyframes account-heart-pop {0%{opacity:0;transform:translate(-50%,-50%) scale(0)}28%{opacity:1;transform:translate(-50%,-50%) scale(1.25)}43%{opacity:1;transform:translate(-50%,-50%) scale(.9)}57%{opacity:1;transform:translate(-50%,-50%) scale(1.06)}70%{opacity:1;transform:translate(-50%,-50%) scale(1)}100%{opacity:0;transform:translate(-50%,-50%) scale(0)}}
.gacha-home-button .gacha-home-cta {display:inline-flex;align-items:center;justify-content:center;min-height:54px;min-width:200px;max-width:100%;box-sizing:border-box;padding:14px 30px;margin-top:18px;font-size:17px;line-height:1.4}
.kojiki-home-link {text-decoration:none;background:#e7ecdc;border-color:#ced5bd;color:#657152}
.kojiki-home-link .gacha-home-cta {background:#778568}
@media(max-width:600px){.account-corner{top:10px;right:12px;width:40px;height:40px}.gacha-home-button .gacha-home-cta{min-width:220px;min-height:54px;font-size:17px}.kojiki-home-link strong{font-size:23px}}
@media(prefers-reduced-motion:reduce){.account-save-burst i{animation:none;opacity:1;transform:translate(-50%,-50%)}}
.kojiki-home-art{display:block;flex:0 1 48%;min-width:0;max-width:440px}
.kojiki-home-art img{display:block;width:100%;height:auto;object-fit:contain}
@media(max-width:600px){.kojiki-home-link .kojiki-home-art{order:-1;flex:none;width:min(300px,100%);margin:0 auto 14px}.kojiki-home-link{padding-top:18px}}

.shrine-text-list .shrine-like-icon{font-size:28px;line-height:1;flex-basis:44px;width:44px;height:44px;color:#df7a83;-webkit-text-fill-color:#df7a83}
.shrine-text-list .shrine-like-icon.selected,.shrine-text-list .shrine-like-icon:disabled{color:#df7a83;-webkit-text-fill-color:#df7a83;background:transparent;opacity:1}

.account-face{display:grid;place-items:center;width:100%;height:100%;font-size:20px;font-weight:700;line-height:1}
.account-face svg{width:25px;height:25px}
.account-corner.signed-in,.account-corner.signed-in.active,.account-corner.signed-in:hover{background:#87674f;color:#fffaf2}
.account-corner.signed-in .account-face{color:#fffaf2}

.account-login-label{position:absolute;top:calc(100% + 3px);left:50%;transform:translateX(-50%);white-space:nowrap;font-size:10px;font-weight:700;line-height:1.3;color:#87674f}
.account-signin-prompt{display:flex;justify-content:center;align-items:center;min-height:220px;padding:32px 16px}
.account-signin-button{display:inline-flex;justify-content:center;align-items:center;min-height:60px;width:min(320px,100%);font-size:18px;font-weight:700;text-align:center;padding:18px 24px;border-radius:18px}
nav.main-navigation a.active::after{content:none}
nav.main-navigation a .nav-label{position:relative;display:inline-block}
nav.main-navigation a.active .nav-label::after{content:"";position:absolute;left:0;right:0;bottom:-8px;height:4px;border-radius:2px;background:var(--coral)}

.photo-login-dialog{width:min(410px,calc(100vw - 40px));padding:24px;border:1px solid #e5d9c9;border-radius:24px;box-shadow:0 20px 70px #48351c26}
.photo-login-dialog .photo-editor-heading h2{font-size:21px}
.photo-login-symbol{display:grid;place-items:center;width:64px;height:64px;margin:24px auto 16px;border-radius:50%;background:#eee5d8;color:#a18162}
.photo-login-symbol svg{width:30px;height:30px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linejoin:round}
.photo-login-dialog .photo-scope{text-align:center;font-size:14px;line-height:1.8;margin:0 0 24px;color:#8b7c6a}
.photo-login-actions{display:flex;flex-direction:column;align-items:stretch;gap:10px}
.photo-login-actions .primary{display:flex;align-items:center;justify-content:center;min-height:52px;padding:12px 16px;border-radius:14px;font-size:16px;font-weight:700;text-decoration:none}
.photo-login-actions .photo-login-cancel{min-height:44px;background:transparent;color:#87674f;border:1px solid #d9c8b5;border-radius:14px;font:inherit;font-size:14px;padding:10px 16px}
.photo-dialog button:focus:not(:focus-visible){outline:none}
.photo-dialog button:focus-visible,.photo-dialog a:focus-visible{outline:2px solid #ad896b;outline-offset:3px}

/* Theme characters replace course numbering; stop names and actions share a row. */
.rally-course summary {padding:20px 24px;gap:24px;min-height:152px}
.rally-course-art {display:flex;align-items:center;justify-content:center;flex:0 0 136px;width:136px;height:144px}
.rally-course-art img.mascot {display:block;width:100%;height:100%;max-width:none;max-height:none;object-fit:contain;object-position:center;margin:0;transform:none}
.rally-title strong {line-height:1.55;font-size:21px;overflow-wrap:anywhere}
.rally-progress-line {flex-wrap:wrap;row-gap:6px}
.rally-stops li {grid-template-columns:minmax(0,1fr) auto}
.rally-stops .rally-stop-name {grid-column:1;grid-row:1}
.rally-stops .rally-stop-actions {grid-column:2;grid-row:1}
.rally-stop-name>a:first-child {white-space:normal;overflow:visible;text-overflow:clip;overflow-wrap:anywhere}
@media(max-width:760px) {
 .rally-course summary {padding:16px 12px;gap:12px;min-height:132px}
 .rally-course-art {flex-basis:100px;width:100px;height:124px}
 .rally-title strong {font-size:16px}
 .rally-progress-line {gap:6px;font-size:11px}
 .rally-progress-line progress {width:86px;max-width:100%}
 .rally-medal {width:36px;flex:0 0 36px}
 .rally-stops li {grid-template-columns:minmax(0,1fr) auto;gap:8px}
 .rally-stops .rally-stop-name>a:first-child {font-size:14px}
 .rally-stops .rally-stop-actions {gap:4px}
}
@media(max-width:380px) {
 .rally-course summary {gap:8px;padding:12px 10px}
 .rally-course-art {flex-basis:88px;width:88px;height:112px}
 .rally-title strong {font-size:15px}
}

/* Keep separate, finger-sized targets for website, map and visit stamp. */
.rally-stops .rally-stop-actions {gap:20px;flex-wrap:nowrap}
.rally-stops .rally-web,.rally-stops .rally-map {width:44px;height:48px;min-width:44px;min-height:48px;padding:0;flex:none;touch-action:manipulation}
.rally-stops .rally-web .external-link-icon {width:32px;height:32px}
.rally-stops .rally-map svg {width:28px;height:28px}
.rally-stops .rally-visit,.rally-stops .rally-visit[aria-pressed="true"] {width:48px;height:48px;min-width:48px;min-height:48px;padding:0;touch-action:manipulation}
.rally-stops .rally-visit svg {width:48px;height:48px}
.rally-stops .rally-web:focus-visible {outline:2px solid #c98f69;outline-offset:4px}
@media(max-width:760px) {
 .rally-stops .rally-stop-actions {gap:14px}
 .rally-stops li {column-gap:12px}
}

/* Today's omikuji: six illustrated paper lots, then a deliberate reveal. */
.omikuji-home{background:#efe1da;border-color:#dcc4b8}.omikuji-home .gacha-home-cta{background:#af6857}
.omikuji-paper{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;width:86px;height:184px;border:2px solid #b96e5b;border-radius:4px;background:#fffaf0;box-shadow:5px 7px 0 #76544212;color:#a65c4a;position:relative;box-sizing:border-box}
.omikuji-seal{font-size:15px;border:1px solid currentColor;border-radius:50%;width:25px;height:25px;display:grid;place-items:center}.omikuji-lettering{writing-mode:vertical-rl;font-family:serif;font-size:23px;font-weight:700;letter-spacing:.14em}.omikuji-lines{width:32px;height:8px;border-top:1px solid #c69a84;border-bottom:1px solid #c69a84}
.omikuji-home-art{display:flex;justify-content:center;align-items:center;flex:0 1 48%;padding:10px}.omikuji-home-art .omikuji-paper:first-child{transform:rotate(-17deg) translate(12px,8px)}.omikuji-home-art .omikuji-paper:last-child{transform:rotate(17deg) translate(-12px,8px)}.omikuji-home-art .omikuji-paper:nth-child(2){z-index:1;transform:translateY(-7px)}
.omikuji-dialog{width:min(560px,calc(100% - 24px))}.omikuji-deck{display:grid;grid-template-columns:repeat(3,1fr);gap:16px 12px;position:relative;max-width:360px;margin:0 auto;padding:8px 0}.omikuji-slip{display:grid;place-items:center;background:none;border:0;padding:0;box-shadow:none;min-width:0;animation:omikuji-deal .22s both;animation-delay:calc(var(--i)*.1s);transition:transform .45s ease,opacity .25s;touch-action:manipulation}.omikuji-slip:disabled{opacity:1;cursor:default}.omikuji-slip .omikuji-paper{width:78px;height:156px;gap:8px}.omikuji-slip .omikuji-lettering{font-size:21px}.omikuji-slip.unchosen{opacity:0;transform:scale(.82);pointer-events:none}.omikuji-slip.chosen{z-index:2;transform:translate(var(--move-x),var(--move-y)) scale(1.18)}.omikuji-instruction{font-size:14px;min-height:44px;margin:22px 0 0;line-height:1.7;color:#8b705e}.omikuji-dialog h2.omikuji-fortune{font-family:serif;font-size:clamp(60px,16vw,88px);letter-spacing:.08em;color:#ac5c48;margin:15px 0 24px}.omikuji-message-label{font-size:12px;color:#a3836d;letter-spacing:.12em;margin:0 0 10px}.omikuji-message{font-family:serif;font-size:18px;line-height:1.9;margin:0 auto 26px;max-width:380px}.omikuji-luck{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;border-top:1px solid #ddcbb7;padding:20px 0}.omikuji-luck>div+div{border-left:1px solid #ddcbb7}.omikuji-luck h3{font-size:13px;font-weight:500;margin:0 0 12px;color:#9c7c65}.omikuji-luck strong{display:block;font-size:14px;line-height:1.6;overflow-wrap:anywhere}.omikuji-luck a{text-decoration:none;color:inherit}.omikuji-dialog .omikuji-luck .spirit-character{width:100%;height:90px;object-fit:contain;display:block;margin:0 auto 8px}.omikuji-compass,.omikuji-color{display:grid;place-items:center;height:90px;margin:0 auto 8px}.omikuji-compass{font-size:64px;color:#a88862}.omikuji-color{width:48px;height:48px;border-radius:50%;border:1px solid #c4b19a;margin:21px auto 29px}.omikuji-done{margin-top:12px;min-width:160px;min-height:46px}#omikuji-title:focus{outline:none}
@keyframes omikuji-deal{from{opacity:0;translate:45px -12px;rotate:8deg}to{opacity:1;translate:0 0;rotate:0deg}}
@media(max-width:600px){.omikuji-home-art{order:-1;flex:none;height:130px;margin:0 0 18px}.omikuji-home-art .omikuji-paper{width:58px;height:125px;gap:5px}.omikuji-home-art .omikuji-lettering{font-size:17px}.omikuji-home-art .omikuji-seal{font-size:11px;width:19px;height:19px}.omikuji-home-art .omikuji-lines{width:23px;height:5px}.omikuji-dialog{padding:30px 16px 22px}.omikuji-luck strong{font-size:12px}}
@media(prefers-reduced-motion:reduce){.omikuji-slip{animation:none;transition:none}}

/* Keep focus unobtrusive and align all three result columns to shared rows. */
.omikuji-slip:focus{outline:none}.omikuji-slip:focus-visible .omikuji-paper{background:#f5e7d3}
.omikuji-dialog .omikuji-luck{gap:0;align-items:start;padding:20px 0 12px}
.omikuji-luck>div{display:grid;grid-template-rows:28px 100px auto;padding:0 8px;min-width:0}
.omikuji-luck>div>a{display:contents}
.omikuji-dialog .omikuji-luck h3{font-size:13px;line-height:20px;margin:0;text-align:center}
.omikuji-luck-art{display:flex;align-items:center;justify-content:center;width:100%;height:100px}
.omikuji-luck .omikuji-compass{font-family:serif;font-size:58px;line-height:1;width:64px;height:64px;margin:0;display:flex;align-items:center;justify-content:center}
.omikuji-luck .omikuji-color{width:48px;height:48px;margin:0;display:block;flex-shrink:0}
.omikuji-dialog .omikuji-luck .spirit-character{width:90px;max-width:100%;height:90px;margin:0;object-fit:contain}
.omikuji-luck strong{margin:8px 0 0;line-height:1.6;min-height:2.6em;text-align:center}
.omikuji-dialog h2.omikuji-fortune{line-height:1.2;margin:24px 0 26px;letter-spacing:.04em}
.omikuji-message{max-width:24em;font-size:17px;line-height:1.85;text-wrap:balance;margin:0 auto 26px}
@media(max-width:420px){.omikuji-luck>div{padding:0 5px;grid-template-rows:26px 88px auto}.omikuji-luck-art{height:88px}.omikuji-dialog .omikuji-luck .spirit-character{width:80px;height:80px}.omikuji-message{font-size:16px}.omikuji-dialog h2.omikuji-fortune{margin:18px 0 24px}}

/* A warm, illustrated capsule replaces the gacha reel. */
.capsule-stage{position:relative;height:300px;margin:0 auto 12px;overflow:hidden;isolation:isolate}
.capsule-ground{position:absolute;width:145px;height:18px;border-radius:50%;background:#ad94792b;bottom:25px;left:50%;transform:translateX(-50%);animation:capsule-shadow .7s ease-out both}
.capsule-drop{position:absolute;width:180px;height:180px;left:calc(50% - 90px);bottom:38px;animation:capsule-fall .7s cubic-bezier(.3,.05,.65,1) both}
.capsule-shake{position:relative;width:100%;height:100%;transform-origin:50% 90%;animation:capsule-rattle .62s .8s ease-in-out 2}
.capsule-half{position:absolute;left:0;width:180px;height:90px;box-sizing:border-box;border:3px solid #8d705a;box-shadow:inset -10px 0 0 #6d4d2b0d;z-index:2}
.capsule-top{top:0;border-radius:100px 100px 0 0;background:var(--capsule-color);transform-origin:20% 100%;animation:capsule-open-top .55s 2.2s cubic-bezier(.2,.7,.3,1) both}
.capsule-top:before{content:'';position:absolute;left:34px;top:15px;width:54px;height:20px;background:#fff9;transform:rotate(-24deg);border-radius:50%}

.capsule-bottom{top:88px;height:92px;border-radius:0 0 100px 100px;background:#f3e7cf;animation:capsule-open-bottom .55s 2.2s ease-out both}
.capsule-bottom:after{content:'';position:absolute;top:-8px;left:70px;width:34px;height:13px;border:2px solid #8d705a;border-radius:8px;background:#e7d2af}
.capsule-spirit{position:absolute;inset:-40px -30px 0;display:grid;place-items:center;z-index:1;animation:capsule-emerge .7s 2.3s ease-out both}
.oshi-gacha-dialog .capsule-spirit .spirit-character{display:block;width:155px;height:180px;max-width:100%;object-fit:contain;filter:brightness(0) saturate(100%) invert(40%) sepia(22%) saturate(700%) hue-rotate(345deg) brightness(91%) contrast(86%)}
.capsule-status{font-size:13px;line-height:1.7;color:#927253;min-height:24px;margin:8px 0}
@keyframes capsule-fall{0%{transform:translateY(-320px) rotate(-12deg)}65%{transform:translateY(0) rotate(3deg)}82%{transform:translateY(-25px) rotate(-3deg)}100%{transform:translateY(0) rotate(0)}}
@keyframes capsule-shadow{from{opacity:0;scale:.5}to{opacity:1;scale:1}}
@keyframes capsule-rattle{0%,100%{transform:rotate(0)}15%{transform:rotate(-12deg)}32%{transform:rotate(11deg)}49%{transform:rotate(-8deg)}65%{transform:rotate(6deg)}80%{transform:rotate(-3deg)}}
@keyframes capsule-open-top{to{transform:translate(-58px,-55px) rotate(-38deg)}}
@keyframes capsule-open-bottom{to{transform:translateY(6px)}}
@keyframes capsule-emerge{from{opacity:0;transform:translateY(65px) scale(.65)}to{opacity:1;transform:translateY(-20px) scale(1)}}
@media(max-width:480px){.capsule-stage{height:270px}}
@media(prefers-reduced-motion:reduce){.capsule-drop,.capsule-shake,.capsule-ground{animation:none}.capsule-half{animation:none;opacity:1}.capsule-top{transform:translate(-58px,-55px) rotate(-38deg)}.capsule-spirit{animation:none;opacity:1;transform:translateY(-20px)}}

/* Center the seal independently of inherited text metrics. */
.omikuji-seal{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;padding:0;line-height:1;letter-spacing:0;text-indent:0}
.omikuji-seal>span{display:block;line-height:1;margin:0;padding:0;letter-spacing:0;transform:translateY(-.035em)}
/* Fixed center with two full-width leaves hinged at its edges. */
.omikuji-fold-scene{position:relative;display:block;width:78px;height:156px;perspective:1000px;perspective-origin:50% 50%;isolation:isolate}
.omikuji-fold-center,.omikuji-fold-leaf{position:absolute;box-sizing:border-box;top:0;height:156px;background:#fffaf0;border-top:2px solid #b96e5b;border-bottom:2px solid #b96e5b;backface-visibility:visible}
.omikuji-fold-center{left:0;width:78px;z-index:1}
.omikuji-fold-leaf{width:79px;transform-style:preserve-3d;will-change:transform}
.omikuji-fold-left{right:calc(100% - 1px);border-left:2px solid #b96e5b;border-radius:4px 0 0 4px;transform-origin:right center;z-index:2;animation:omikuji-open-left .75s .55s cubic-bezier(.33,0,.2,1) both}
.omikuji-fold-right{left:calc(100% - 1px);border-right:2px solid #b96e5b;border-radius:0 4px 4px 0;transform-origin:left center;z-index:3;animation:omikuji-open-right .85s cubic-bezier(.33,0,.2,1) both}
.omikuji-fold-leaf:after{content:'';position:absolute;inset:0;background:#8c7059;pointer-events:none;opacity:0}
.omikuji-fold-right:after{animation:omikuji-fold-shade .85s both}
.omikuji-fold-left:after{animation:omikuji-fold-shade .75s .55s both}
@keyframes omikuji-open-right{from{transform:rotateY(-180deg)}to{transform:rotateY(0)}}
@keyframes omikuji-open-left{from{transform:rotateY(180deg)}to{transform:rotateY(0)}}
@keyframes omikuji-fold-shade{0%{opacity:.08}45%{opacity:.18}100%{opacity:0}}
@media(prefers-reduced-motion:reduce){.omikuji-fold-leaf,.omikuji-fold-leaf:after{animation:none}}


.capsule-top{z-index:0}.capsule-bottom{z-index:2}.capsule-spirit{z-index:1}.omikuji-message{text-wrap:initial}

/* Separate visit choices from favorite action. */
.shrine-detail-actions {display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
.shrine-detail-actions .shrine-map-button {grid-column:1/-1}

.map-detail .map-status-buttons {grid-template-columns:repeat(2,minmax(0,1fr))}
.visit-choice,.map-status-buttons .visit-choice {border:1px solid #d8c8b2;background:#fffdf7;color:#816b55;min-height:44px;font:inherit;font-size:12px;font-weight:600;border-radius:10px;cursor:pointer}
.visit-choice.selected[data-visit-choice="want"],.map-status-buttons .visit-choice.selected[data-advance-visit="want"] {background:#99664d;border-color:#99664d;color:#fff}
.visit-choice.selected[data-visit-choice="visited"],.map-status-buttons .visit-choice.selected[data-advance-visit="visited"] {background:#58734c;border-color:#58734c;color:#fff}
.map-favorite-action {display:flex;align-items:center;gap:4px;flex-shrink:0}
.map-favorite-action>.shrine-like-icon {position:static;flex:0 0 38px;padding:0}
.map-favorite-action .map-like-count {font-size:0;gap:0}
.map-favorite-action .map-like-count strong {font-size:13px}
.visit-choice:disabled {opacity:.6;cursor:wait}
/* Visitor-sourced ratings and facilities. */
.shrine-review-summary{margin:24px 0 0;padding:20px 0;border-top:1px solid #ded4c5;border-bottom:1px solid #ded4c5}
.review-summary-top{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:18px}
.review-summary-top h2{font-size:17px;margin:0}.review-summary-top strong{font-size:24px}.review-summary-top small{color:#948673;font-size:12px}
.review-stars{color:#ba934d;letter-spacing:2px;white-space:nowrap}.review-facilities{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.review-facilities>div{display:flex;flex-direction:column;align-items:center;text-align:center;gap:7px;min-width:0}.review-facilities span{font-size:12px;color:#948673}.review-facilities strong{font-size:14px}.review-facilities small{font-size:11px;color:#948673}
.review-source-note{font-size:11px;color:#948673;line-height:1.8;margin:16px 0 0}
.personal-review{display:flex;align-items:center;justify-content:center;gap:10px;flex-wrap:wrap;width:100%;font-size:12px}.review-edit{border:0;background:none;color:#8b6d52;text-decoration:none;padding:10px 12px;cursor:pointer;font:inherit}
.shrine-card-actions:has(.personal-review){display:flex;flex-wrap:wrap;gap:8px}
.review-dialog{border:1px solid #ded4c5;border-radius:24px;background:#fffdf7;color:#343a36;width:min(460px,calc(100vw - 32px));max-height:90dvh;overflow:auto;box-sizing:border-box;padding:26px;box-shadow:0 18px 60px #48351c30}
.review-dialog::backdrop{background:#3e352a66;backdrop-filter:blur(5px)}.review-dialog-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.review-dialog-heading h2{font-size:21px;margin:0}
.review-form fieldset{border:0;padding:0;margin:18px 0}.review-form legend{font-size:13px;color:#816b55;margin-bottom:9px}.review-rating{text-align:center}.review-rating legend{float:left;width:100%}.review-rating>div{display:flex;justify-content:center;gap:8px;clear:both}.review-rating label{position:relative;color:#d8cebc;font-size:38px;cursor:pointer}.review-rating label.filled{color:#ba934d}.review-rating input{position:absolute;opacity:0;width:100%;height:100%;inset:0;cursor:pointer}.review-rating input:focus-visible+span{outline:2px solid #8b6d52;border-radius:5px}.review-rating output{display:block;font-size:12px;color:#948673;margin-top:6px}
.review-inputs fieldset>div{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.review-inputs label{position:relative;cursor:pointer}.review-inputs input{position:absolute;opacity:0;inset:0;width:100%;height:100%;cursor:pointer}.review-inputs span{display:block;border:1px solid #ded4c5;border-radius:8px;padding:11px 2px;text-align:center;font-size:12px}.review-inputs input:checked+span{background:#eadfcf;border-color:#b79c78;color:#755c42}.review-inputs input:focus-visible+span{outline:2px solid #8b6d52;outline-offset:2px}
.review-save{width:100%;min-height:46px}.review-error{font-size:12px;color:#af5245}.review-dialog button:disabled{opacity:.6}
@media(max-width:600px){.review-facilities{grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}.review-facilities span{font-size:10px;white-space:nowrap}.review-facilities small{font-size:10px;line-height:1.6}.review-dialog{padding:20px}.review-summary-top h2{font-size:15px}}

.review-unknown{color:#927d64}
.personal-review .review-edit{display:inline-flex;align-items:center;justify-content:center;min-height:44px;text-align:center}

/* Clearly distinguish selected visit choices without shifting the label. */
.visit-choice,.map-status-buttons .visit-choice{display:inline-flex;align-items:center;justify-content:center;gap:8px;border-width:2px;transition:background .15s,color .15s,border-color .15s}
.visit-choice::before{content:"";display:inline-flex;align-items:center;justify-content:center;flex:0 0 16px;width:16px;height:16px;border:1.5px solid #c3b29b;border-radius:50%;box-sizing:border-box;font-size:12px;line-height:1}
.visit-choice.selected::before{content:"✓";border-color:currentColor;color:inherit}
.visit-choice:focus-visible{outline:2px solid #927d64;outline-offset:3px}
.review-facilities .review-mixed{color:#927d64;font-size:10px;font-weight:400;line-height:1.6;text-align:center}
.review-facilities .review-mixed span{display:block;color:inherit;font-size:inherit;white-space:nowrap}
@media(max-width:380px){.review-facilities .review-mixed{font-size:9px}}
.shrine-list-rating{display:inline-block;white-space:nowrap;color:#927d64;font-size:12px;font-weight:500;line-height:1.6;text-decoration:none}
.shrine-list-rating>span{color:#ba934d}.shrine-list-rating small{font-size:10px;color:#a08e79}
.shrine-text-main>.shrine-list-rating,.saved-shrine-name>.shrine-list-rating,.rally-stop-name>.shrine-list-rating{display:block;margin-top:5px}
.map-list-item .shrine-list-rating{margin-left:8px}.map-list-item .shrine-list-rating small{display:inline}
.related-shrine-prefecture{margin-top:24px}.related-shrine-prefecture h3{display:flex;align-items:baseline;gap:10px;font-size:15px;color:#8b6d52;padding-bottom:9px;border-bottom:1px solid #ded4c5;margin:0}
.related-shrine-prefecture h3 small{font-size:11px;font-weight:400}.related-shrine-prefecture .link-row{display:flex;align-items:center;justify-content:space-between;gap:12px}.related-shrine-prefecture .link-row>span:first-child{min-width:0}.related-shrine-prefecture .shrine-list-rating{flex-shrink:0}

.filters.shrine-filters>a{grid-column:1/-1;justify-self:end;text-align:right}

/* Shared JINJYA surfaces and controls across every route. */
:root{--ui-brown:#927b63;--ui-border:#ded4c5;--ui-soft:#eee4d6;--ui-radius:14px;--ui-dialog-radius:28px;--ui-shadow:0 18px 60px #48351c30}
:is(a,button,input,select,textarea):focus-visible{outline-color:var(--ui-brown)}
.primary,.secondary{min-height:44px;border-radius:var(--ui-radius);text-align:center}
.filters :is(select,input),.map-controls :is(select,input){border-color:var(--ui-border);border-radius:var(--ui-radius)}
:is(.review-dialog,.photo-dialog,.selection-dialog,.oshi-gacha-dialog){border:1px solid var(--ui-border);border-radius:var(--ui-dialog-radius);background:var(--paper);color:var(--ink);padding:28px;max-height:calc(100dvh - 32px);box-shadow:var(--ui-shadow)}
:is(.review-dialog,.photo-dialog,.selection-dialog,.oshi-gacha-dialog)::backdrop{background:#443e3660;backdrop-filter:blur(4px)}
:is(.review-dialog-heading,.photo-editor-heading,.selection-heading){display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:44px;margin:0 0 20px}
:is(.review-dialog-heading,.photo-editor-heading,.selection-heading) h2{font-size:20px;line-height:1.5;margin:0;color:var(--ink)}
@media(hover:hover){}
.oshi-gacha-dialog .gacha-eyebrow{padding-inline:34px;min-height:24px}
.review-inputs span{border-color:var(--ui-border);border-radius:var(--ui-radius)}
.photo-editor-footer .primary,.photo-login-actions .primary,.gacha-result-actions a{border-radius:var(--ui-radius)}
:is(.review-dialog,.photo-dialog) .primary{display:inline-flex;align-items:center;justify-content:center;min-height:48px}
@media(max-width:600px){:is(.review-dialog,.photo-dialog,.selection-dialog,.oshi-gacha-dialog){padding:24px 20px}:is(.review-dialog-heading,.photo-editor-heading,.selection-heading) h2{font-size:18px}}

/* One close control for reviews, photos, selections, gacha, omikuji and map. */
:is(.review-dialog,.photo-dialog,.selection-dialog){position:fixed;inset:0;margin:auto}
:is(.review-dialog-heading,.photo-editor-heading,.selection-heading){margin-top:-12px;padding-right:48px;min-height:44px}
:is(.review-dialog-heading,.photo-editor-heading,.selection-heading) h2{min-width:0;overflow-wrap:anywhere}
button.popup-close,button.popup-close:is(:hover,:active,:focus,:focus-visible,:disabled){position:absolute;inset:16px 16px auto auto;display:grid;place-items:center;width:44px;height:44px;min-width:44px;min-height:44px;padding:0;margin:0;border:0;border-radius:50%;background:transparent;color:#927b63;-webkit-text-fill-color:#927b63;box-shadow:none;outline:none;opacity:1;transform:none;transition:none;z-index:5;cursor:pointer;appearance:none}
button.popup-close span{position:relative;display:block;width:24px;height:24px;pointer-events:none}
button.popup-close span::before,button.popup-close span::after{content:"";position:absolute;left:0;top:11px;width:24px;height:2px;border-radius:2px;background:#927b63;transform:rotate(45deg)}
button.popup-close span::after{transform:rotate(-45deg)}
/* Auto-focus on opening must not add a fill around the close icon. */
button.popup-close:focus-visible{background:transparent}
button.popup-close:disabled{cursor:wait}
.oshi-gacha-dialog .gacha-eyebrow{min-height:44px;display:flex;align-items:center;justify-content:center;margin-top:-12px;padding-inline:44px}
.map-detail .map-detail-title{padding-right:48px}
@media(max-width:600px){:is(.review-dialog-heading,.photo-editor-heading,.selection-heading),.oshi-gacha-dialog .gacha-eyebrow{margin-top:-8px}}

.photo-retry{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);z-index:1;padding:12px 18px;border:1px solid #ddcbb3;border-radius:12px;background:var(--paper);color:var(--ink);font:inherit;font-size:13px;cursor:pointer}

/* Glossy capsule; the seam has no central oval or latch. */
.capsule-half{border-color:#8d705a;box-shadow:inset -12px -5px 18px #65432624,inset 8px 3px 15px #ffffff70}
.capsule-top{background:radial-gradient(ellipse at 30% 20%,#ffffffe6 0%,#ffffff55 20%,transparent 48%),linear-gradient(135deg,#ffffff38,transparent 50%,#49352530),var(--capsule-color);animation:none;transform:none}
.capsule-top::before{content:none}
.capsule-bottom{background:radial-gradient(ellipse at 30% 12%,#fffef8 0%,#f6ead7 45%,#d8bda0 100%);animation:none;transform:none}
.capsule-bottom::after{content:none}
.capsule-spirit{animation:none;opacity:0;transform:translateY(65px) scale(.65)}
.capsule-ready .capsule-top{animation:capsule-open-top .55s cubic-bezier(.2,.7,.3,1) both}
.capsule-ready .capsule-bottom{animation:capsule-open-bottom .55s ease-out both}
.capsule-ready .capsule-spirit{animation:capsule-emerge .7s .1s ease-out both}
@media(prefers-reduced-motion:reduce){.capsule-ready .capsule-top{animation:none;transform:translate(-58px,-55px) rotate(-38deg)}.capsule-ready .capsule-bottom{animation:none;transform:translateY(6px)}.capsule-ready .capsule-spirit{animation:none;opacity:1;transform:translateY(-20px) scale(1)}}

/* Current location sits above the lower-left zoom controls. */
.map-locate{position:absolute;left:12px;bottom:135px;z-index:1001;width:44px;height:44px;min-width:44px;padding:10px;display:grid;place-items:center;border:1px solid #ded5c8;border-radius:10px;background:#fffdf8;color:#927b63;box-shadow:0 2px 8px #3b30221c;cursor:pointer}
.map-locate[aria-busy="true"]{opacity:.6}
.map-current-location{background:transparent!important;border:0!important;box-shadow:none!important;pointer-events:none}
.current-location-dot{display:block;width:18px;height:18px;background:#4285f4;border:3px solid white;border-radius:50%;box-shadow:0 0 0 1px #4285f450,0 1px 5px #263b5355;box-sizing:border-box}
/* Keep touch focus inside the existing fields: no second frame or tinted block. */
.search input,.search input:is(:focus,:focus-visible),.map-search input,.map-search input:is(:focus,:focus-visible){outline:0!important;box-shadow:none!important;border:0!important;background:transparent!important;border-radius:0;-webkit-appearance:none;appearance:none}
.search:focus-within,.map-search:focus-within{border-color:#b7a18a}
.filters select:is(:focus,:focus-visible),.map-controls select:is(:focus,:focus-visible),.encounter-filter input:is(:focus,:focus-visible){outline:0;box-shadow:none;border-color:#a88f75}
.map-control-bar .map-controls>summary,.map-clear-filters{background:transparent!important;border:0!important;box-shadow:none!important;padding:8px 4px}
.map-control-bar .map-controls>summary:focus-visible,.map-clear-filters:focus-visible{outline:0;text-decoration:underline;text-underline-offset:5px}
.map-banner{top:auto;bottom:25px;left:70px;right:16px;padding:0;background:transparent;border:0;box-shadow:none;color:#705e4e;pointer-events:none;text-shadow:0 1px 3px #fff}
.map-banner[hidden]{display:none}
/* Nearby gods: matching the warm, centered home feature cards. */
.encounter-invitation{display:flex;flex-direction:column;align-items:center;text-align:center;gap:18px;padding:30px 24px 28px;margin:16px 0 36px;border:1px solid #ddc9ab;border-radius:22px;background:#f1e3c9;color:#705641;text-decoration:none;overflow:hidden}
.encounter-invitation-art{display:grid;place-items:center;position:relative;isolation:isolate;width:min(440px,100%);height:200px;flex:none}
.encounter-invitation-art:before{content:"";position:absolute;inset:-12px 0;background:url('/static/encounter-japan.svg') center/contain no-repeat;opacity:.62;z-index:-1}
.encounter-invitation-art .spirit-character{width:200px;height:200px;object-fit:contain;background:transparent;margin:0;filter:drop-shadow(0 6px 0 #d9c2a029)}
.encounter-invitation-copy{display:flex;flex-direction:column;align-items:center;gap:12px;min-width:0}
.encounter-invitation strong{font-size:28px;line-height:1.5;letter-spacing:.04em}.encounter-invitation-copy>span{font-size:14px;line-height:1.8}
.encounter-invitation b{display:inline-flex;align-items:center;justify-content:center;background:#9c6d50;color:#fffaf1;border-radius:30px;min-height:54px;min-width:220px;padding:14px 30px;margin-top:6px;font-size:17px;box-sizing:border-box}
.encounter-invitation:focus-visible{outline:2px solid #9c6d50;outline-offset:4px}
.nearby-gods{background:#f5f0e5;border:1px solid #e4d8c5;border-radius:26px;padding:30px;margin:14px auto 38px;max-width:720px;text-align:center}
.encounter-eyebrow{font-size:12px;letter-spacing:.08em;color:#96816a}.encounter-heading h1{margin:8px 0 20px;font-size:28px;color:#705641}
.nearby-god{display:flex;flex-direction:column;align-items:center;gap:12px;text-align:center}
.nearby-god-art,.encounter-location-art{position:relative;display:grid;place-items:center;isolation:isolate;width:min(300px,100%);height:240px}
.nearby-god-art:before,.encounter-location-art:before{content:"";position:absolute;inset:12px 0;background:url('/static/encounter-japan.svg') center/contain no-repeat;opacity:.35;z-index:-1}
.nearby-god-art .spirit-character,.encounter-location-art .spirit-character{display:block;width:240px;height:240px;max-width:100%;object-fit:contain;background:transparent;margin:0}
.nearby-god-copy{display:flex;flex-direction:column;align-items:center;width:100%;max-width:440px}
.nearby-god-name{font-weight:700;font-size:28px;color:var(--ink);text-decoration:none;line-height:1.5;margin:4px 0 0;overflow-wrap:anywhere}.nearby-reading{color:#9a8c7a;margin:5px 0 20px;font-size:13px}
.nearby-shrine{display:flex;flex-direction:column;align-items:center;gap:6px;width:100%;padding:18px 12px;margin:0 0 22px;background:#fffcf5;border-radius:16px;box-sizing:border-box}.nearby-shrine small{font-size:11px;color:#9a8c7a;letter-spacing:.08em}.nearby-shrine a{color:#79614b;font-size:23px;font-weight:700;line-height:1.6;text-decoration:none;overflow-wrap:anywhere}.nearby-shrine a:hover{text-decoration:underline;text-underline-offset:5px}.nearby-shrine span{font-size:12px;color:#9a8c7a}
.nearby-god-copy .primary,.encounter-actions .primary{display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:30px;min-height:52px;width:min(100%,340px);padding:14px 22px;background:#9c6d50;color:#fffaf1;font-size:16px;font-weight:700;text-decoration:none;box-sizing:border-box}
.encounter-met-label{color:#7d8a68;font-weight:700;padding:12px}.nearby-god>p{max-width:360px;color:#817563;font-size:14px;line-height:1.9;margin:0 0 6px}
.encounter-locate-row{margin:22px auto 0;max-width:480px}.encounter-actions{display:flex;justify-content:center;gap:12px}.encounter-actions.paired{display:grid;grid-template-columns:1fr 1fr}
.encounter-actions .secondary{display:flex;justify-content:center;align-items:center;min-width:0;min-height:50px;margin:0;padding:12px 10px;border:1px solid #cdbca5;border-radius:14px;background:#fffaf1;color:#80674f;font-size:14px;font-weight:600;text-decoration:none;line-height:1.5;box-shadow:none;box-sizing:border-box}
.nearby-gods button:disabled{opacity:.45;cursor:default}.encounter-locate-row p{font-size:12px;color:#9b6450;margin:12px 0 0;line-height:1.8}.encounter-locate-row p:empty{display:none}
.encounter-collection-heading{display:flex;align-items:center;justify-content:space-between;gap:15px}.encounter-collection h2{font-size:22px;margin:0 0 5px}.encounter-collection-heading p{margin:0;color:#948673;font-size:13px}.encounter-collection-heading>strong{font-size:32px;white-space:nowrap;color:#7c896a}.encounter-collection-heading>strong small{font-size:13px;font-weight:400;color:#9c8f7d}
.encounter-progress{appearance:none;width:100%;height:8px;display:block;margin:20px 0 24px;border:0;border-radius:8px;overflow:hidden;background:#eee9df}.encounter-progress::-webkit-progress-bar{background:#eee9df}.encounter-progress::-webkit-progress-value{background:#9aa785;border-radius:8px}.encounter-progress::-moz-progress-bar{background:#9aa785}
.encounter-filter{display:block;max-width:350px;margin:0 0 20px}.encounter-filter input{width:100%;padding:10px 14px;border:1px solid #e4ded3;border-radius:12px;background:transparent;font:inherit;font-size:14px}
.encounter-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(95px,1fr));gap:22px 12px}.encounter-tile{color:#9c968b;text-decoration:none;text-align:center;font-size:11px;line-height:1.6;overflow-wrap:anywhere}.encounter-thumb{display:block;position:relative;height:100px;margin:0 auto 7px;max-width:100px}.encounter-thumb .spirit-character{display:block;width:100%;height:100%;object-fit:contain;background:transparent;margin:0;filter:brightness(0);opacity:.21;transition:filter .35s,opacity .35s}.encounter-tile.met{color:#685945}.encounter-tile.met .spirit-character{filter:none;opacity:1}.encounter-tile.met .deity-silhouette{filter:sepia(1) saturate(.7);opacity:1}
.encounter-check{position:absolute;right:0;bottom:0;background:#8c9b78;color:white;border-radius:50%;width:20px;height:20px;font-size:12px;display:grid;place-items:center;border:2px solid var(--paper)}.encounter-complete{text-align:center;color:#8b7958;background:#f6edce;border-radius:14px;padding:15px}.encounter-grid .encounter-tile:focus-visible{outline:2px solid #a7b194;outline-offset:5px;border-radius:8px}
@media(max-width:600px){.encounter-invitation{padding:24px 14px;gap:12px}.encounter-invitation-art{height:130px;width:260px;max-width:100%}.encounter-invitation-art .spirit-character{width:140px;height:140px}.encounter-invitation strong{font-size:24px}.encounter-invitation-copy>span{font-size:11px}.encounter-invitation-copy{gap:10px}.encounter-invitation b{margin-top:8px}.nearby-gods{padding:24px 16px}.encounter-heading h1{font-size:25px}.nearby-god-art,.encounter-location-art{height:200px}.nearby-god-art .spirit-character,.encounter-location-art .spirit-character{width:200px;height:200px}.nearby-god-name{font-size:25px}.nearby-shrine a{font-size:21px}.encounter-actions{gap:8px}.encounter-actions .secondary{font-size:12px;padding:12px 6px;white-space:nowrap}.encounter-collection h2{font-size:20px}.encounter-collection-heading p{font-size:11px}.encounter-collection-heading>strong{font-size:27px}.encounter-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:19px 8px}.encounter-thumb{height:78px;max-width:78px}.encounter-tile{font-size:10px}.encounter-check{width:17px;height:17px;font-size:10px}}
/* Discovery stays in a native modal; the collection behind it is stable. */
.encounter-dialog.nearby-gods{position:fixed;inset:0;margin:auto;width:min(520px,calc(100% - 32px));max-width:520px;max-height:calc(100dvh - 32px);padding:28px 24px;overflow:auto;overscroll-behavior:contain;box-sizing:border-box;border:1px solid var(--ui-border);border-radius:var(--ui-dialog-radius);background:var(--paper);box-shadow:var(--ui-shadow)}
.encounter-dialog::backdrop{background:#443e3660;backdrop-filter:blur(4px)}
.encounter-dialog h2{font-size:19px;color:#927b63;margin:-8px 0 18px;padding:0 42px;min-height:44px;display:flex;align-items:center;justify-content:center;outline:0}
.encounter-dialog .nearby-god-art{height:210px}.encounter-dialog .nearby-god-art .spirit-character{height:210px;width:210px;position:relative;z-index:1}.encounter-dialog .nearby-reading{margin-bottom:14px}.encounter-dialog .nearby-shrine{margin-bottom:16px}.encounter-dialog .encounter-locate-row{margin-top:16px}
.encounter-found{font-size:12px;color:#a38b62;letter-spacing:.1em;margin:0 0 4px}.encounter-empty{padding:38px 8px}.encounter-empty p{font-size:14px;line-height:1.9;color:#8b7863;margin:0 0 25px}
.encounter-searching{padding:24px 0 36px}.encounter-search-stage{position:relative;width:min(280px,100%);height:260px;margin:auto;background:url('/static/encounter-japan.svg') center/contain no-repeat;background-blend-mode:screen;background-color:#fffcf5c9}
.encounter-search-spirit{position:absolute;inset:0;display:grid;place-items:center;opacity:0;animation:encounter-search-fade 2.7s ease-in-out infinite;animation-delay:calc(var(--phase)*.9s)}
.encounter-search-spirit .spirit-character{width:230px;height:230px;object-fit:contain;margin:0;background:transparent;filter:grayscale(1) brightness(.55);opacity:.6}
.encounter-searching p{font-size:14px;color:#927b63;letter-spacing:.05em;margin:25px 0 0}.encounter-search-orbit{position:absolute;inset:55px;border:2px solid #dbd2c4;border-top-color:#a38b62;border-radius:50%;animation:encounter-orbit 1.4s linear infinite}
.encounter-aura{position:absolute;inset:0;border-radius:50%;background:radial-gradient(ellipse,#f7dda8a8 0,#f9e9c660 40%,transparent 70%);opacity:0;pointer-events:none}
.encounter-reveal .encounter-aura{animation:encounter-glow 1.4s ease-out forwards}.encounter-reveal .nearby-god-art>.spirit-character{animation:encounter-arrive .9s cubic-bezier(.2,.7,.3,1) both}.encounter-reveal .nearby-god-copy{animation:encounter-copy .6s .35s ease-out both}
.encounter-sparks{position:absolute;inset:0;pointer-events:none}.encounter-sparks i{position:absolute;top:50%;left:50%;width:5px;height:5px;border-radius:50%;background:#d6b576;opacity:0;transform:rotate(calc(var(--spark)*45deg)) translateY(-65px)}
.encounter-reveal .encounter-sparks i{animation:encounter-spark 1.1s .15s ease-out both}
@keyframes encounter-search-fade{0%{opacity:0;transform:translateY(8px) scale(.96)}12%,24%{opacity:1;transform:translateY(0) scale(1)}36%,100%{opacity:0;transform:translateY(-6px) scale(1.02)}}
@keyframes encounter-arrive{from{opacity:0;transform:translateY(12px) scale(.9);filter:brightness(1.6)}to{opacity:1;transform:none;filter:none}}
@keyframes encounter-glow{0%{opacity:0;transform:scale(.5)}45%{opacity:1;transform:scale(1.15)}100%{opacity:.65;transform:scale(1)}}
@keyframes encounter-copy{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes encounter-spark{0%{opacity:0;transform:rotate(calc(var(--spark)*45deg)) translateY(-65px) scale(.5)}35%{opacity:1}100%{opacity:0;transform:rotate(calc(var(--spark)*45deg)) translateY(-122px) scale(0)}}
@keyframes encounter-orbit{to{transform:rotate(360deg)}}
@media(max-width:600px){.encounter-dialog.nearby-gods{padding:24px 18px}.encounter-dialog h2{font-size:17px}.encounter-dialog .nearby-god-art,.encounter-dialog .nearby-god-art .spirit-character{height:180px}.encounter-dialog .nearby-god-name{font-size:24px}.encounter-dialog .nearby-shrine{padding:12px 8px}}
@media(prefers-reduced-motion:reduce){.encounter-search-spirit{animation:none;opacity:0}.encounter-search-spirit:first-child{opacity:1}.encounter-reveal .encounter-aura,.encounter-reveal .nearby-god-art>.spirit-character,.encounter-reveal .nearby-god-copy,.encounter-reveal .encounter-sparks i,.encounter-search-orbit{animation:none}.encounter-reveal .encounter-aura{opacity:.4}}
/* Shared shrine photographs and first encounters */
.encounter-new{position:absolute;right:5%;top:5%;z-index:3;color:#e45748;font-size:18px;font-weight:800;letter-spacing:.06em;transform:rotate(8deg)}
.shrine-header-photo:has(.shrine-gallery){aspect-ratio:auto;min-height:0;background:transparent;overflow:visible;padding-bottom:0}
.shrine-gallery{position:relative;min-height:160px}.gallery-track{display:grid;grid-auto-flow:column;grid-template-rows:repeat(2,minmax(0,1fr));grid-auto-columns:60% 38%;gap:10px;height:360px;overflow-x:auto;scroll-snap-type:x proximity;scrollbar-width:thin;overscroll-behavior-x:contain;padding-bottom:8px}
.gallery-track:empty{display:none}.gallery-tile{position:relative;display:block;border:0;padding:0;border-radius:18px;overflow:hidden;background:#eae2d5;min-width:0;min-height:0;scroll-snap-align:start;cursor:zoom-in}.gallery-tile:nth-of-type(3n+1){grid-row:span 2}.gallery-tile img{display:block;width:100%;height:100%;object-fit:cover}.gallery-track:has(.gallery-tile:only-child){grid-template-columns:100%}.gallery-tile:only-child{grid-column:auto}.gallery-more{grid-row:span 2;border:1px solid #d9cdbb;border-radius:18px;background:#f7f3ea;color:#816b55}.photo-private{position:absolute;bottom:8px;left:8px;padding:4px 8px;background:#fffef2e8;border-radius:8px;color:#816b55;font-size:11px}.gallery-error:empty{display:none}
.photo-visibility{border:0;padding:12px 0;margin:8px 0;display:flex;flex-wrap:wrap;gap:20px}.photo-visibility legend{font-size:13px;color:#816b55;margin-bottom:8px}.photo-visibility label{display:flex;gap:7px;align-items:center;font-size:14px}.photo-visibility input{accent-color:#9a6d4d;width:18px;height:18px}
.review-photo-add{display:flex;position:relative;align-items:center;justify-content:center;width:122px;height:96px;margin:4px 0 20px;overflow:hidden;border:1px dashed #baa68c;border-radius:12px;background:#f4efe5;color:#816b55;font-size:12px}.review-photo-add img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}.review-photo-add span{position:relative;background:#fffaf0e8;padding:6px;border-radius:6px}
.photo-lightbox{width:min(1000px,calc(100vw - 24px));max-width:none;border:0;border-radius:22px;background:var(--paper);padding:60px 16px 16px;box-sizing:border-box;max-height:95dvh}.photo-lightbox::backdrop{background:#302d29c9}.photo-lightbox-track{display:flex;overflow-x:auto;scroll-snap-type:x mandatory;overscroll-behavior-x:contain}.photo-lightbox figure{flex:0 0 100%;min-width:0;margin:0;scroll-snap-align:center;text-align:center}.photo-lightbox img{width:100%;height:min(65dvh,650px);object-fit:contain}.photo-lightbox figcaption{padding:12px;color:#816b55;font-size:12px}.photo-lightbox figcaption button{background:none;border:1px solid #d9cdbb;border-radius:8px;padding:8px 12px;color:inherit}.photo-lightbox-nav{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:12px;color:#816b55}.photo-lightbox-nav button{border:1px solid #d9cdbb;border-radius:50%;background:none;width:40px;height:40px;color:inherit}
@media(max-width:600px){.gallery-track{height:280px;grid-auto-columns:62% 42%;gap:8px}.gallery-tile{border-radius:14px}.gallery-tile:only-child{grid-column:auto}.encounter-new{font-size:16px}.photo-lightbox{padding-top:54px}}
/* The scroll container must not acquire the browser's blue focus rectangle. */
.gallery-track,.gallery-track:is(:focus,:focus-visible){outline:none;box-shadow:none;-webkit-tap-highlight-color:transparent}
.gallery-tile{-webkit-tap-highlight-color:transparent}
.gallery-tile:focus:not(:focus-visible){outline:none;box-shadow:none}
.gallery-tile:focus-visible{outline:none;box-shadow:inset 0 0 0 2px var(--ui-brown)}

.gallery-placeholder{height:360px;border-radius:18px;background:#eee9df}@media(max-width:600px){.gallery-placeholder{height:280px}}
/* Dialog surfaces do not need the browser's focus outline on open/return. */
dialog,dialog:is(:focus,:focus-visible){outline:none}
dialog :is(button,input,label){-webkit-tap-highlight-color:transparent}
.review-dialog{width:min(480px,calc(100vw - 28px));padding:24px;scrollbar-width:thin}
.review-dialog-heading{margin-bottom:20px}
.review-form{display:grid;grid-template-columns:92px minmax(0,1fr);column-gap:20px;row-gap:20px;align-items:center}
.review-form>.review-photo-add{width:92px;height:92px;margin:0;border:1px dashed #baa68c;border-radius:14px;background:#f2ede4;box-shadow:none}
.review-photo-add span{padding:0;background:none;font-size:11px;white-space:nowrap}
.review-photo-add:has(img) span{align-self:flex-end;width:100%;padding:6px 2px;background:#fffaf0e8;border-radius:0}
.review-form>.review-rating{min-width:0;margin:0;padding:0}
.review-rating legend{font-size:12px;margin-bottom:8px}
.review-rating>div{gap:4px;line-height:1.2}
.review-rating label{font-size:34px;line-height:1.2}
.review-rating output{margin-top:8px;line-height:1.5;font-size:12px}
.review-form>.review-inputs,.review-form>.review-source-note,.review-form>.review-error,.review-form>.review-save{grid-column:1/-1;margin:0}
.review-inputs{display:grid;gap:16px;padding-top:18px;border-top:1px solid #e8dfd2}
.review-inputs fieldset{min-width:0;margin:0}
.review-inputs legend{font-size:12px;line-height:1.5;margin-bottom:7px}
.review-inputs fieldset>div{gap:8px}
.review-inputs span{padding:10px 2px;font-size:12px;line-height:1.6;border-radius:11px}
.review-source-note{font-size:10px;line-height:1.7}
.review-error:empty{display:none}
.review-form>.review-save{min-height:48px;border-radius:13px}
.review-dialog input:focus{outline:none}
.review-photo-add:focus:not(:focus-visible){outline:none}
@media(max-width:380px){.review-dialog{padding:20px 16px}.review-form{grid-template-columns:80px minmax(0,1fr);column-gap:12px;row-gap:18px}.review-form>.review-photo-add{width:80px;height:84px}.review-rating label{font-size:28px}.review-rating>div{gap:3px}}
/* Vector hearts keep their selected red fill on iOS and while saving. */
.favorite-heart{display:inline-block;width:24px;height:24px;vertical-align:middle;flex-shrink:0;pointer-events:none}
.heart:has(.favorite-heart){display:inline-flex;align-items:center;justify-content:center;padding:0}
.heart .favorite-heart{width:24px;height:24px}
:is(.heart,.shrine-like)[aria-pressed="true"] .favorite-heart{fill:#e96d60;stroke:#e96d60}
:is(.heart,.shrine-like)[aria-pressed="false"] .favorite-heart{fill:none;stroke:#e96d60}
:is(.heart,.shrine-like):disabled:has(.favorite-heart){opacity:1}

/* Shared deity cards and native sharing controls. */
.home-introduction{max-width:700px;margin:24px auto 40px;padding:0 16px;text-align:center;color:var(--muted,#897762);font-size:clamp(15px,2vw,18px);line-height:2;}
.deity-share-button{display:inline-flex;align-items:center;justify-content:center;gap:8px;vertical-align:middle;margin:8px 8px 8px 0;}
.deity-share-button svg{width:20px;height:20px;flex:none;}
.deity-share-dialog{width:min(460px,calc(100vw - 32px));max-height:calc(100dvh - 32px);overflow:auto;box-sizing:border-box;border:1px solid #ded7c9;border-radius:28px;padding:24px;background:#fffdf7;color:#303a37;outline:none;}
.deity-share-dialog::backdrop{background:rgba(42,38,30,.42);}
.deity-share-dialog h2{font-size:20px;text-align:center;margin:4px 40px 20px;}
.deity-share-preview img{display:block;width:100%;max-height:48dvh;object-fit:contain;border-radius:16px;}
.deity-share-dialog .share-status{font-size:13px;line-height:1.7;text-align:center;color:#8b7964;margin:16px 0;}
.deity-share-dialog .share-native{width:100%;}
.share-fallback{display:flex;justify-content:center;gap:10px;margin-top:12px;flex-wrap:wrap;}
.share-fallback .secondary{flex:1;white-space:nowrap;text-align:center;padding:12px 10px;font-size:14px;}
.deity-share-dialog [hidden]{display:none!important;}
.share-link{width:100%;box-sizing:border-box;margin-top:12px;font-size:16px;}
/* Administrator workspace */
.cms{max-width:1120px;margin:0 auto}.cms-heading{position:static;display:flex;align-items:center;justify-content:space-between;gap:20px;background:none;padding:20px 0}.cms-heading h1{margin:4px 0;font-size:30px}.cms-kicker{color:#df705f;letter-spacing:.15em;font-weight:700}.cms-nav{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0 28px}.cms-nav button{padding:10px 16px}.cms-content{background:#fffdf7;border:1px solid #e4dfd3;border-radius:20px;padding:24px}.cms-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:16px 0;flex-wrap:wrap}.cms-toolbar h2{margin:0}.cms h2 small{font-size:14px;font-weight:400}.cms-filters{display:flex;gap:8px;flex-wrap:wrap;margin:20px 0}.cms-filters input{flex:2;min-width:160px}.cms-filters select{flex:1;min-width:110px}.cms input:not([type=checkbox]),.cms select,.cms textarea{box-sizing:border-box;border:1px solid #d7ccba;border-radius:10px;background:white;padding:12px;color:#3a3c36;font:inherit;max-width:100%}.cms textarea{resize:vertical;line-height:1.7}.cms-list{display:grid}.cms-list>button,.cms-list>div{display:flex;align-items:center;gap:16px;justify-content:space-between;text-align:left;padding:18px 8px;border:0;border-bottom:1px solid #e9e4d9;border-radius:0;background:transparent;color:inherit;min-width:0}.cms-list>button>span:first-child,.cms-list>div>span{flex:1;min-width:0;overflow-wrap:anywhere}.cms-list small{display:block;font-size:12px;color:#8b7b66;margin-top:5px}.cms-fields{display:grid;grid-template-columns:1fr 1fr;gap:18px}.cms-fields label:has(textarea){grid-column:1/-1}.cms-editor>label,.cms-fields label,.cms-course label{display:grid;gap:8px;margin:12px 0;color:#7f6b55}.cms-editor fieldset{border:1px solid #e6dfd2;border-radius:14px;margin:24px 0;padding:18px}.cms-editor legend{padding:0 8px;color:#7f6b55}.cms-editor input[type=checkbox]{accent-color:#9d7453;width:18px;height:18px;margin-right:8px}.cms-checks{display:flex;gap:16px;flex-wrap:wrap}.cms-relations{max-height:240px;overflow:auto;display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:16px}.cms-relations [hidden]{display:none}.cms-media{display:flex;gap:12px;flex-wrap:wrap}.cms-media>div{display:grid;gap:8px}.cms-media img{width:140px;height:140px;object-fit:contain;background:#f1ebdf;border-radius:12px}.cms-savebar{position:sticky;bottom:12px;display:flex;gap:10px;flex-wrap:wrap;background:#fffdf7;padding:16px 0;border-top:1px solid #e1d8c8;z-index:2}.cms-danger{color:#b95345!important}.cms-preview{box-sizing:border-box;width:min(820px,calc(100vw - 24px));max-height:88dvh;overflow:auto;border:1px solid #ddd2bf;border-radius:24px;padding:28px;background:#fffdf7;outline:none}.cms-preview::backdrop{background:#302a2266}.cms-preview h2{padding-right:40px}.cms-preview-card{padding:20px;background:#f1ecdf;border-radius:16px}.cms-diff section{padding:16px 0;border-bottom:1px solid #ddd2bf}.cms-diff section>div{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:10px}.cms-diff del,.cms-diff ins{display:block;white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;text-decoration:none;padding:12px;border-radius:8px}.cms-diff del{background:#f8e9e4}.cms-diff ins{background:#e9eddf}.cms-preview [data-confirm]{margin-top:24px}.cms-history{margin-top:36px}.cms-pair{display:flex;gap:12px;margin:12px 0}.cms-pair input{width:50%}.cms button:focus-visible,.cms a:focus-visible{outline:2px solid #9d7453;outline-offset:3px}.cms-course textarea{font-size:13px}.cms-editor select[multiple]{min-height:120px;width:100%}
@media(max-width:640px){.cms-content{padding:16px}.cms-fields,.cms-relations{grid-template-columns:1fr}.cms-nav{gap:6px}.cms-nav button{font-size:13px;padding:9px 12px}.cms-heading h1{font-size:25px}.cms-list .tag{font-size:11px}.cms-savebar button{flex:1;font-size:14px;padding:12px 8px}.cms-diff section>div{grid-template-columns:1fr}.cms-preview{padding:20px}.cms-pair{flex-direction:column}.cms-pair input{width:100%}}
.cms-post-photo{display:block;width:140px;height:110px;object-fit:cover;border-radius:10px;margin-top:8px}
.dinjya-ad{margin:32px 0;min-height:300px;contain:layout;overflow:hidden;text-align:center;color:#88745f}.dinjya-ad small{display:block;margin-bottom:12px}.dinjya-ad[hidden]{display:none}
.legal-footer{display:flex;justify-content:center;flex-wrap:wrap;gap:16px 28px;padding:32px 0;color:#806b57;font-size:13px}.legal-document{max-width:800px;margin:24px auto;line-height:1.9}.legal-document h2{font-size:20px;margin-top:32px}.legal-document form label{display:flex;align-items:flex-start;gap:12px;margin:24px 0}.legal-document input[type=checkbox]{flex:none;width:22px;height:22px;margin-top:5px}.legal-draft-note{color:#806b57}.legal-document button:disabled{opacity:.45}
.shrine-detail-header .shrine-header-photo{width:100vw;max-width:none;margin-left:calc(50% - 50vw);border-radius:0}.shrine-detail-header .shrine-gallery{border-radius:0}.shrine-detail-header .shrine-gallery img{border-radius:0}

/* Keep navigation visible; only unfinished content pulses. */

.route-skeleton .skeleton-heading,.route-skeleton .skeleton-search,.route-skeleton .skeleton-picture,.route-skeleton .skeleton-line{background:#e7e7e5}
@media(prefers-reduced-motion:reduce){.route-skeleton *{animation:none!important}}

.encounter-actions .encounter-start{width:100%;min-height:72px;padding:20px 24px;font-size:clamp(18px,4.8vw,22px);border-radius:40px;line-height:1.5}

/* Editorial news shares the warm paper and brown typography of JINJYA. */
.home-news{margin:32px 0 42px}.home-news .section-head{display:flex;align-items:center;justify-content:space-between;gap:16px}.news-more{color:#88715b;font-size:14px;white-space:nowrap;text-underline-offset:4px}
.news-list{border-top:1px solid #e1d9ce}.news-card{display:grid;grid-template-columns:minmax(0,1fr);align-items:center;gap:20px;padding:24px 4px;border-bottom:1px solid #e1d9ce;text-decoration:none;color:inherit}.news-card.has-image{grid-template-columns:120px minmax(0,1fr)}.news-card img{width:120px;aspect-ratio:3/2;object-fit:cover;border-radius:12px}.news-card time,.news-article time{font-size:13px;color:#927b63;font-variant-numeric:tabular-nums}.news-card h3{font-size:18px;line-height:1.6;margin:6px 0;overflow-wrap:anywhere}.news-card p{font-size:14px;color:#8c8174;margin:4px 0 0;line-height:1.7;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.news-arrow{color:#9c6d50}.news-card:hover h3{text-decoration:underline;text-underline-offset:4px}.news-card:focus-visible{outline:2px solid #9c6d50;outline-offset:3px}
.news-article{max-width:760px;margin:30px auto 60px}.news-article h1{font-size:clamp(24px,4vw,36px);line-height:1.6;margin:12px 0 28px;overflow-wrap:anywhere}.news-article>img{display:block;width:100%;max-height:560px;object-fit:contain;border-radius:16px;margin:0 0 32px}.news-body{white-space:pre-wrap;overflow-wrap:anywhere;line-height:2;font-size:16px}.cms-preview .news-article{text-align:left;margin-bottom:24px}
@media(max-width:600px){.home-news{margin:24px 0 32px}.news-card{padding:18px 0;gap:12px}.news-card.has-image{grid-template-columns:80px minmax(0,1fr)}.news-card img{width:80px}.news-card h3{font-size:16px}.news-card p{font-size:12px}.news-card time{font-size:12px}.news-more{font-size:12px}.news-body{font-size:15px}}

.news-title{font-family:inherit;font-weight:900;color:var(--coral);letter-spacing:.07em;line-height:1.15}
.news-body figure{margin:28px 0;white-space:normal}.news-body figure img{display:block;width:100%;max-height:680px;object-fit:contain;border-radius:14px}
.news-insert{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin:12px 0 20px}.news-upload-status{color:#88715b;font-size:14px}

.encounter-heading h2{margin:8px 0 20px;font-size:28px;color:#705641}
.encounter-collection-button{margin:20px auto 28px}
#encounter-list[hidden]{display:none}
@media(max-width:600px){.encounter-heading h2{font-size:25px}}

/* Discovery controls and collection progress share one card. */
.encounter-discovery-card .encounter-start{background:var(--coral)}
.encounter-card-collection{margin:30px 0 0;padding-top:26px;border-top:1px solid #e4d8c5;text-align:left}
.encounter-card-collection .encounter-collection-heading h2{font-size:clamp(17px,4.5vw,22px);margin:0}
.encounter-card-collection .encounter-collection-button{margin:12px 0 0;width:100%;min-height:58px}
.encounter-collection-page{margin:20px auto 40px;max-width:900px}
.home-news .news-card img{display:block;width:100%;height:auto;aspect-ratio:1/1;object-fit:cover;align-self:start}
.home-news .news-card{align-items:start}
@media(max-width:600px){.encounter-card-collection{margin-top:24px;padding-top:20px}.encounter-card-collection .encounter-collection-heading{gap:8px}.encounter-card-collection .encounter-collection-heading>strong{font-size:25px}}

/* Route placeholders follow the actual page geometry; no temporary text headings. */
.route-skeleton{padding:0;overflow:visible;min-height:70vh}
.loading-part{background:#e7e7e5;border-radius:8px;animation:soft-pulse 1.2s ease-in-out infinite alternate;max-width:100%}
.loading-text{height:16px;width:100%;margin:14px 0}
.loading-short{height:13px;width:30%;margin:12px 0}
.loading-title{height:40px;width:55%;margin:12px 0 20px}
.loading-subtitle{height:16px;width:65%;margin:16px 0 24px}
.loading-name{height:22px;width:45%;margin:8px 0}
.loading-rating{height:18px;width:110px;margin:12px 0}
.loading-search{height:60px;width:100%;margin:24px 0}
.loading-filters{display:flex;gap:12px;margin:20px 0;flex-wrap:wrap}
.loading-control{height:46px;flex:1;min-width:100px}
.loading-heart{width:30px;height:30px;border-radius:50%}
.loading-button{height:52px;width:100%;border-radius:28px;margin:20px 0}
.loading-portrait{width:100%;aspect-ratio:1/1}
.loading-content-card{padding:20px}
.loading-content-card .loading-portrait{margin-bottom:24px}
.loading-cover{width:100%;aspect-ratio:16/7;min-height:160px}
.shrine-detail-header>.loading-cover{width:100vw;max-width:none;margin-left:calc(50% - 50vw);border-radius:0}
.loading-two-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.loading-progress{height:8px;width:100%;border-radius:8px;margin:26px 0}
.loading-discovery{display:block;text-align:center}
.loading-discovery>.loading-part{margin-left:auto;margin-right:auto}
.loading-discovery>.loading-button{height:64px;margin-top:30px}
.loading-discovery .encounter-card-collection .loading-button{width:84%;margin-left:auto;margin-right:auto}
.loading-collection{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:16px;margin-top:24px}
.loading-deity-hero>.loading-portrait{width:220px;flex-shrink:0}
.loading-deity-hero>div:last-child{flex:1}
.loading-map-surface{min-height:calc(100dvh - 100px);background:#e7e7e5;padding:20px}
.loading-map-surface .loading-part{background:#f5f5f3}
.route-skeleton .hero-copy{width:min(440px,100%)}
.route-skeleton .hero-copy .loading-title{width:100%}
.loading-hero-characters{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;width:min(520px,100%)}
.loading-news-row{display:grid;grid-template-columns:120px 1fr;gap:20px;margin:24px 0}
.loading-square{width:100%;aspect-ratio:1}
.loading-invitation{display:grid;grid-template-columns:1fr 1fr;align-items:center;gap:32px;padding:32px;margin:32px 0}
@media(max-width:760px){
 .loading-title{height:32px;width:70%}
 .loading-collection{grid-template-columns:repeat(3,minmax(0,1fr))}
 .loading-deity-hero{flex-direction:column;align-items:center}
 .loading-deity-hero>.loading-portrait{width:190px}
 .loading-deity-hero>div:last-child{width:100%}
 .loading-news-row{grid-template-columns:90px 1fr;gap:16px}
 .loading-invitation{padding:20px;gap:20px}
}
@media(prefers-reduced-motion:reduce){.loading-part{animation:none}}

/* Separate shrine photography from goshuin, keeping the entire stamp visible. */
.goshuin-section{margin:24px 0 8px;padding:0}
.goshuin-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:12px}
.goshuin-heading h2{font-size:18px;margin:0;color:#816b55}
.goshuin-heading .secondary{font-size:12px;padding:8px 14px;min-height:38px}
.goshuin-gallery{min-height:0}
.goshuin-gallery .gallery-track,.goshuin-gallery .gallery-track:has(.gallery-tile:only-child){display:flex;gap:12px;height:auto;padding:0 0 8px;grid-template-columns:none}
.goshuin-gallery .gallery-tile{display:flex;align-items:center;justify-content:center;flex:0 0 112px;width:112px;height:144px;border:1px solid #e7dfd2;border-radius:12px;background:#f4f0e8;padding:5px}
.goshuin-gallery .gallery-tile img{width:auto;height:auto;max-width:100%;max-height:100%;flex:none;object-fit:contain;border-radius:7px}
.goshuin-gallery .gallery-more{flex:0 0 100px}
.goshuin-gallery .gallery-placeholder{height:144px;min-height:0}
.goshuin-photo-empty{padding:18px 0;color:#948673;font-size:12px}
.review-form .review-photo-uploads{grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr;gap:12px;width:100%}
.review-photo-uploads .review-photo-add{width:100%;height:126px;margin:0;flex-direction:column;gap:8px;border-radius:14px}
.review-photo-uploads .review-photo-add strong{position:relative;font-size:13px;font-weight:600}
.review-photo-uploads .review-photo-add span{font-size:12px}
.review-photo-uploads .review-photo-add:has(img){justify-content:flex-end;gap:0;padding:0}
.review-photo-uploads .review-photo-add:has(img) strong,.review-photo-uploads .review-photo-add:has(img) span{width:100%;background:#fffaf0ed;text-align:center;padding:4px}
.review-photo-uploads [data-photo-category=goshuin] img{object-fit:contain}
.review-form>.review-rating{grid-column:1/-1;text-align:center;justify-self:center;padding:6px 0}
@media(max-width:380px){.review-photo-uploads .review-photo-add{height:110px}.goshuin-gallery .gallery-tile{flex-basis:96px;width:96px;height:128px}}

/* Shrine detail: name first, consistent photo actions and a clear reading rhythm. */
.shrine-detail-refined{margin-top:16px}
.shrine-detail-refined .shrine-detail-heading{padding:0 0 24px;margin:0}
.shrine-detail-refined .shrine-detail-heading h1{font-size:clamp(28px,4.5vw,40px);line-height:1.4;margin:0 0 8px;letter-spacing:.03em;overflow-wrap:anywhere}
.shrine-detail-refined .shrine-location{margin:16px 0 0;font-size:14px;line-height:1.8;color:var(--muted,#8b8072)}
.shrine-detail-refined .shrine-header-photo{height:auto;aspect-ratio:auto;min-height:0;margin-bottom:0;overflow:hidden}
.shrine-detail-refined .shrine-header-photo .gallery-track{height:clamp(260px,42vw,480px);padding-bottom:0;gap:8px}
.shrine-detail-refined .shrine-header-photo .gallery-tile{border-radius:0}
.shrine-photo-toolbar{display:flex;justify-content:flex-end;padding:14px 0 0}
.shrine-detail-refined .photo-edit{position:static;display:inline-flex;gap:8px;min-height:44px;padding:10px 16px;border:1px solid var(--ui-border,#ded4c5);border-radius:var(--ui-radius,14px);background:var(--paper);color:#806c54;font-size:13px;font-weight:600;line-height:1.5;box-shadow:none;white-space:nowrap}
.shrine-detail-refined .photo-edit svg{width:20px;height:20px}
.shrine-detail-refined .photo-edit:hover{background:#f2ece2}
.shrine-detail-refined .shrine-review-summary{margin:20px 0 0;padding:24px 0;border-top:0}
.shrine-detail-refined .shrine-detail-actions{gap:12px;margin-top:24px}
.shrine-detail-refined .shrine-detail-actions>*{min-height:50px;font-size:14px;display:flex;align-items:center;justify-content:center;padding:12px}
.shrine-detail-refined .goshuin-section{margin:36px 0 0;padding:28px 0;border:0}
.shrine-detail-refined .goshuin-heading{gap:12px;margin-bottom:18px}
.shrine-detail-refined .goshuin-heading h2{color:var(--ink);font-size:19px}
.shrine-detail-refined .goshuin-photo-empty{margin:0;padding:20px;text-align:center;background:#f4f0e8;border-radius:14px}
.shrine-detail-refined+.detail-grid{margin-top:12px;gap:40px}
.shrine-detail-refined+.detail-grid .panel{padding:24px 0}
.shrine-detail-refined+.detail-grid .panel p{line-height:1.95}
@media(max-width:760px){.shrine-detail-refined .shrine-detail-heading{padding-bottom:20px}.shrine-detail-refined .shrine-detail-actions{gap:10px}.shrine-detail-refined .goshuin-section{margin-top:28px;padding:24px 0}.shrine-detail-refined+.detail-grid{gap:0}.shrine-detail-refined .review-facilities{gap:4px}}

/* Compact photo action, without a separate tall toolbar row. */
.shrine-detail-refined .shrine-photo-toolbar{padding:0;min-height:36px;align-items:center}
.shrine-detail-refined .shrine-photo-toolbar .photo-edit{min-height:36px;padding:5px 2px;gap:5px;border:0;border-radius:6px;background:transparent;font-size:11px;font-weight:500;line-height:1.4}
.shrine-detail-refined .shrine-photo-toolbar .photo-edit svg{width:16px;height:16px}
.shrine-detail-refined .shrine-photo-toolbar .photo-edit:hover{color:var(--coral)}
.shrine-detail-refined .shrine-review-summary{margin-top:0;padding-top:10px;padding-bottom:16px}
.shrine-detail-refined .shrine-detail-heading{padding-bottom:14px}
.shrine-detail-refined .shrine-detail-actions{margin-top:16px}
.shrine-photo-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:0;width:100%;margin:16px 0 0}
.shrine-photo-tile{position:relative;display:block;aspect-ratio:1;min-width:0;overflow:hidden;background:#e8e4dc;border:0;border-radius:0}
.shrine-photo-tile .shrine-grid-photo{display:block;width:100%;height:100%;object-fit:cover;border-radius:0;margin:0}
.shrine-photo-tile:focus-visible{outline:2px solid #806c54;outline-offset:-3px}
@media(max-width:760px){.shrine-photo-grid{grid-template-columns:repeat(3,minmax(0,1fr));width:100vw;margin-left:calc(50% - 50vw)}}

/* The upload action lives alongside the photos, in the fifth slot. */
.gallery-add-photo{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;min-width:0;min-height:0;padding:16px;border:0;border-radius:18px;background:linear-gradient(145deg,#a28b71,#7e6954);color:#fffaf1;font:inherit;font-size:14px;font-weight:600;cursor:pointer;scroll-snap-align:start}
.gallery-add-icon{display:grid;place-items:center;width:52px;height:52px;border:1px solid #fffaf199;border-radius:50%}
.gallery-add-icon svg{width:30px;height:30px;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.gallery-add-photo:hover{background:linear-gradient(145deg,#947c63,#705a45)}
.gallery-add-photo:focus-visible{outline:2px solid #fffaf1;outline-offset:-5px}
.gallery-add-photo:only-child{grid-row:span 2;grid-column:1/-1}
.shrine-detail-refined .shrine-header-photo .gallery-add-photo{border-radius:0}
.shrine-detail-refined .shrine-review-summary{margin-top:0;padding-top:12px;padding-bottom:14px}
.shrine-detail-refined .goshuin-heading .photo-edit{min-height:36px;padding:5px 2px;gap:5px;border:0;border-radius:6px;background:transparent;font-size:11px;font-weight:500;line-height:1.4}
.shrine-detail-refined .goshuin-heading .photo-edit svg{width:16px;height:16px}
.shrine-detail-refined .goshuin-heading .photo-edit:hover{color:var(--coral)}
@media(max-width:600px){.gallery-add-photo{gap:8px;padding:12px;font-size:12px}.gallery-add-icon{width:44px;height:44px}.gallery-add-icon svg{width:25px;height:25px}}
.gallery-track:has(.gallery-add-photo:only-child){grid-template-columns:1fr;grid-auto-columns:100%}
/* Shrine first view: compact title, photos and rating above visit actions. */
main:has(>.shrine-detail-refined){padding-top:10px}
.shrine-detail-refined{margin-top:6px}
.shrine-detail-refined .shrine-detail-heading{padding-bottom:14px}
.shrine-detail-refined .shrine-detail-heading h1{font-size:clamp(25px,3.5vw,34px);line-height:1.3;margin-bottom:3px}
.shrine-detail-refined .shrine-detail-heading .name-reading{margin:2px 0 4px;line-height:1.4}
.shrine-detail-refined .shrine-location{margin:4px 0 0;font-size:12px;line-height:1.5}
.shrine-detail-refined .shrine-header-photo{border-radius:16px;background:transparent}
.shrine-detail-refined .shrine-header-photo .gallery-track{height:clamp(252px,calc(28svh + 72px),372px);gap:6px}
.shrine-detail-refined .shrine-header-photo .gallery-tile,
.shrine-detail-refined .shrine-header-photo .gallery-add-photo{border-radius:14px}
.shrine-detail-refined .shrine-header-photo .gallery-placeholder{height:clamp(252px,calc(28svh + 72px),372px);min-height:0;border-radius:14px}
.shrine-detail-refined .gallery-add-photo{background:#fff;color:#806c54;border:1px solid var(--ui-border,#ded4c5);font-weight:500;font-size:12px;gap:6px;padding:10px}
.shrine-detail-refined .gallery-add-photo:hover{background:#faf7f1}
.shrine-detail-refined .gallery-add-icon{border:0;width:32px;height:32px}
.shrine-detail-refined .gallery-add-icon svg{width:24px;height:24px}
.shrine-detail-refined .gallery-add-photo:focus-visible{outline-color:#806c54}
.shrine-detail-refined .shrine-review-summary{padding:16px 0 12px;margin:0;border:0}
.shrine-detail-refined .review-summary-top{margin-bottom:12px}
.shrine-detail-refined .review-summary-top strong{font-size:22px;line-height:1.3}
.shrine-detail-refined .review-facilities>div{gap:6px}
.shrine-detail-refined .shrine-detail-actions{margin-top:12px;gap:10px}
.shrine-detail-refined .shrine-detail-actions>*{min-height:44px;padding:8px 10px;font-size:13px}
@media(max-width:760px){
 main:has(>.shrine-detail-refined){padding-top:4px}
 .shrine-detail-refined .shrine-header-photo .gallery-track,
 .shrine-detail-refined .shrine-header-photo .gallery-placeholder{height:clamp(192px,calc(20svh + 72px),252px)}
 .shrine-detail-refined .shrine-header-photo .shrine-gallery{min-height:0}
 .shrine-detail-refined .shrine-detail-heading h1{font-size:25px}
 .shrine-detail-refined .gallery-add-icon{width:26px;height:26px}
 .shrine-detail-refined .gallery-add-icon svg{width:20px;height:20px}
 .shrine-detail-refined .gallery-add-photo{font-size:11px;padding:6px}
}

/* Keep horizontal swipe areas clean without disabling scrolling. */
.gallery-track,.photo-lightbox-track,.collection-tabs,.selection-options{scrollbar-width:none;-ms-overflow-style:none}
.gallery-track::-webkit-scrollbar,.photo-lightbox-track::-webkit-scrollbar,.collection-tabs::-webkit-scrollbar,.selection-options::-webkit-scrollbar{display:none;width:0;height:0}
.shrine-detail-refined+.detail-grid .source,.shrine-detail-refined+.detail-grid .link-row{border-bottom:0}

/* Align the favorite action with the shrine title. */
.shrine-title-row{display:flex;align-items:center;justify-content:space-between;gap:16px}
.shrine-title-row h1{flex:1;min-width:0}
.shrine-title-row>.shrine-like-icon{position:static;display:flex;align-items:center;justify-content:center;flex:0 0 44px;width:44px;height:44px;padding:0;border:0;background:transparent;color:var(--coral);margin-left:auto}
.shrine-detail-refined .goshuin-section{padding-bottom:8px;margin-bottom:0}
.shrine-detail-refined+.detail-grid{margin-top:0}
.shrine-detail-refined+.detail-grid>div>.panel:first-child{padding-top:8px}

/* Keep CMS navigation independent of the public header and mobile navigation. */
.cms .cms-heading{height:auto;min-height:0;flex-direction:row;flex-wrap:wrap;margin:0;padding:16px 0;gap:12px;text-align:left}
.cms .cms-heading>div{min-width:0;flex:1}
.cms .cms-heading>a{flex:none;white-space:nowrap}
.cms .cms-nav{position:static;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));width:100%;height:auto;min-width:0;gap:8px;margin:12px 0 24px;padding:0;background:none;transform:none}
.cms .cms-nav>button{position:static;box-sizing:border-box;min-width:0;width:100%;height:auto;min-height:44px;margin:0;padding:12px 8px;line-height:1.5;white-space:normal;overflow-wrap:anywhere;transform:none}
@media(max-width:640px){
 .cms .cms-nav{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .cms .cms-heading>a{font-size:12px;padding:8px 10px}
 .cms .cms-content{min-width:0}
 .cms .cms-toolbar{align-items:flex-start}
}

/* Notifications use the existing cream, coral and brown controls. */
.notification-settings{max-width:640px;margin:0 auto}.notification-settings fieldset{border:0;padding:0;margin:24px 0}.notification-settings legend{font-weight:700;margin-bottom:12px}.notification-settings label{display:flex;align-items:center;gap:12px;padding:14px 12px;border-radius:12px}.notification-settings label:has(input:checked){background:#eee5d6}.notification-settings input{width:20px;height:20px;accent-color:#a17b58;flex:none}.notification-settings button{min-height:44px}.notification-device{margin-top:24px}.account-notifications{display:inline-flex;margin:0 0 16px auto}.news-tags{display:flex;flex-wrap:wrap;gap:8px;margin-top:24px}.news-tags a{font-size:14px}

/* Keep standalone navigation above the home indicator, even without viewport-fit. */
@media(max-width:760px) and (display-mode:standalone), (max-width:760px) and (display-mode:fullscreen){
 nav.main-navigation{height:calc(66px + max(24px,env(safe-area-inset-bottom,0px)));padding-bottom:max(24px,env(safe-area-inset-bottom,0px))}
 body{padding-bottom:calc(66px + max(24px,env(safe-area-inset-bottom,0px)))}
 body.map-layout .map-page>div{height:calc(100dvh - 66px - max(24px,env(safe-area-inset-bottom,0px)))}
}
.news-image-loading{display:block;width:100%;aspect-ratio:3/2;overflow:hidden;border-radius:12px;background:#e7e7e5;align-self:start}
.home-news .news-image-loading{aspect-ratio:1}
.news-card .news-image-loading img{display:block;width:100%;height:100%;object-fit:cover;opacity:0;transition:opacity .2s}
.news-image-loading.loaded img{opacity:1}
.news-image-loading.failed img{visibility:hidden}
.notification-welcome{width:min(440px,calc(100% - 36px));border:1px solid #ded4c5;border-radius:24px;background:#fffcf7;color:#303838;padding:28px;outline:none}
.notification-welcome::backdrop{background:#302b2455}
.notification-welcome h2{font-size:21px;margin:0 0 16px}.notification-welcome p{font-size:14px;line-height:1.8}.notification-welcome button,.notification-welcome a{display:block;width:100%;margin-top:12px;text-align:center}

/* CMS keeps its own management menu; hide only the public global navigation. */
body.admin-layout nav.main-navigation{display:none}
body.admin-layout{padding-bottom:env(safe-area-inset-bottom,0px)}

.cms-news-editor .cms-savebar{position:static;bottom:auto;z-index:auto}
.notification-settings form[hidden],.notification-settings button[hidden]{display:none!important}
.notification-settings{padding:24px}.notification-settings h1{margin-top:0}.notification-device{margin:0 0 24px;padding:20px;border-radius:16px;background:#f2eee5}.notification-device h2{margin:0 0 8px;font-size:18px}.notification-device button{width:100%;margin:8px 0 0}.notification-device .muted{font-size:12px;line-height:1.8}.notification-settings form{padding-top:4px}.notification-settings fieldset{margin:16px 0 24px}.notification-settings label{border:1px solid #e4ded3;margin:8px 0;padding:14px}.notification-settings form>.muted{font-size:12px;line-height:1.8}.notification-settings form>button{width:100%}

/* Map filters: prominent disclosure, ordered fields and compact help. */
.map-control-bar .map-controls>summary{background:#9b7051!important;color:#fff;border:1px solid #9b7051!important;border-radius:999px;padding:10px 18px!important;font-weight:700;min-height:44px}
.map-controls>summary::before{content:"☷";margin-right:8px;font-size:18px}
.map-control-bar .map-controls>summary:focus-visible{outline:2px solid #806c56;outline-offset:3px}
.map-select-row .map-distance-label{grid-column:1;grid-row:1}
.map-select-row .map-blessing-label{grid-column:2;grid-row:1}
.map-select-row .map-prefecture-label{grid-column:1;grid-row:2}
.map-select-row .map-deity-label{grid-column:2;grid-row:2}
.map-distance-status{margin:0;font-size:12px;color:#806c56;line-height:1.5}
.map-distance-status[hidden]{display:none}
.map-info{order:3;align-self:stretch}
.map-info>summary{list-style:none;cursor:pointer;width:32px;height:32px;display:flex;align-items:center;justify-content:center;margin-left:auto;color:#806c56}
.map-info>summary::-webkit-details-marker{display:none}
.map-info>summary span{border:1.5px solid currentColor;border-radius:50%;width:20px;height:20px;text-align:center;font:bold 14px/20px Georgia,serif}
.map-info>summary:focus-visible{outline:2px solid #a57d60;outline-offset:2px;border-radius:50%}
.map-info .map-source{margin-top:8px}

.map-control-bar .map-clear-filters{background:#fffdf8!important;border:1px solid #bda78e!important;border-radius:999px;padding:10px 12px!important;min-height:44px;font-weight:600;color:#765b43}
.map-clear-filters::before{content:"↺";font-size:18px;margin-right:5px;vertical-align:-1px}
.map-control-bar .map-controls>summary{max-width:calc(100% - 154px)}
.map-control-bar .map-clear-filters:hover{background:#f0e7d8!important}
.map-control-bar .map-clear-filters:focus-visible{outline:2px solid #a57d60;outline-offset:3px}
.notification-permission-help{padding:16px;border-radius:12px;background:#fffaf0;color:#765b43;font-size:14px;line-height:1.7;margin-bottom:16px}
.notification-permission-help[hidden]{display:none!important}
.notification-permission-help p{margin:10px 0 0}

.notification-device[hidden]{display:none!important}

.map-shrine-icon .map-pin.favorite{--pin-color:var(--coral)}
.map-pin.favorite svg.favorite-heart{width:18px;height:18px;fill:#fff;stroke:#fff;stroke-width:1.8}

.review-memo-label{display:block;margin:20px 0 8px;color:#806c56;font-weight:600}
.review-memo-label small,.private-shrine-memo h2 small{font-size:12px;font-weight:400;color:#887764;margin-left:8px}
.review-form textarea{display:block;width:100%;box-sizing:border-box;border:1px solid #d8cdbd;border-radius:12px;padding:12px;font:inherit;font-size:16px;line-height:1.7;background:#fffdf8;color:var(--ink);resize:vertical}
.private-shrine-memo{margin-top:16px;padding:16px;background:#f4efe5;border-radius:14px;text-align:left}
.private-shrine-memo h2{font-size:16px;margin:0 0 8px}.private-shrine-memo p{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.8;margin:0 0 12px}.private-shrine-memo button{font-size:13px;padding:8px 12px}

/* Compact account heading: title and settings share one row. */
.account-book-header{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 6px}
.account-book-header .account-book-title{margin:0;line-height:1.35}
.account-book-header .account-notifications{margin:0;display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:7px 14px;border-radius:999px;font-size:13px;line-height:1.4;white-space:nowrap}
.account-book-header+.account-heading{margin:0 0 12px;min-height:36px;gap:12px}
.account-book-header+.account-heading .account-name{font-size:12px;margin:0}
.account-book-header+.account-heading .account-login{min-height:36px;padding:4px 0;font-size:12px;gap:5px}
.account-book-header+.account-heading .account-login svg{width:18px;height:18px}
@media(max-width:600px){.account-book-header{gap:10px}.account-book-header .account-book-title{font-size:23px}.account-book-header .account-notifications{font-size:12px;padding:7px 12px}.account-book-header+.account-heading{margin-bottom:10px}}

.review-form>.review-memo-label,.review-form>#review-private-memo{grid-column:1/-1;width:100%;min-width:0}
.review-form>.review-memo-label{display:flex;align-items:baseline;flex-wrap:wrap;gap:8px;margin:0 0 -12px}
.review-memo-label small{margin:0;white-space:nowrap}

/* Primary collection destination and its two sections. */
nav.main-navigation .nav-book{display:flex;align-items:center;gap:7px;color:#a36b51;background:#f7ebdc;border-radius:20px;padding:8px 16px}
.nav-book-icon{width:32px;height:30px;flex-shrink:0}
nav.main-navigation .nav-book.active{color:var(--coral);background:#fce7df}
nav.main-navigation .nav-book.active .nav-label::after{content:none}
.book-navigation{display:flex;gap:24px;align-items:center;margin:8px 0 24px;border-bottom:1px solid var(--line)}
.book-navigation a{font-size:25px;font-weight:700;color:var(--muted);padding:8px 2px 14px;position:relative}
.book-navigation a[aria-current="page"]{color:var(--coral)}
.book-navigation a[aria-current="page"]::after{content:"";position:absolute;bottom:-1px;height:3px;border-radius:3px;background:var(--coral);left:0;right:0}
.account-settings{max-width:720px;margin:0 auto}
.settings-profile{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:20px 0 28px;flex-wrap:wrap}
.settings-profile .secondary{padding:10px 18px}
.account-settings .notification-settings{margin:0}
body.catalog-layout header .brand{display:none}
body.catalog-layout header{height:80px;padding-top:0}
@media(max-width:760px){
 nav.main-navigation>a{flex:1;text-align:center}
 nav.main-navigation .nav-book{flex:0 0 76px;flex-direction:column;gap:0;padding:5px 8px;border-radius:18px;line-height:1.35}
 .nav-book-icon{width:30px;height:28px}
 .book-navigation{gap:24px;margin:0 0 20px}
 .book-navigation a{font-size:23px}
 body.catalog-layout header{height:62px;padding:0}
 body.catalog-layout main{padding-top:0}
}

/* Equal navigation slots keep the central book from pulling adjacent labels inward. */
nav.main-navigation[aria-label="メインナビゲーション"]{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:0;width:min(100%,560px);align-items:center}
nav.main-navigation[aria-label="メインナビゲーション"]>a{justify-self:center;text-align:center;min-width:0}
@media(max-width:760px){nav.main-navigation[aria-label="メインナビゲーション"]{width:100%;padding-left:8px;padding-right:8px;box-sizing:border-box}nav.main-navigation .nav-book{width:72px;box-sizing:border-box}}
.filters.catalog-shrine-filters{grid-template-columns:repeat(2,minmax(0,1fr))}
.filters.catalog-shrine-filters>a{grid-column:auto;grid-row:auto;justify-self:stretch;align-self:stretch;display:flex;align-items:center;justify-content:center;padding:8px 10px;min-height:44px;box-sizing:border-box;font-size:13px;white-space:nowrap}
@media(min-width:1000px){.filters.catalog-shrine-filters{grid-template-columns:repeat(6,minmax(0,1fr))}}
/* Both map controls use the reset button's compact height and typography. */
.map-control-bar .map-controls>summary,.map-control-bar .map-clear-filters{box-sizing:border-box;height:44px;min-height:44px;padding:10px 12px!important;font-size:13px;line-height:22px;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap}
.map-control-bar .map-controls>summary{width:calc(50% - 5px);max-width:none}
.map-control-bar .map-clear-filters{width:calc(50% - 5px)}
.map-control-bar .map-controls>summary::before,.map-control-bar .map-clear-filters::before{font-size:18px;line-height:1;margin-right:6px;flex-shrink:0}
@media(max-width:360px){.map-control-bar .map-controls>summary,.map-control-bar .map-clear-filters{font-size:12px;padding:10px 6px!important}}

.book-navigation{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.book-navigation a{text-align:center;font-size:clamp(16px,4.2vw,23px);white-space:nowrap}
.encounter-open-collection{margin:32px 0 0;padding:0;border:0;background:none;border-radius:0}
.encounter-open-collection .encounter-filter{display:block;margin:18px 0 22px}
.encounter-open-collection .encounter-filter input{width:100%;box-sizing:border-box}
@media(max-width:600px){.book-navigation{gap:8px}.encounter-open-collection{margin-top:26px}}

/* Map popup: title, reading and overall review score form one compact header. */
.map-detail{padding:20px;border-radius:20px}
.map-detail .map-detail-title{margin:0 0 4px;padding-right:38px}
.map-detail .map-detail-title h2{font-size:19px;line-height:1.5;overflow-wrap:anywhere}
.map-detail .name-reading{font-size:11px;line-height:1.7;margin:0 0 8px}
.map-detail-rating{margin:6px 0 10px}
.map-detail-rating .shrine-list-rating{display:inline-flex;align-items:baseline;gap:5px;margin:0;font-size:18px;font-weight:700;line-height:1.4}
.map-detail-rating .shrine-list-rating>span{color:#b69853;font-size:20px}
.map-detail-rating .shrine-list-rating small{font-size:11px;font-weight:400;color:var(--muted)}
.map-detail .map-shrine-intro{margin:8px 0 12px;line-height:1.65}
.map-detail .map-status-buttons{margin:12px 0 10px;gap:8px}
.map-detail .map-detail-links{margin-top:10px;padding-top:10px}
@media(max-width:760px){.map-detail{padding:18px 16px 16px}.map-detail .map-detail-title h2{font-size:18px}}

/* Fixed, cached color portraits for page loading; never intercept navigation. */
.deity-page-loader{position:fixed;top:50%;left:50%;width:88px;height:88px;transform:translate(-50%,-50%);z-index:20;pointer-events:none}
.deity-page-loader img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;opacity:0;animation:deity-page-loop 2.8s ease-in-out infinite;filter:none}
.deity-page-loader img:first-child{animation-delay:-.35s}
.deity-page-loader img:last-child{animation-delay:1.05s}
.route-loading-placeholder{opacity:.35}
@keyframes deity-page-loop{0%{opacity:0;transform:translateY(5px) scale(.96)}12%,36%{opacity:1;transform:translateY(0) scale(1)}50%,100%{opacity:0;transform:translateY(-5px) scale(.98)}}
@media(prefers-reduced-motion:reduce){.deity-page-loader img{animation:none}.deity-page-loader img:first-child{opacity:1}.deity-page-loader img:last-child{display:none}}

.inline-route-pending{padding:32px 16px;text-align:center;color:#8b7966;min-height:100px}
.refreshing-results .grid,.refreshing-results .shrine-prefecture-group,.refreshing-results .shrine-photo-grid{opacity:.55;transition:opacity .12s}
.rating-pending{color:transparent!important;background:#eee9e0;border-radius:5px;min-width:55px;min-height:18px}
.rating-pending>*{visibility:hidden}

.card-art.shine [data-pending-section]{width:100%;height:100%}
.card-art.shrine [data-pending-section]{width:100%;height:100%;display:grid;place-items:center}
.card-art.shrine [data-pending-section] .loading-part{width:100%;height:100%;border-radius:inherit}

.cms .cms-savebar{position:static;bottom:auto;z-index:auto}
.cms-photo-actions{display:flex;flex-direction:column;gap:8px;flex-shrink:0;max-width:45%}
.cms-photo-actions button{font-size:13px;padding:10px}

.cms-course-preview .spirit-character{width:100px;height:100px;object-fit:contain;margin:0}.cms-course-stop{display:flex;gap:6px;align-items:center;padding:10px 0;border-bottom:1px solid #e8e0d3}.cms-course-stop span{flex:1;min-width:0}.cms-course-stop button{padding:8px;font-size:12px}.cms-encounter-options{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:10px;max-height:65vh;overflow:auto}.cms-encounter-options label{display:flex;align-items:center;gap:8px;padding:8px;background:#f6f1e8;border-radius:12px}.cms-encounter-options label[hidden]{display:none}.cms-encounter-options .spirit-character{width:58px;height:65px;object-fit:contain;margin:0}.cms-encounter-options small{display:block;color:#8b7966;font-size:12px}.rally-theme-note{margin:0 20px 20px;padding:16px 18px;color:#786751;font-size:14px;line-height:1.9;white-space:pre-line;overflow-wrap:anywhere}
@media(max-width:600px){.rally-theme-note{margin:0 12px 16px;padding:14px 16px}}

/* Compact filters; reset follows the ordering control in document and visual order. */
.filters.catalog-shrine-filters{gap:8px;margin-top:12px;margin-bottom:16px}
.filters.catalog-shrine-filters>select,.filters.catalog-shrine-filters>a{min-width:0;width:100%;min-height:44px;box-sizing:border-box;margin:0;padding:8px 10px;font-size:13px}
#toast{background:var(--coral);bottom:48px;z-index:150;max-width:calc(100vw - 32px);box-sizing:border-box;white-space:normal;text-align:center;pointer-events:none}
@media(max-width:760px){#toast{bottom:calc(130px + env(safe-area-inset-bottom,0px));padding:12px 22px}}
nav.main-navigation .nav-book{position:relative;overflow:visible}
.nav-book .account-save-burst{z-index:3}
.nav-book .account-save-burst i{color:var(--coral);top:10%;font-size:36px;filter:drop-shadow(0 2px 2px #fff8)}

/* Keep the notebook confirmation visible long enough to recognize. */
.nav-book .account-save-burst i{animation-duration:2.1s}
.shrine-title-row{flex-wrap:wrap}
.shrine-title-row>.shrine-notebook-button{flex:0 0 auto;margin-left:auto;white-space:nowrap;padding:10px 23px;font-size:inherit}
@media(max-width:760px){.shrine-title-row>.shrine-notebook-button{font-size:11px}}

/* Visit actions are buttons, not radio choices. Keep descriptions within the dialog. */
.selection-action-dialog{width:min(400px,calc(100vw - 32px));padding:20px;border-radius:22px}
.selection-action-dialog .selection-heading{margin:0 0 16px;padding:0;min-height:40px;gap:8px;align-items:center}
.selection-action-dialog .selection-heading h2{font-size:18px;line-height:1.5;letter-spacing:.01em}
.selection-action-dialog .selection-heading .popup-close{position:static;flex:0 0 40px;width:40px;height:40px;min-width:40px;min-height:40px}
.selection-action-dialog .selection-heading .popup-close span{width:20px;height:20px}
.selection-action-dialog .selection-heading .popup-close span::before,.selection-action-dialog .selection-heading .popup-close span::after{width:20px;top:9px}
.selection-action-dialog .selection-options{overflow:visible;gap:10px;padding:0}
.selection-action-dialog .selection-options>button{width:100%;min-width:0;min-height:48px;white-space:normal;flex-direction:column;align-items:center;justify-content:center;gap:5px;padding:12px 16px;text-align:center;line-height:1.5;font-size:14px;border-radius:12px}
.selection-action-dialog .selection-options>button::before{display:none}
.selection-action-dialog .selection-options small{display:block;margin:0;white-space:normal;overflow-wrap:anywhere;font-size:11px;line-height:1.6;font-weight:400}
.selection-action-dialog .selection-name{font-weight:600}
.selection-action-dialog .selection-options>[data-option="yes"]{padding:12px 16px;min-height:72px}
.selection-action-dialog [data-option="yes"]{border-color:#d9a59a;color:#a3483b;background:#fcf0ec}
.selection-action-dialog [data-option="edit"]{background:var(--coral);border-color:var(--coral);color:white;font-weight:700}
.selection-action-dialog [data-option="no"]{background:transparent}

/* Search belongs to the expanded map filters. */
.map-control-bar .map-controls>summary::before{content:none;display:none}
body.map-layout .map-controls-body>.map-search{width:100%;box-sizing:border-box;margin:0 0 10px;flex-shrink:0}

.gacha-collection-note{margin:0;text-align:center;font-size:12px;line-height:1.5;color:#927b63}

.settings-withdrawal{margin-top:24px;padding-top:20px;border-top:1px solid #e5dfd5}.withdrawal-page p{line-height:1.8}.withdrawal-actions{display:flex;flex-wrap:wrap;gap:12px}.withdrawal-actions a{text-align:center}.withdrawal-page .panel{margin:20px 0}@media(max-width:600px){.withdrawal-actions{flex-direction:column}}

.withdrawal-confirm{display:flex;align-items:flex-start;gap:10px;margin:24px 0;line-height:1.7}.withdrawal-confirm input{flex:0 0 auto;width:20px;height:20px;margin-top:4px;accent-color:#ef6755}.withdrawal-page li{margin:8px 0}.withdrawal-page button:disabled{opacity:.6;cursor:wait}

.cms-map-link{grid-column:1/-1}.cms-map-link small{display:block;line-height:1.7;color:#857765}.cms-map-link button{justify-self:start;margin:6px 0}.cms-map-link input{min-width:0;width:100%;box-sizing:border-box}

/* Calendar shares the home's warm paper and coral palette. */
.home-calendar{margin:28px 0 36px}.home-calendar [data-calendar]{border:1px solid #e5ded3;border-radius:24px;padding:24px;background:#fffdf8}.calendar-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:20px}.calendar-heading h3{font-size:22px;margin:0}.calendar-heading button{min-width:44px;min-height:44px;padding:4px 14px;font-size:26px;line-height:1}.calendar-week,.calendar-days{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:6px}.calendar-week{text-align:center;color:#8b7c68;margin-bottom:8px;font-size:13px}.calendar-week span:first-child{color:#ef6755}.calendar-day{border:0;background:transparent;color:#303839;border-radius:14px;min-width:0;min-height:54px;padding:8px 0 4px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;font:inherit;cursor:pointer}.calendar-day i{font-style:normal;font-size:7px;min-height:10px;color:#ef6755}.calendar-day.is-today{box-shadow:inset 0 0 0 1px #ef6755}.calendar-day.is-selected{background:#ef6755;color:#fff}.calendar-day.is-selected i{color:#fff}.calendar-day:hover{background:#f7e6df}.calendar-day.is-selected:hover{background:#db6051}.calendar-list-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:24px 0 12px}.calendar-list-heading h3{font-size:16px;margin:0}.calendar-reset{background:none;border:0;padding:8px 0;color:#9b7155;font:inherit;font-size:12px;cursor:pointer;text-decoration:underline}.calendar-event{padding:16px 0;border-top:1px solid #eee8df}.calendar-event h4{margin:5px 0;font-size:17px}.calendar-event p{margin:4px 0;font-size:14px;line-height:1.7}.calendar-event .calendar-event-date{font-size:12px;color:#9b7155}.calendar-description{white-space:pre-wrap}.calendar-event a{font-size:13px;color:#9b7155}.calendar-empty{color:#8b8071;font-size:14px;padding:12px 0;margin:0}.cms-calendar-event{margin:18px 0}.cms-calendar-event textarea{width:100%;box-sizing:border-box;min-height:90px}@media(max-width:600px){.home-calendar [data-calendar]{padding:16px;border-radius:18px}.calendar-week,.calendar-days{gap:3px}.calendar-day{min-height:46px;font-size:14px}.calendar-heading h3{font-size:19px}.calendar-list-heading{flex-wrap:wrap}}
/* Calendar editing and desktop administration */
body.admin-layout{display:block}
.cms-calendar-workspace{display:grid;gap:24px;grid-template-columns:minmax(0,1fr)}
.cms-calendar-workspace>section{min-width:0}.cms-calendar-workspace .calendar-day{align-items:stretch;justify-content:flex-start;text-align:left;padding:8px;min-height:80px;border:1px solid #e8e0d5;border-radius:8px}.cms-calendar-workspace .calendar-day small{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:11px;font-weight:400}.cms-calendar-choices{display:flex;flex-wrap:wrap;gap:8px}.cms-calendar-choices button{padding:8px 12px;font-size:14px}.cms-calendar-detail .cms-fields{grid-template-columns:1fr}.cms-calendar-detail label{min-width:0}.cms-calendar-detail input,.cms-calendar-detail textarea{width:100%}.cms-calendar-detail input[type=checkbox]{width:18px;flex:none}.cms-calendar-tags .cms-relations{grid-template-columns:1fr;max-height:180px}.cms-calendar-tags .cms-relations label{display:flex;align-items:center;font-size:13px}.cms-calendar-detail .cms-toolbar h3{margin:0}.calendar-tags{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}.calendar-tags a{padding:8px 12px;text-decoration:none}
@media(min-width:1024px){body.admin-layout main{max-width:1600px;padding:24px 32px 60px;width:100%;box-sizing:border-box}body.admin-layout>header{display:none}.cms{max-width:none;display:grid;grid-template-columns:190px minmax(0,1fr);gap:24px;align-items:start}.cms .cms-heading{grid-column:1/-1;padding:0 0 18px;border-bottom:1px solid #e5ded3}.cms .cms-nav{grid-column:1;grid-template-columns:1fr;margin:0;gap:6px}.cms .cms-nav>button{text-align:left;padding:11px 16px;font-size:14px;border-radius:10px}.cms .cms-content{grid-column:2;padding:28px;min-width:0}.cms-calendar-workspace{grid-template-columns:minmax(0,1.15fr) minmax(320px,1fr);gap:24px}.cms-calendar-detail{border-left:1px solid #e5ded3;padding-left:24px}.cms .cms-heading h1{font-size:28px}.cms-content>h2{font-size:24px}.cms-editor{font-size:14px}.cms-editor input:not([type=checkbox]),.cms-editor select,.cms-editor textarea{padding:10px 12px}.cms-list>button{padding:15px 12px}}
@media(max-width:600px){.cms-calendar-workspace .calendar-days{gap:2px}.cms-calendar-workspace .calendar-day{padding:6px 3px;min-height:64px}.cms-calendar-workspace .calendar-day small{font-size:9px}}
.cms-editor>label:has(>input[type=checkbox]){display:flex;align-items:center;gap:8px}
@media(min-width:1024px){.cms-calendar-detail .cms-fields{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.cms-calendar-detail .cms-fields label{margin:6px 0}.cms-calendar-detail .cms-fields label:has([data-field=title]),.cms-calendar-detail .cms-fields label:has([data-field=url]),.cms-calendar-detail .cms-fields label:has([data-field=description]){grid-column:1/-1}}
.shrine-view-switch{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;width:100%;box-sizing:border-box;margin:12px 0 20px;padding:0;background:transparent;border-radius:0;border-bottom:1px solid var(--line)}.shrine-view-switch a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;min-height:46px;padding:8px 14px;box-sizing:border-box;border-radius:0;text-decoration:none;color:var(--muted);font-size:clamp(16px,4.2vw,23px);font-weight:700;line-height:1.3}.shrine-view-switch a.active{background:transparent;color:var(--coral);box-shadow:none}.shrine-view-switch a.active::after{content:"";position:absolute;bottom:-1px;left:0;right:0;height:3px;border-radius:3px;background:var(--coral)}.shrine-view-label{display:flex;align-items:center;justify-content:center;gap:8px}.shrine-view-label svg{width:18px;height:18px;flex:none;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.shrine-view-switch small{display:block;margin:0;font-size:9px;font-weight:400;line-height:1.3;color:#948574}.shrine-view-switch a:focus-visible{outline:2px solid var(--coral);outline-offset:2px}.photo-membership-fade{display:grid;grid-template-columns:repeat(3,1fr);gap:0;mask-image:linear-gradient(#0009,transparent);height:150px}.photo-membership-fade i{background:#e8dfd2;border:1px solid #fff9}.photo-membership-message{text-align:center;font-weight:700;color:#9a7356;margin:0 0 36px}.photo-manager-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.photo-manager-grid button{padding:0;border:1px solid #ded5c7;border-radius:14px;overflow:hidden;background:#fffdf8;color:#8d765d}.photo-manager-grid img{width:100%;aspect-ratio:1;object-fit:contain;display:block;background:#f1ece3}.photo-manager-grid span{display:block;font-size:12px;padding:10px 3px}.photo-manager-grid .photo-manager-add{font-size:30px;min-height:130px}.photo-manager-grid .photo-manager-add span{font-size:13px}.photo-manager .photo-scope{font-size:13px;line-height:1.8}.photo-manager .photo-editor-heading{margin-bottom:20px}
@media(min-width:761px){body.catalog-layout header .brand{display:flex}body.catalog-layout header{height:auto;min-height:150px;padding-top:24px}}
@media(max-width:600px){.photo-manager-grid{gap:8px}}
.calendar-members-only{border:1px solid #e5ded3;border-radius:20px;background:#f5efe4;padding:28px;text-align:center}.calendar-members-only p{color:#8b735a;margin:0 0 18px;font-size:15px}.calendar-members-only .primary{display:inline-flex;min-height:44px;align-items:center;justify-content:center}
.calendar-schedule{margin-top:20px;border-top:1px solid #e8e0d5}.calendar-schedule>summary{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px 0 2px;list-style:none;cursor:pointer;font-size:16px;font-weight:700;color:#303839}.calendar-schedule>summary::-webkit-details-marker{display:none}.calendar-schedule>summary .calendar-expand-label,.calendar-schedule>summary .calendar-collapse-label{font-size:12px;font-weight:500;color:#9b7155;border:1px solid #ddd2c2;border-radius:20px;padding:7px 18px}.calendar-schedule:not([open]) .calendar-collapse-label,.calendar-schedule[open] .calendar-expand-label{display:none}.calendar-schedule>summary:focus-visible{outline:2px solid var(--coral);outline-offset:4px}.calendar-schedule .calendar-list-heading{margin-top:20px}

.membership-card{margin:24px 0;padding:24px;border:1px solid #e1d5c3;border-radius:24px;background:#faf5e9}.membership-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.membership-heading h2{margin:0;color:var(--coral);font-size:22px}.membership-heading p{margin:0;white-space:nowrap}.membership-heading strong{font-size:32px}.membership-heading span{font-size:13px}.membership-card ul{display:flex;flex-wrap:wrap;gap:8px;list-style:none;padding:0;margin:20px 0}.membership-card li{background:#fffdf8;padding:8px 12px;border-radius:10px;font-size:14px}.membership-donation,.membership-status{font-size:14px;line-height:1.8}.membership-status{font-weight:600}.membership-card small{display:block;color:#85796b;line-height:1.8;font-size:12px}

.shrine-search-toolbar{display:flex;align-items:center;gap:12px;margin:12px 0 20px;width:100%}.shrine-search-toolbar .shrine-view-switch{flex:1;min-width:0;width:auto;margin:0}.shrine-search-toolbar .shrine-view-switch a{position:relative;height:64px;min-height:64px;padding:8px 2px 14px}.shrine-search-toolbar .shrine-view-switch small{position:absolute;top:calc(50% + 12px);font-size:9px;white-space:nowrap}.shrine-search-toolbar .shrine-view-label{gap:6px}.shrine-search-toggle{display:flex;align-items:center;justify-content:center;flex:0 0 52px;width:52px;height:52px;min-width:52px;min-height:52px;aspect-ratio:1;box-sizing:border-box;border:1px solid #ded5c7;border-radius:10px;background:#fffdf8;color:#887761;font-size:13px;cursor:pointer;padding:0}.shrine-search-toggle svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round}.shrine-search-toggle:focus-visible{outline:2px solid var(--coral);outline-offset:3px}#shrine-search-controls[hidden]{display:none}

/* Rankings share the home news thumbnail scale. */
.home-ranking h2{color:var(--coral,#ee6959)}
.home-ranking li{flex-wrap:nowrap;gap:12px;padding:18px 0}
.home-ranking li>a.ranking-link{display:flex;align-items:center;gap:20px;flex:1;min-width:0;text-decoration:none;color:inherit}
.ranking-thumbnail{display:flex;align-items:center;justify-content:center;width:120px;height:120px;flex:0 0 120px;border-radius:12px;overflow:hidden;background:#eeece5}
.ranking-thumbnail img{display:block;width:100%;height:100%;object-fit:cover}
.ranking-thumbnail.ranking-deity{background:transparent;padding:6px}
.ranking-deity img,.ranking-deity svg{width:100%;height:100%;object-fit:contain}
.ranking-copy{min-width:0}.ranking-copy strong{display:block;font-size:18px;line-height:1.5;overflow-wrap:anywhere}
.ranking-copy .name-reading{font-size:12px}.ranking-no-photo{font-size:11px;color:#8c8174}
.ranking-number{flex:0 0 22px;width:22px}.ranking-link:hover strong{text-decoration:underline}
@media(max-width:600px){.ranking-thumbnail{width:80px;height:80px;flex-basis:80px}.home-ranking li>a.ranking-link{gap:12px;flex-basis:0}.home-ranking li{gap:8px}.ranking-copy strong{font-size:15px}.ranking-copy .name-reading{font-size:10px}.ranking-likes{font-size:11px}}

/* Photo category occupies its own row; sort and reset stay side by side. */
.filters.catalog-shrine-filters>select[data-filter=category]{grid-column:1/-1}


/* Five fixed home illustrations, four seconds per deity. */
.encounter-invitation-frame{grid-area:1/1;display:grid;place-items:center;opacity:0;animation:home-deity-loop 20s ease-in-out infinite}
@keyframes home-deity-loop{0%,16%{opacity:1;transform:translateY(0) scale(1)}20%,96%{opacity:0;transform:translateY(4px) scale(.98)}100%{opacity:1;transform:translateY(0) scale(1)}}
@media(prefers-reduced-motion:reduce){.encounter-invitation-frame{animation:none;opacity:0}.encounter-invitation-frame:first-child{opacity:1}}

.calendar-clear-day{background:none;border:0;padding:8px 0;color:#9b7155;font:inherit;font-size:12px;cursor:pointer;text-decoration:underline}

.review-facilities .review-goshuin-summary>span{white-space:normal}.review-goshuin-summary>strong{color:#ba934d;white-space:nowrap}

.review-goshuin-help{clear:both;margin:0 0 10px;color:#948673;font-size:12px;line-height:1.7;font-weight:400;text-align:center;overflow-wrap:anywhere}

/* Keep gestures inside the top-layer popup, while its content remains scrollable. */
dialog{overscroll-behavior:contain;max-height:calc(100dvh - 32px);overflow-y:auto;-webkit-overflow-scrolling:touch}
dialog::backdrop{touch-action:none}

.cms-benefit-sources{margin:8px 0 24px;font-size:13px;line-height:1.7}.cms-benefit-sources summary{cursor:pointer;color:#7c6c59}.cms-benefit-sources ul{padding-left:20px}.cms-benefit-sources li{margin:10px 0}.cms-benefit-sources p{margin:4px 0;overflow-wrap:anywhere}

.deity-benefits .blessing-tags{gap:8px 18px;margin-top:12px}.deity-benefits .blessing-tags span{font-size:16px;font-weight:500;line-height:1.8}

.shrine-detail-actions.has-official .shrine-map-button{grid-column:1}.shrine-detail-actions .shrine-official-button{grid-column:2;gap:5px;text-align:center;line-height:1.5;overflow-wrap:anywhere}

/* Every navigation slot is a touch target, including its surrounding whitespace. */
nav.main-navigation[aria-label="メインナビゲーション"]>a{justify-self:stretch;display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:100%;min-height:48px;touch-action:manipulation}
nav.main-navigation[aria-label="メインナビゲーション"]>.nav-book{width:100%;max-width:none;justify-self:stretch}
@media(max-width:760px){nav.main-navigation[aria-label="メインナビゲーション"]>a{height:66px;padding:8px 0}nav.main-navigation[aria-label="メインナビゲーション"]>.nav-book{max-width:none;background:none;position:relative;isolation:isolate}nav.main-navigation[aria-label="メインナビゲーション"]>.nav-book::before{content:"";position:absolute;width:72px;max-width:100%;height:60px;border-radius:18px;background:#f7ebdc;z-index:-1;pointer-events:none}nav.main-navigation[aria-label="メインナビゲーション"]>.nav-book.active::before{background:#fce7df}}

/* Notebook view controls stay above the mobile navigation and safe area. */
.visited-view-switch{position:fixed;right:16px;bottom:24px;z-index:45;display:flex;gap:4px;padding:5px;border:1px solid var(--line);border-radius:14px;background:var(--paper);box-shadow:0 3px 16px #503b2920}
.visited-view-switch a{display:grid;place-items:center;width:44px;height:44px;border-radius:9px;color:var(--muted);touch-action:manipulation}
.visited-view-switch a.active{color:var(--coral);background:#fce7df}
.visited-view-switch svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.visited-view-switch a:focus-visible{outline:2px solid var(--coral);outline-offset:2px}
.saved-collection:has(.visited-view-switch){padding-bottom:76px}
@media(max-width:760px){.visited-view-switch{right:max(12px,env(safe-area-inset-right,0px));bottom:calc(78px + max(24px,env(safe-area-inset-bottom,0px)))}}

.saved-filter-actions{grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;width:100%}
.saved-membership-link{margin-right:auto;text-align:left;color:var(--coral);font-size:12px;text-decoration:none}
.photo-membership-cta{text-align:center;margin:-18px 0 36px}.photo-membership-cta .primary{display:inline-flex;min-height:44px;align-items:center;justify-content:center}
.membership-enrollment{font-size:14px;line-height:1.8}.membership-enrollment .primary{display:inline-flex;min-height:44px;align-items:center}

/* Match the existing notebook reset even when grouped with membership guidance. */
.filters.shrine-filters>.saved-filter-actions>.secondary{margin-left:auto;padding:7px 0;background:transparent;border:0;color:#927b63;font-size:12px;text-align:right;white-space:nowrap}

/* Full-bleed photo strips must not clip the outer tiles' rounded edges/borders. */
.shrine-detail-refined .shrine-header-photo{border:0;border-radius:0;box-shadow:none}
.shrine-detail-refined .gallery-track{box-sizing:border-box}
.shrine-detail-refined .gallery-tile,.shrine-detail-refined .gallery-add-photo,.shrine-detail-refined .gallery-more{box-sizing:border-box;box-shadow:none}
.shrine-detail-refined .shrine-header-photo .gallery-tile{border:0}
.shrine-detail-refined .gallery-add-photo,.shrine-detail-refined .gallery-more,.shrine-detail-refined .goshuin-gallery .gallery-tile{border:1px solid var(--ui-border);border-radius:14px}

.shrine-detail-grid{grid-template-columns:minmax(0,1fr)}

/* 2026-11-17 account and compact view controls */
.legal-footer a,.legal-footer a:visited{color:#806b57}
.account-face img,.account-avatar img{display:block;width:100%;height:100%;object-fit:cover;border-radius:50%}
.account-face{overflow:hidden}
.avatar-settings .account-avatar{margin-bottom:16px;overflow:hidden}
.avatar-settings label.secondary{display:inline-flex;cursor:pointer}
.single-view-switch{width:auto;grid-template-columns:1fr}
.single-view-switch a{color:var(--accent,#ed695a)}

/* Home discovery and signed-out notebook preview. */
.home-nearby{display:flex;justify-content:center;margin:20px 0 32px}
.home-nearby-button{display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:min(100%,440px);min-height:58px;padding:16px 24px;border-radius:16px;background:var(--coral);color:#fff;font-size:18px;font-weight:700;text-align:center}
.home-nearby-button:visited{color:#fff}
.account-photo-preview{position:relative;isolation:isolate;overflow:hidden;min-height:420px;width:100%;max-width:680px;margin:0 auto;box-sizing:border-box;border-radius:18px}
.account-preview-photos{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:top;opacity:.20;pointer-events:none;z-index:-2}
.account-photo-preview::before{content:"";position:absolute;inset:0;background:linear-gradient(transparent 30%,var(--paper));pointer-events:none;z-index:-1}
.account-photo-preview .account-signin-button{box-shadow:0 4px 20px #fff9}
@media(max-width:760px){
 body>nav.main-navigation{position:fixed;inset:auto 0 0;z-index:100;width:100%;height:calc(66px + env(safe-area-inset-bottom,0px));padding-bottom:env(safe-area-inset-bottom,0px);margin:0;box-sizing:border-box;background:#fffdf7;border-top:1px solid var(--line);backdrop-filter:none;-webkit-backdrop-filter:none;transform:translateZ(0);pointer-events:auto}
 body.map-layout>nav.main-navigation{background:#fffdf7;border-top:1px solid var(--line);text-shadow:none}
 .account-photo-preview{min-height:58svh}
}

/* One target-view button at right; matching search button at left, near page top only. */
.floating-search-toggle{position:fixed;left:16px;bottom:24px;z-index:45;display:grid;place-items:center;width:56px;height:56px;box-sizing:border-box;padding:5px;border:1px solid var(--line);border-radius:14px;background:var(--paper);color:var(--accent,#ed695a);box-shadow:0 3px 16px #503b2920;cursor:pointer;touch-action:manipulation}
.floating-search-toggle svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.floating-search-toggle[aria-expanded="true"]{background:#fce7df}
.floating-search-toggle:focus-visible{outline:2px solid var(--coral);outline-offset:2px}
.search-tools-scrolled .floating-search-toggle{visibility:hidden;pointer-events:none}
@media(max-width:760px){.floating-search-toggle{left:max(12px,env(safe-area-inset-left,0px));bottom:calc(78px + max(24px,env(safe-area-inset-bottom,0px)))}}

.membership-limit-dialog{position:relative;padding:48px 24px 24px;text-align:center;max-width:calc(100vw - 32px)}
.membership-limit-message{white-space:pre-line;line-height:1.9;margin:0 0 24px;font-size:15px}
.membership-limit-dialog>.primary{display:flex;justify-content:center;min-height:48px;align-items:center}
