:root {
  color-scheme: light;
  --page: oklch(0.235 0.028 232);
  --stage: oklch(0.12 0.034 178);
  --surface: oklch(0.982 0.01 86);
  --surface-raised: oklch(0.948 0.012 228);
  --surface-pressed: oklch(0.88 0.052 190);
  --ink: oklch(0.145 0.024 248);
  --muted: oklch(0.345 0.026 238);
  --soft: oklch(0.48 0.028 230);
  --line: oklch(0.69 0.018 230);
  --line-strong: oklch(0.47 0.04 220);
  --accent: oklch(0.43 0.118 190);
  --accent-hover: oklch(0.34 0.118 190);
  --accent-two: oklch(0.75 0.17 82);
  --accent-soft: oklch(0.88 0.06 188);
  --accent-wash: oklch(0.928 0.045 188);
  --warm: oklch(0.5 0.12 42);
  --warning-bg: oklch(0.94 0.045 52);
  --warning-line: oklch(0.72 0.095 42);
  --danger: oklch(0.44 0.12 30);
  --success: oklch(0.34 0.085 150);
  --success-soft: oklch(0.9 0.045 150);
  --preview-bg: oklch(0.095 0.027 188);
  --preview-surface: oklch(0.155 0.034 188);
  --preview-ink: oklch(0.945 0.012 174);
  --preview-muted: oklch(0.77 0.032 176);
  --preview-line: oklch(0.36 0.072 188);
  --prompt-shell: oklch(0.06 0.022 188);
  --prompt-bg: oklch(0.085 0.026 188);
  --prompt-ink: oklch(0.94 0.014 174);
  --prompt-font: SFMono-Regular, ui-monospace, Menlo, Consolas, monospace;
  --focus: oklch(0.66 0.16 190 / 0.38);
  --radius: 8px;
  --radius-lg: 12px;
  --z-skip-link: 5;
  --z-mobile-dock: 4;
  --display:
    "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-family:
    var(--sans);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 0;
}

body {
  min-width: 0;
  margin: 0;
  background:
    linear-gradient(180deg, oklch(0.32 0.035 232 / 0.6) 0, transparent 360px),
    linear-gradient(90deg, var(--page) 0 66%, var(--stage) 66% 100%);
  color: var(--ink);
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

button,
input,
textarea,
summary {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

.skip-link {
  position: fixed;
  z-index: var(--z-skip-link);
  left: 16px;
  top: 16px;
  transform: translateY(-160%);
  border-radius: 999px;
  padding: 10px 14px;
  background: var(--ink);
  color: var(--surface);
  font-weight: 800;
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.app-shell {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 28px;
}

.topbar {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.brand-block {
  display: grid;
  min-width: 0;
  max-width: 880px;
  gap: 8px;
}

h1 {
  max-width: 18ch;
  margin-bottom: 0;
  color: oklch(0.965 0.01 86);
  font-family: var(--display);
  font-size: 3rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.018em;
  overflow-wrap: anywhere;
}

.lede {
  max-width: min(58ch, 100%);
  margin: 2px 0 0;
  color: oklch(0.84 0.018 228);
  font-size: 1rem;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.take-badge {
  flex: 0 0 auto;
  min-width: 92px;
  border: 1px solid oklch(0.78 0.15 82);
  border-radius: 999px;
  padding: 11px 16px;
  background: oklch(0.75 0.17 82 / 0.16);
  color: oklch(0.9 0.12 82);
  font-weight: 900;
  text-align: center;
}

.builder-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.66fr);
  gap: 24px;
  align-items: start;
}

@media (min-width: 1101px) {
  .preview-panel {
    position: sticky;
    top: 24px;
    align-self: start;
  }
}

.builder-panel,
.preview-panel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.builder-panel {
  padding: 26px;
}

.preview-panel {
  overflow: hidden;
  border-color: var(--preview-line);
  background: var(--preview-bg);
  color: var(--preview-ink);
}

.preview-header,
.action-row,
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.preview-header > div {
  min-width: 0;
}

.preview-panel h3,
.preview-panel summary {
  color: var(--preview-ink);
}

h2 {
  font-size: 1.42rem;
  line-height: 1.15;
}

h3 {
  margin-bottom: 0;
  font-size: 1rem;
  line-height: 1.2;
}

.prompt-form {
  display: grid;
  min-width: 0;
  gap: 22px;
}

.story-grid {
  display: grid;
  min-width: 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.starter-frame-strip {
  display: grid;
  min-width: 0;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  background: oklch(0.966 0.008 220);
}

.starter-frame-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.starter-frame-header h3 {
  margin: 0;
}

.starter-frame-header span {
  border-radius: 999px;
  padding: 4px 9px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
}

.starter-frame-grid {
  display: grid;
  min-width: 0;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.starter-frame-button {
  display: grid;
  min-width: 0;
  min-height: 72px;
  align-content: center;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 11px 12px;
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  transition:
    border-color 170ms ease,
    background-color 170ms ease;
}

.starter-frame-button:hover {
  border-color: var(--accent);
  background: var(--accent-wash);
}

.starter-frame-button span,
.starter-frame-button small {
  min-width: 0;
  overflow-wrap: anywhere;
}

.starter-frame-button span {
  font-weight: 900;
  line-height: 1.2;
}

.starter-frame-button small {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
  line-height: 1.25;
}

.option-swatch {
  display: flex;
  gap: 4px;
  min-height: 12px;
  align-items: center;
}

.option-swatch-color {
  width: 24px;
  height: 10px;
  flex: 0 0 24px;
  border: 1px solid rgb(15 23 42 / 0.18);
  border-radius: 999px;
}

.focus-cue {
  display: block;
  margin-top: 2px;
  color: var(--accent);
}

.focus-cue svg {
  display: block;
}

.option-card input:checked + .option-body .focus-cue {
  color: var(--accent-two);
}

.story-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.mobile-prompt-dock {
  display: none;
}

.field {
  display: grid;
  min-width: 0;
  gap: 8px;
  color: var(--ink);
  font-weight: 850;
}

.field > span {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.field :is(input, textarea) {
  min-width: 0;
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 13px 14px;
  background: var(--surface-raised);
  color: var(--ink);
}

.field textarea {
  resize: vertical;
  line-height: 1.35;
}

.field :is(input, textarea)::placeholder {
  color: var(--soft);
  font-weight: 650;
}

.option-group {
  min-width: 0;
  min-inline-size: 0;
  border: 0;
  padding: 0;
  margin: 0;
}

.option-group legend {
  width: 100%;
  margin-bottom: 10px;
  color: var(--ink);
  font-weight: 900;
}

.option-group-note {
  max-width: 68ch;
  margin: -2px 0 12px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.4;
}

.fine-grid .option-group legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.option-grid {
  display: grid;
  min-width: 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.option-grid.starters {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.option-stack {
  display: grid;
  min-width: 0;
  gap: 10px;
}

.constraint-grid {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.option-card {
  min-width: 0;
}

.option-card input,
.constraint-chip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.option-body {
  position: relative;
  display: grid;
  min-height: 92px;
  align-content: start;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 15px;
  background: var(--surface-raised);
  color: var(--ink);
  transition:
    border-color 170ms ease,
    background-color 170ms ease,
    color 170ms ease,
    transform 170ms ease;
}

.option-body::after {
  content: "";
  position: absolute;
  right: 13px;
  top: 13px;
  width: 10px;
  height: 10px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
}

.option-card:hover .option-body,
.constraint-chip:hover span {
  border-color: var(--line-strong);
}

.option-card:hover .option-body {
  transform: translateY(-1px);
}

.option-card input:checked + .option-body {
  border-color: var(--accent);
  background: var(--accent-wash);
}

.option-card input:checked + .option-body::after {
  border-color: var(--accent);
  background: var(--accent);
}

.option-card input:focus-visible + .option-body,
.constraint-chip input:focus-visible + span {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.option-card.is-disabled {
  cursor: not-allowed;
  opacity: 0.42;
}

.option-card.is-disabled .option-body {
  background: var(--surface);
  color: var(--muted);
}

.option-card.is-disabled:hover .option-body {
  border-color: var(--line);
  transform: none;
}

.option-label {
  max-width: calc(100% - 24px);
  font-weight: 900;
  line-height: 1.25;
}

.option-description {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.35;
}

.fine-tune-panel,
.shot-detail-panel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: oklch(0.978 0.004 245);
}

.fine-tune-panel > summary,
.shot-detail-panel > summary {
  display: flex;
  min-height: 54px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
  cursor: pointer;
  color: var(--ink);
  font-weight: 900;
  list-style: none;
}

.fine-tune-panel > summary::after,
.shot-detail-panel > summary::after {
  content: "+";
  display: inline-grid;
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--accent);
  font-weight: 900;
}

.fine-tune-panel[open] > summary::after,
.shot-detail-panel[open] > summary::after {
  content: "-";
}

.fine-tune-panel > summary::-webkit-details-marker,
.shot-detail-panel > summary::-webkit-details-marker {
  display: none;
}

.summary-note {
  border-radius: 999px;
  padding: 4px 9px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
}

.fine-grid,
.shot-detail-grid {
  display: grid;
  min-width: 0;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding: 16px;
}

.shot-detail-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.recommended-craft {
  display: grid;
  gap: 4px;
  border: 1px solid var(--accent-soft);
  border-radius: var(--radius);
  padding: 12px;
  background: var(--accent-wash);
  color: var(--ink);
}

.recommended-craft strong {
  font-size: 0.9rem;
}

.recommended-craft span {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.4;
}

.craft-choice {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.craft-choice summary {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 12px;
  cursor: pointer;
  color: var(--ink);
  font-weight: 900;
  list-style: none;
}

.craft-choice summary::-webkit-details-marker {
  display: none;
}

.craft-choice summary::after {
  content: "+";
  display: inline-grid;
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  place-items: center;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
}

.craft-choice[open] summary::after {
  content: "-";
}

.craft-choice-summary {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 850;
  text-align: right;
}

.craft-choice .option-group {
  display: grid;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding: 12px;
}

.clear-choice-button {
  min-height: 30px;
  width: fit-content;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 10px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 850;
}

.constraint-chip span {
  display: inline-grid;
  min-height: 42px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 13px;
  background: var(--surface-raised);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 850;
  transition:
    border-color 170ms ease,
    background-color 170ms ease,
    color 170ms ease;
}

.constraint-chip input:checked + span {
  border-color: var(--accent);
  background: var(--accent-wash);
  color: var(--accent);
}

.preview-header,
.action-row,
.copy-mode,
.missing-list,
.take-history,
.prompt-output,
.prompt-hint {
  margin: 18px;
}

.preview-header {
  align-items: start;
  justify-content: flex-end;
}

.button-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.missing-list {
  display: grid;
  gap: 6px;
  border: 1px solid var(--preview-line);
  border-radius: var(--radius);
  padding: 10px 12px;
  background: var(--preview-surface);
}

.missing-list:empty {
  display: none;
}

.missing-list p {
  display: flex;
  gap: 8px;
  align-items: start;
  margin: 0;
  color: var(--preview-muted);
  font-weight: 800;
  line-height: 1.35;
}

.missing-list p::before {
  content: "";
  flex: 0 0 6px;
  width: 6px;
  height: 6px;
  margin-top: 0.55em;
  border-radius: 999px;
  background: var(--accent-two);
}

.prompt-output {
  position: relative;
  display: block;
  border-radius: var(--radius-lg);
  padding: 11px;
  background: var(--prompt-shell);
}

.prompt-hint {
  margin-top: 10px;
  color: var(--accent-two);
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.4;
}

.prompt-output textarea {
  min-width: 0;
  width: 100%;
  min-height: 280px;
  resize: vertical;
  border: 1px solid var(--preview-line);
  border-radius: var(--radius);
  padding: 18px;
  background: var(--prompt-bg);
  color: var(--prompt-ink);
  font-family: var(--prompt-font);
  font-size: 1.02rem;
  line-height: 1.62;
  outline: none;
}

.prompt-output textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.prompt-output textarea {
  letter-spacing: 0;
}

.prompt-output textarea.is-updated {
  animation: prompt-update 260ms ease-out;
}

.prompt-output textarea::placeholder {
  color: var(--preview-muted);
}

.copy-mode {
  display: inline-flex;
  gap: 4px;
  width: fit-content;
  border: 1px solid var(--preview-line);
  border-radius: var(--radius);
  padding: 4px;
  background: var(--preview-surface);
}

.copy-mode label {
  position: relative;
}

.copy-mode input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.copy-mode span {
  display: inline-grid;
  min-height: 36px;
  place-items: center;
  border-radius: calc(var(--radius) - 2px);
  padding: 0 12px;
  color: var(--preview-muted);
  font-size: 0.86rem;
  font-weight: 850;
  transition:
    background-color 170ms ease,
    color 170ms ease;
}

.copy-mode input:checked + span {
  background: var(--accent-two);
  color: var(--preview-bg);
}

.copy-mode input:focus-visible + span {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.primary-button,
.secondary-button,
.quiet-button {
  min-height: 44px;
  border-radius: var(--radius);
  padding: 0 16px;
  font-weight: 900;
}

.primary-button {
  border: 0;
  background: var(--accent);
  color: oklch(0.98 0.004 155);
}

.primary-button:hover:not(:disabled) {
  background: var(--accent-hover);
}

.secondary-button {
  border: 1px solid var(--preview-line);
  background: transparent;
  color: var(--preview-ink);
}

.secondary-button:hover:not(:disabled) {
  border-color: var(--accent-two);
  background: oklch(1 0 0 / 0.08);
}

.quiet-button {
  border: 1px solid var(--preview-line);
  background: transparent;
  color: var(--preview-muted);
}

.quiet-button:hover:not(:disabled),
.clear-choice-button:hover:not(:disabled) {
  border-color: var(--accent-two);
}

.copy-status {
  min-width: 74px;
  color: var(--accent-two);
  font-weight: 850;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.action-row {
  align-items: center;
}

.action-row .primary-button {
  min-width: 164px;
  font-size: 1rem;
}

.take-history[hidden] {
  display: none;
}

.take-history-list {
  display: grid;
  margin-top: 10px;
  border-top: 1px solid var(--preview-line);
}

.take-history-item {
  display: grid;
  gap: 10px;
  border-bottom: 1px solid var(--preview-line);
  padding: 12px 0;
}

.take-history-item-header {
  display: grid;
  gap: 6px;
}

.take-history-item-header strong {
  color: var(--accent-two);
}

.take-history-context {
  color: var(--preview-muted);
  font-size: 0.84rem;
  line-height: 1.35;
}

.take-history-meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.take-history-chip {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  border: 1px solid var(--preview-line);
  border-radius: 999px;
  padding: 3px 8px;
  background: var(--preview-surface);
  color: var(--preview-muted);
  font-size: 0.76rem;
  font-weight: 900;
  line-height: 1.2;
}

.take-history-chip.is-still,
.take-history-chip.is-video {
  border-color: oklch(0.78 0.15 82 / 0.72);
  background: oklch(0.75 0.17 82 / 0.13);
  color: var(--accent-two);
}

.take-history-prompt {
  max-height: 8.75rem;
  margin: 0;
  overflow: auto;
  border: 1px solid var(--preview-line);
  border-radius: var(--radius);
  padding: 10px;
  background: var(--preview-surface);
  color: var(--preview-ink);
  font-size: 0.86rem;
  line-height: 1.45;
  white-space: pre-wrap;
}

.take-history-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.take-history-actions .secondary-button {
  min-height: 36px;
  font-size: 0.9rem;
}

@keyframes prompt-update {
  0% {
    border-color: var(--accent-two);
  }

  100% {
    border-color: var(--preview-line);
  }
}

.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;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}

@media (max-width: 1100px) {
  body {
    background:
      linear-gradient(180deg, oklch(0.32 0.035 232 / 0.6) 0, transparent 340px),
      var(--page);
  }

  .builder-layout {
    grid-template-columns: 1fr;
  }

  h1 {
    max-width: none;
  }
}

@media (max-width: 820px) {
  .app-shell {
    padding: 18px;
  }

  .topbar,
  .panel-heading,
  .preview-header,
  .action-row,
  .section-header {
    align-items: stretch;
    flex-direction: column;
  }

  .story-grid,
  .starter-frame-grid,
  .shot-detail-grid,
  .option-grid,
  .option-grid.starters {
    grid-template-columns: 1fr;
  }

  .story-actions {
    align-items: stretch;
  }

  .mobile-prompt-dock {
    position: sticky;
    z-index: var(--z-mobile-dock);
    bottom: 12px;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 8px;
    align-items: center;
    width: 100%;
    border: 1px solid var(--preview-line);
    border-radius: var(--radius-lg);
    padding: 8px;
    background: var(--prompt-shell);
    color: var(--preview-ink);
  }

  .mobile-prompt-dock span {
    color: var(--accent-two);
    font-size: 0.8rem;
    font-weight: 900;
  }

  .mobile-prompt-dock a,
  .mobile-prompt-dock button {
    display: inline-grid;
    min-height: 44px;
    place-items: center;
    border-radius: var(--radius);
    padding: 0 11px;
    font-size: 0.86rem;
    font-weight: 900;
    text-decoration: none;
  }

  .mobile-prompt-dock a {
    border: 1px solid var(--preview-line);
    color: var(--preview-ink);
  }

  .mobile-prompt-dock button {
    border: 0;
    background: var(--accent);
    color: oklch(0.98 0.004 155);
  }

  .button-row {
    justify-content: flex-start;
  }
}

@media (max-width: 520px) {
  .app-shell {
    padding: 14px;
  }

  .brand-block {
    gap: 6px;
  }

  h1 {
    max-width: 12ch;
    font-size: 2.2rem;
    line-height: 1.02;
  }

  .lede {
    font-size: 0.95rem;
  }

  .builder-panel {
    padding: 16px;
  }

  .fine-grid {
    padding: 14px;
  }

  .preview-header,
  .action-row,
  .copy-mode,
  .missing-list,
  .take-history,
  .prompt-output,
  .prompt-hint {
    margin: 14px;
  }

  .prompt-output textarea {
    min-height: 240px;
  }
}

/* Footer: brand line plus collapsible Privacy / Terms disclosures. */
.app-footer {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid oklch(0.42 0.03 228);
  display: grid;
  gap: 14px;
}

.app-footer-brand {
  margin: 0;
  font-size: 0.9rem;
  color: oklch(0.72 0.02 228);
}

.legal-disclosures {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
}

.legal-disclosure {
  min-width: 0;
  flex: 1 1 320px;
}

.legal-disclosure > summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  padding: 4px 2px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.9rem;
  color: oklch(0.86 0.018 228);
  list-style: none;
}

.legal-disclosure > summary::-webkit-details-marker {
  display: none;
}

.legal-disclosure > summary::before {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg);
  transition: transform 160ms ease;
}

.legal-disclosure[open] > summary::before {
  transform: rotate(45deg);
}

.legal-body {
  max-width: 70ch;
  margin-top: 6px;
  font-size: 0.86rem;
  line-height: 1.6;
  color: oklch(0.78 0.018 228);
  overflow-wrap: anywhere;
}

.legal-body p {
  margin: 0 0 10px;
}

.legal-body ul {
  margin: 0 0 10px;
  padding-left: 18px;
  display: grid;
  gap: 6px;
}

.legal-body strong {
  color: oklch(0.9 0.015 228);
}

.legal-body a {
  color: var(--accent-two);
}

.legal-body a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 3px;
}

.legal-meta {
  color: oklch(0.64 0.02 228);
  font-size: 0.82rem;
}
