:root {
  --ink: #f1edf4;
  --muted: #a9a1ae;
  --paper: #111015;
  --card: #1a181f;
  --line: #302d36;
  --accent: #d7b9ff;
  --accent-soft: #2d2439;
  --verified: #75d6a5;
  --disclosed: #e7c27b;
  --mixed: #eeb484;
  --warning: #ef9da9;
  --caution: #b7b2bc;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

body {
  margin: 0;
  font-family: "Avenir Next", Avenir, "Segoe UI", Helvetica, Arial, sans-serif;
  min-height: 100vh;
  background:
    radial-gradient(60rem 38rem at 52% -10%, rgb(112 73 148 / 19%), transparent 56%),
    var(--paper);
  color: var(--ink);
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 13.75rem minmax(0, 1fr);
}

.app-rail {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 1.35rem 0.8rem;
  display: flex;
  flex-direction: column;
  background: #15131a;
  border-right: 1px solid var(--line);
}

.rail-brand {
  height: 2.9rem;
  padding: 0 0.55rem;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--accent);
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: #201b26;
}

.rail-brand h1 {
  margin: 0;
  color: var(--ink);
  font-size: 0.96rem;
  font-weight: 600;
  letter-spacing: -0.04em;
}

.rail-nav {
  display: grid;
  gap: 0.2rem;
  margin-top: 2.75rem;
}

.rail-nav__item {
  appearance: none;
  width: 100%;
  border: 0;
  border-radius: 0.65rem;
  padding: 0.72rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
}

.rail-nav__item:hover { background: #211e27; color: var(--ink); }
.rail-nav__item.is-active {
  color: var(--ink);
  background: #292331;
  box-shadow: inset 0 0 0 1px rgb(215 185 255 / 14%);
}

.rail-nav__icon {
  width: 1.3rem;
  color: var(--accent);
  font-size: 1.2rem;
  line-height: 1;
  text-align: center;
}

.rail-note {
  margin: auto 0 0;
  padding: 0.8rem 0.45rem 0;
  border-top: 1px solid var(--line);
  color: #797380;
  font-size: 0.68rem;
}

.workspace {
  min-width: 0;
  padding: 0 3.25rem 3rem;
  background: linear-gradient(180deg, rgb(255 255 255 / 1%), transparent 18rem);
}

.site-header {
  padding: 2.4rem 0 2.4rem;
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
}

.site-header__top {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
}

.available-tools-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  flex: 0 0 auto;
  padding: 0.5rem 0.72rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #19161e;
  color: var(--ink);
  font: inherit;
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
}

.available-tools-btn:hover { border-color: #6e587c; background: #211c27; }
.available-tools-btn__dot { width: 0.42rem; height: 0.42rem; border-radius: 50%; background: var(--verified); box-shadow: 0 0 0.5rem rgb(117 214 165 / 60%); }

.site-tagline {
  color: var(--muted);
  margin: -1.8rem 0 0;
  color: #817a88;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.workspace-view {
  max-width: 1100px;
  margin: 0 auto;
}

.view-heading {
  margin: 0 0 1.6rem;
}

.view-heading__eyebrow {
  margin: 0 0 0.25rem;
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.view-heading h2 { margin: 0; font-size: clamp(1.85rem, 3.5vw, 2.65rem); font-weight: 500; letter-spacing: -0.05em; }
.view-heading > p:last-child { max-width: 35rem; margin: 0.55rem 0 0; color: var(--muted); line-height: 1.55; }

.home-view { padding: 2rem 0 1rem; }

.home-hero {
  min-height: min(39rem, calc(100vh - 11rem));
  display: grid;
  grid-template-columns: minmax(18rem, 0.9fr) minmax(26rem, 1.1fr);
  align-items: center;
  gap: 2rem;
}

.home-hero__copy { position: relative; z-index: 2; }

.home-hero__copy h2 {
  max-width: 37rem;
  margin: 0.45rem 0 1.15rem;
  font-size: clamp(2.65rem, 5.2vw, 5.1rem);
  font-weight: 500;
  line-height: 0.98;
  letter-spacing: -0.075em;
}

.home-hero__copy > p:last-of-type {
  max-width: 31rem;
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.65;
}

.home-hero__actions { display: flex; flex-wrap: wrap; gap: 0.65rem; margin-top: 1.6rem; }

.home-action {
  padding: 0.7rem 0.95rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.84rem;
  cursor: pointer;
}

.home-action:hover { background: #24202a; border-color: #66556f; }
.home-action--primary { border-color: transparent; background: #eee6f3; color: #251d2a; }
.home-action--primary:hover { background: #fff7ff; }

.home-hero__art { position: relative; height: min(34rem, 50vw); min-height: 28rem; }

.floating-asset {
  position: absolute;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgb(255 255 255 / 12%);
  background: #24202a;
  box-shadow: 0 1.5rem 3rem rgb(0 0 0 / 32%);
}

.floating-asset img { display: block; width: 100%; height: 100%; object-fit: cover; }
.floating-asset figcaption { position: absolute; left: 0.6rem; bottom: 0.6rem; padding: 0.25rem 0.45rem; border-radius: 999px; background: rgb(14 12 17 / 82%); color: #fff; font-size: 0.63rem; font-weight: 600; }

.floating-asset--one { width: 38%; height: 45%; left: 8%; top: 8%; transform: rotate(-7deg); animation: drift-one 8s ease-in-out infinite; }
.floating-asset--two { width: 42%; height: 34%; right: 1%; top: 9%; transform: rotate(7deg); animation: drift-two 9s ease-in-out infinite; }
.floating-asset--three { width: 48%; height: 42%; right: 14%; bottom: 5%; transform: rotate(-2deg); animation: drift-three 10s ease-in-out infinite; }
.floating-asset--four { width: 27%; height: 24%; left: 2%; bottom: 14%; transform: rotate(9deg); opacity: 0.8; animation: drift-two 7s ease-in-out infinite reverse; }

@keyframes drift-one { 50% { transform: translate(0.4rem, -0.7rem) rotate(-5deg); } }
@keyframes drift-two { 50% { transform: translate(-0.45rem, 0.55rem) rotate(5deg); } }
@keyframes drift-three { 50% { transform: translate(0.25rem, -0.45rem) rotate(0deg); } }

.home-principles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  padding-top: 2.3rem;
  border-top: 1px solid var(--line);
}

.home-principles article { padding-right: 1.25rem; }
.home-principles span { color: var(--accent); font-size: 0.72rem; font-weight: 700; }
.home-principles h3 { margin: 0.65rem 0 0.35rem; font-size: 1rem; font-weight: 600; letter-spacing: -0.02em; }
.home-principles p { margin: 0; color: var(--muted); font-size: 0.82rem; line-height: 1.55; }

.how-to-try {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1rem;
  margin: 1.1rem 0 0;
  padding: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.how-to-try li {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.how-to-try__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.2rem;
  height: 1.2rem;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 700;
}

.uploader {
  max-width: 100%;
  margin: 0;
  padding: 1.45rem;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 1.15rem;
  box-shadow: 0 20px 50px rgb(0 0 0 / 16%);
}

.uploader-dropzone {
  width: min(100%, 27rem);
  min-height: 0;
  aspect-ratio: 1;
  margin-inline: auto;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  border: 1px dashed #5b5362;
  border-radius: 1rem;
  background: #151319;
  color: var(--muted);
  text-align: center;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.uploader-dropzone:hover, .uploader-dropzone.is-dragging { border-color: var(--accent); background: #1d1822; }
.uploader-dropzone.is-dragging { box-shadow: inset 0 0 0 1px rgb(215 185 255 / 30%), 0 0 1.5rem rgb(167 116 211 / 12%); }
.uploader-dropzone__icon { display: grid; place-items: center; margin-bottom: 0.55rem; color: #9cb7ff; }
.uploader-dropzone strong { color: var(--ink); font-size: 1.28rem; font-weight: 500; letter-spacing: -0.04em; }
.uploader-dropzone__formats { color: var(--muted); font-size: 0.82rem; }
.uploader-dropzone__button { min-width: 10.75rem; margin-top: 0.9rem; padding: 0.62rem 1rem; border: 0; border-radius: 0.55rem; background: #93aaff; color: #13121a; font: inherit; font-size: 0.95rem; font-weight: 600; cursor: pointer; }
.uploader-dropzone__button:hover { background: #b0c1ff; }
.uploader-dropzone__filename { max-width: 100%; overflow: hidden; color: var(--accent); font-size: 0.78rem; text-overflow: ellipsis; white-space: nowrap; }

.camera-demo .uploader__heading-row { display: flex; align-items: center; gap: 0.5rem; }
.camera-demo .uploader__icon { display: inline-flex; color: var(--accent); }
.camera-demo .uploader__title { margin: 0 0 0.35rem; font-size: 1.06rem; font-weight: 600; letter-spacing: -0.02em; }
.camera-demo .uploader__hint { margin: 0 0 0.9rem; color: var(--muted); font-size: 0.85rem; line-height: 1.4; }

.camera-demo {
  margin-top: 1rem;
}

.workspace-view .camera-demo { margin-top: 0; }

.concept-tag {
  display: inline-block;
  vertical-align: middle;
  margin-left: 0.4rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
}

.camera-demo__stage {
  width: min(100%, 27rem);
  min-height: 0;
  aspect-ratio: 1;
  margin: 0 auto;
  border: 1px dashed #5b5362;
  border-radius: 1rem;
  overflow: hidden;
  background: #151319;
}

.camera-demo__stage.is-live { border-style: solid; border-color: var(--accent); }

.camera-demo__empty {
  width: 100%;
  height: 100%;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  color: var(--muted);
  text-align: center;
}

.camera-demo__empty strong { color: var(--ink); font-size: 1.12rem; font-weight: 500; letter-spacing: -0.03em; }
.camera-demo__empty .uploader-dropzone__button { margin-top: 0.9rem; }

.camera-demo__stage video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.camera-demo__stage:not(.is-live) video { display: none; }

.camera-demo__controls {
  display: flex;
  gap: 0.6rem;
  width: min(100%, 27rem);
  margin: 0.9rem auto 0;
}

.verify-result {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.verify-result.is-compact { grid-template-columns: minmax(0, 1fr); }

.upload-agent-hint {
  margin: 0.85rem 0 0;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 0.65rem;
  background: #201c25;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.45;
}

.upload-signed-identity {
  display: block;
  width: fit-content;
  margin: 0.85rem 0 0;
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 700;
  text-decoration: none;
}

a.upload-signed-identity:hover { text-decoration: underline; }

.identity-platform-icon {
  display: inline-block;
  font-size: 0.92em;
  line-height: 1;
}

.source-comparison {
  grid-column: 1 / -1;
  background: #15131a;
  border: 1px solid var(--line);
  border-radius: 0.85rem;
  padding: 1.2rem;
}

.source-comparison__heading {
  margin: 0;
  font-size: 1.1rem;
}

.source-comparison__instructions {
  margin: 0.25rem 0 0.7rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.source-comparison__reference { margin: 0.7rem 0 0; color: var(--ink); font-size: 0.9rem; }

.source-comparison__frame {
  position: relative;
  height: clamp(220px, 36vw, 430px);
  overflow: hidden;
  border-radius: 0.7rem;
  background: #0e0912;
  isolation: isolate;
}

.source-comparison__image,
.source-comparison__uploaded-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.source-comparison__image {
  object-fit: cover;
}

.source-comparison__uploaded-layer {
  z-index: 1;
}

.source-comparison__label {
  position: absolute;
  z-index: 3;
  top: 0.65rem;
  padding: 0.28rem 0.45rem;
  border-radius: 4px;
  background: rgb(8 13 22 / 82%);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.source-comparison__label--source { left: 0.65rem; }
.source-comparison__label--file { right: 0.65rem; }

.source-comparison__divider {
  position: absolute;
  z-index: 4;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--ink);
  box-shadow: 0 0 4px rgb(0 0 0 / 45%);
  transform: translateX(-50%);
}

.source-comparison__handle {
  position: absolute;
  z-index: 5;
  top: 50%;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #fff;
  border: 1px solid var(--line);
  color: #0b1120;
  font-size: 1.4rem;
  line-height: 1;
  box-shadow: 0 1px 4px rgb(0 0 0 / 25%);
  transform: translate(-50%, -50%);
}

.source-comparison__slider {
  position: absolute;
  z-index: 6;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}

.provenance-lineage { margin-top: 1.35rem; padding-top: 1.1rem; border-top: 1px solid var(--line); }
.provenance-lineage__heading { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; }
.provenance-lineage__heading h4 { margin: 0; font-size: 0.92rem; }
.provenance-lineage__heading p { margin: 0; color: var(--muted); font-size: 0.78rem; }
.provenance-lineage__track { display: flex; align-items: center; margin: 1rem 0; }
.provenance-step { width: 5.4rem; padding: 0; border: 0; background: transparent; color: var(--muted); font: inherit; text-align: center; cursor: pointer; }
.provenance-step__tile { width: 4.2rem; height: 4.2rem; margin: 0 auto 0.45rem; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 0.7rem; background: #211d27; color: var(--accent); object-fit: cover; transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease; }
.provenance-step__label { display: block; font-size: 0.72rem; line-height: 1.2; }
.provenance-step:hover .provenance-step__tile, .provenance-step.is-selected .provenance-step__tile { border-color: var(--accent); box-shadow: 0 0 0 3px rgb(183 141 255 / 13%); transform: translateY(-2px); }
.provenance-step.is-selected { color: var(--ink); }
.provenance-lineage__connector { flex: 1; min-width: 1.5rem; height: 1px; margin: 0 0.25rem 1.4rem; background: linear-gradient(90deg, var(--accent), var(--line)); }
.provenance-lineage__inspector { min-height: 5.7rem; padding: 0.85rem 1rem; border-radius: 0.7rem; background: #1c1921; }
.provenance-lineage__inspector-label, .provenance-lineage__inspector-meta { display: block; color: var(--accent); font-size: 0.69rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.provenance-lineage__inspector strong { display: block; margin-top: 0.25rem; font-size: 0.93rem; }
.provenance-lineage__inspector p { margin: 0.22rem 0 0.42rem; color: var(--muted); font-size: 0.8rem; line-height: 1.4; }
.provenance-lineage__inspector-meta { color: #a59aac; font-weight: 500; letter-spacing: 0.02em; text-transform: none; }

@media (max-width: 560px) {
  .verify-result {
    grid-template-columns: 1fr;
  }
  .provenance-lineage__heading { display: block; }
  .provenance-lineage__heading p { margin-top: 0.25rem; }
  .provenance-step { width: 4.5rem; }
  .provenance-step__tile { width: 3.5rem; height: 3.5rem; }
}

.verify-result__col {
  background: #15131a;
  border: 1px solid var(--line);
  border-radius: 0.85rem;
  padding: 0.85rem;
}

.verify-result__heading {
  margin: 0 0 0.6rem;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
}

.credential-details {
  margin-top: 0.85rem;
  padding-top: 0.8rem;
  border-top: 1px solid var(--line);
}

.credential-details h3 {
  margin: 0 0 0.65rem;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.credential-details dl {
  margin: 0;
}

.credential-details__item {
  display: grid;
  gap: 0.15rem;
  margin-top: 0.55rem;
}

.credential-details__item:first-child {
  margin-top: 0;
}

.credential-details dt {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--muted);
}

.credential-details dd {
  margin: 0;
  font-size: 0.88rem;
  overflow-wrap: anywhere;
}

.credential-details a {
  color: var(--accent);
}

.verify-result__preview {
  margin-bottom: 0.6rem;
}

.verify-result__preview-img {
  width: 100%;
  max-height: 220px;
  object-fit: cover;
  border-radius: 8px;
  display: block;
  background: #0e0912;
}

/* An uploaded artwork is the subject of the check, so never crop it into
   the compact card-preview ratio used elsewhere in the interface. */
#uploader-preview .verify-result__preview-img {
  width: auto !important;
  max-width: 100% !important;
  height: auto !important;
  max-height: 70vh !important;
  margin-inline: auto;
  object-fit: contain !important;
  aspect-ratio: auto !important;
}

.verify-result__source {
  min-height: 2rem;
}

.traced-source__label {
  margin: 1rem 0 0.25rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.verify-result__preview + .traced-source__label { margin-top: 0.65rem; }

.traced-source__asset-name {
  margin: 0;
  overflow-wrap: anywhere;
  font-weight: 700;
}

.verify-result__empty {
  color: var(--muted);
  font-style: italic;
}

.verify-result__link {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--ink);
}

.card__source {
  margin-top: 0.9rem;
  border-top: 1px solid var(--line);
  padding-top: 0.9rem;
}

.feed {
  margin: 0;
  padding: 0;
  columns: 3 16rem;
  column-gap: 1.15rem;
}

.card {
  position: relative;
  display: inline-block;
  width: 100%;
  margin: 0 0 1.15rem;
  break-inside: avoid;
  background: #19171d;
  border: 1px solid rgb(255 255 255 / 7%);
  border-radius: 0.45rem;
  overflow: hidden;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.card:hover {
  box-shadow: 0 18px 34px rgb(0 0 0 / 30%);
  transform: translateY(-2px);
}

.card__image {
  width: 100%;
  display: block;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #0e0912;
}

video.card__image {
  background: #111;
}

.card:nth-child(3n + 1) .card__image { aspect-ratio: 3 / 4; }
.card:nth-child(4n + 2) .card__image { aspect-ratio: 16 / 10; }
.card:nth-child(5n) .card__image { aspect-ratio: 1 / 1; }

.card__body {
  position: absolute;
  inset: auto 0 0;
  z-index: 1;
  padding: 2.75rem 1rem 1rem;
  background: linear-gradient(transparent, rgb(11 9 14 / 94%) 44%);
  opacity: 0;
  transform: translateY(0.4rem);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.card:hover .card__body,
.card:focus-within .card__body,
.card.is-expanded .card__body { opacity: 1; transform: translateY(0); }

.card.is-expanded .card__body {
  position: static;
  padding-top: 1rem;
  background: var(--card);
}

.card__title {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 0.25rem;
}

.card__caption {
  color: var(--muted);
  font-size: 0.8rem;
  margin: 0 0 0.75rem;
}

.card__verify-btn {
  background: #eee6f3;
  color: #231c29;
  border: none;
  border-radius: 0.6rem;
  padding: 0.55rem 0.9rem;
  font-size: 0.9rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: filter 0.15s ease;
}

.card__verify-btn:hover:not(:disabled) {
  filter: brightness(1.15);
}

.card__verify-btn:disabled {
  opacity: 0.7;
  cursor: default;
}

.card__verify-btn.is-loading::after {
  content: "";
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.card__result {
  margin-top: 0.75rem;
  border-top: 1px solid var(--line);
  padding-top: 0.9rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  background: #2a2730;
  color: var(--ink);
}

.badge::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
}

.badge--verified { background: #1d3329; color: var(--verified); }
.badge--disclosed { background: #39301f; color: var(--disclosed); }
.badge--mixed { background: #3c2921; color: var(--mixed); }
.badge--warning { background: #3f252c; color: var(--warning); }
.badge--caution { background: #2b2930; color: var(--caution); }

.card__explanation {
  margin: 0.6rem 0 0;
  font-size: 0.92rem;
  line-height: 1.4;
}

.site-footer {
  max-width: 900px;
  margin: 2rem auto 0;
  padding: 0;
  color: var(--muted);
  font-size: 0.82rem;
  text-align: center;
}

.tools-dialog {
  width: min(33rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  margin: auto;
  padding: 1.35rem;
  border: 1px solid #43364a;
  border-radius: 1.15rem;
  background: #1a171e;
  color: var(--ink);
  box-shadow: 0 2rem 5rem rgb(0 0 0 / 55%);
  overflow: auto;
}

.tools-dialog::backdrop { background: rgb(6 5 8 / 70%); backdrop-filter: blur(5px); }
.tools-dialog__header { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; }
.tools-dialog__eyebrow { margin: 0 0 0.25rem; color: var(--accent); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.tools-dialog h2 { margin: 0; font-size: 1.45rem; letter-spacing: -0.04em; }
.tools-dialog__close { width: 2rem; height: 2rem; border: 1px solid var(--line); border-radius: 50%; background: transparent; color: var(--muted); font: inherit; font-size: 1.4rem; line-height: 1; cursor: pointer; }
.tools-dialog__close:hover { color: var(--ink); background: #28232c; }
.tools-dialog__intro { margin: 0.75rem 0 1.1rem; color: var(--muted); font-size: 0.9rem; line-height: 1.5; }
.tools-dialog__list { display: grid; gap: 0.55rem; padding: 0; margin: 0; list-style: none; }
.tools-dialog__list li { display: grid; gap: 0.32rem; padding: 0.8rem; border: 1px solid var(--line); border-radius: 0.7rem; background: #15131a; }
.tools-dialog code { color: #eddcff; font: 600 0.8rem ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.tools-dialog__list span, .tools-dialog__footnote { color: var(--muted); font-size: 0.8rem; line-height: 1.45; }
.tools-dialog__footnote { margin: 1rem 0 0; }

@media (max-width: 700px) {
  .app-shell { display: block; }
  .app-rail {
    position: static;
    height: auto;
    padding: 0.7rem 0.85rem;
    flex-direction: row;
    align-items: center;
    gap: 0.8rem;
    border-right: 0;
    border-bottom: 1px solid rgb(232 190 255 / 18%);
  }
  .rail-brand { height: 2.25rem; flex: 0 0 auto; }
  .rail-brand h1 { display: none; }
  .rail-nav { margin: 0; display: flex; gap: 0.25rem; overflow-x: auto; }
  .rail-nav__item { width: auto; white-space: nowrap; padding: 0.55rem 0.6rem; }
  .rail-note { display: none; }
  .workspace { padding: 0 1rem 1.5rem; }
  .site-header__top { align-items: flex-start; }
  .home-view { padding-top: 0.5rem; }
  .home-hero { min-height: 0; grid-template-columns: 1fr; gap: 1.5rem; }
  .home-hero__art { height: 20rem; min-height: 0; }
  .home-principles { grid-template-columns: 1fr; gap: 1.3rem; }
  .home-principles article { padding-right: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .floating-asset { animation: none; }
  .card, .card__body { transition: none; }
}
