/* =========================================================
   Detail Page Modern Styles
   Shared layout & components for interior pages
   ========================================================= */

:root {
  --c-primary: #b11;
  --c-primary-dark: #931010;
  --c-bg: #fafafa;
  --c-dark: #222;
  --c-text: #333;
  --w-max: 1180px;
}

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

body {
  font-family: "Noto Sans JP", sans-serif;
  line-height: 1.8;
  color: var(--c-text);
  background: #fff;
  scroll-behavior: smooth;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
  border: none;
}

a {
  color: inherit;
  text-decoration: none;
  transition: opacity .3s, color .3s;
}

a:hover {
  opacity: .85;
}

.container {
  width: 90%;
  max-width: var(--w-max);
  margin-inline: auto;
}

.section {
  padding: clamp(48px, 8vw, 72px) 0;
}

.section-title {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  font-weight: 700;
  border-left: 6px solid var(--c-primary);
  padding-left: 14px;
  margin-bottom: clamp(28px, 6vw, 40px);
}

.section-lede .section-title {
  margin-bottom: clamp(20px, 5vw, 28px);
}

.text-muted {
  color: #777;
}

.text-accent {
  color: var(--c-primary);
  font-weight: 600;
}

.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

.required {
  color: var(--c-primary);
  font-weight: 700;
  font-size: .85rem;
  letter-spacing: .04em;
}

.badge {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(177, 17, 17, .1);
  color: var(--c-primary);
  font-weight: 700;
  font-size: .9rem;
}

.lead {
  font-size: 1.05rem;
  margin-bottom: 1.25em;
}

.content-text p {
  margin-bottom: 1.4em;
}

.content-text strong {
  font-weight: 700;
}

.content-text li {
  margin-bottom: .6em;
}

.content-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 20px 45px rgba(0, 0, 0, .06);
  padding: clamp(28px, 5vw, 44px);
}

.content-card + .content-card {
  margin-top: clamp(32px, 6vw, 48px);
}

.form-card {
  display: grid;
  gap: clamp(20px, 5vw, 28px);
}

.form-grid {
  display: grid;
  gap: clamp(18px, 5vw, 24px);
}

@media (min-width: 640px) {
  .form-grid.two-cols {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: clamp(18px, 4vw, 28px) clamp(16px, 5vw, 32px);
  }
}

.form-field label {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .01em;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  margin-top: 10px;
  border: 1px solid #d8d8d8;
  border-radius: 10px;
  padding: 14px 16px;
  font-size: 1rem;
  font-family: inherit;
  transition: border-color .2s, box-shadow .2s;
  background: #fff;
}

.form-field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, rgba(0,0,0,.4) 50%), linear-gradient(135deg, rgba(0,0,0,.4) 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 4px), calc(100% - 13px) calc(50% - 4px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 42px;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: rgba(177, 17, 17, .5);
  box-shadow: 0 0 0 4px rgba(177, 17, 17, .1);
}

.form-field textarea {
  min-height: 180px;
  resize: vertical;
}

.form-note {
  font-size: .9rem;
  color: #666;
}

.form-actions {
  display: flex;
  justify-content: center;
  margin-top: clamp(12px, 4vw, 20px);
}

.subnav {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, .05);
  padding: clamp(24px, 5vw, 36px);
}

.subnav-title {
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 16px;
}

.subnav ul {
  list-style: none;
  display: grid;
  gap: 10px;
}

.subnav a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--c-bg);
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .02em;
}

.subnav a::after {
  content: "→";
  font-size: .85rem;
  color: var(--c-primary);
}

.content-grid {
  display: grid;
  gap: clamp(28px, 6vw, 40px);
}

.content-grid.two-cols {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: start;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: clamp(16px, 4vw, 24px);
}

.media-grid figure,
.media-grid dl {
  margin: 0;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .05);
  overflow: hidden;
  text-align: center;
  padding-bottom: 12px;
}

.media-grid figcaption,
.media-grid dd {
  padding: 12px 18px 0;
  font-size: .9rem;
}

.table-wrapper {
  width: 100%;
  overflow-x: auto;
  padding-bottom: 12px;
}

.table-wrapper table {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
}

.table-wrapper th,
.table-wrapper td {
  padding: 14px 18px;
  border-bottom: 1px solid #eee;
  text-align: left;
}

.table-wrapper th {
  background: rgba(177, 17, 17, .08);
  font-weight: 700;
  white-space: nowrap;
}

.table-wrapper tr:last-child td {
  border-bottom: none;
}

.number-list {
  counter-reset: number;
  list-style: none;
  display: grid;
  gap: 16px;
}

.number-list li {
  counter-increment: number;
  padding-left: 48px;
  position: relative;
}

.number-list li::before {
  content: counter(number);
  position: absolute;
  left: 0;
  top: 6px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--c-primary);
  color: #fff;
  font-weight: 700;
}

.scroll-box {
  border-radius: 16px;
  border: 1px solid #e5e5e5;
  background: #fff;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05);
  padding: clamp(20px, 4vw, 28px);
  max-height: 520px;
  overflow: auto;
  margin-top: 24px;
}

.scroll-box pre {
  font-family: "Noto Sans JP", sans-serif;
  white-space: pre-wrap;
  font-size: .92rem;
  line-height: 1.7;
}

.cta-panel {
  margin-top: clamp(40px, 8vw, 60px);
  background: linear-gradient(135deg, rgba(177, 17, 17, .92), rgba(177, 17, 17, .75));
  color: #fff;
  border-radius: 20px;
  padding: clamp(36px, 8vw, 54px);
  display: grid;
  gap: 18px;
  text-align: center;
}

.cta-panel p {
  margin: 0 auto;
  max-width: 540px;
}

.cta-panel .cta-btn {
  margin-inline: auto;
}

.cta-btn {
  display: inline-block;
  padding: 14px 42px;
  border-radius: 999px;
  background: #fff;
  color: var(--c-primary);
  font-weight: 700;
  font-size: 1rem;
  transition: transform .3s, box-shadow .3s;
}

.cta-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, .12);
}

.tagline {
  font-size: 1rem;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.hero {
  position: relative;
  min-height: 48vh;
  display: grid;
  place-items: center;
  text-align: center;
  color: #fff;
  padding: clamp(60px, 12vw, 120px) 0;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--hero-image, url("../image/topimg1.jpg")) center/cover no-repeat fixed;
  transform: scale(1);
  animation: heroZoom 20s ease-in-out infinite alternate;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, rgba(0, 0, 0, .6), rgba(0, 0, 0, .35));
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 720px;
  padding-inline: 20px;
}

.hero h1 {
  font-family: "Playfair Display", serif;
  font-size: clamp(2rem, 5vw, 3.4rem);
  letter-spacing: .02em;
  margin-bottom: clamp(12px, 3vw, 18px);
}

.hero p {
  font-size: clamp(1rem, 2.4vw, 1.15rem);
}

@keyframes heroZoom {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.12);
  }
}

header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .9);
  backdrop-filter: saturate(180%) blur(14px);
  box-shadow: 0 1px 6px rgba(0, 0, 0, .06);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.logo img {
  height: 48px;
}

.nav-links {
  display: flex;
  gap: 24px;
  font-weight: 700;
  font-size: .95rem;
}

.nav-links a {
  padding: 6px 0;
  border-bottom: 3px solid transparent;
}

.nav-links a.active,
.nav-links a:hover {
  border-color: var(--c-primary);
}

.burger {
  display: none;
}

footer {
  background: var(--c-dark);
  color: #eee;
  text-align: center;
  padding: 32px 16px;
  font-size: .9rem;
  margin-top: clamp(40px, 8vw, 80px);
}

footer small {
  display: block;
  margin-top: 12px;
  color: #999;
}

.content-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: clamp(24px, 5vw, 32px);
}

.anchor-top {
  margin-top: clamp(32px, 7vw, 48px);
  text-align: right;
}

.anchor-top a {
  font-weight: 600;
  color: var(--c-primary);
}

.note-box {
  background: rgba(177, 17, 17, .08);
  border-radius: 12px;
  padding: 18px 22px;
  margin-top: 24px;
  font-size: .92rem;
}

.split {
  display: grid;
  gap: clamp(24px, 5vw, 36px);
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  align-items: start;
}

.list-inline {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.list-inline li {
  background: var(--c-bg);
  padding: 6px 12px;
  border-radius: 999px;
  font-size: .88rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .nav-links {
    position: fixed;
    top: 70px;
    right: -100%;
    flex-direction: column;
    align-items: center;
    width: 100vw;
    height: calc(100vh - 70px);
    padding-top: 48px;
    gap: 24px;
    font-size: 1.1rem;
    background: #fff;
    box-shadow: -2px 0 8px rgba(0, 0, 0, .08);
    transition: right .4s;
  }

  .burger {
    display: flex;
    width: 32px;
    height: 22px;
    position: relative;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
  }

  .burger span {
    height: 3px;
    background: var(--c-dark);
    border-radius: 2px;
    transition: .3s;
  }

  .nav-open .nav-links {
    right: 0;
  }

  .nav-open .burger span:nth-child(1) {
    transform: translateY(9.5px) rotate(45deg);
  }

  .nav-open .burger span:nth-child(2) {
    opacity: 0;
  }

  .nav-open .burger span:nth-child(3) {
    transform: translateY(-9.5px) rotate(-45deg);
  }

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

  .table-wrapper table {
    min-width: 100%;
  }
}

@media (max-width: 600px) {
  .section {
    padding: clamp(36px, 12vw, 52px) 0;
  }

  .section-title {
    border-left-width: 4px;
    padding-left: 10px;
  }

  .cta-btn {
    width: 100%;
    text-align: center;
  }

  .hero {
    min-height: 44vh;
  }
}

