@import url('https://fonts.googleapis.com/css2?family=Zen+Kaku+Gothic+New:wght@500;700;900&family=Noto+Sans+JP:wght@400;500;700&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

:root {
  /* ===== Color tokens ===== */
  --ink:        #484848;  /* primary text */
  --muted:      #5B6B7C;  /* secondary text */
  --paper:      #E6E6E6;  /* page background */
  --surface:    #FFFFFF;  /* card background */
  --brand:      #0032FF;  /* at+link blue */
  --brand-deep: #0A3D66;  /* deep navy */
  --amber:      #EB7B00;  /* maintenance accent */
  --amber-soft: #FDEEDD;
  --amber-ink:  #9A5A1E;
  --green:      #1F8F5E;  /* normal-operation accent */
  --green-soft: #E1F4EC;
  --green-ink:  #1F7A50;
  --line:       #DCE4ED;  /* hairline borders */
  --line-soft:  #EEF2F7;

  /* ===== Type tokens ===== */
  --font-body:    'Arial', 'Helvetica', 'ヒラギノ角ゴ Pro W3', 'Hiragino Kaku Gothic Pro', 'メイリオ', Meiryo, Osaka, 'ＭＳ Ｐゴシック', 'MS PGothic', sans-serif;
}

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

html { font-size: 16px; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  line-height: 1.7;
  background-color: var(--paper);
  min-height: 100vh;
}

/* ===== Header ===== */
.site-header {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px;
}

.site-logo {
  width: clamp(70px, 22vw, 140px);
  height: auto;
  display: block;
}

/* ===== Main card ===== */
.card {
  max-width: 1000px; margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: clamp(30px, 5vw, 60px);
  box-shadow: 0 24px 60px -32px rgba(10, 61, 102, 0.28);
}

/* ----- Hero ----- */
h1 {
  font-weight: 900;
  font-size: clamp(20px, 4.6vw, 32px);
  line-height: 1.45;
  letter-spacing: 0.02em;
  margin-bottom: 30px;
}
h1 .accent { color: var(--brand); }

.lead {
  color: var(--muted);
  font-size: 16px;
  margin-bottom: 12px;
}
.lead + .lead { margin-bottom: 32px; }

/* ----- Status panel (signature element) ----- */
.status-panel {
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 12px;
}
.status-panel__head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  background: var(--brand-deep);
  color: #FFFFFF;
}
.status-panel__head .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #5BD6A6;
  box-shadow: 0 0 0 0 rgba(91, 214, 166, 0.55);
  animation: live 2.6s ease-out infinite;
  flex-shrink: 0;
}
.status-panel__head span.label {
  font-size: 14px;
  font-weight: 700;
}

.status-row {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 10px 16px;
  padding: 14px 18px;
  border-top: 1px solid var(--line-soft);
}
.status-row.is-maint { background: #FFFBF5; }

.led {
  width: 11px; height: 11px; border-radius: 50%;
  margin-top: 4px;
  flex-shrink: 0;
}
.led.ok    { background: var(--green); box-shadow: 0 0 0 3px var(--green-soft); }
.led.maint {
  background: var(--amber); box-shadow: 0 0 0 3px var(--amber-soft);
  animation: pulse 2.2s ease-in-out infinite;
}

.status-row__body { flex: 1 1 220px; }
.status-row__title { font-weight: 700; font-size: 18px; }
.status-row__sub {
  display: block;
  margin-top: 2px;
  font-size: 14px;
  color: var(--muted);
}

.status-row__state {
  align-self: center;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 5px 12px;
  border-radius: 999px;
  white-space: nowrap;
}
.status-row__state.ok    { color: var(--green-ink); background: var(--green-soft); }
.status-row__state.maint { color: var(--amber-ink); background: var(--amber-soft); }

.status-caption {
  font-size: 14px;
  color: var(--muted);
  margin: 0 4px 60px;
}

/* ----- Divider / section heading ----- */
.section-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 20px;
}
.section-head h2 {
  font-weight: 700;
  font-size: 20px;
  white-space: nowrap;
}
.section-head__line {
  flex: 1;
  height: 1px;
  background: var(--line);
}
.section-intro {
  color: var(--muted);
  font-size: 16px;
  margin-bottom: 30px;
}

/* ----- Contact ports ----- */
.ports {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
@media (max-width: 760px) {
  .ports { grid-template-columns: 1fr; }
}

.port {
  border: 1px solid var(--line);
  border-top: 3px solid var(--brand);
  border-radius: 12px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.port:hover {
  box-shadow: 0 12px 28px -18px rgba(10, 61, 102, 0.35);
  transform: translateY(-2px);
}
.port.is-alert { border-top-color: var(--amber); }
.port.is-deep  { border-top-color: var(--brand-deep); }

.port__head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  margin-bottom: 12px;
}
.port__id {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--muted);
}
.port__head .led { margin-top: 0; }

.port__icon {
  width: 30px; height: 30px;
  margin-bottom: 10px;
  color: var(--brand);
}
.port.is-alert .port__icon { color: var(--amber-ink); }
.port.is-deep  .port__icon { color: var(--brand-deep); }
.port__icon svg { width: 100%; height: 100%; }

.port h3 {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 6px;
}
.port p {
  font-size: 0.84rem;
  color: var(--muted);
  margin-bottom: 14px;
  min-height: 45px;
}

@media (max-width: 760px) {
  .port p {
    min-height: auto;
  }
}

.port dl { margin-bottom: auto; }
.port .line { margin-bottom: 10px; }
.port .line:last-child { margin-bottom: 0; }
.port dt {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin-bottom: 2px;
}
.port dd {
  font-size: 0.95rem;
  font-weight: 600;
  word-break: break-all;
}
.port dd a {
  color: var(--brand-deep);
  text-decoration: none;
}
.port dd a:hover,
.port dd a:focus-visible {
  text-decoration: underline;
}
.port .hours {
  display: block;
  margin-top: 2px;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 400;
  color: var(--muted);
}

/* ===== Footer ===== */
.site-footer {
  margin-top: 40px;
  padding: 30px;
  font-size: 0.78rem;
  color: var(--surface);
  background-color: #3E3E3E;
}
.site-footer .container {
  display: flex;
  align-items: center;
  max-width: 1000px;
  margin: 0 auto;
}
.footer-logo {
  width: clamp(60px, 18vw, 100px);
  height: auto;
  display: block;
  margin-right: auto;
}
.site-footer .group {
  text-align: right;
}
.footer-iso,
.footer-copy {
  font-size: 0.74rem;
  letter-spacing: 0.04em;
}

/* ===== Motion ===== */
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.35; }
}
@keyframes live {
  0%   { box-shadow: 0 0 0 0 rgba(91, 214, 166, 0.5); }
  70%  { box-shadow: 0 0 0 6px rgba(91, 214, 166, 0); }
  100% { box-shadow: 0 0 0 0 rgba(91, 214, 166, 0); }
}
@media (prefers-reduced-motion: reduce) {
  .led.maint,
  .status-panel__head .dot {
    animation: none;
  }
}

a:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* ===== Section spacing ===== */
.card > * + .section-head,
.status-caption + .section-head {
  margin-top: 36px;
}
