/* caprix.jp — 控えめな一覧（I 案） */
:root {
  color-scheme: light;
  --bg: #f6f6f3;
  --field: #fbfbf9;
  --ink: #141414;
  --ink-2: #3a3a36;
  --ink-3: #4a4a46;
  --muted: #6b6b66;
  --rule: #cfcfc9;
  --rule-2: #b5b5ae;
  --live: #1f8a4c;
  --error: #b42318;
  --warn: #b7791f;
  --error-bg: #fdf3f2;
  --sans: "CX Grotesk", "CX Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --jp: "CX Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --serif: "CX Serif", "Times New Roman", serif;
  --mono: "CX Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --pad: clamp(20px, 5vw, 72px);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

img,
svg {
  display: block;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 4px;
}

.wrap {
  width: 100%;
  max-width: 1440px;
  margin-inline: auto;
  padding-inline: var(--pad);
}

.mono {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0;
}

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

.small {
  font-family: var(--jp);
  font-size: 13px;
}

.text-link {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.text-link:hover {
  text-decoration-thickness: 2px;
}

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 10;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--jp);
  font-size: 14px;
}

.skip:focus {
  top: 12px;
}

/* ヘッダー */
.site-header {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  font-size: 24px;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.brand-sm {
  font-size: 20px;
}

.site-nav,
.footer-nav {
  display: flex;
  align-items: center;
  gap: 36px;
  font-family: var(--jp);
  font-size: 14px;
}

.nav-link {
  color: var(--ink-3);
  transition: color 160ms ease;
}

.nav-link:hover,
.nav-link[aria-current] {
  color: var(--ink);
}

.nav-pill {
  height: 44px;
  display: inline-flex;
  align-items: center;
  padding: 0 20px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  transition: background-color 160ms ease, color 160ms ease;
}

.nav-pill:hover,
.nav-pill[aria-current] {
  background: var(--ink);
  color: var(--bg);
}

/* ヒーロー */
.hero {
  padding-top: 104px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 64px;
}

.hero p {
  margin: 0;
}

.hero-title {
  margin: 28px 0 0;
  font-family: var(--sans);
  font-size: clamp(56px, 8.4vw, 124px);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-lead {
  max-width: 340px;
  margin-bottom: 16px !important;
  font-family: var(--jp);
  font-size: 15px;
  line-height: 2;
  color: var(--ink-3);
  /* 日本語を文節で折り返す（「一覧で／す。」のような切れ方を防ぐ） */
  word-break: auto-phrase;
  text-wrap: pretty;
}

/* 五本の線 */
.waves {
  position: relative;
  margin-top: 72px;
  height: 150px;
  overflow: hidden;
}

.waves-svg {
  position: absolute;
  left: 0;
  top: 0;
  overflow: visible;
}

.w {
  stroke: var(--ink);
  stroke-width: 1;
  will-change: transform;
}

.w0 { stroke-opacity: 0.4; animation: w0 16s linear infinite; }
.w1 { stroke-opacity: 0.5; animation: w1 22s linear infinite; }
.w2 { stroke-opacity: 0.7; stroke-width: 1.2; animation: w2 12s linear infinite; }
.w3 { stroke-opacity: 0.5; animation: w3 19s linear infinite; }
.w4 { stroke-opacity: 0.4; animation: w4 26s linear infinite; }

@keyframes w0 { to { transform: translateX(-360px); } }
@keyframes w1 { to { transform: translateX(-480px); } }
@keyframes w2 { to { transform: translateX(-300px); } }
@keyframes w3 { to { transform: translateX(-420px); } }
@keyframes w4 { to { transform: translateX(-540px); } }

/* 見出し */
.display {
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 14px;
  font-family: var(--sans);
  font-size: 56px;
  font-weight: 300;
  letter-spacing: -0.03em;
  line-height: 1;
}

.display-sm {
  font-size: 40px;
  letter-spacing: -0.02em;
}

.count {
  font-size: 14px;
  font-weight: 400;
}

/* サービス一覧 */
.services {
  margin-top: 96px;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 28px;
}

.service-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-bottom: 1px solid var(--rule);
}

.svc-row {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) 440px 112px 32px;
  grid-template-areas: "no name desc status arrow";
  column-gap: 32px;
  align-items: center;
  padding: 36px 0;
  border-top: 1px solid var(--rule);
}

.svc-no { grid-area: no; font-size: 13px; }
.svc-name { grid-area: name; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.svc-desc { grid-area: desc; font-family: var(--jp); font-size: 15px; line-height: 1.9; color: var(--ink-2); }
.svc-row .status { grid-area: status; }
.svc-row .arrow,
.svc-row .arrow-none { grid-area: arrow; }

.svc-domain {
  font-size: 56px;
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1;
  overflow-wrap: anywhere;
  transition: transform 360ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.svc-sub {
  font-family: var(--jp);
  font-size: 14px;
  color: var(--muted);
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--jp);
  font-size: 13px;
  white-space: nowrap;
}

.status-dot {
  width: 8px;
  height: 8px;
  flex-shrink: 0;
  border-radius: 50%;
}

.status-dot.is-live { background: var(--live); }
.status-dot.is-soon { border: 1.5px dashed var(--muted); }
.status-dot.is-down { background: var(--error); }

.arrow {
  opacity: 0.25;
  transition: opacity 240ms ease, transform 240ms ease;
}

.svc-row.is-link:hover .svc-domain,
.svc-row.is-link:focus-visible .svc-domain {
  transform: translateX(10px);
}

.svc-row.is-link:hover .arrow,
.svc-row.is-link:focus-visible .arrow {
  opacity: 1;
  transform: translateX(4px);
}

.is-next .svc-row {
  border-top-style: dashed;
  border-top-color: var(--rule-2);
  color: var(--muted);
}

.svc-next {
  grid-area: name;
  font-family: var(--jp);
  font-size: 32px;
  font-weight: 300;
}

.is-next .svc-desc {
  color: var(--muted);
}

/* 左に見出し、右に本文の段組み */
.split {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  column-gap: 64px;
}

section.split {
  margin-top: 128px;
}

.split-head {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* お知らせ */
.news-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-bottom: 1px solid var(--rule);
}

.news-item {
  display: grid;
  grid-template-columns: 140px 160px minmax(0, 1fr);
  column-gap: 24px;
  align-items: baseline;
  padding: 20px 0;
  border-top: 1px solid var(--rule);
}

.news-item .mono {
  font-size: 13px;
}

.news-domain {
  font-size: 18px;
}

.news-text {
  font-family: var(--jp);
  font-size: 15px;
}

/* About */
.about-body {
  max-width: 780px;
  font-family: var(--jp);
}

.about-lead {
  margin: 0;
  font-size: 28px;
  font-weight: 300;
  line-height: 1.9;
}

.serif {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.3em;
  line-height: 1;
}

.facts {
  margin: 40px 0 0;
  padding-top: 20px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 24px;
  border-top: 1px solid var(--rule);
}

.facts div {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.facts dt {
  font-size: 12px;
  color: var(--muted);
}

.facts dd {
  margin: 0;
  font-size: 15px;
}

/* フッター */
.site-footer {
  margin-top: 160px;
  padding-bottom: 40px;
}

.staff-rule {
  height: 25px;
  background: repeating-linear-gradient(180deg, rgba(20, 20, 20, 0.3) 0 1px, transparent 1px 6px);
}

.footer-row {
  padding-top: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.footer-nav {
  gap: 28px;
  font-size: 13px;
}

/* 下層ページ */
.page {
  padding-top: 104px;
}

.page-lead {
  margin: 0 0 32px;
  font-family: var(--jp);
  font-size: 17px;
  line-height: 2;
}

.form-wrap {
  max-width: 720px;
  font-family: var(--jp);
}

.form-wrap p {
  margin: 0 0 16px;
}

.form-alert {
  margin-bottom: 28px;
  padding: 14px 16px;
  border: 1px solid var(--error);
  background: var(--error-bg);
  color: #8a1c13;
  font-size: 14px;
}

.contact-form {
  position: relative;
}

.field {
  margin-bottom: 28px;
}

.field label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 500;
}

.req,
.opt {
  font-size: 11px;
  font-weight: 400;
  padding: 1px 8px;
  border-radius: 999px;
}

.req {
  background: var(--ink);
  color: var(--bg);
}

.opt {
  border: 1px solid var(--rule-2);
  color: var(--muted);
}

.field input,
.field textarea,
.field select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--rule);
  border-radius: 2px;
  background: var(--field);
  color: var(--ink);
  font: inherit;
  font-size: 17px;
  line-height: 1.7;
  transition: border-color 160ms ease;
  appearance: none;
}

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

.field input:hover,
.field textarea:hover,
.field select:hover {
  border-color: var(--rule-2);
}

.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: var(--ink);
  outline: none;
}

.field input:focus-visible,
.field textarea:focus-visible,
.field select:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.field [aria-invalid="true"] {
  border-color: var(--error);
}

.select {
  position: relative;
}

.select::after {
  content: "";
  position: absolute;
  right: 18px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 1.4px solid var(--ink);
  border-bottom: 1.4px solid var(--ink);
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}

.field-help {
  margin: 8px 0 0 !important;
  text-align: right;
}

.field-help.is-over {
  color: var(--error);
}

.field-error {
  margin: 8px 0 0 !important;
  color: var(--error);
  font-size: 13px;
}

.trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.cf-turnstile {
  margin: 8px 0 24px;
  min-height: 65px;
}

.privacy-note {
  font-size: 13px;
  line-height: 1.9;
}

.submit {
  height: 56px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  padding: 0 24px 0 28px;
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--jp);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 160ms ease;
}

.submit .arrow {
  opacity: 1;
}

.submit:hover {
  background: #33332f;
}

.submit:hover .arrow {
  transform: translateX(4px);
}

.submit[disabled] {
  opacity: 0.6;
  cursor: progress;
}

/* プライバシーポリシー */
.prose {
  max-width: 760px;
  font-family: var(--jp);
  font-size: 15px;
  line-height: 2;
}

.prose p {
  margin: 0 0 16px;
}

.prose h2 {
  margin: 40px 0 12px;
  font-size: 18px;
  font-weight: 500;
}

.prose ul {
  margin: 0 0 16px;
  padding-left: 1.2em;
}

/* タブレット */
@media (max-width: 1100px) {
  .svc-row {
    grid-template-columns: 48px minmax(0, 1fr) auto 28px;
    grid-template-areas:
      "no name status arrow"
      ". desc desc .";
    row-gap: 16px;
  }

  .svc-domain {
    font-size: 48px;
  }

  .split {
    grid-template-columns: 240px minmax(0, 1fr);
    column-gap: 40px;
  }
}

/* スマートフォン */
@media (max-width: 720px) {
  .site-header {
    height: 60px;
  }

  .brand {
    font-size: 21px;
  }

  .site-nav .nav-link {
    display: none;
  }

  .nav-pill {
    padding: 0 16px;
    font-size: 13px;
  }

  .hero {
    padding-top: 48px;
    flex-direction: column;
    align-items: stretch;
    gap: 20px;
  }

  .hero-title {
    margin-top: 20px;
    line-height: 1.04;
  }

  .hero-lead {
    max-width: none;
    margin-bottom: 0 !important;
    font-size: 14px;
  }

  .waves {
    margin-top: 40px;
    height: 110px;
  }

  .waves-svg {
    width: 2816px;
    height: 110px;
  }

  .services {
    margin-top: 64px;
  }

  .section-head {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    padding-bottom: 16px;
  }

  .display {
    font-size: 40px;
    gap: 10px;
  }

  .display-sm {
    font-size: 32px;
  }

  .svc-row {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "no status"
      "name arrow"
      "desc desc";
    row-gap: 10px;
    column-gap: 12px;
    padding: 28px 0;
  }

  .svc-no {
    font-size: 12px;
  }

  .svc-domain {
    font-size: 36px;
    line-height: 1.05;
  }

  .svc-name {
    gap: 8px;
  }

  .svc-sub {
    font-size: 13px;
  }

  .svc-desc {
    font-size: 14px;
  }

  .status {
    font-size: 12px;
    gap: 8px;
  }

  .svc-row .arrow {
    width: 24px;
    height: 24px;
    align-self: start;
    margin-top: 6px;
    opacity: 0.5;
  }

  .svc-next {
    font-size: 24px;
  }

  .svc-row.is-link:hover .svc-domain {
    transform: none;
  }

  .split {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 16px;
  }

  section.split {
    margin-top: 80px;
  }

  .news-item {
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas:
      "date domain"
      "text text";
    column-gap: 12px;
    row-gap: 6px;
    padding: 16px 0;
  }

  .news-item time { grid-area: date; font-size: 12px; }
  .news-domain { grid-area: domain; font-size: 16px; }
  .news-text { grid-area: text; font-size: 14px; line-height: 1.8; }

  .about-lead {
    font-size: 21px;
  }


  .facts {
    margin-top: 24px;
    padding-top: 0;
    grid-template-columns: minmax(0, 1fr);
  }

  .facts div {
    flex-direction: row;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--rule);
  }

  .site-footer {
    margin-top: 96px;
    padding-bottom: 32px;
  }

  .footer-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding-top: 20px;
  }

  .footer-nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }

  .footer-nav .nav-link {
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .page {
    padding-top: 48px;
  }

  .page-lead {
    font-size: 15px;
  }

  .submit {
    width: 100%;
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .w,
  .svc-domain,
  .arrow {
    animation: none !important;
    transition: none !important;
  }
}

/* 稼働状況 */
.status-summary {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0;
  font-family: var(--jp);
  font-size: 24px;
  font-weight: 400;
  line-height: 1.5;
}

.status-summary .status-dot {
  width: 10px;
  height: 10px;
}

.status-summary.is-down {
  color: var(--error);
}

.status-note {
  margin: 10px 0 0;
  font-family: var(--jp);
}

.uptime-list {
  list-style: none;
  margin: 48px 0 0;
  padding: 0;
  border-bottom: 1px solid var(--rule);
}

.uptime-item {
  padding: 28px 0 24px;
  border-top: 1px solid var(--rule);
}

.uptime-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.uptime-domain {
  font-size: 30px;
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.uptime-domain:hover {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 6px;
}

.uptime-bars {
  width: 100%;
  height: 34px;
  margin-top: 18px;
}

.bar { fill: var(--rule); }
.bar.is-up { fill: var(--live); }
.bar.is-partial { fill: var(--warn); }
.bar.is-down { fill: var(--error); }

.uptime-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
  font-size: 12px;
}

.uptime-rate {
  color: var(--ink-2);
}

.status-h2 {
  margin: 72px 0 0;
  font-family: var(--jp);
  font-size: 16px;
  font-weight: 500;
}

.incident-list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  border-bottom: 1px solid var(--rule);
}

.incident-item {
  display: grid;
  grid-template-columns: 250px 120px minmax(0, 1fr);
  column-gap: 24px;
  align-items: baseline;
  padding: 14px 0;
  border-top: 1px solid var(--rule);
  font-size: 14px;
}

.incident-item .mono {
  font-size: 13px;
}

.incident-text {
  font-family: var(--jp);
}

.incident-detail {
  margin-left: 1em;
}

.incident-none {
  margin: 12px 0 0;
  font-family: var(--jp);
  font-size: 14px;
}

@media (max-width: 720px) {
  .status-summary {
    font-size: 18px;
    gap: 12px;
  }

  .uptime-domain {
    font-size: 24px;
  }

  .uptime-bars {
    height: 28px;
  }

  .incident-item {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 2px;
  }
}

/* 画面には出さず、読み上げだけに使う */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* 動きの案の切り替え（preview.caprix.jp だけ） */
.preview-bar {
  position: fixed;
  left: 50%;
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 2px;
  max-width: calc(100vw - 24px);
  padding: 5px;
  border-radius: 999px;
  background: rgba(20, 20, 20, 0.9);
  box-shadow: 0 12px 40px -12px rgba(20, 20, 20, 0.5);
  font-family: var(--jp);
  font-size: 13px;
  transform: translateX(-50%);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.preview-label {
  padding: 0 8px 0 12px;
  color: rgba(246, 246, 243, 0.55);
  white-space: nowrap;
}

.preview-bar a {
  padding: 8px 14px;
  border-radius: 999px;
  color: #f6f6f3;
  white-space: nowrap;
  transition: background-color 160ms ease;
}

.preview-bar a:hover {
  background: rgba(246, 246, 243, 0.14);
}

.preview-bar a[aria-current] {
  background: #f6f6f3;
  color: #141414;
}

@media (max-width: 720px) {
  .preview-label {
    display: none;
  }

  .preview-bar {
    font-size: 12px;
  }

  .preview-bar a {
    padding: 8px 11px;
  }
}
