:root {
  color-scheme: light;
  --bg: #eaf1ff;
  --ink: #0f172a;
  --muted: #4b5d77;
  --panel: #ffffff;
  --panel-2: #e0edff;
  --chrome-bg: rgba(252, 247, 237, 0.96);
  --chrome-bg-soft: rgba(252, 247, 237, 0.88);
  --accent: #2563eb;
  --accent-2: #38bdf8;
  --accent-3: #1d4ed8;
  --danger: #dc2626;
  --shadow: 0 20px 60px rgba(15, 23, 42, 0.12);
  --radius: 18px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "IBM Plex Sans", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at top left, #dbeafe 0%, transparent 45%),
    radial-gradient(circle at 80% 0%, #d9f0ff 0%, transparent 45%),
    radial-gradient(circle at 20% 80%, #c7ddff 0%, transparent 40%),
    var(--bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Prevent pre-render auth/view flicker until app bootstraps and auth is resolved. */
body:not([data-app-ready="1"]) {
  overflow: hidden;
}

body:not([data-app-ready="1"]) .topbar,
body:not([data-app-ready="1"]) .layout,
body:not([data-app-ready="1"]) .site-footer {
  visibility: hidden;
}

body:not([data-app-ready="1"])::before {
  content: "불러오는 중...";
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  font-weight: 700;
  color: var(--muted);
  z-index: 9999;
  background: radial-gradient(circle at top left, #dbeafe 0%, transparent 45%),
    radial-gradient(circle at 80% 0%, #d9f0ff 0%, transparent 45%),
    radial-gradient(circle at 20% 80%, #c7ddff 0%, transparent 40%),
    var(--bg);
}

h1,
h2,
h3,
h4 {
  font-family: "Space Grotesk", sans-serif;
  margin: 0;
}

.bg-orb {
  position: fixed;
  border-radius: 999px;
  opacity: 0.5;
  filter: blur(0px);
  z-index: 0;
}

.orb-1 {
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.25), transparent 70%);
  top: -120px;
  right: 5vw;
}

.orb-2 {
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.2), transparent 70%);
  bottom: 5vh;
  left: -80px;
}

.orb-3 {
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(29, 78, 216, 0.2), transparent 70%);
  top: 40vh;
  right: -60px;
}

.topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 5vw 12px;
  position: sticky;
  top: 0;
  background: linear-gradient(180deg, var(--chrome-bg), var(--chrome-bg-soft));
  backdrop-filter: blur(12px);
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
}

.logo {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  color: white;
  font-weight: 700;
  display: grid;
  place-items: center;
  font-size: 18px;
}

.brand-title {
  font-weight: 700;
  font-size: 18px;
}

.brand-sub {
  font-size: 12px;
  color: var(--muted);
}

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

.nav-btn {
  border: none;
  background: transparent;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
  cursor: pointer;
  color: var(--muted);
}

.nav-btn.active {
  background: var(--panel);
  color: var(--ink);
  box-shadow: var(--shadow);
}

.auth {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.primary,
.chip,
.ghost {
  border: none;
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  font-weight: 600;
}

.primary {
  background: var(--accent);
  color: white;
  box-shadow: var(--shadow);
}

.chip {
  background: var(--panel);
  color: var(--ink);
  border: 1px solid rgba(26, 28, 32, 0.08);
}

.chip.active {
  background: var(--accent-3);
  color: white;
  border: none;
}

.ghost {
  background: transparent;
  color: var(--muted);
}

.ghost:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.user-pill {
  background: var(--panel-2);
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 13px;
  border: 1px solid rgba(37, 99, 235, 0.2);
  cursor: pointer;
}

.user-menu {
  position: relative;
}

.user-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 12px);
  width: min(320px, 76vw);
  background: var(--panel);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 12px;
  display: grid;
  gap: 10px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px);
  transition: all 0.2s ease;
  z-index: 20;
}

.user-menu.open .user-dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.menu-head {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  padding: 6px 4px 10px;
  border-bottom: 1px solid rgba(26, 28, 32, 0.08);
}

.menu-avatar {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  color: white;
  display: grid;
  place-items: center;
  font-weight: 700;
}

.menu-avatar,
.member-avatar {
  position: relative;
  overflow: hidden;
}

.avatar-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar-has-image {
  color: transparent;
}

.menu-email {
  font-weight: 700;
  font-size: 14px;
}

.menu-handle {
  font-size: 12px;
  color: var(--muted);
}

.menu-section {
  display: grid;
  gap: 6px;
  padding: 4px;
}

.menu-item {
  border: none;
  background: transparent;
  padding: 8px 10px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
}

.menu-item:hover {
  background: rgba(37, 99, 235, 0.08);
}

.menu-item.has-unread {
  background: rgba(59, 130, 246, 0.12);
  color: #1d4ed8;
  font-weight: 700;
}

.menu-item.has-unread::after {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #ef4444;
}

.menu-item.danger {
  color: var(--danger);
}

.menu-count {
  background: var(--panel-2);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.layout {
  display: grid;
  gap: 0;
  padding: 0 0 80px;
  flex: 1;
}

.site-footer {
  width: 100%;
  margin: 0;
  padding: 14px 0;
  text-align: center;
  background: var(--chrome-bg);
  border-top: 1px solid rgba(26, 28, 32, 0.12);
  position: relative;
  z-index: 2;
}

.site-footer-copy {
  color: var(--muted);
  font-size: 13px;
  font-weight: 500;
}

.view {
  background: transparent;
  padding: 0 0 48px;
  border-radius: 0;
  box-shadow: none;
  display: none;
}

.view.active {
  display: block;
}

.view-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.hot-head {
  padding: 28px 5vw 0;
  margin-bottom: 0;
  align-items: flex-end;
}

.hot-copy {
  max-width: 720px;
}

.centered-head {
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
}

.centered-head .inline-search {
  margin-bottom: 12px;
  width: 40vw;
  min-width: 320px;
}

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

.hero {
  display: grid;
  gap: 18px;
  padding: 90px 8vw 70px;
  margin-bottom: 0;
  border-radius: 0;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(56, 189, 248, 0.1));
  border: 1px solid rgba(37, 99, 235, 0.15);
  justify-items: center;
  text-align: center;
}

.hero-title {
  font-size: 36px;
  font-weight: 700;
}

.hero-subtitle {
  font-size: 20px;
  font-weight: 600;
  margin-top: 6px;
}

.hero-desc {
  color: var(--muted);
  margin: 10px 0 0;
  max-width: 700px;
  line-height: 1.5;
}

.hero-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  width: min(720px, 100%);
  margin: 0 auto;
}

.hero-search input {
  border-radius: 999px;
  padding: 12px 16px;
  border: 1px solid rgba(26, 28, 32, 0.12);
  font-size: 15px;
}

.community-page {
  padding: 28px 5vw 80px;
  display: grid;
  gap: 24px;
}

.community-hero {
  position: relative;
  display: grid;
  gap: 24px;
  padding: 48px;
  border-radius: 28px;
  color: #f8fafc;
  background: linear-gradient(130deg, rgba(15, 23, 42, 0.95), rgba(37, 99, 235, 0.8));
  overflow: hidden;
  box-shadow: var(--shadow);
}

.community-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.35), transparent 55%),
    radial-gradient(circle at 80% 20%, rgba(37, 99, 235, 0.4), transparent 60%);
  opacity: 0.8;
}

.community-hero::after {
  content: "";
  position: absolute;
  right: -25%;
  top: -40%;
  width: 60%;
  height: 90%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.45), transparent 70%);
  opacity: 0.7;
}

.community-hero-content,
.community-hero-stats {
  position: relative;
  z-index: 1;
}

.community-kicker {
  font-size: 12px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(248, 250, 252, 0.7);
}

.community-hero-title {
  font-size: 36px;
  line-height: 1.1;
}

.community-hero-subtitle {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  color: rgba(248, 250, 252, 0.78);
}

.community-hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.community-hero .ghost {
  color: #f8fafc;
  border: 1px solid rgba(248, 250, 252, 0.35);
}

.community-hero .ghost:hover {
  background: rgba(248, 250, 252, 0.12);
}

.community-hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.hero-stat {
  background: rgba(15, 23, 42, 0.35);
  border: 1px solid rgba(248, 250, 252, 0.15);
  padding: 14px 16px;
  border-radius: 18px;
  display: grid;
  gap: 6px;
}

.hero-stat-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(248, 250, 252, 0.7);
}

.hero-stat-value {
  font-size: 22px;
  font-weight: 700;
}

.community-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(320px, 1.3fr) minmax(240px, 0.9fr);
  gap: 20px;
  align-items: start;
}

.community-card {
  background: var(--panel);
  border-radius: 22px;
  padding: 18px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 12px;
}

.community-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.community-card-title {
  font-size: 18px;
  font-weight: 700;
}

.community-side {
  display: grid;
  gap: 20px;
}

.spotlight-card {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(56, 189, 248, 0.12));
  border: 1px solid rgba(37, 99, 235, 0.18);
}

.spotlight-body {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.spotlight-info {
  display: grid;
  gap: 4px;
}

.spotlight-name {
  font-weight: 700;
  font-size: 16px;
}

.spotlight-handle {
  font-size: 12px;
  color: var(--muted);
}

.spotlight-streak {
  margin-left: auto;
  font-weight: 700;
  font-size: 14px;
  color: var(--ink);
}

.streak-list {
  display: grid;
  gap: 10px;
}

.streak-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.12);
}

.streak-row--top {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.18), rgba(56, 189, 248, 0.12));
  border-color: rgba(37, 99, 235, 0.25);
}

.streak-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.streak-rank {
  font-weight: 700;
  color: var(--muted);
  width: 30px;
}

.member-avatar {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  color: white;
  display: grid;
  place-items: center;
  font-weight: 700;
  flex-shrink: 0;
}

.member-avatar.large {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  font-size: 20px;
}

.streak-meta {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.streak-name {
  font-weight: 700;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.community-user-link {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.community-user-link:hover {
  color: var(--accent-3);
}

.community-user-link:focus-visible {
  outline: 2px solid rgba(37, 99, 235, 0.35);
  outline-offset: 2px;
  border-radius: 6px;
}

.streak-sub {
  font-size: 12px;
  color: var(--muted);
}

.streak-count {
  text-align: right;
}

.streak-count-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.streak-count-value {
  font-size: 18px;
  font-weight: 700;
}

.feed-list {
  display: grid;
  gap: 10px;
}

.feed-item {
  width: 100%;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: rgba(15, 23, 42, 0.03);
  border-radius: 16px;
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  color: inherit;
}

.feed-item:hover {
  background: rgba(37, 99, 235, 0.08);
}

.feed-item:focus-visible {
  outline: 2px solid rgba(37, 99, 235, 0.35);
  outline-offset: 2px;
}

.feed-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.feed-text {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.feed-title {
  font-weight: 700;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.feed-user-link {
  max-width: 100%;
}

.feed-sub {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.feed-stats {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}

.member-list {
  display: grid;
  gap: 10px;
}

.member-row {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.member-info {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.member-name {
  font-weight: 700;
  font-size: 14px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.member-handle {
  font-size: 12px;
  color: var(--muted);
}

.member-meta {
  margin-left: auto;
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}

.member-badge {
  margin-left: auto;
  background: rgba(37, 99, 235, 0.12);
  color: var(--accent-3);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.community-empty {
  padding: 12px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.04);
  color: var(--muted);
  font-size: 13px;
}

.sentinel {
  text-align: center;
  color: var(--muted);
  padding: 16px;
}

.unlock-modal {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: grid;
  place-items: center;
  z-index: 40;
}

.unlock-card {
  width: min(520px, 92vw);
  background: var(--panel);
  border-radius: 24px;
  padding: 28px;
  box-shadow: var(--shadow);
  text-align: center;
  display: grid;
  gap: 14px;
}

.unlock-title {
  font-family: "Space Grotesk", sans-serif;
  font-size: 24px;
  font-weight: 700;
}

.unlock-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.filters {
  display: flex;
  align-items: center;
  gap: 8px;
}

.select {
  border: 1px solid rgba(26, 28, 32, 0.1);
  border-radius: 999px;
  padding: 8px 12px;
  background: var(--panel);
}

.prompt-list,
.recommend-list,
.comment-list,
.media-grid {
  display: grid;
  gap: 14px;
}

.recommend-list {
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 12px;
}

.recommend-tile {
  border: none;
  padding: 0;
  background: #eef3ff;
  aspect-ratio: 1 / 1;
  width: 100%;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.recommend-tile.recommend-tile-video {
  aspect-ratio: 16 / 9;
}

.recommend-tile img,
.recommend-tile video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.recommend-video-pill {
  position: absolute;
  left: 8px;
  top: 8px;
  color: #ffffff;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-shadow: 0 1px 4px rgba(6, 10, 18, 0.85);
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.recommend-tile:hover .recommend-video-pill {
  opacity: 1;
}

.recommend-placeholder {
  color: var(--muted);
  font-size: 12px;
  text-align: center;
  padding: 10px;
}

.prompt-list {
  padding: 0;
}

.prompt-list.masonry {
  display: flex;
  gap: 0;
  padding: 0;
}

.masonry-column {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.prompt-list.masonry .prompt-card {
  display: block;
  margin: 0;
  width: 100%;
}

.prompt-list.masonry .prompt-media {
  aspect-ratio: auto;
  min-height: 0;
}

.prompt-list.masonry .prompt-media img {
  height: auto;
  object-fit: cover;
}

.prompt-card {
  padding: 0;
  border-radius: 18px;
  border: 1px solid rgba(26, 28, 32, 0.08);
  display: grid;
  gap: 0;
  overflow: hidden;
  position: relative;
  background: linear-gradient(180deg, rgba(37, 99, 235, 0.08), rgba(37, 99, 235, 0.02));
  cursor: pointer;
}


.prompt-card.image-card {
  border: none;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.prompt-card h3 {
  font-size: 18px;
}

.prompt-media {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: linear-gradient(120deg, rgba(37, 99, 235, 0.15), rgba(56, 189, 248, 0.2));
}

.prompt-card.image-card .prompt-media {
  aspect-ratio: auto;
  min-height: 180px;
  border-radius: 0;
}

.prompt-card.image-card.has-video-media .prompt-media {
  min-height: 0;
}

.prompt-list.masonry .prompt-card.image-card .prompt-media {
  min-height: 0;
}

.prompt-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease, opacity 0.22s ease;
  display: block;
}

.prompt-media video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.22s ease;
  pointer-events: none;
}

.prompt-media.playing-video video {
  opacity: 1;
  visibility: visible;
}

.prompt-media.playing-video img {
  opacity: 0;
}

.prompt-card.image-card .prompt-media img {
  height: 100%;
}

.prompt-card.image-card.has-video-media .prompt-media img {
  height: auto;
}

.prompt-list.masonry .prompt-card.image-card .prompt-media img {
  height: auto;
}

.prompt-card.video-only-card .prompt-media,
.prompt-card.video-only-card .prompt-media img,
.prompt-card.video-only-card .prompt-media video {
  background: #0b1220;
}

.prompt-card.video-only-card .prompt-media img,
.prompt-card.video-only-card .prompt-media video {
  object-fit: contain;
}

.prompt-card:hover .prompt-media img {
  transform: scale(1.06);
}

.prompt-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(8, 13, 22, 0) 26%, rgba(8, 13, 22, 0.22) 54%, rgba(8, 13, 22, 0.68) 78%, rgba(8, 13, 22, 0.92) 100%),
    radial-gradient(130% 64% at 50% 100%, rgba(8, 13, 22, 0.48) 0%, rgba(8, 13, 22, 0) 68%);
  opacity: 0;
  transition: opacity 0.3s ease;
  padding: 0;
  color: white;
}

.prompt-card:hover .prompt-overlay {
  opacity: 1;
}

.overlay-left {
  position: absolute;
  bottom: 12px;
  left: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
}

.overlay-left > div {
  padding: 0;
  text-shadow: 0 1px 3px rgba(6, 10, 18, 0.85);
}

.overlay-like {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(10, 15, 24, 0.58);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(7, 11, 20, 0.28);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: background 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.overlay-like:hover {
  box-shadow: 0 8px 18px rgba(7, 11, 20, 0.28);
}

.overlay-like:active {
  box-shadow: 0 8px 18px rgba(7, 11, 20, 0.28);
}

.overlay-like-icon {
  width: 16px;
  height: 16px;
}

.overlay-like-icon path {
  fill: transparent;
  stroke: rgba(255, 255, 255, 0.96);
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: fill 0.2s ease, stroke 0.2s ease;
}

.overlay-like.liked {
  background: rgba(239, 68, 68, 0.92);
  border-color: rgba(255, 255, 255, 0.42);
}

.overlay-like.liked .overlay-like-icon path {
  fill: #fff;
  stroke: #fff;
}

.overlay-prompt {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 40px;
  font-size: 12.5px;
  line-height: 1.42;
  color: rgba(255, 255, 255, 0.96);
  text-shadow: 0 1px 4px rgba(6, 10, 18, 0.85);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.model-pill {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 0;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-shadow: 0 1px 4px rgba(6, 10, 18, 0.85);
}

.video-pill {
  position: absolute;
  left: 12px;
  top: 12px;
  padding: 0;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-shadow: 0 1px 4px rgba(6, 10, 18, 0.85);
}

.prompt-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.prompt-info {
  padding: 12px 14px 16px;
  display: grid;
  gap: 6px;
}

.prompt-card.image-card .prompt-info {
  display: none;
}

.prompt-meta {
  display: flex;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}

.ranking-list {
  display: grid;
  gap: 10px;
}

.ranking-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(46, 196, 182, 0.08);
}

.form {
  display: grid;
  gap: 14px;
}

.form input,
.form textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(26, 28, 32, 0.12);
  font-family: inherit;
}

#view-new {
  padding: 24px 0 80px;
}

.upload-layout {
  display: grid;
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr) minmax(200px, 260px);
  gap: 20px;
  padding: 12px 5vw;
  align-items: start;
}

.upload-panel,
.upload-recent {
  background: var(--panel);
  border-radius: 20px;
  padding: 18px;
  box-shadow: var(--shadow);
}

.upload-panel {
  display: grid;
  gap: 16px;
  position: sticky;
  top: 96px;
}

.segmented {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  background: var(--panel-2);
  padding: 6px;
  border-radius: 999px;
}

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

.images-sort-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  justify-content: center;
  width: max-content;
  max-width: 100%;
  margin-bottom: 16px;
}

.images-controls-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 6px 10px;
  background: var(--panel-2);
  border-radius: 999px;
  box-sizing: border-box;
}

.images-mode-menu {
  position: relative;
  display: inline-flex;
  align-items: center;
  height: 100%;
}

.images-mode-pill {
  border: 1px solid rgba(26, 28, 32, 0.12);
  background: var(--panel);
  border-radius: 999px;
  height: 34px;
  padding: 0 12px;
  font-size: 14px;
  font-family: inherit;
  font-weight: 600;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  line-height: 1;
}

.images-mode-caret {
  font-size: 11px;
  color: var(--muted);
}

.images-mode-menu.open .images-mode-pill {
  border-color: rgba(37, 99, 235, 0.35);
}

.images-mode-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  min-width: 130px;
  background: var(--panel);
  border-radius: 14px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(26, 28, 32, 0.1);
  padding: 6px;
  display: grid;
  gap: 4px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: all 0.2s ease;
  z-index: 22;
}

.images-mode-menu.open .images-mode-dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.images-mode-item {
  border: none;
  background: transparent;
  color: var(--ink);
  border-radius: 10px;
  padding: 8px 10px;
  text-align: left;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}

.images-mode-item:hover {
  background: rgba(37, 99, 235, 0.08);
}

.images-mode-item.active {
  background: rgba(37, 99, 235, 0.14);
  color: var(--accent-3);
}

.images-sort-controls {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 100%;
  padding: 0;
  width: fit-content;
  box-sizing: border-box;
}

.images-controls-separator {
  width: 1px;
  height: 28px;
  background: rgba(26, 28, 32, 0.18);
  border-radius: 999px;
}

.images-sort-controls .seg-btn {
  height: 34px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  line-height: 1;
  font-size: 14px;
}

.images-panel {
  display: block;
}

.seg-btn {
  border: none;
  border-radius: 999px;
  padding: 8px 12px;
  font-weight: 600;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.seg-btn.active {
  background: var(--accent);
  color: white;
}

.seg-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.images-sort-controls .seg-btn:disabled,
.images-sort-controls .seg-btn:disabled.active {
  opacity: 1;
  background: #d9dee8;
  color: #7a8699;
}

.inline-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--panel);
  border-radius: 999px;
  padding: 6px 8px;
  border: 1px solid rgba(26, 28, 32, 0.08);
  box-shadow: var(--shadow);
}

.inline-search input {
  border: none;
  background: transparent;
  padding: 6px 10px;
  font-size: 14px;
  min-width: 200px;
  flex: 1;
  outline: none;
  font-family: inherit;
}

.field {
  display: grid;
  gap: 8px;
  font-weight: 600;
  color: var(--ink);
}

.upload-panel input,
.upload-panel textarea,
.upload-panel select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(26, 28, 32, 0.12);
  font-family: inherit;
  font-size: 14px;
}

.upload-drop {
  border: 1px dashed rgba(37, 99, 235, 0.4);
  border-radius: 16px;
  padding: 18px;
  background: rgba(37, 99, 235, 0.05);
  text-align: center;
  display: grid;
  gap: 6px;
  cursor: pointer;
  position: relative;
  min-height: 120px;
  align-content: center;
}

.upload-drop input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.upload-drop.drag {
  border-color: var(--accent);
  background: rgba(37, 99, 235, 0.12);
}

.upload-drop-title {
  font-weight: 600;
}

.upload-drop-meta {
  font-size: 12px;
  color: var(--muted);
}

.upload-file-name {
  font-size: 12px;
  color: var(--ink);
  font-weight: 600;
}

.format-toggle {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.upload-hint {
  font-size: 12px;
  color: var(--muted);
  margin: 0;
}

.account-wrap {
  display: grid;
  place-items: center;
  padding: 24px 6vw 60px;
}

.account-card {
  width: min(520px, 92vw);
  background: var(--panel);
  border-radius: 20px;
  padding: 24px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 18px;
}

.notifications-hero {
  margin-top: 6px;
}

.notifications-avatar {
  background: linear-gradient(140deg, #2563eb, #38bdf8);
}

.notifications-lists {
  padding-top: 14px;
}

.notifications-panel {
  gap: 16px;
}

.notifications-panel-top {
  justify-content: space-between;
}

.notifications-unread-summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 8px 12px;
  border: 1px solid rgba(37, 99, 235, 0.16);
  background: rgba(37, 99, 235, 0.08);
  color: #1d4ed8;
  font-size: 13px;
  font-weight: 700;
}

.notifications-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.notifications-list {
  display: grid;
  gap: 12px;
}

.notification-item {
  border: 1px solid rgba(26, 28, 32, 0.1);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.94);
  padding: 14px 15px;
  display: grid;
  gap: 8px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.notification-item.unread {
  border-color: rgba(37, 99, 235, 0.35);
  background:
    linear-gradient(145deg, rgba(37, 99, 235, 0.12), rgba(56, 189, 248, 0.05)),
    rgba(255, 255, 255, 0.96);
}

.notification-status {
  width: fit-content;
  font-size: 11px;
  font-weight: 700;
  border-radius: 999px;
  padding: 2px 8px;
}

.notification-status.unread {
  color: #1d4ed8;
  background: rgba(59, 130, 246, 0.14);
}

.notification-status.read {
  color: var(--muted);
  background: rgba(148, 163, 184, 0.18);
}

.notification-message {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
}

.notification-prompt {
  font-size: 13px;
  color: var(--muted);
}

.notification-meta {
  font-size: 12px;
  color: var(--muted);
}

.notification-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.notifications-empty {
  border: 1px dashed rgba(37, 99, 235, 0.2);
  border-radius: 16px;
  background: rgba(219, 234, 254, 0.3);
  color: var(--muted);
  text-align: center;
  padding: 22px 18px;
  font-size: 13px;
  font-weight: 600;
}

.avatar-control {
  display: flex;
  align-items: center;
  gap: 16px;
}

.avatar-circle {
  width: 72px;
  height: 72px;
  border-radius: 22px;
  background: linear-gradient(140deg, var(--accent), var(--accent-2));
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
  color: white;
  font-weight: 700;
}

.avatar-circle.large {
  width: 96px;
  height: 96px;
  border-radius: 28px;
}

.avatar-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar-initial {
  font-size: 24px;
}

.avatar-upload {
  font-weight: 600;
  color: var(--accent);
  cursor: pointer;
  position: relative;
}

.avatar-upload input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.profile-hero {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 24px;
  max-width: 1040px;
  margin: 0 auto;
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(37, 99, 235, 0.12), rgba(56, 189, 248, 0.04)),
    var(--panel);
  border: 1px solid rgba(37, 99, 235, 0.14);
  box-shadow: var(--shadow);
}

.profile-meta {
  display: grid;
  gap: 8px;
}

.profile-avatar-editable {
  position: relative;
}

.profile-avatar-edit {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.5);
  color: #fff;
  font-weight: 700;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
  cursor: pointer;
}

.profile-avatar-edit input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.profile-avatar-editable:hover .profile-avatar-edit,
.profile-avatar-editable:focus-within .profile-avatar-edit {
  opacity: 1;
  pointer-events: auto;
}

.profile-avatar-edit-text {
  border: 1px solid rgba(255, 255, 255, 0.58);
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.38);
  font-size: 13px;
}

@media (hover: none) {
  .profile-avatar-editable .profile-avatar-edit {
    opacity: 1;
    pointer-events: auto;
    background: rgba(15, 23, 42, 0.34);
  }
}

.profile-kicker {
  font-size: 11px;
  letter-spacing: 0.04em;
  font-weight: 700;
  color: rgba(29, 78, 216, 0.86);
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  padding: 14px 0 20px;
  max-width: 1040px;
  margin: 0 auto;
}

.stat-card {
  background: rgba(255, 255, 255, 0.9);
  border-radius: 18px;
  padding: 14px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(37, 99, 235, 0.08);
  display: grid;
  gap: 6px;
  text-align: center;
}

.stat-label {
  font-size: 12px;
  color: var(--muted);
}

.stat-value {
  font-size: 20px;
  font-weight: 700;
}

.profile-lists {
  display: block;
  padding: 12px 0 60px;
  max-width: 1040px;
  margin: 0 auto;
}

.profile-panel {
  background: rgba(255, 255, 255, 0.93);
  border-radius: 20px;
  padding: 18px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(37, 99, 235, 0.1);
  display: grid;
  gap: 14px;
}

.profile-panel-top {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  flex-wrap: wrap;
}

.profile-switch {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.16);
}

.profile-switch-btn {
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.18s ease, color 0.18s ease;
}

.profile-switch-btn.active {
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.1);
}

.profile-feed-label {
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
}

.profile-prompt-grid {
  padding: 0;
}

.profile-feed-card {
  width: 100%;
  border-radius: 14px;
  overflow: hidden;
}

.profile-prompt-grid .prompt-card.image-card .prompt-media {
  min-height: 180px;
}

.profile-feed-empty {
  min-height: 160px;
  border-radius: 14px;
  border: 1px dashed rgba(37, 99, 235, 0.18);
  background: rgba(219, 234, 254, 0.36);
  display: grid;
  place-items: center;
  text-align: center;
  padding: 16px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.admin-shell {
  width: min(1360px, 95vw);
  margin: 0 auto 70px;
  display: grid;
  gap: 14px;
}

.admin-head {
  margin: 0;
  padding: 22px 24px;
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(56, 189, 248, 0.04)),
    var(--panel);
  border: 1px solid rgba(37, 99, 235, 0.14);
  box-shadow: var(--shadow);
}

.admin-head.centered-head {
  align-items: flex-start;
  text-align: left;
  gap: 8px;
}

.admin-head .hero-title {
  font-size: clamp(30px, 3vw, 38px);
  line-height: 1.05;
}

.admin-head .hero-desc {
  max-width: 820px;
  color: var(--muted);
  margin: 0;
}

.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
}

.admin-stat-card {
  border-radius: 16px;
  padding: 14px 15px;
  background: var(--panel);
  border: 1px solid rgba(26, 28, 32, 0.1);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  display: grid;
  gap: 4px;
}

.admin-stat-label {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.admin-stat-value {
  font-size: 28px;
  line-height: 1;
  font-weight: 700;
}

.admin-toolbar {
  display: flex;
  justify-content: flex-end;
}

.admin-section-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.admin-section-btn.active {
  background: var(--accent-3);
  color: #fff;
  border-color: transparent;
}

.admin-page-block {
  display: grid;
  gap: 14px;
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.95fr);
  gap: 16px;
  align-items: start;
}

.admin-column {
  display: grid;
  gap: 16px;
}

.admin-panel {
  background: var(--panel);
  border-radius: 20px;
  padding: 16px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(26, 28, 32, 0.1);
  display: grid;
  gap: 12px;
}

.admin-panel-sticky {
  position: sticky;
  top: 96px;
}

.admin-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(26, 28, 32, 0.08);
}

.admin-panel-head h3 {
  margin: 0;
  font-size: 18px;
}

.admin-inline-form {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  flex-wrap: nowrap;
}

.admin-inline-form .chip,
.admin-inline-form .ghost {
  flex: 0 0 auto;
  min-width: 64px;
  white-space: nowrap;
  word-break: keep-all;
  writing-mode: horizontal-tb;
  text-orientation: mixed;
}

.admin-inline-form input {
  min-width: 240px;
  width: min(420px, 100%);
  border-radius: 999px;
  border: 1px solid rgba(26, 28, 32, 0.14);
  background: #fff;
  padding: 9px 13px;
  font-size: 14px;
}

.admin-inline-form input:focus {
  outline: none;
  border-color: rgba(37, 99, 235, 0.42);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.admin-table-wrap {
  display: grid;
  gap: 8px;
}

.admin-column-side .admin-table-wrap {
  max-height: min(72vh, 760px);
  overflow: auto;
  padding-right: 3px;
}

.admin-table-empty {
  color: var(--muted);
  font-size: 13px;
  background: rgba(15, 23, 42, 0.03);
  border-radius: 12px;
  padding: 12px;
}

.admin-row {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr) auto;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(26, 28, 32, 0.08);
  border-radius: 14px;
  padding: 10px 12px;
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.admin-row:hover {
  border-color: rgba(37, 99, 235, 0.24);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.08);
}

.admin-row-main {
  min-width: 0;
}

.admin-row-title {
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-row-sub {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-row-meta {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

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

.admin-video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}

.admin-video-grid .admin-row {
  grid-column: 1 / -1;
}

.admin-video-card {
  border: 1px solid rgba(26, 28, 32, 0.1);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  display: grid;
  gap: 8px;
}

.admin-video-preview {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #e2e8f0;
}

.admin-video-body {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.admin-top-posts {
  display: grid;
  gap: 8px;
}

.admin-top-post {
  width: 100%;
  text-align: left;
  cursor: pointer;
}

@media (max-width: 1200px) {
  .admin-layout {
    grid-template-columns: 1fr;
  }
  .admin-panel-sticky {
    position: static;
  }
  .admin-column-side .admin-table-wrap {
    max-height: none;
    overflow: visible;
  }
}

.upload-stage {
  min-height: 520px;
  border-radius: 24px;
  border: 1px solid rgba(26, 28, 32, 0.08);
  background-image: radial-gradient(rgba(37, 99, 235, 0.16) 1px, transparent 1px);
  background-size: 22px 22px;
  background-color: rgba(255, 255, 255, 0.7);
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.upload-placeholder {
  text-align: center;
  color: var(--muted);
  display: grid;
  gap: 10px;
}

.placeholder-icon {
  width: 64px;
  height: 64px;
  border-radius: 20px;
  background: var(--panel-2);
  display: grid;
  place-items: center;
  font-weight: 700;
  color: var(--accent);
  margin: 0 auto;
}

.placeholder-title {
  font-weight: 600;
  color: var(--ink);
}

.placeholder-sub {
  font-size: 12px;
}

.upload-preview {
  width: 92%;
  max-height: 520px;
  object-fit: contain;
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.upload-recent {
  display: grid;
  gap: 12px;
}

.recent-head {
  font-weight: 700;
}

.recent-list {
  display: grid;
  gap: 10px;
}

.recent-item {
  border-radius: 14px;
  padding: 10px 12px;
  background: rgba(37, 99, 235, 0.08);
  display: grid;
  gap: 4px;
}

.recent-title {
  font-weight: 600;
  font-size: 13px;
}

.recent-meta {
  font-size: 11px;
  color: var(--muted);
}

.recent-empty {
  font-size: 12px;
  color: var(--muted);
}

.drawer {
  position: fixed;
  inset: 0;
  background: rgba(26, 28, 32, 0.3);
  display: grid;
  place-items: center;
  z-index: 20;
}

.drawer-card {
  width: min(820px, 92vw);
  background: var(--panel);
  border-radius: 24px;
  padding: 24px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 20px;
  max-height: 90vh;
  overflow: auto;
}

.drawer-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.detail-actions,
.inline {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.detail-content {
  white-space: pre-wrap;
}

.prompt-page {
  width: min(980px, 92vw);
  margin: 32px auto 80px;
  background: var(--panel);
  border-radius: 24px;
  padding: 24px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 20px;
}

.prompt-head {
  display: grid;
  gap: 10px;
}

.prompt-head-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.prompt-detail-page {
  width: min(1200px, 92vw);
  margin: 32px auto 80px;
}

.prompt-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.85fr);
  gap: 32px;
  align-items: start;
}

.prompt-detail-media,
.prompt-detail-info {
  background: var(--panel);
  border-radius: 24px;
  padding: 20px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 16px;
}

.prompt-media-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.prompt-hero-media {
  background: #f8fafc;
  border-radius: 18px;
  padding: 12px;
  display: grid;
  place-items: center;
  min-height: 320px;
  overflow: hidden;
}

.prompt-hero-media img,
.prompt-hero-media video {
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: contain;
  display: block;
}

.prompt-hero-empty {
  color: var(--muted);
  font-size: 14px;
}

.prompt-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

.prompt-user-meta {
  display: grid;
  gap: 4px;
}

.prompt-user-name {
  font-weight: 700;
}

.prompt-user-sub {
  color: var(--muted);
  font-size: 12px;
}

.prompt-head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.prompt-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.prompt-meta-row #like-btn {
  position: relative;
  z-index: 4;
  pointer-events: auto;
}

.prompt-title {
  font-size: 26px;
}

.meta {
  color: var(--muted);
  font-size: 14px;
}

.prompt-block-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.prompt-section {
  display: grid;
  gap: 10px;
}

.section-label {
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

.prompt-text {
  white-space: pre-wrap;
  background: rgba(15, 23, 42, 0.04);
  padding: 14px;
  border-radius: 14px;
}

.model-line {
  font-weight: 600;
  color: var(--muted);
}

.block {
  display: grid;
  gap: 10px;
}

.block-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.media-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.media-card {
  border-radius: 14px;
  border: 1px solid rgba(26, 28, 32, 0.1);
  padding: 8px;
  display: grid;
  gap: 6px;
}

.media-card img,
.media-card video {
  width: 100%;
  border-radius: 10px;
}

.detail-actions {
  justify-content: flex-end;
}

.report-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(26, 28, 32, 0.12);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.03);
}

.report-option {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--ink);
}

.report-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

@media (max-width: 1100px) {
  .community-grid {
    grid-template-columns: 1fr;
  }
  .community-side {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .prompt-detail-grid {
    grid-template-columns: 1fr;
  }
}

.comment-item {
  --comment-depth: 0;
  padding: 10px;
  background: rgba(37, 99, 235, 0.08);
  border-radius: 12px;
  display: grid;
  gap: 6px;
  margin-left: calc(var(--comment-depth) * 18px);
}

.comment-item--reply {
  background: rgba(37, 99, 235, 0.05);
}

.comment-form {
  display: grid;
  gap: 10px;
}

.comment-form #comment-input {
  width: 100%;
  min-height: 120px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(26, 28, 32, 0.12);
  font-family: inherit;
  font-size: 16px;
  line-height: 1.45;
  resize: vertical;
}

.comment-submit {
  justify-self: start;
  padding: 10px 18px;
  font-size: 14px;
}

.comment-author {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}

.comment-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.comment-time {
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}

.comment-content {
  color: var(--ink);
  white-space: pre-wrap;
  word-break: break-word;
}

.comment-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.comment-reply-toggle {
  padding: 6px 12px;
  font-size: 12px;
}

.comment-delete-btn {
  padding: 6px 12px;
  font-size: 12px;
}

.comment-reply-form {
  display: grid;
  gap: 8px;
}

.comment-reply-form textarea {
  width: 100%;
  min-height: 72px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(26, 28, 32, 0.12);
  font-family: inherit;
  font-size: 14px;
  line-height: 1.4;
  resize: vertical;
}

.comment-reply-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.comment-empty {
  color: var(--muted);
  font-size: 14px;
  padding: 8px 2px;
}

.auth-split {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
  align-items: start;
  max-width: 720px;
  margin: 0 auto;
}

.verify-panel {
  background: var(--panel-2);
  padding: 18px;
  border-radius: 16px;
  border: 1px solid rgba(37, 99, 235, 0.15);
  display: grid;
  gap: 10px;
}

.form-help {
  margin-top: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
}

.auth-form {
  max-width: 720px;
  width: 100%;
  margin: 0 auto;
}

#view-login,
#view-register {
  padding: 60px 6vw;
}

#view-login .view-head,
#view-register .view-head,
#view-login .form-help,
#view-register .form-help {
  justify-content: center;
  text-align: center;
}

#view-login .form-help,
#view-register .form-help {
  margin-left: auto;
  margin-right: auto;
}

#verify-sent {
  max-width: 720px;
  margin: 20px auto 0;
  text-align: center;
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  background: var(--panel);
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: var(--shadow);
  z-index: 40;
}

.hidden {
  display: none !important;
}

@media (max-width: 900px) {
  .topbar {
    position: sticky;
    top: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand auth"
      "nav nav";
    align-items: center;
    gap: 10px;
    padding: 14px 4vw 10px;
  }
  .brand {
    grid-area: brand;
    min-width: 0;
    gap: 10px;
  }
  .logo {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 15px;
  }
  .brand-title {
    font-size: 16px;
  }
  .brand-sub {
    display: none;
  }
  .auth {
    grid-area: auth;
    justify-self: end;
    gap: 8px;
  }
  .auth .ghost,
  .auth .primary,
  .user-pill {
    padding: 7px 10px;
    font-size: 12px;
  }
  .nav {
    grid-area: nav;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    width: 100%;
    gap: 6px;
    padding: 6px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(26, 28, 32, 0.08);
  }
  .nav-btn {
    padding: 8px 6px;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .nav-btn.active {
    box-shadow: none;
  }
  .user-dropdown {
    right: 0;
    top: calc(100% + 8px);
    width: min(360px, 92vw);
  }
  .layout {
    padding: 10px 0 84px;
  }
  .hot-head {
    padding: 20px 4vw 0;
    align-items: center;
  }
  .hero-title {
    font-size: 30px;
  }
  .hero-subtitle {
    font-size: 18px;
  }
  .hero-desc {
    font-size: 14px;
    max-width: 620px;
  }
  .centered-head .inline-search {
    width: min(680px, 100%);
    min-width: 0;
  }
  .hero-search {
    grid-template-columns: 1fr;
  }
  .images-sort-row {
    width: 100%;
    justify-content: center;
    padding: 0 4vw;
  }
  .images-controls-pill {
    width: min(100%, 700px);
    height: auto;
    flex-wrap: wrap;
    justify-content: center;
    border-radius: 18px;
    padding: 10px;
  }
  .images-mode-menu {
    height: auto;
  }
  .images-mode-dropdown {
    left: 50%;
    transform: translate(-50%, -6px);
  }
  .images-mode-menu.open .images-mode-dropdown {
    transform: translate(-50%, 0);
  }
  .images-controls-separator {
    display: none;
  }
  .images-sort-controls {
    height: auto;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
  }
  .images-sort-controls .seg-btn {
    flex: 1 1 140px;
  }
  .prompt-list.masonry {
    column-count: 2;
    padding: 0;
  }
  .upload-layout {
    grid-template-columns: 1fr;
    padding: 10px 4vw;
  }
  .upload-panel {
    position: static;
  }
  .upload-stage {
    min-height: 320px;
  }
  .upload-preview {
    width: 100%;
  }
  .inline-search {
    width: 100%;
  }
  .inline-search input {
    min-width: 0;
    flex: 1;
  }
  .community-hero {
    padding: 26px;
  }
  .community-hero-stats {
    grid-template-columns: 1fr;
  }
  .community-hero-title {
    font-size: 30px;
  }
  .feed-item {
    flex-direction: column;
    align-items: flex-start;
  }
  .spotlight-body {
    flex-direction: column;
    align-items: flex-start;
  }
  .spotlight-streak {
    margin-left: 0;
  }
  .prompt-detail-page {
    width: min(1200px, 95vw);
    margin: 20px auto 72px;
  }
  .prompt-detail-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .prompt-detail-media,
  .prompt-detail-info {
    padding: 16px;
    border-radius: 18px;
  }
  .prompt-hero-media {
    min-height: 240px;
    padding: 10px;
  }
  .profile-hero {
    flex-direction: column;
    align-items: flex-start;
    padding: 18px 16px;
    max-width: 95vw;
    border-radius: 20px;
  }
  .profile-stats {
    padding: 10px 4vw 18px;
    max-width: none;
  }
  .profile-lists {
    padding: 10px 4vw 50px;
    max-width: none;
  }
  .profile-panel {
    min-height: 0;
  }
  .profile-panel-top {
    align-items: flex-start;
  }
  .admin-shell {
    width: min(1360px, 96vw);
  }
  .admin-stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .admin-layout {
    grid-template-columns: 1fr;
  }
  .admin-panel-sticky {
    position: static;
  }
  .admin-column-side .admin-table-wrap {
    max-height: none;
    overflow: visible;
  }
  .admin-inline-form {
    width: 100%;
  }
  .admin-inline-form input {
    min-width: 0;
    max-width: none;
    flex: 1 1 auto;
  }
  .admin-row {
    grid-template-columns: 1fr;
    align-items: start;
  }
  .admin-row-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 700px) {
  .topbar {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand auth"
      "nav nav";
    gap: 8px;
    padding: 12px 4vw 8px;
  }
  .brand {
    grid-area: brand;
    width: auto;
    justify-content: flex-start;
  }
  .auth {
    grid-area: auth;
    width: auto;
    max-width: 100%;
    justify-self: end;
    justify-content: flex-end;
  }
  .user-menu {
    width: auto;
    display: block;
  }
  .user-dropdown {
    position: fixed;
    right: 10px;
    top: 72px;
    width: min(360px, calc(100vw - 20px));
    z-index: 45;
  }
  .nav {
    grid-area: nav;
    position: static;
    left: auto;
    right: auto;
    bottom: auto;
    z-index: auto;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(26, 28, 32, 0.08);
    box-shadow: none;
    backdrop-filter: none;
    margin-top: 2px;
  }
  .profile-panel-top {
    flex-direction: column;
    align-items: flex-start;
  }
  .profile-switch {
    width: 100%;
    justify-content: space-between;
  }
  .profile-switch-btn {
    flex: 1 1 0;
    text-align: center;
  }
  .layout {
    padding-bottom: 84px;
  }
  .site-footer {
    padding-bottom: 12px;
  }
}

@media (max-width: 600px) {
  .topbar {
    padding: 10px 12px 8px;
  }
  .logo {
    width: 36px;
    height: 36px;
    font-size: 14px;
  }
  .brand-title {
    font-size: 15px;
  }
  .auth .ghost,
  .auth .primary,
  .user-pill {
    font-size: 11.5px;
    padding: 6px 9px;
  }
  .site-footer {
    padding: 10px 0 calc(10px + env(safe-area-inset-bottom));
  }
  .site-footer-copy {
    font-size: 11.5px;
  }
  .hero-title {
    font-size: 26px;
  }
  .hero-subtitle {
    font-size: 16px;
  }
  .hero-desc {
    font-size: 13px;
  }
  .admin-head {
    padding: 18px 16px;
  }
  .admin-stats-grid {
    grid-template-columns: 1fr;
  }
  .admin-stat-value {
    font-size: 24px;
  }
  .images-sort-row {
    flex-wrap: wrap;
    padding: 0 10px;
  }
  .images-controls-pill {
    border-radius: 16px;
    padding: 8px;
  }
  .images-mode-pill,
  .images-sort-controls .seg-btn {
    height: 32px;
    font-size: 13px;
  }
  .images-sort-controls .seg-btn {
    min-width: 0;
    flex: 1 1 120px;
  }
  .prompt-list.masonry {
    column-count: 1;
  }
  .prompt-card.image-card .prompt-media {
    min-height: 150px;
  }
  .community-hero-title {
    font-size: 26px;
  }
  .hero-stat-value {
    font-size: 18px;
  }
  .prompt-title {
    font-size: 22px;
  }
  .prompt-head-actions {
    width: 100%;
    justify-content: flex-end;
  }
  .comment-submit {
    width: 100%;
    justify-self: stretch;
  }
}
