:root {
  --ink: #173838;
  --ink-soft: #547070;
  --muted: #7b8d8a;
  --paper: #f4f7f2;
  --paper-strong: #ffffff;
  --line: #dce7df;
  --line-strong: #bfd3c7;
  --mint: #d9f1df;
  --mint-strong: #bce8ca;
  --accent: #b9f27b;
  --accent-deep: #456c3a;
  --warning: #fff1c9;
  --warning-ink: #75581e;
  --danger: #8e4038;
  --shadow: 0 24px 80px rgba(36, 77, 64, 0.08);
  --display: "Avenir Next", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --body: "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 6% 4%, rgba(185, 242, 123, 0.22), transparent 23rem),
    radial-gradient(circle at 92% 34%, rgba(188, 232, 202, 0.24), transparent 27rem),
    var(--paper);
  font-family: var(--body);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

.page-shell {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 92px;
  border-bottom: 1px solid rgba(191, 211, 199, 0.62);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 12px;
  color: var(--ink);
  background: var(--accent);
  box-shadow: 4px 4px 0 rgba(23, 56, 56, 0.12);
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
}

.brand-copy {
  display: grid;
  gap: 0;
}

.brand-copy strong {
  font-family: var(--display);
  font-size: 16px;
  letter-spacing: 0.08em;
}

.brand-copy small {
  color: var(--muted);
  font-family: var(--display);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.2em;
}

.local-badge,
.privacy-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #55ad68;
  box-shadow: 0 0 0 4px rgba(85, 173, 104, 0.13);
}

.hero {
  position: relative;
  padding: 92px 0 88px;
}

.hero::after {
  position: absolute;
  top: 66px;
  right: 2%;
  width: 136px;
  height: 136px;
  border: 1px solid rgba(69, 108, 58, 0.25);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.hero::before {
  position: absolute;
  top: 98px;
  right: 6.2%;
  width: 64px;
  height: 64px;
  border: 1px solid rgba(69, 108, 58, 0.18);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.eyebrow,
.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--accent-deep);
  font-family: var(--display);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.2em;
}

.eyebrow > span {
  width: 25px;
  height: 1px;
  background: var(--accent-deep);
}

.hero h1 {
  max-width: 720px;
  margin: 18px 0 18px;
  font-family: var(--display);
  font-size: clamp(42px, 6.6vw, 78px);
  font-weight: 700;
  letter-spacing: -0.07em;
  line-height: 1.12;
}

.hero h1 em {
  position: relative;
  display: inline-block;
  color: var(--accent-deep);
  font-style: normal;
}

.hero h1 em::after {
  position: absolute;
  right: 3px;
  bottom: -3px;
  left: 3px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  content: "";
  opacity: 0.72;
  transform: rotate(-1deg);
  z-index: -1;
}

.hero-lede {
  max-width: 560px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 16px;
  line-height: 2;
}

.hero-lede strong {
  color: var(--ink);
}

.hero-notes {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 34px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.hero-notes span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.hero-notes b {
  color: var(--accent-deep);
  font-family: var(--display);
  font-size: 10px;
  letter-spacing: 0.07em;
}

.download-panel {
  position: relative;
  padding: clamp(28px, 5vw, 56px);
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 31px;
  border-bottom: 1px solid var(--line);
}

.panel-heading h2,
.section-intro h2,
.status-copy h2,
.usage-note h2 {
  margin: 8px 0 0;
  font-family: var(--display);
  font-size: clamp(23px, 3vw, 31px);
  letter-spacing: -0.05em;
  line-height: 1.25;
}

.privacy-chip {
  padding: 8px 13px;
  border: 1px solid var(--mint-strong);
  border-radius: 999px;
  background: rgba(217, 241, 223, 0.55);
  white-space: nowrap;
}

.privacy-chip span {
  color: var(--accent-deep);
}

#download-form {
  display: grid;
  gap: 27px;
  padding-top: 34px;
}

.field-group {
  display: grid;
  gap: 9px;
}

.label-line,
.file-preview,
.format-fieldset legend {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.label-line label,
.format-fieldset legend {
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.label-line span,
.format-fieldset legend span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.url-input-wrap {
  display: flex;
  align-items: center;
  min-height: 64px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: var(--paper-strong);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.url-input-wrap:focus-within {
  border-color: var(--accent-deep);
  box-shadow: 0 0 0 4px rgba(185, 242, 123, 0.34);
}

.url-input-wrap.has-error {
  border-color: var(--danger);
  box-shadow: 0 0 0 4px rgba(142, 64, 56, 0.1);
}

.url-prefix {
  padding-left: 19px;
  color: var(--accent-deep);
  font-size: 21px;
  font-weight: 700;
  line-height: 1;
}

.url-input-wrap input {
  min-width: 0;
  flex: 1;
  height: 62px;
  padding: 0 13px;
  border: 0;
  outline: 0;
  color: var(--ink);
  background: transparent;
  font-family: var(--display);
  font-size: 14px;
}

.url-input-wrap input::placeholder {
  color: #a2b1aa;
}

.clear-button {
  display: grid;
  width: 38px;
  height: 38px;
  margin-right: 10px;
  place-items: center;
  border: 0;
  border-radius: 10px;
  color: var(--ink-soft);
  background: transparent;
  cursor: pointer;
  font-size: 23px;
  line-height: 1;
}

.clear-button:hover,
.clear-button:focus-visible {
  background: var(--mint);
}

.field-help,
.field-error,
.form-footnote {
  margin: 0;
  font-size: 11px;
  line-height: 1.65;
}

.field-help,
.form-footnote {
  color: var(--muted);
}

.field-error {
  color: var(--danger);
  font-weight: 700;
}

.format-fieldset {
  min-width: 0;
  padding: 0;
  border: 0;
}

.format-fieldset legend {
  width: 100%;
  padding: 0;
}

.format-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 11px;
}

.format-option {
  position: relative;
  cursor: pointer;
}

.format-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.format-card {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 72px;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper-strong);
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.format-card:hover {
  border-color: var(--line-strong);
  transform: translateY(-1px);
}

.format-option input:checked + .format-card {
  border-color: var(--accent-deep);
  background: #f2faef;
  box-shadow: inset 0 0 0 1px var(--accent-deep);
}

.format-option input:focus-visible + .format-card {
  outline: 3px solid rgba(185, 242, 123, 0.8);
  outline-offset: 2px;
}

.format-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 10px;
  color: #2d5c3c;
  background: var(--accent);
  font-family: var(--display);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.05em;
}

.format-icon.audio {
  color: #315461;
  background: #c5e6e5;
}

.format-copy {
  display: grid;
  gap: 1px;
}

.format-copy strong {
  font-size: 13px;
}

.format-copy small {
  color: var(--muted);
  font-size: 10px;
}

.radio-indicator {
  width: 17px;
  height: 17px;
  margin-left: auto;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
}

.format-option input:checked + .format-card .radio-indicator {
  border: 5px solid var(--accent-deep);
  background: var(--paper-strong);
}

.file-preview {
  min-height: 40px;
  padding: 10px 13px;
  border-top: 1px dashed var(--line-strong);
  border-bottom: 1px dashed var(--line-strong);
}

.preview-label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.file-preview code {
  max-width: 70%;
  overflow: hidden;
  color: var(--accent-deep);
  font-family: var(--display);
  font-size: 11px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rights-confirmation {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  color: var(--ink-soft);
  font-size: 11px;
  cursor: pointer;
}

.rights-confirmation input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.custom-check {
  display: grid;
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: transparent;
  background: var(--paper-strong);
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.rights-confirmation input:checked + .custom-check {
  border-color: var(--accent-deep);
  color: var(--ink);
  background: var(--accent);
}

.rights-confirmation input:focus-visible + .custom-check {
  outline: 3px solid rgba(185, 242, 123, 0.8);
  outline-offset: 2px;
}

.primary-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 62px;
  padding: 0 21px 0 24px;
  border: 1px solid var(--ink);
  border-radius: 13px;
  color: var(--ink);
  background: var(--accent);
  box-shadow: 4px 4px 0 rgba(23, 56, 56, 0.13);
  cursor: pointer;
  font-family: var(--display);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.06em;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.primary-button:hover:not(:disabled) {
  background: #c8fb8d;
  transform: translate(-1px, -1px);
  box-shadow: 6px 6px 0 rgba(23, 56, 56, 0.13);
}

.primary-button:active:not(:disabled) {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 rgba(23, 56, 56, 0.13);
}

.primary-button:focus-visible {
  outline: 3px solid rgba(69, 108, 58, 0.4);
  outline-offset: 3px;
}

.primary-button:disabled {
  border-color: #c9d5cc;
  color: #94a39a;
  background: #e6ece6;
  box-shadow: none;
  cursor: not-allowed;
}

.button-arrow {
  font-size: 23px;
  font-weight: 400;
  line-height: 1;
}

.form-footnote {
  display: flex;
  align-items: flex-start;
  gap: 7px;
}

.form-footnote span {
  color: var(--accent-deep);
  font-size: 13px;
  line-height: 1.4;
}

.status-panel {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 18px;
  margin-top: 18px;
  padding: 24px 28px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: rgba(217, 241, 223, 0.62);
}

.status-panel[data-state="error"] {
  border-color: #e4bdb7;
  background: #fff3f0;
}

.status-panel[data-state="warning"] {
  border-color: #e8d397;
  background: var(--warning);
}

.status-icon {
  display: grid;
  width: 37px;
  height: 37px;
  place-items: center;
  border-radius: 50%;
  color: var(--ink);
  background: var(--accent);
  font-weight: 900;
}

.status-panel[data-state="error"] .status-icon {
  color: #fff;
  background: var(--danger);
}

.status-panel[data-state="warning"] .status-icon {
  color: var(--warning-ink);
  background: #f0cb69;
}

.status-copy h2 {
  margin-top: 5px;
  font-size: 20px;
}

.status-copy p {
  max-width: 680px;
  margin: 7px 0 0;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.75;
}

.status-meta {
  color: var(--muted) !important;
  font-family: var(--display);
  font-size: 10px !important;
}

.text-link {
  display: inline-flex;
  margin-top: 11px;
  color: var(--accent-deep);
  font-size: 11px;
  font-weight: 800;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.text-link:hover {
  color: var(--ink);
}

.principles {
  display: grid;
  grid-template-columns: minmax(190px, 0.7fr) minmax(0, 1.6fr);
  gap: clamp(30px, 7vw, 100px);
  padding: 112px 0 104px;
}

.section-intro h2 {
  font-size: clamp(25px, 3vw, 37px);
}

.principle-list {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line-strong);
}

.principle-card {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 18px;
  padding: 23px 0 24px;
  border-bottom: 1px solid var(--line);
}

.principle-number {
  color: var(--accent-deep);
  font-family: var(--display);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.principle-card h3 {
  margin: -4px 0 4px;
  font-family: var(--display);
  font-size: 16px;
  letter-spacing: -0.03em;
}

.principle-card p {
  max-width: 560px;
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.8;
}

.usage-note {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 17px;
  padding: 25px 28px;
  border: 1px solid #e8d397;
  border-radius: 16px;
  background: rgba(255, 241, 201, 0.76);
}

.note-mark {
  display: grid;
  width: 27px;
  height: 27px;
  place-items: center;
  border-radius: 8px;
  color: var(--warning-ink);
  background: #f0cb69;
  font-family: var(--display);
  font-size: 13px;
  font-weight: 900;
}

.usage-note h2 {
  margin: 0;
  color: var(--warning-ink);
  font-size: 16px;
}

.usage-note p {
  max-width: 720px;
  margin: 4px 0 0;
  color: var(--warning-ink);
  font-size: 11px;
  line-height: 1.8;
}

.usage-note .text-link {
  margin-top: 3px;
  color: var(--warning-ink);
  white-space: nowrap;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 29px 0 36px;
  color: var(--muted);
  font-family: var(--display);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.13em;
}

@media (max-width: 760px) {
  .page-shell {
    width: min(100% - 30px, 600px);
  }

  .site-header {
    min-height: 75px;
  }

  .local-badge {
    font-size: 0;
  }

  .local-badge .status-dot {
    width: 8px;
    height: 8px;
  }

  .hero {
    padding: 64px 0 58px;
  }

  .hero::after,
  .hero::before {
    display: none;
  }

  .hero h1 {
    font-size: clamp(40px, 13vw, 62px);
  }

  .hero-lede {
    font-size: 14px;
    line-height: 1.9;
  }

  .hero-notes {
    display: grid;
    gap: 5px;
    margin-top: 25px;
  }

  .download-panel {
    padding: 24px 18px 22px;
    border-radius: 20px;
  }

  .panel-heading {
    display: grid;
    gap: 13px;
  }

  .privacy-chip {
    justify-self: start;
  }

  .label-line span,
  .format-fieldset legend span {
    font-size: 9px;
  }

  .url-input-wrap {
    min-height: 58px;
  }

  .url-input-wrap input {
    height: 56px;
    padding: 0 9px;
    font-size: 12px;
  }

  .url-prefix {
    padding-left: 14px;
  }

  .format-grid {
    grid-template-columns: 1fr;
  }

  .status-panel {
    padding: 21px;
  }

  .principles {
    display: block;
    padding: 77px 0 68px;
  }

  .section-intro {
    margin-bottom: 35px;
  }

  .usage-note {
    grid-template-columns: auto 1fr;
    padding: 21px;
  }

  .usage-note .text-link {
    grid-column: 2;
    justify-self: start;
  }

  .site-footer {
    display: grid;
    gap: 6px;
    line-height: 1.5;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
