@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400&family=Zen+Maru+Gothic:wght@400;500;700&display=swap');

:root { --font-zen: 'Zen Maru Gothic'; --font-mono: 'DM Mono'; }

:root {
  --paper: #f4ece0;
  --paper-2: #efe4d4;
  --card: #fbf6ee;
  --map-paper: #ece1cd;
  --ink: #36291d;
  --ink-soft: #6a5847;
  --muted: #9c8a76;
  --line: #ddcdb6;
  --hazel: #8a6d4f;
  --hazel-deep: #6c5238;
  --hazel-soft: #ece0cf;
  --teal: #2f7d76;
  --teal-deep: #245f59;
  --teal-soft: #dcebe8;
  --grid: rgba(108, 82, 56, 0.1);
  --radius: 16px;
  --radius-sm: 11px;
  --shadow: 0 22px 50px rgba(76, 56, 36, 0.16);
  --shadow-soft: 0 12px 28px rgba(76, 56, 36, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 88% -6%, rgba(47, 125, 118, 0.1), transparent 28rem),
    radial-gradient(circle at 6% 4%, rgba(138, 109, 79, 0.12), transparent 26rem),
    var(--paper);
  color: var(--ink);
  font-family: var(--font-zen), ui-sans-serif, system-ui, sans-serif;
  font-weight: 400;
  letter-spacing: 0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font-zen), system-ui, sans-serif;
  font-weight: 700;
  line-height: 1.34;
  color: var(--ink);
}

.skip-link {
  position: fixed;
  left: 1rem;
  top: -4rem;
  z-index: 30;
  background: var(--teal-deep);
  color: #fff;
  padding: 0.65rem 0.9rem;
  border-radius: 8px;
}

.skip-link:focus {
  top: 1rem;
}

/* ---------- Slim map header + legend ---------- */
.map-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  flex-wrap: wrap;
  width: 100%;
  padding: 12px clamp(18px, 4vw, 40px);
  background: rgba(244, 236, 224, 0.86);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.map-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
}

.map-brand__mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--hazel-soft);
  color: var(--hazel-deep);
  border: 1px solid var(--line);
}

.map-brand__text strong {
  display: block;
  font-size: 1.16rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.map-brand__text small {
  display: block;
  margin-top: 1px;
  color: var(--muted);
  font-size: 0.74rem;
}

.map-legend {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin: 0;
  padding: 7px 14px;
  list-style: none;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.map-legend__item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 0.8rem;
  font-weight: 500;
}

.legend-sym {
  width: 16px;
  height: 16px;
  display: inline-block;
  flex: none;
}

.legend-sym--stop {
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 3px var(--teal-soft);
}

.legend-sym--dock {
  width: 13px;
  height: 13px;
  background: var(--hazel-deep);
  border-radius: 3px;
  transform: rotate(45deg);
}

.legend-sym--path {
  height: 0;
  border-top: 3px dotted var(--teal);
  align-self: center;
}

.legend-sym--area {
  border: 1.5px dashed var(--hazel);
  border-radius: 4px;
  background: rgba(251, 246, 238, 0.6);
}

/* ---------- Home: intro ---------- */
.dock-shell {
  width: min(1200px, calc(100% - 40px));
  margin: 0 auto;
  padding: clamp(28px, 5vw, 56px) 0 40px;
}

.dock-intro {
  max-width: 720px;
  margin-bottom: clamp(22px, 3vw, 34px);
}

.dock-eyebrow {
  margin: 0 0 12px;
  color: var(--teal-deep);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.dock-intro h1 {
  font-size: clamp(1.8rem, 3.4vw, 2.7rem);
  line-height: 1.32;
}

.dock-lede {
  margin: 18px 0 0;
  color: var(--ink-soft);
  font-size: clamp(1rem, 1.5vw, 1.1rem);
  line-height: 1.85;
}

/* ---------- Home: 2D map plane + side detail list ---------- */
.dock-plane {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(330px, 0.92fr);
  gap: clamp(20px, 2.6vw, 34px);
  align-items: start;
}

.dock-map {
  position: relative;
  aspect-ratio: 1000 / 640;
  border-radius: 20px;
  border: 1px solid var(--line);
  overflow: hidden;
  background-color: var(--map-paper);
  background-image:
    url("/images/hazeldock-lead.jpg"),
    linear-gradient(135deg, rgba(138, 109, 79, 0.22), rgba(47, 125, 118, 0.18) 68%, rgba(138, 109, 79, 0.2));
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat, no-repeat;
  background-blend-mode: soft-light, normal;
  box-shadow: var(--shadow);
}

.dock-map__svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.map-grid line {
  stroke: var(--grid);
  stroke-width: 1;
}

.map-area__zone {
  fill: rgba(251, 246, 238, 0.5);
  stroke: rgba(108, 82, 56, 0.28);
  stroke-width: 1.4;
  stroke-dasharray: 4 6;
}

.map-area__label {
  fill: var(--hazel-deep);
  font-family: var(--font-zen), sans-serif;
  font-size: 25px;
  font-weight: 700;
}

.map-area__reading {
  fill: var(--muted);
  font-family: var(--font-mono), monospace;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.map-path {
  fill: none;
  stroke: var(--teal);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-dasharray: 1 13;
  opacity: 0.9;
}

.map-dock__mark {
  fill: var(--hazel-deep);
  stroke: #fff;
  stroke-width: 2.5;
}

.map-dock__label {
  fill: var(--hazel-deep);
  font-family: var(--font-zen), sans-serif;
  font-size: 21px;
  font-weight: 700;
}

.map-pin__halo {
  fill: rgba(47, 125, 118, 0.16);
}

.map-pin__dot {
  fill: var(--teal);
  stroke: #fff;
  stroke-width: 3.5;
}

.map-pin__num {
  fill: #fff;
  font-family: var(--font-zen), sans-serif;
  font-weight: 700;
  font-size: 18px;
}

.map-pin__ref {
  fill: var(--hazel-deep);
  font-family: var(--font-mono), monospace;
  font-size: 16px;
}

/* side detail list */
.dock-aside {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: clamp(18px, 2vw, 26px);
  box-shadow: var(--shadow-soft);
}

.dock-aside__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.dock-aside__head h2 {
  font-size: 1.32rem;
}

.dock-count {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
}

.dock-count b {
  color: var(--teal-deep);
  font-family: var(--font-mono), monospace;
  font-size: 1.04rem;
}

.dock-aside__hint {
  margin: 8px 0 16px;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.6;
}

.dock-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
  counter-reset: none;
}

.dock-stop {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 13px;
  padding: 15px 15px 16px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease;
}

.dock-stop:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
  border-color: var(--teal);
}

.dock-stop__num {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 0 0 4px var(--teal-soft);
}

.dock-stop__body {
  display: grid;
  gap: 7px;
}

.dock-stop__coord {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 9px;
}

.dock-stop__ref {
  padding: 1px 8px;
  border-radius: 6px;
  background: var(--hazel-soft);
  color: var(--hazel-deep);
  font-family: var(--font-mono), monospace;
  font-size: 0.78rem;
  font-weight: 500;
}

.dock-stop__mono {
  color: var(--muted);
  font-family: var(--font-mono), monospace;
  font-size: 0.74rem;
}

.dock-stop__area {
  color: var(--teal-deep);
  font-size: 0.76rem;
  font-weight: 500;
}

.dock-stop__title {
  font-size: 1.06rem;
  line-height: 1.45;
  letter-spacing: 0.005em;
}

.dock-stop:hover .dock-stop__title {
  color: var(--teal-deep);
}

.dock-stop__note {
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.62;
}

.dock-stop__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 2px;
}

.dock-tag {
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--teal-soft);
  color: var(--teal-deep);
  font-size: 0.72rem;
  font-weight: 500;
}

/* ---------- Article: 立ち寄りメモ ---------- */
.memo-shell {
  width: min(1040px, calc(100% - 40px));
  margin: 0 auto;
  padding: clamp(26px, 4vw, 48px) 0 70px;
}

.memo {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: clamp(24px, 4vw, 48px);
  box-shadow: var(--shadow-soft);
}

.memo-head {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: clamp(20px, 3vw, 36px);
  align-items: center;
  padding-bottom: 26px;
  border-bottom: 2px dashed var(--line);
}

.memo-plan {
  aspect-ratio: 1000 / 640;
  border-radius: 14px;
  border: 1px solid var(--line);
  overflow: hidden;
  background: var(--map-paper);
}

.memo-plan svg {
  width: 100%;
  height: 100%;
  display: block;
}

.memo-plan__bg {
  fill: var(--map-paper);
}

.memo-plan__area {
  fill: var(--muted);
  font-family: var(--font-zen), sans-serif;
  font-size: 30px;
  opacity: 0.5;
}

.memo-plan__path {
  fill: none;
  stroke: var(--teal);
  stroke-width: 5;
  stroke-linecap: round;
  stroke-dasharray: 2 16;
}

.memo-plan__dock {
  fill: var(--hazel-deep);
  stroke: #fff;
  stroke-width: 3;
}

.memo-plan__pin {
  fill: rgba(47, 125, 118, 0.18);
}

.memo-plan__pinDot {
  fill: var(--teal);
  stroke: #fff;
  stroke-width: 4;
}

.memo-kicker {
  margin: 0 0 10px;
  color: var(--teal-deep);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.memo-coord {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px 11px;
  margin-bottom: 12px;
}

.memo-coord__ref {
  padding: 2px 10px;
  border-radius: 7px;
  background: var(--hazel-deep);
  color: #fff;
  font-family: var(--font-mono), monospace;
  font-size: 0.82rem;
}

.memo-coord__mono {
  color: var(--muted);
  font-family: var(--font-mono), monospace;
  font-size: 0.8rem;
}

.memo-coord__area {
  color: var(--teal-deep);
  font-size: 0.82rem;
  font-weight: 500;
}

.memo-head h1 {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  line-height: 1.32;
}

.memo-record {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.86rem;
}

.memo-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 13px;
}

.memo-tag {
  padding: 3px 11px;
  border-radius: 999px;
  background: var(--hazel-soft);
  color: var(--hazel-deep);
  font-size: 0.76rem;
  font-weight: 500;
}

.memo-lead {
  margin: 26px 0 0;
  padding: 18px 22px;
  background: var(--teal-soft);
  border-left: 4px solid var(--teal);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--teal-deep);
  font-size: 1.06rem;
  line-height: 1.78;
}

/* injected content */
.article-content {
  margin-top: 28px;
  color: #3a2d20;
  font-size: 1.05rem;
  line-height: 1.92;
}

.article-content h2 {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 40px 0 14px;
  font-size: clamp(1.3rem, 2.2vw, 1.65rem);
}

.article-content h2::before {
  content: "";
  flex: none;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: var(--teal);
  transform: rotate(45deg);
}

.article-content p {
  margin: 0 0 18px;
}

.article-content a {
  color: var(--teal-deep);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--teal);
  text-underline-offset: 3px;
}

.article-content ul,
.article-content ol {
  margin: 0 0 20px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 11px;
}

.article-content ul li {
  position: relative;
  padding-left: 26px;
  color: var(--ink-soft);
  line-height: 1.7;
}

.article-content ul li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.62em;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  border: 2px solid var(--teal);
}

.article-content blockquote {
  margin: 26px 0;
  padding: 20px 26px;
  border-left: 4px solid var(--hazel);
  background: var(--hazel-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--hazel-deep);
  font-size: 1.12rem;
  line-height: 1.74;
}

.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 0.96rem;
  overflow: hidden;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
}

.article-content th,
.article-content td {
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  padding: 13px 15px;
  text-align: left;
  vertical-align: top;
}

.article-content th:last-child,
.article-content td:last-child {
  border-right: 0;
}

.article-content tbody tr:last-child td {
  border-bottom: 0;
}

.article-content th {
  background: var(--hazel-soft);
  color: var(--hazel-deep);
  font-weight: 700;
}

.article-content tbody tr:nth-child(even) td {
  background: rgba(251, 246, 238, 0.6);
}

/* FAQ */
.memo-faq {
  margin-top: 40px;
}

.memo-faq h2 {
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  margin-bottom: 6px;
}

.memo-faq details {
  border-bottom: 1px solid var(--line);
  padding: 15px 0;
}

.memo-faq summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--ink);
  list-style: none;
  display: flex;
  gap: 10px;
}

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

.memo-faq summary::before {
  content: "";
  flex: none;
  width: 13px;
  height: 13px;
  margin-top: 5px;
  border-radius: 50%;
  border: 2px solid var(--teal);
  background:
    linear-gradient(var(--teal), var(--teal)) center / 7px 2px no-repeat,
    linear-gradient(var(--teal), var(--teal)) center / 2px 7px no-repeat;
}

.memo-faq details[open] summary::before {
  background: linear-gradient(var(--teal), var(--teal)) center / 7px 2px no-repeat;
}

.memo-faq details p {
  margin: 11px 0 0 23px;
  color: var(--ink-soft);
  line-height: 1.76;
}

/* nearby stops */
.memo-near {
  margin-top: 40px;
  padding-top: 26px;
  border-top: 2px dashed var(--line);
}

.memo-near__head {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.memo-near__head h2 {
  font-size: clamp(1.2rem, 2vw, 1.5rem);
}

.memo-near__count {
  color: var(--muted);
  font-size: 0.84rem;
}

.memo-near__count b {
  color: var(--teal-deep);
  font-family: var(--font-mono), monospace;
}

.memo-near__list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 13px;
}

.memo-near__card {
  display: grid;
  gap: 8px;
  padding: 16px 17px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.memo-near__card:hover {
  transform: translateY(-2px);
  border-color: var(--teal);
  box-shadow: var(--shadow-soft);
}

.memo-near__coord {
  display: flex;
  align-items: center;
  gap: 9px;
}

.memo-near__ref {
  padding: 1px 8px;
  border-radius: 6px;
  background: var(--hazel-soft);
  color: var(--hazel-deep);
  font-family: var(--font-mono), monospace;
  font-size: 0.76rem;
}

.memo-near__mono {
  color: var(--muted);
  font-family: var(--font-mono), monospace;
  font-size: 0.72rem;
}

.memo-near__card strong {
  font-size: 1rem;
  line-height: 1.45;
}

.memo-near__area {
  color: var(--teal-deep);
  font-size: 0.78rem;
  font-weight: 500;
}

.memo-near__empty {
  margin: 14px 0 0;
  color: var(--muted);
}

.memo-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 22px;
  color: var(--teal-deep);
  font-weight: 700;
}

.memo-back::before {
  content: "";
  width: 11px;
  height: 11px;
  border-left: 2px solid var(--teal-deep);
  border-bottom: 2px solid var(--teal-deep);
  transform: rotate(45deg);
}

/* ---------- Footer ---------- */
.dock-footer {
  width: min(1200px, calc(100% - 40px));
  margin: 30px auto 0;
  padding: 30px 0 56px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.3fr);
  gap: 28px;
}

.dock-footer__brand strong {
  display: block;
  font-size: 1.12rem;
  color: var(--ink);
}

.dock-footer__brand p {
  margin: 9px 0 0;
  max-width: 380px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.7;
}

.dock-footer__notes {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.dock-footer__notes li {
  position: relative;
  padding-left: 22px;
  color: var(--ink-soft);
  font-size: 0.9rem;
  line-height: 1.66;
}

.dock-footer__notes li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 9px;
  height: 9px;
  border-radius: 2px;
  background: var(--hazel);
  transform: rotate(45deg);
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .dock-plane {
    grid-template-columns: 1fr;
  }

  .memo-head {
    grid-template-columns: 1fr;
  }

  .memo-plan {
    max-width: 320px;
  }

  .dock-footer {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .map-header {
    gap: 12px;
  }

  .article-content table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}
