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

.composer-count {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink-soft);
}

.composer-count.is-over {
  color: #9f1e1e;
}

.story-card,
.empty-state {
  border-radius: 4px;
  padding: 14px;
  background: var(--card-bg);
  border: 1px solid #8e8e8e;
  box-shadow: var(--bevel-out);
}

.story-card {
  display: grid;
  gap: 14px;
}

.story-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.story-byline {
  display: grid;
  gap: 4px;
}

.story-author {
  font-weight: 700;
}

.story-handle,
.story-date,
.story-meta,
.story-link {
  color: var(--ink-soft);
}

.story-copy {
  margin: 0;
  white-space: pre-wrap;
  line-height: 1.5;
}

.story-action-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  font-size: 0.82rem;
  padding-top: 4px;
  border-top: 1px dotted rgba(0, 0, 0, 0.28);
}

.story-action-button {
  min-width: 96px;
  padding-inline: 10px;
}

.story-action-button.is-active {
  background: linear-gradient(180deg, var(--accent), var(--accent));
  color: #fff;
  border-color: var(--accent-deep);
  box-shadow: var(--bevel-in);
}

.story-embed {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 14px;
  align-items: start;
  border-top: 1px solid rgba(56, 47, 40, 0.2);
  padding-top: 14px;
}

.story-embed-stack {
  display: grid;
  gap: 12px;
}

.story-embed img {
  width: 88px;
  height: 88px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid #5a5a5a;
}

.story-external-card {
  color: inherit;
  text-decoration: none;
}

.story-link-host {
  display: inline-block;
  margin-top: 6px;
  font-size: 0.78rem;
  color: var(--ink-soft);
}

.story-image-grid {
  display: grid;
  gap: 8px;
}

.story-image-grid-1 {
  grid-template-columns: 1fr;
}

.story-image-grid-2,
.story-image-grid-4 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.story-image-grid-3 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.story-image-grid-3 .story-image-link:first-child {
  grid-row: span 2;
}

.story-image-link {
  display: block;
  min-width: 0;
}

.story-image {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid #5a5a5a;
  border-radius: 4px;
  background: var(--surface-1);
}

.story-video-wrap {
  display: grid;
  gap: 8px;
}

.story-video {
  display: block;
  width: 100%;
  max-height: 520px;
  border: 1px solid #5a5a5a;
  border-radius: 4px;
  background: #000;
}

.story-media-caption {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.82rem;
}
.story-quote-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid #8e8e8e;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--quote-surface-1), var(--quote-surface-2));
  box-shadow: var(--bevel-out);
  color: inherit;
  text-decoration: none;
}

.prefs-icon-image {
  display: block;
  object-fit: contain;
  image-rendering: pixelated;
}

.prefs-icon-image-desktop {
  width: 72px;
  height: 72px;
}

.prefs-icon-image-mini {
  width: 24px;
  height: 24px;
}

.prefs-window {
  overflow: auto;
}

.prefs-window-body {
  display: grid;
  gap: 16px;
  padding: 16px;
  background:
    linear-gradient(180deg, var(--surface-1), var(--window));
}

.prefs-section {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #8e8e8e;
  border-radius: 4px;
  background: var(--card-bg);
  box-shadow: var(--bevel-out);
}

.prefs-section h2 {
  margin: 0;
  font-size: 1rem;
}

.prefs-toggle-row {
  display: flex;
  gap: 8px;
}

.prefs-toggle-button.is-active {
  background: linear-gradient(180deg, var(--accent), var(--accent));
  color: #fff;
  border-color: var(--accent-deep);
  box-shadow: var(--bevel-in);
}

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

.wallpaper-swatch {
  width: 48px;
  height: 48px;
  border: 2px solid #8e8e8e;
  border-radius: 4px;
  cursor: pointer;
  box-shadow: var(--bevel-out);
  padding: 0;
}

.wallpaper-swatch:active {
  box-shadow: var(--bevel-in);
  transform: translate(1px, 1px);
}

.wallpaper-swatch.is-active {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent);
}

.wallpaper-swatch-mesh {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.15) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.15) 1px, transparent 1px),
    linear-gradient(180deg, #4e84b3, #3e6f9c);
  background-size: 4px 4px, 4px 4px, 100% 100%;
}

.wallpaper-swatch-amethyst {
  background:
    linear-gradient(45deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px),
    linear-gradient(-45deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px),
    linear-gradient(180deg, #6b4a8a, #452d6b);
  background-size: 6px 6px, 6px 6px, 100% 100%;
}

.wallpaper-swatch-seafoam {
  background:
    radial-gradient(circle, rgba(255, 255, 255, 0.14) 1px, transparent 1px),
    linear-gradient(180deg, #3a8a7a, #1f6458);
  background-size: 5px 5px, 100% 100%;
}

.wallpaper-swatch-fern {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.1) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.1) 1px, transparent 1px),
    linear-gradient(180deg, #4a7a3a, #2d5c1f);
  background-size: 6px 6px, 6px 6px, 100% 100%;
}

.wallpaper-swatch-slate {
  background:
    repeating-linear-gradient(
      -45deg,
      rgba(255, 255, 255, 0.06),
      rgba(255, 255, 255, 0.06) 1px,
      transparent 1px,
      transparent 4px
    ),
    linear-gradient(180deg, #5a5e66, #3a3d44);
}

.wallpaper-swatch-sunset {
  background:
    linear-gradient(90deg, rgba(255, 214, 153, 0.2) 1px, transparent 1px),
    linear-gradient(rgba(255, 214, 153, 0.14) 1px, transparent 1px),
    linear-gradient(180deg, #ffb36b, #e36a63 48%, #6d4aa2);
  background-size: 8px 8px, 8px 8px, 100% 100%;
}

.story-quote-muted {
  color: var(--ink-soft);
}

.story-quote-header {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
}

.story-quote-copy {
  margin: 0;
  white-space: pre-wrap;
  line-height: 1.45;
}

.story-link {
  text-decoration: none;
  font-weight: 700;
}

.story-link:hover {
  color: var(--accent-deep);
}
