@import url("/assets/fonts/fonts.css?v=20260517-self-hosted-fonts");

:root {
  --bg: #0b0d10;
  --panel: #111418;
  --panel-soft: #171b21;
  --card: #111418;
  --input: #20242c;
  --border: #343a46;
  --border-soft: #2b3038;
  --text: #f8fafc;
  --muted: #cbd5e1;
  --subtle: #94a3b8;
  --accent: #e5e7eb;
  --accent-strong: #f8fafc;
  --blue: #252a33;
  --blue-border: #596273;
  --blue-text: var(--blue-border);
  --gold: #9ca3af;
  --red: var(--accent);
  --red-border: #f85149;
  --surface-soft: var(--panel-soft);
  --border-strong: var(--border);
  --shadow: rgba(0, 0, 0, 0.32);
  --font-body: "Courier New", Courier, monospace;
  --font-weight: 800;
  --field-font-family: var(--font-body);
  --field-font-size: 13px;
  --title-size: 28px;
  --panel-title-size: 22px;
  --content-size: 15px;
  --title-padding: 4px;
  --text-padding: 8px;
  --chat-box-font-size: 15px;
  --chat-box-padding: 12px;
  --chat-box-border-radius: 14px;
  --button-bg: #111418;
  --button-text: #f8fafc;
  --button-border: #343a46;
  --button-primary-bg: #e5e7eb;
  --button-primary-text: #0b0d10;
  --button-primary-border: #f8fafc;
  --button-blue-bg: #252a33;
  --button-blue-text: #f8fafc;
  --button-blue-border: #596273;
  --button-gold-bg: #9ca3af;
  --button-gold-text: #0b0d10;
  --button-gold-border: #cbd5e1;
  --button-danger-bg: #4b1114;
  --button-danger-text: #fee2e2;
  --button-danger-border: #f87171;
  --theme-background-image: none;
  --theme-background-opacity: 1;
  --spotlight-canvas-opacity: 1;
  --spotlight-panel-mix: 92%;
  --spotlight-sidebar-mix: 88%;
  --spotlight-dark-base: #050712;
  --spotlight-dark-lift: #111827;
  --panel-glass-tint: #ffffff;
  --panel-glass-opacity: 24%;
  --panel-glass-blur: 16px;
}

/* Badge collection and public profile achievements */
.badge-collection-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 32px;
  align-items: center;
  overflow: hidden;
  padding: clamp(24px, 4vw, 42px);
  border-color: color-mix(in srgb, #f04d78 34%, var(--border));
  background:
    radial-gradient(circle at 90% 20%, rgba(240, 77, 120, .2), transparent 34%),
    radial-gradient(circle at 5% 100%, rgba(113, 83, 255, .15), transparent 38%),
    var(--panel-surface);
}

.badge-collection-hero::after {
  position: absolute;
  right: -54px;
  bottom: -74px;
  width: 230px;
  height: 230px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 50%;
  box-shadow: 0 0 0 28px rgba(255, 255, 255, .025), 0 0 0 56px rgba(255, 255, 255, .018);
  content: "";
  pointer-events: none;
}

.badge-hero-copy {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.badge-hero-copy h2 {
  max-width: 620px;
  margin: 8px 0 12px;
  font-size: clamp(30px, 5vw, 54px);
  line-height: .98;
  letter-spacing: -.04em;
}

.badge-hero-copy > p {
  max-width: 66ch;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
}

.badge-hero-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.badge-hero-pills span {
  padding: 7px 11px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, .055);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
}

.badge-progress-orbit {
  position: relative;
  z-index: 1;
  display: grid;
  width: 142px;
  height: 142px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 50%;
  background: conic-gradient(#ff5c88 var(--badge-progress), rgba(255, 255, 255, .1) 0);
  box-shadow: 0 18px 54px rgba(0, 0, 0, .28), 0 0 36px rgba(240, 77, 120, .16);
}

.badge-progress-orbit::before {
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: inherit;
  background: var(--panel);
  content: "";
}

.badge-progress-orbit div {
  position: relative;
  display: grid;
  gap: 2px;
  text-align: center;
}

.badge-progress-orbit strong {
  font-size: 31px;
  letter-spacing: -.04em;
}

.badge-progress-orbit span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: .09em;
  text-transform: uppercase;
}

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

.badge-summary article {
  display: flex;
  min-width: 0;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 88%, transparent);
}

.badge-summary article div {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.badge-summary small,
.badge-eyebrow,
.profile-achievements-label {
  color: var(--subtle);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.badge-summary strong {
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.badge-summary-icon,
.profile-achievement-icon {
  --achievement-accent: #ff5c88;
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  color: var(--achievement-accent);
  background: color-mix(in srgb, var(--achievement-accent) 14%, transparent);
}

.badge-summary-icon {
  width: 42px;
  height: 42px;
  border: 1px solid color-mix(in srgb, var(--achievement-accent) 46%, transparent);
  border-radius: 12px;
}

.badge-summary-icon svg,
.profile-achievement-icon svg,
.badge-medallion svg {
  width: 55%;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.badge-shelf-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: end;
  margin: 10px 2px -2px;
}

.badge-shelf-heading h2 {
  margin: 5px 0 0;
}

.badge-shelf-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.badge-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.badge-card {
  --badge-accent: #ff5c88;
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 330px;
  gap: 20px;
  align-content: space-between;
  overflow: hidden;
  padding: 22px;
  border: 1px solid color-mix(in srgb, var(--badge-accent) 30%, var(--border));
  border-radius: 18px;
  background:
    radial-gradient(circle at 88% 4%, color-mix(in srgb, var(--badge-accent) 19%, transparent), transparent 36%),
    color-mix(in srgb, var(--panel) 93%, transparent);
  box-shadow: 0 14px 34px rgba(0, 0, 0, .14);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.badge-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--badge-accent) 64%, var(--border));
  box-shadow: 0 20px 44px rgba(0, 0, 0, .22);
}

.badge-card.blue { --badge-accent: #5da9ff; }
.badge-card.gold { --badge-accent: #f6c85f; }
.badge-card.rose { --badge-accent: #ff658e; }
.badge-card.violet { --badge-accent: #a58bff; }
.badge-card.mint { --badge-accent: #4bd6a2; }
.badge-card.coral { --badge-accent: #ff8b6a; }

.badge-card.is-locked {
  filter: saturate(.55);
}

.badge-card.is-locked .badge-medallion,
.badge-card.is-locked .badge-card-copy {
  opacity: .7;
}

.badge-card-top,
.badge-card-footer {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.badge-medallion {
  position: relative;
  display: grid;
  width: 78px;
  height: 78px;
  place-items: center;
  color: var(--badge-accent);
  background: color-mix(in srgb, var(--badge-accent) 17%, var(--panel));
  clip-path: polygon(25% 5%, 75% 5%, 98% 50%, 75% 95%, 25% 95%, 2% 50%);
  filter: drop-shadow(0 10px 18px color-mix(in srgb, var(--badge-accent) 22%, transparent));
}

.badge-medallion::before {
  position: absolute;
  inset: 5px;
  border: 1px solid color-mix(in srgb, var(--badge-accent) 58%, transparent);
  clip-path: inherit;
  content: "";
}

.badge-medallion i {
  position: absolute;
  right: 9px;
  bottom: 12px;
  width: 8px;
  height: 8px;
  border: 2px solid var(--panel);
  border-radius: 50%;
  background: var(--badge-accent);
  box-shadow: 0 0 12px var(--badge-accent);
}

.badge-status {
  align-self: start;
  padding: 6px 9px;
  border: 1px solid color-mix(in srgb, var(--badge-accent) 38%, var(--border));
  border-radius: 999px;
  background: color-mix(in srgb, var(--badge-accent) 11%, transparent);
  color: color-mix(in srgb, var(--badge-accent) 82%, white);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.badge-card-copy {
  display: grid;
  gap: 7px;
}

.badge-card-copy h3 {
  margin: 0;
  font-size: 22px;
  letter-spacing: -.025em;
}

.badge-card-copy p {
  min-height: 42px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.badge-meter {
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, .08);
}

.badge-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, color-mix(in srgb, var(--badge-accent) 70%, white), var(--badge-accent));
  box-shadow: 0 0 12px color-mix(in srgb, var(--badge-accent) 40%, transparent);
}

.badge-card-footer > span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 850;
}

.badge-card-footer .btn {
  min-height: 38px;
  padding: 8px 12px;
  border-color: color-mix(in srgb, var(--badge-accent) 42%, var(--border));
}

.profile-achievements {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel-soft) 80%, transparent);
}

.profile-achievement-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.profile-achievement {
  --achievement-accent: #ff5c88;
  display: inline-flex;
  gap: 7px;
  align-items: center;
  padding: 5px 9px 5px 5px;
  border: 1px solid color-mix(in srgb, var(--achievement-accent) 33%, var(--border));
  border-radius: 999px;
  background: color-mix(in srgb, var(--achievement-accent) 9%, transparent);
  color: var(--text);
  font-size: 11px;
  font-weight: 850;
}

.profile-achievement-icon {
  width: 26px;
  height: 26px;
  border-radius: 50%;
}

.mint { --achievement-accent: #4bd6a2; }
.blue { --achievement-accent: #5da9ff; }
.gold { --achievement-accent: #f6c85f; }
.rose { --achievement-accent: #ff658e; }
.violet { --achievement-accent: #a58bff; }

body[data-theme="day"] .badge-collection-hero,
body[data-theme="day"] .badge-card,
body[data-theme="day"] .badge-summary article,
body[data-theme="day"] .profile-achievements {
  box-shadow: 0 12px 30px rgba(26, 35, 52, .08);
}

body[data-theme="day"] .badge-progress-orbit::before {
  background: #fff;
}

body[data-theme="day"] .badge-status {
  color: color-mix(in srgb, var(--badge-accent) 72%, #182032);
}

@media (max-width: 980px) {
  .badge-grid,
  .badge-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .badge-summary article:last-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .badge-collection-hero {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .badge-progress-orbit {
    width: 112px;
    height: 112px;
  }

  .badge-progress-orbit strong {
    font-size: 25px;
  }

  .badge-summary,
  .badge-grid {
    grid-template-columns: 1fr;
  }

  .badge-summary article:last-child {
    grid-column: auto;
  }

  .badge-shelf-heading {
    display: grid;
    gap: 6px;
  }

  .badge-card {
    min-height: 300px;
  }

  .profile-achievement > span:last-child {
    display: none;
  }

  .profile-achievement {
    padding: 4px;
  }
}

.draw-report-list {
  display: grid;
  gap: 8px;
}

.draw-report-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border: 1px solid color-mix(in srgb, #ff6f61 40%, var(--border));
  border-radius: 11px;
  background: color-mix(in srgb, var(--panel) 82%, transparent);
}

.draw-report-row > div {
  display: grid;
  gap: 2px;
  min-width: 0;
  margin-right: auto;
}

.draw-report-row span,
.draw-report-row small {
  color: var(--muted);
}

.draw-share-preview {
  display: grid;
  gap: 12px;
  margin: 14px 0 4px;
  padding: 14px;
  border: 1px solid color-mix(in srgb, #f4a340 62%, var(--border));
  border-radius: 15px;
  background: color-mix(in srgb, var(--panel-soft) 92%, #f4a340 8%);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
}

.draw-share-preview > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.draw-share-preview h3 {
  margin: 0;
}

.draw-share-preview img {
  display: block;
  width: 100%;
  max-height: 420px;
  object-fit: contain;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #07151b;
}

.draw-share-preview textarea {
  min-height: 76px;
  resize: vertical;
}

@media (max-width: 700px) {
  .draw-tools-float,
  .draw-fullscreen-btn,
  .draw-exit-fullscreen-btn {
    min-width: 46px;
    min-height: 46px;
  }

  .draw-viewbar .tiny-btn,
  .draw-fullscreen-tools .tiny-btn,
  .draw-context-menu .tiny-btn,
  .draw-context-menu .btn {
    min-height: 42px;
    padding: 9px 12px;
  }

  .draw-context-menu {
    width: min(250px, calc(100vw - 30px));
    max-height: min(420px, calc(100vh - 30px));
    overflow: auto;
  }

  .draw-report-row {
    align-items: stretch;
    flex-direction: column;
  }

  .draw-report-row .tiny-btn {
    width: 100%;
  }
}

.l2c-screen-reader {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

body.preloader-active {
  overflow: hidden;
}

.l2c-preloader {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #05060d;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: scale(1.03);
  filter: blur(14px);
  transition: opacity 0.45s ease-out, transform 0.45s ease-out, filter 0.45s ease-out, visibility 0s linear 0.45s;
}

.l2c-preloader.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: scale(1);
  filter: blur(0);
  animation: l2cPreloaderEnter 0.45s ease-out both;
  transition: opacity 0.45s ease-out, transform 0.45s ease-out, filter 0.45s ease-out;
}

.l2c-preloader-glow {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.l2c-preloader-glow-main,
.l2c-preloader-glow-left,
.l2c-preloader-glow-right {
  position: absolute;
  display: block;
  border-radius: 999px;
  pointer-events: none;
}

.l2c-preloader-glow-main {
  left: 50%;
  top: 50%;
  width: min(820px, 112vw);
  height: min(820px, 112vw);
  background: radial-gradient(circle, rgba(255, 20, 92, 0.18), rgba(0, 138, 214, 0.14) 34%, rgba(255, 255, 255, 0.04) 54%, transparent 72%);
  filter: blur(32px);
  transform: translate(-50%, -50%);
  animation: l2cGlowMain 16s linear infinite;
}

.l2c-preloader-glow-left {
  left: -112px;
  top: 48px;
  width: 320px;
  height: 320px;
  background: rgba(255, 11, 85, 0.18);
  filter: blur(48px);
  animation: l2cGlowLeft 10s ease-in-out infinite;
}

.l2c-preloader-glow-right {
  right: -96px;
  bottom: 32px;
  width: 384px;
  height: 384px;
  background: rgba(0, 138, 214, 0.2);
  filter: blur(48px);
  animation: l2cGlowRight 11s ease-in-out infinite;
}

.l2c-preloader-figure {
  position: relative;
  display: grid;
  width: min(24rem, 82vw);
  height: min(24rem, 82vw);
  place-items: center;
}

.l2c-preloader-ring {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  animation: l2cSpin 22s linear infinite, l2cRingScale 5s ease-in-out infinite;
}

.l2c-preloader-ring.dashed {
  inset: 40px;
  border-style: dashed;
  border-color: rgba(255, 255, 255, 0.15);
  animation: l2cSpinReverse 17s linear infinite, l2cRingDashScale 5.6s ease-in-out infinite;
}

.l2c-preloader-svg {
  width: min(24rem, 82vw);
  height: min(24rem, 82vw);
  overflow: visible;
  transform-style: preserve-3d;
  animation: l2cTilt 7.5s ease-in-out infinite;
}

.l2c-eight-track,
.l2c-eight-dots {
  transform-origin: 210px 210px;
}

.l2c-eight-track {
  animation: l2cSpinReverse 8.5s linear infinite;
}

.l2c-eight-dots {
  animation: l2cSpin 5.4s linear infinite;
}

.l2c-eight-shadow,
.l2c-eight-soft,
.l2c-eight-main {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.l2c-eight-shadow {
  stroke: rgba(255, 255, 255, 0.08);
  stroke-width: 44;
  animation: l2cShadowPulse 2.8s ease-in-out infinite;
}

.l2c-eight-soft {
  stroke-width: 32;
  stroke-dasharray: 220 210;
  animation: l2cSoftDash 4.2s ease-in-out infinite;
}

.l2c-eight-main {
  stroke-width: 16;
  stroke-dasharray: 120 46 22 46;
  animation: l2cMainDash 3.2s linear infinite, l2cMainWidth 2.4s ease-in-out infinite;
}

.l2c-eight-dots .dot {
  transform-origin: center;
}

.l2c-eight-dots .red {
  fill: #ff0b55;
  animation: l2cDotPulseRed 1.6s ease-in-out infinite;
}

.l2c-eight-dots .blue {
  fill: #008ad6;
  animation: l2cDotPulseBlue 1.6s ease-in-out infinite;
}

@keyframes l2cPreloaderEnter {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes l2cGlowMain {
  0% { transform: translate(-50%, -50%) scale(1) rotate(0deg); }
  33% { transform: translate(-50%, -50%) scale(1.14) rotate(120deg); }
  66% { transform: translate(-50%, -50%) scale(0.94) rotate(240deg); }
  100% { transform: translate(-50%, -50%) scale(1) rotate(360deg); }
}

@keyframes l2cGlowLeft {
  0%, 100% { transform: translate(0, 0) scale(1); }
  34% { transform: translate(130px, 80px) scale(1.25); }
  67% { transform: translate(40px, -35px) scale(0.9); }
}

@keyframes l2cGlowRight {
  0%, 100% { transform: translate(0, 0) scale(1); }
  34% { transform: translate(-130px, -80px) scale(0.86); }
  67% { transform: translate(-30px, 45px) scale(1.2); }
}

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

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

@keyframes l2cRingScale {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.04); }
}

@keyframes l2cRingDashScale {
  0%, 100% { transform: scale(1); }
  34% { transform: scale(0.94); }
  67% { transform: scale(1.03); }
}

@keyframes l2cTilt {
  0%, 100% { transform: perspective(900px) rotateY(0deg) rotateX(0deg); }
  25% { transform: perspective(900px) rotateY(24deg) rotateX(10deg); }
  50% { transform: perspective(900px) rotateY(0deg) rotateX(0deg); }
  75% { transform: perspective(900px) rotateY(-24deg) rotateX(-10deg); }
}

@keyframes l2cShadowPulse {
  0%, 100% { opacity: 0.16; }
  50% { opacity: 0.32; }
}

@keyframes l2cSoftDash {
  0%, 100% { stroke-dashoffset: 0; opacity: 0.35; }
  45% { stroke-dashoffset: -210; opacity: 0.7; }
  75% { stroke-dashoffset: -410; opacity: 0.45; }
}

@keyframes l2cMainDash {
  to { stroke-dashoffset: -468; }
}

@keyframes l2cMainWidth {
  0%, 100% { stroke-width: 13; }
  50% { stroke-width: 22; }
}

@keyframes l2cDotPulseRed {
  0%, 100% { opacity: 0.65; transform: scale(1); }
  34% { opacity: 1; transform: scale(1.45); }
  67% { opacity: 0.55; transform: scale(0.85); }
}

@keyframes l2cDotPulseBlue {
  0%, 100% { opacity: 0.55; transform: scale(0.85); }
  34% { opacity: 0.65; transform: scale(1); }
  67% { opacity: 1; transform: scale(1.45); }
}

.friends-profile-stack {
  display: grid;
  gap: 16px;
}

.friend-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}

.friend-card.vip-member-card {
  padding: 24px;
}

.friend-profile-media,
.friend-profile-details {
  min-width: 0;
}

.friend-profile-media {
  display: flex;
}

.friend-profile-photo {
  width: 100%;
  height: 100%;
  min-height: 280px;
  aspect-ratio: 4 / 5;
  border: 1px solid var(--border);
  border-radius: 8px;
  object-fit: cover;
  background: var(--panel-soft);
}

.friend-profile-photo-empty {
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 64px;
  font-weight: 900;
}

.friend-profile-details {
  display: grid;
  align-content: start;
  gap: 12px;
}

.friend-profile-details p {
  margin: 0;
}

.friend-profile-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.friend-profile-head h2 {
  margin: 0;
}

.friend-profile-head strong {
  flex: 0 0 auto;
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--input);
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
}

.friend-card.vip-member-card .friend-profile-head strong {
  border-color: rgba(245, 185, 66, 0.72);
  background: rgba(245, 185, 66, 0.18);
  color: #ffe8aa;
}

body[data-theme="day"] .friend-card.vip-member-card .friend-profile-head strong {
  border-color: #cf8d00;
  background: #fff0bd;
  color: #5c3700;
}

.friend-card-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
}

.friend-card-actions .btn {
  width: 100%;
}

.relationship-lines {
  display: grid;
  gap: 8px;
  margin: 8px 0 12px;
  width: 100%;
}

.relationship-line {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 8px 12px;
  border: 1px solid rgba(46, 160, 67, 0.55);
  border-radius: 8px;
  background: rgba(46, 160, 67, 0.16);
  color: #d7ffe1;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.relationship-link-panel {
  display: grid;
  gap: 10px;
  width: 100%;
  margin: 12px 0;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--panel-soft-surface);
}

.relationship-link-panel.compact {
  margin-top: auto;
}

.relationship-link-head,
.relationship-request-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
}

.relationship-link-panel .field {
  margin: 0;
}

body[data-theme="day"] .relationship-line {
  border-color: #167a3a;
  background: #c9f2d2;
  color: #052e16;
  text-shadow: none;
}

body[data-theme="day"] {
  --bg: #f2f4f7;
  --panel: #ffffff;
  --panel-soft: #f8fafc;
  --card: #ffffff;
  --input: #edf0f4;
  --border: #c9d1dc;
  --border-soft: #d8dde5;
  --text: #111827;
  --muted: #4b5563;
  --subtle: #6b7280;
  --accent: #111827;
  --accent-strong: #374151;
  --blue: #e5e7eb;
  --blue-border: #9ca3af;
  --shadow: rgba(43, 52, 66, 0.13);
  --button-bg: #ffffff;
  --button-text: #111827;
  --button-border: #c9d1dc;
  --button-primary-bg: #111827;
  --button-primary-text: #ffffff;
  --button-primary-border: #6b7280;
  --button-blue-bg: #e5e7eb;
  --button-blue-text: #111827;
  --button-blue-border: #9ca3af;
  --button-gold-bg: #d1d5db;
  --button-gold-text: #111827;
  --button-gold-border: #9ca3af;
  --button-danger-bg: #fee2e2;
  --button-danger-text: #7f1d1d;
  --button-danger-border: #f87171;
  --spotlight-canvas-opacity: 0.96;
  --spotlight-panel-mix: 84%;
  --spotlight-sidebar-mix: 88%;
  --spotlight-dark-base: #101827;
  --spotlight-dark-lift: #1e293b;
}

* {
  box-sizing: border-box;
}

body {
  --panel-surface: color-mix(in srgb, var(--panel) var(--spotlight-panel-mix), transparent);
  --panel-soft-surface: color-mix(in srgb, var(--panel-soft) var(--spotlight-panel-mix), transparent);
  margin: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--content-size);
  font-weight: var(--font-weight);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

.l2c-spotlight-background,
.l2c-background-effects {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  opacity: var(--spotlight-canvas-opacity);
}

.l2c-background-effects {
  border: 0;
  background: var(--bg);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image: var(--theme-background-image);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  opacity: var(--theme-background-opacity);
}

body:not(.has-custom-background)::before {
  display: none;
}

#root {
  min-height: 100vh;
  position: relative;
  z-index: 2;
}

button {
  font: inherit;
}

input,
select,
textarea {
  font-family: var(--field-font-family);
  font-size: var(--field-font-size);
  font-weight: var(--font-weight);
  line-height: inherit;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  max-width: 100vw;
  overflow-x: hidden;
  transition: grid-template-columns 180ms ease;
}

.app-shell.sidebar-collapsed {
  grid-template-columns: minmax(0, 1fr);
}

.menu-float {
  position: fixed;
  top: 14px;
  left: 14px;
  z-index: 30;
  width: 44px;
  height: 44px;
  display: grid;
  place-content: center;
  gap: 5px;
  border: 1px solid var(--blue-border);
  border-radius: 12px;
  background: var(--blue);
  box-shadow: 0 14px 34px var(--shadow);
  cursor: pointer;
}

.menu-float span {
  width: 18px;
  height: 2px;
  border-radius: 99px;
  background: var(--text);
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  align-self: start;
  width: 250px;
  height: 100vh;
  max-height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 22px 18px;
  background: color-mix(in srgb, var(--panel) var(--spotlight-sidebar-mix), transparent);
  backdrop-filter: blur(14px);
  border-right: 1px solid var(--border-soft);
  overflow-x: hidden;
  overflow-y: auto;
  z-index: 20;
  transition: transform 240ms cubic-bezier(.2, .8, .2, 1), opacity 180ms ease, padding 180ms ease;
  overscroll-behavior: contain;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px 0 16px;
}

.brand img {
  width: 170px;
  max-width: 100%;
  height: auto;
}

.nav {
  display: grid;
  gap: 8px;
  width: 100%;
  max-width: 100%;
}

.nav-section {
  display: grid;
  gap: 8px;
}

.nav-label {
  color: var(--subtle);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.nav a,
.theme-toggle {
  width: 100%;
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font-weight: 800;
  min-width: 0;
  text-decoration: none;
}

.nav a:hover,
.theme-toggle:hover {
  border-color: var(--border);
  background: var(--panel-soft);
}

.nav a.active {
  border-color: var(--blue-border);
  background: var(--blue);
}

.theme-box {
  display: grid;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
}

.theme-toggle span:last-child {
  min-width: 72px;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--input);
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}

.pwa-install-button {
  width: 100%;
  min-height: 58px;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border: 1px solid var(--blue-border);
  border-radius: 12px;
  background: color-mix(in srgb, var(--blue) 70%, var(--panel) 30%);
  color: var(--text);
  cursor: pointer;
  text-align: left;
}

.pwa-install-button:disabled {
  cursor: default;
  opacity: .88;
}

.pwa-install-button img {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
}

.pwa-install-button span {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.pwa-install-button strong {
  font-size: 14px;
  line-height: 1.1;
}

.pwa-install-button em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.pwa-install-button.installed {
  border-color: rgba(46, 160, 67, 0.55);
  background: rgba(35, 134, 54, 0.22);
}

.pwa-install-note {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.pwa-install-banner {
  display: none;
}

.sidebar-collapsed .sidebar {
  position: fixed;
  left: 0;
  top: 0;
  width: 250px;
  transform: translateX(-110%);
  opacity: 0;
  pointer-events: none;
}

.main {
  grid-column: 2;
  min-width: 0;
  padding: 28px;
  display: grid;
  gap: 22px;
}

.sidebar-collapsed .main {
  grid-column: 1;
}

.page {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  display: grid;
  gap: 20px;
  min-width: 0;
}

.hero,
.panel,
.card,
.filters {
  width: 100%;
  min-width: 0;
  background: linear-gradient(180deg, var(--panel-soft-surface) 0%, var(--panel-surface) 100%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 18px 48px var(--shadow);
}

.hero {
  padding: 24px;
}

.hero h1,
.panel h2,
.card h3 {
  margin: 0;
  padding-bottom: var(--title-padding);
}

.hero h1 {
  font-size: var(--title-size);
  line-height: 1.1;
}

.panel h2,
.card h3 {
  font-size: var(--panel-title-size);
  line-height: 1.18;
}

.hero p,
.panel p,
.card p {
  margin: var(--text-padding) 0;
  color: var(--muted);
  font-size: var(--content-size);
  line-height: 1.5;
}

.grid {
  display: grid;
  gap: 16px;
}

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

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

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

.panel,
.card,
.filters {
  padding: 20px;
}

body.appearance-glass-goo {
  --glass-goo-border: color-mix(in srgb, var(--blue-border) 54%, rgba(255, 255, 255, 0.58));
  --glass-goo-sheen: color-mix(in srgb, var(--accent) 24%, rgba(255, 255, 255, 0.5));
  --glass-goo-glow: color-mix(in srgb, var(--accent-strong) 28%, transparent);
}

body.appearance-glass-goo .hero,
body.appearance-glass-goo .panel,
body.appearance-glass-goo .card,
body.appearance-glass-goo .filters,
body.appearance-glass-goo .appearance-control-group,
body.appearance-glass-goo .appearance-background-card,
body.appearance-glass-goo .appearance-preview,
body.appearance-glass-goo .message,
body.appearance-glass-goo .room-card,
body.appearance-glass-goo .event-card,
body.appearance-glass-goo .group-card,
body.appearance-glass-goo .marketplace-card,
body.appearance-glass-goo .oracle-reader-card {
  position: relative;
  overflow: hidden;
  border-color: var(--glass-goo-border);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.06) 42%, rgba(0, 0, 0, 0.14)),
    color-mix(in srgb, var(--panel) 68%, transparent) !important;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.14),
    inset 18px 16px 36px rgba(255, 255, 255, 0.08),
    inset -22px -20px 38px rgba(0, 0, 0, 0.12),
    0 24px 70px var(--shadow);
  backdrop-filter: blur(18px) saturate(1.22);
  -webkit-backdrop-filter: blur(18px) saturate(1.22);
}

body.appearance-glass-goo .hero::before,
body.appearance-glass-goo .panel::before,
body.appearance-glass-goo .card::before,
body.appearance-glass-goo .filters::before,
body.appearance-glass-goo .appearance-control-group::before,
body.appearance-glass-goo .appearance-background-card::before,
body.appearance-glass-goo .appearance-preview::before,
body.appearance-glass-goo .message::before,
body.appearance-glass-goo .room-card::before,
body.appearance-glass-goo .event-card::before,
body.appearance-glass-goo .group-card::before,
body.appearance-glass-goo .marketplace-card::before,
body.appearance-glass-goo .oracle-reader-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.34), transparent 32%, rgba(255, 255, 255, 0.08) 72%),
    linear-gradient(90deg, transparent 0 64%, var(--glass-goo-sheen) 92%, transparent 100%);
  opacity: 0.7;
  mix-blend-mode: screen;
}

body.appearance-glass-goo .hero::after,
body.appearance-glass-goo .panel::after,
body.appearance-glass-goo .card::after,
body.appearance-glass-goo .filters::after,
body.appearance-glass-goo .message::after {
  content: "";
  position: absolute;
  right: -28px;
  top: 18%;
  z-index: 0;
  width: 72px;
  height: 54%;
  min-height: 64px;
  border-radius: 999px 0 0 999px;
  pointer-events: none;
  background: linear-gradient(180deg, var(--glass-goo-sheen), var(--glass-goo-glow));
  filter: blur(13px);
  opacity: 0.24;
  transform: scaleX(0.68);
}

body.appearance-glass-goo .hero > *,
body.appearance-glass-goo .panel > *,
body.appearance-glass-goo .card > *,
body.appearance-glass-goo .filters > *,
body.appearance-glass-goo .appearance-control-group > *,
body.appearance-glass-goo .appearance-background-card > *,
body.appearance-glass-goo .appearance-preview > *,
body.appearance-glass-goo .message > *,
body.appearance-glass-goo .room-card > *,
body.appearance-glass-goo .event-card > *,
body.appearance-glass-goo .group-card > *,
body.appearance-glass-goo .marketplace-card > *,
body.appearance-glass-goo .oracle-reader-card > * {
  position: relative;
  z-index: 1;
}

body.appearance-glass-goo .btn,
body.appearance-glass-goo .tiny-btn,
body.appearance-glass-goo .theme-toggle,
body.appearance-glass-goo .nav a,
body.appearance-glass-goo input,
body.appearance-glass-goo select,
body.appearance-glass-goo textarea {
  backdrop-filter: blur(12px) saturate(1.15);
  -webkit-backdrop-filter: blur(12px) saturate(1.15);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  body.appearance-glass-goo .hero,
  body.appearance-glass-goo .panel,
  body.appearance-glass-goo .card,
  body.appearance-glass-goo .filters,
  body.appearance-glass-goo .message {
    background: color-mix(in srgb, var(--panel) 92%, var(--panel-soft) 8%) !important;
  }
}

.public-cta-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
}

.public-cta-panel h2 {
  max-width: 760px;
}

.public-cta-panel .button-row {
  margin-top: 0;
  justify-content: flex-end;
}

.public-feature-preview {
  display: grid;
  gap: 16px;
}

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

.feature-preview-card {
  display: grid;
  align-content: start;
  gap: 12px;
  min-height: 240px;
  padding: 18px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
}

.feature-preview-card h3 {
  margin: 0;
  font-size: 22px;
}

.feature-preview-card .btn {
  justify-self: start;
  margin-top: auto;
}

.blog-preview-card {
  display: grid;
  align-content: start;
  gap: 12px;
}

.blog-preview-card .button-row {
  margin-top: auto;
}

.locked-route em {
  color: var(--gold);
}

.auth-benefits-panel {
  grid-column: 1 / -1;
}

.stat {
  display: grid;
  gap: 6px;
}

.stat span,
.label {
  color: var(--subtle);
  font-size: 13px;
  font-weight: 800;
}

.stat strong {
  font-size: var(--title-size);
}

.admin-users-stats .stat {
  min-height: 0;
  padding: 18px 20px;
}

.admin-users-stats .stat strong {
  font-size: 30px;
}

.admin-users-stats .stat p {
  margin: 0;
}

.form-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.dealbreaker-grid {
  display: grid;
  gap: 12px;
}

.dealbreaker-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(180px, 0.58fr);
  gap: 12px;
  align-items: end;
}

.dealbreaker-row.age-row {
  grid-template-columns: minmax(120px, 0.5fr) minmax(120px, 0.5fr) minmax(180px, 0.58fr);
}

.dealbreaker-row .field,
.dealbreaker-row .check-card,
.dealbreaker-row .dealbreaker-note {
  min-width: 0;
}

.dealbreaker-row .check-card,
.dealbreaker-row .dealbreaker-note {
  min-height: var(--field-control-height);
}

.dealbreaker-note {
  display: flex;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: color-mix(in srgb, var(--input) 72%, transparent);
  color: var(--subtle);
  font-size: 13px;
  font-weight: 800;
}

.appearance-studio {
  display: grid;
  gap: 18px;
  border-color: var(--blue-border);
  background: linear-gradient(180deg, color-mix(in srgb, var(--panel) 92%, var(--blue) 8%), var(--panel));
}

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

.appearance-toolbar .field {
  min-width: 0;
}

.appearance-body {
  display: grid;
  gap: 16px;
  grid-template-columns: minmax(320px, 0.82fr) minmax(0, 1.18fr);
  align-items: stretch;
}

.appearance-side,
.appearance-controls {
  display: grid;
  gap: 14px;
}

.appearance-side {
  grid-template-rows: auto auto minmax(320px, 1fr);
  align-content: stretch;
}

.appearance-controls .appearance-control-group,
.appearance-background-card,
.appearance-preview {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 86%, var(--panel-soft) 14%);
}

.appearance-preview {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.appearance-preview strong {
  font-size: var(--panel-title-size);
}

.appearance-control-group {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.appearance-control-group h3 {
  margin: 0;
  color: var(--subtle);
  font-size: 13px;
}

.appearance-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.appearance-background-row {
  display: grid;
  grid-template-columns: minmax(180px, 0.55fr) minmax(0, 1fr);
  gap: 12px;
  align-items: stretch;
}

.appearance-background-card {
  grid-template-rows: auto minmax(0, 1fr);
}

.appearance-background-card .appearance-background-row {
  grid-template-columns: 1fr;
  grid-template-rows: minmax(280px, 1fr) auto;
  min-height: 100%;
}

.appearance-background-card .appearance-background-preview {
  min-height: 280px;
}

.appearance-background-preview {
  --preview-background-image: none;
  --preview-background-opacity: 1;
  position: relative;
  min-height: 120px;
  display: grid;
  place-items: end start;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
}

.appearance-background-preview::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--preview-background-image);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  opacity: var(--preview-background-opacity);
}

.appearance-background-preview span {
  position: relative;
  z-index: 1;
  padding: 6px 9px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: color-mix(in srgb, var(--panel) 78%, transparent);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
}

.appearance-background-preview:not(.has-background)::before {
  display: none;
}

.appearance-background-preview.has-background {
  box-shadow: none;
}

.appearance-background-actions {
  display: grid;
  align-content: center;
  gap: 10px;
}

.appearance-background-action-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
}

.appearance-background-action-grid .btn {
  width: 100%;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.appearance-background-action-grid .range-field {
  min-width: 0;
}

.color-field {
  grid-template-columns: minmax(0, 1fr) 54px;
  align-items: center;
}

.color-field input[type="color"] {
  min-height: 42px;
  padding: 3px;
  cursor: pointer;
}

.range-field {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.range-field input[type="range"] {
  grid-column: 1 / -1;
  padding: 0;
}

.auth-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.6fr);
  gap: 16px;
}

.auth-layout.auth-layout-verify {
  grid-template-columns: minmax(0, 760px);
  justify-content: center;
}

.auth-verify-panel {
  max-width: 560px;
  width: 100%;
  margin: 0 auto;
  text-align: center;
}

.auth-pin-field {
  max-width: 360px;
  margin: 24px auto 0;
}

.auth-pin-field input {
  min-height: 72px;
  text-align: center;
  font-size: clamp(28px, 8vw, 42px);
  font-weight: 800;
  letter-spacing: 0.32em;
  padding-left: calc(14px + 0.32em);
}

.auth-pin-help {
  margin: 12px auto 0;
}

.auth-change-login {
  margin-top: 14px;
  border: 0;
  background: transparent;
  color: var(--blue-soft);
  text-decoration: underline;
  cursor: pointer;
}

.field {
  display: grid;
  gap: 7px;
  font-family: var(--field-font-family);
  font-weight: var(--font-weight);
  font-size: var(--field-font-size);
}

.field.full {
  grid-column: 1 / -1;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--input);
  color: var(--text);
  padding: 12px 14px;
}

.translation-toggle-field {
  align-content: start;
}

.switch-control {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--input);
  font-family: var(--field-font-family);
  font-size: var(--field-font-size);
  cursor: pointer;
}

.switch-control input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  padding: 0;
  opacity: 0;
  pointer-events: none;
}

.switch-track {
  width: 56px;
  height: 30px;
  display: flex;
  align-items: center;
  padding: 3px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: var(--panel-soft);
  transition: background 0.2s ease, border-color 0.2s ease;
}

.switch-thumb {
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: var(--muted);
  transition: transform 0.2s ease, background 0.2s ease;
}

.switch-control input:focus-visible + .switch-track {
  outline: 2px solid var(--accent-strong);
  outline-offset: 2px;
}

.switch-control input:checked + .switch-track {
  border-color: var(--button-primary-border);
  background: var(--button-primary-bg);
}

.switch-control input:checked + .switch-track .switch-thumb {
  transform: translateX(26px);
  background: var(--button-primary-text);
}

.switch-control strong {
  min-width: 28px;
  color: var(--text);
  text-align: right;
}

.field input[type="file"] {
  color: var(--text);
  padding: 10px 12px;
}

.field input[type="file"]::file-selector-button {
  margin-right: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--panel);
  color: var(--text);
  font-weight: var(--font-weight);
}

.file-status {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 4px 8px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--text);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.field textarea {
  min-height: 110px;
  resize: vertical;
}

.password-field > label {
  font-weight: var(--font-weight);
}

.password-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.password-eye-control {
  grid-template-columns: minmax(0, 1fr) 48px;
}

.password-control input {
  min-width: 0;
}

.password-eye-btn {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--input);
  color: var(--text);
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
}

.password-eye-btn.active {
  border-color: var(--button-gold-border);
  background: var(--button-gold-bg);
  color: var(--button-gold-text);
}

.password-control .password-suggest-btn {
  min-height: 48px;
  white-space: nowrap;
}

.button-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.btn {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid var(--button-border);
  border-radius: 14px;
  background: var(--button-bg);
  color: var(--button-text);
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
}

.btn.primary {
  background: var(--button-primary-bg);
  border-color: var(--button-primary-border);
  color: var(--button-primary-text);
}

.btn.secondary {
  background: var(--button-blue-bg);
  border-color: var(--button-blue-border);
  color: var(--button-blue-text);
}

.btn.moderation-queue-button-clear {
  border-color: rgba(46, 160, 67, 0.55);
  background: rgba(46, 160, 67, 0.18);
  color: #b8f5c7;
}

.btn.moderation-queue-button-hot {
  background: linear-gradient(180deg, var(--accent-strong), var(--accent));
  border-color: #efb4b4;
  color: #fff;
}

.btn:disabled {
  opacity: 0.58;
  cursor: default;
}

.btn.blue {
  background: var(--button-blue-bg);
  border-color: var(--button-blue-border);
  color: var(--button-blue-text);
}

.btn.gold {
  background: var(--button-gold-bg);
  border-color: var(--button-gold-border);
  color: var(--button-gold-text);
}

.btn.danger {
  border-color: var(--button-danger-border);
  background: var(--button-danger-bg);
  color: var(--button-danger-text);
}

body[data-theme="day"] .btn.danger {
  border-color: var(--button-danger-border);
  background: var(--button-danger-bg);
  color: var(--button-danger-text);
}

body[data-theme="day"] .btn.danger:disabled {
  opacity: 1;
  color: var(--button-danger-text);
}

body[data-theme="day"] .btn.moderation-queue-button-clear {
  border-color: #167a3a;
  background: #c9f2d2;
  color: #052e16;
  text-shadow: none;
}

body[data-theme="day"] .btn.moderation-queue-button-hot {
  border-color: #d1242f;
  background: #d81725;
  color: #fff;
  text-shadow: none;
}

.btn.small {
  min-height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  font-size: 13px;
}

.dashboard-page {
  max-width: 1082px;
  gap: 18px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.dashboard-grid-small {
  gap: 18px;
}

.dashboard-card {
  min-height: 206px;
  padding: 20px;
  border-color: var(--border);
  border-radius: 18px;
  background: linear-gradient(180deg, var(--panel-soft-surface) 0%, var(--panel-surface) 100%);
  box-shadow: none;
}

.dashboard-card h2 {
  font-size: var(--title-size);
  line-height: 1.28;
  font-weight: 400;
}

.dashboard-card h2 strong {
  font-size: var(--title-size);
  line-height: 1.12;
  font-weight: 800;
}

.dashboard-card p {
  max-width: 300px;
  margin: 8px 0 0;
  color: #ffffff;
  line-height: 1.45;
}

.dashboard-card .blue-text {
  color: #bfe0ff;
  font-size: 14px;
}

body[data-theme="day"] .dashboard-card {
  border-color: var(--border);
  background: linear-gradient(180deg, var(--panel-surface) 0%, var(--panel-soft-surface) 100%);
  color: var(--text);
  box-shadow: 0 10px 26px var(--shadow);
}

body[data-theme="day"] .dashboard-card h2,
body[data-theme="day"] .dashboard-card h2 strong {
  color: var(--text);
}

body[data-theme="day"] .dashboard-card p {
  color: var(--muted);
}

body[data-theme="day"] .dashboard-card .blue-text {
  color: #214e77;
}

.recommendation-panel {
  display: grid;
  gap: 16px;
}

.dashboard-recommendations-stack {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.dashboard-recommendations-stack > .dashboard-card {
  --recommendation-accent: #a58bff;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.dashboard-recommendations-stack > .dashboard-card:hover,
.dashboard-recommendations-stack > .dashboard-card:focus-within {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--recommendation-accent) 62%, var(--border));
  box-shadow: 0 20px 42px rgba(0, 0, 0, .2);
}

.recommendation-people-panel {
  background:
    radial-gradient(circle at 94% 8%, rgba(165, 139, 255, 0.13), transparent 30%),
    var(--panel-surface);
}

.recommendation-eyebrow {
  display: block;
  margin-bottom: 5px;
  color: #c8b9ff;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: .095em;
  text-transform: uppercase;
}

.recommendation-category-panel {
  --recommendation-accent: #5da9ff;
  display: grid;
  gap: 18px;
  background:
    radial-gradient(circle at 94% 4%, color-mix(in srgb, var(--recommendation-accent) 12%, transparent), transparent 32%),
    var(--panel-surface);
}

.recommendation-groups-panel { --recommendation-accent: #4bd6a2; }
.recommendation-rooms-panel { --recommendation-accent: #5da9ff; }
.recommendation-events-panel { --recommendation-accent: #ff8b6a; }

.recommendation-category-head {
  align-items: center;
  gap: 20px;
}

.recommendation-category-title {
  display: flex;
  min-width: 0;
  gap: 14px;
  align-items: center;
}

.recommendation-category-title > div {
  min-width: 0;
}

.recommendation-category-title h2 {
  margin-bottom: 3px;
}

.recommendation-category-title p {
  margin: 0;
}

.recommendation-category-icon {
  display: grid;
  flex: 0 0 48px;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--recommendation-accent) 42%, var(--border));
  border-radius: 15px;
  background: color-mix(in srgb, var(--recommendation-accent) 15%, var(--input));
  color: color-mix(in srgb, var(--recommendation-accent) 84%, white);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 10px 24px color-mix(in srgb, var(--recommendation-accent) 10%, transparent);
  font-size: 20px;
  font-weight: 900;
}

.recommendation-category-panel .recommendation-eyebrow {
  color: color-mix(in srgb, var(--recommendation-accent) 78%, white);
}

.recommendation-category-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.recommendation-category-panel .recommendation-item {
  align-content: space-between;
  min-height: 190px;
  padding: 16px;
  border: 1px solid color-mix(in srgb, var(--recommendation-accent) 25%, var(--border));
  border-radius: 14px;
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--recommendation-accent) 8%, var(--input)), color-mix(in srgb, var(--input) 94%, transparent));
  box-shadow: 0 10px 24px rgba(0, 0, 0, .09);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.recommendation-category-panel .recommendation-item:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--recommendation-accent) 52%, var(--border));
  box-shadow: 0 14px 28px rgba(0, 0, 0, .15);
}

.recommendation-category-panel .recommendation-item > div:first-child > .pill:first-child {
  border-color: color-mix(in srgb, var(--recommendation-accent) 38%, var(--border));
  background: color-mix(in srgb, var(--recommendation-accent) 12%, var(--input));
}

.recommendation-category-panel .recommendation-actions {
  padding-top: 2px;
}

.recommendation-empty {
  grid-column: 1 / -1;
  padding: 20px;
  border: 1px dashed color-mix(in srgb, var(--recommendation-accent) 34%, var(--border));
  border-radius: 14px;
  background: color-mix(in srgb, var(--recommendation-accent) 5%, var(--input));
}

.recommendation-empty strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text);
}

.recommendation-empty p {
  margin: 0;
}

.recommendation-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.recommendation-column {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 10px;
}

.recommendation-column h3 {
  margin: 0;
  color: #ffffff;
  font-size: 16px;
}

.recommendation-people-column {
  grid-column: 1 / -1;
}

.recommendation-people-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

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

.recommendation-item {
  min-width: 0;
  display: grid;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.recommendation-item h3 {
  margin: 7px 0 4px;
  color: #ffffff;
  font-size: 15px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.recommendation-item p {
  max-width: none;
  margin: 0;
  color: #e5f3ff;
  font-size: 13px;
}

.recommendation-item small,
.recommendation-item em {
  display: block;
  color: #bfe0ff;
  font-size: 12px;
  line-height: 1.35;
  font-style: normal;
}

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

.recommendation-member-card {
  align-content: start;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--panel-soft-surface);
  box-shadow: 0 12px 28px var(--shadow);
}

.recommendation-member-photo-shell {
  display: grid;
  min-width: 0;
}

.recommendation-member-photo-shell > * {
  grid-area: 1 / 1;
}

.recommendation-member-photo-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--blue) 72%, var(--panel)) 0%, color-mix(in srgb, var(--red) 54%, var(--panel)) 100%);
  color: #ffffff;
  font-size: clamp(38px, 8vw, 64px);
  font-weight: 900;
}

.recommendation-member-card .match-card-photo {
  position: relative;
  z-index: 1;
}

.recommendation-member-card .match-top h3 {
  margin: 0;
  font-size: 18px;
}

.recommendation-member-card .match-top strong {
  flex: 0 0 auto;
  color: var(--blue-soft);
  font-size: 13px;
}

.good-match-card {
  border-color: color-mix(in srgb, #c77c95 42%, var(--border)) !important;
  box-shadow: 0 0 0 1px rgba(199, 124, 149, 0.1), 0 12px 28px var(--shadow);
}

.good-match-pill {
  border-color: color-mix(in srgb, #c77c95 48%, var(--border)) !important;
  background: color-mix(in srgb, #7b344f 18%, var(--input)) !important;
  color: #ffffff !important;
  box-shadow: none;
}

.recommendation-member-card .match-card-bio {
  color: var(--muted);
}

.recommendation-member-reason {
  padding-top: 9px;
  border-top: 1px solid var(--border-soft);
}

body[data-theme="day"] .recommendation-member-card {
  border-color: var(--border);
  background: linear-gradient(180deg, var(--panel-surface) 0%, var(--panel-soft-surface) 100%);
}

body[data-theme="day"] .recommendation-member-card .match-top strong {
  color: #214e77;
}

.token-cost-preview {
  display: grid;
  gap: 10px;
  margin-top: 10px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(5, 16, 27, 0.32);
}

.token-cost-preview-shell {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.token-cost-preview-shell .token-cost-preview {
  margin-top: 0;
}

.token-cost-preview-toggle-row,
.token-cost-preview-off {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(5, 16, 27, 0.24);
}

.token-cost-preview-toggle-row > div,
.token-cost-preview-off {
  min-width: 0;
}

.token-cost-preview-toggle-row strong,
.token-cost-preview-off strong {
  display: block;
  color: #ffffff;
  font-size: 14px;
}

.token-cost-preview-toggle-row span,
.token-cost-preview-off span {
  color: #cfe7fb;
  font-size: 12px;
}

.compact-switch {
  flex: 0 0 auto;
}

.compact-switch .switch-track {
  width: 46px;
  height: 26px;
}

.compact-switch .switch-thumb {
  width: 18px;
  height: 18px;
}

.compact-switch input:checked + .switch-track .switch-thumb {
  transform: translateX(20px);
}

.token-cost-preview-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.token-cost-preview-head strong {
  color: #ffffff;
  font-size: 14px;
}

.token-cost-preview-head span,
.token-cost-preview-lines span {
  color: #cfe7fb;
  font-size: 12px;
}

.token-cost-preview-lines {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.token-cost-preview-lines div {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.08);
}

.token-cost-preview-lines strong {
  color: #ffffff;
  font-size: 13px;
  text-align: right;
  overflow-wrap: anywhere;
}

.token-cost-preview-lines .token-cost-total {
  border: 1px solid rgba(106, 193, 255, 0.45);
  background: rgba(106, 193, 255, 0.14);
}

.token-cost-preview.is-warning {
  border-color: rgba(255, 191, 105, 0.65);
  background: rgba(89, 47, 8, 0.26);
}

.token-cost-topup[hidden] {
  display: none;
}

body[data-theme="day"] .recommendation-column h3,
body[data-theme="day"] .recommendation-item h3 {
  color: var(--text);
}

body[data-theme="day"] .recommendation-item {
  border-top-color: var(--border-soft);
}

body[data-theme="day"] .recommendation-item p {
  color: var(--muted);
}

body[data-theme="day"] .recommendation-item small,
body[data-theme="day"] .recommendation-item em {
  color: #365f82;
}

body[data-theme="day"] .recommendation-people-panel,
body[data-theme="day"] .recommendation-category-panel {
  background:
    radial-gradient(circle at 94% 4%, color-mix(in srgb, var(--recommendation-accent, #a58bff) 10%, transparent), transparent 32%),
    linear-gradient(180deg, var(--panel-surface) 0%, var(--panel-soft-surface) 100%);
}

body[data-theme="day"] .recommendation-eyebrow {
  color: color-mix(in srgb, var(--recommendation-accent, #7658d8) 82%, #26314f);
}

body[data-theme="day"] .token-cost-preview {
  border-color: var(--border-soft);
  background: #f6fbff;
}

body[data-theme="day"] .token-cost-preview-toggle-row,
body[data-theme="day"] .token-cost-preview-off {
  border-color: var(--border-soft);
  background: #f6fbff;
}

body[data-theme="day"] .token-cost-preview-toggle-row strong,
body[data-theme="day"] .token-cost-preview-off strong {
  color: var(--text);
}

body[data-theme="day"] .token-cost-preview-toggle-row span,
body[data-theme="day"] .token-cost-preview-off span {
  color: var(--muted);
}

body[data-theme="day"] .token-cost-preview-head strong,
body[data-theme="day"] .token-cost-preview-lines strong {
  color: var(--text);
}

body[data-theme="day"] .token-cost-preview-head span,
body[data-theme="day"] .token-cost-preview-lines span {
  color: var(--muted);
}

body[data-theme="day"] .token-cost-preview-lines div {
  background: #ffffff;
}

body[data-theme="day"] .token-cost-preview-lines .token-cost-total {
  border-color: #9bd5ff;
  background: #eaf6ff;
}

body[data-theme="day"] .token-cost-preview.is-warning {
  border-color: #f2a63b;
  background: #fff7e8;
}

.profile-completion-panel {
  display: grid;
  gap: 14px;
}

.profile-completion-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}

.profile-completion-head h2 {
  margin: 0;
  font-size: 28px;
}

.profile-completion-meter {
  height: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--input);
}

.profile-completion-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #22c7ff 0%, #f5b942 52%, #17ef45 100%);
}

.profile-completion-checklist {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px;
}

.profile-completion-checklist button {
  min-height: 58px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 2px 8px;
  align-items: center;
  padding: 9px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.profile-completion-checklist button span,
.onboarding-step-list button span {
  min-height: 24px;
  display: inline-grid;
  place-items: center;
  padding: 2px 7px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: var(--panel);
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.profile-completion-checklist button strong,
.onboarding-step-list button strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.profile-completion-checklist button em,
.onboarding-step-list button em {
  grid-column: 2;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.profile-completion-checklist button.complete,
.onboarding-step-list button.complete {
  border-color: color-mix(in srgb, #17ef45 48%, var(--border));
  background: color-mix(in srgb, var(--panel-soft) 82%, #17ef45 18%);
}

.profile-completion-checklist button.complete span,
.onboarding-step-list button.complete span {
  border-color: color-mix(in srgb, #17ef45 55%, var(--border));
  color: #17ef45;
}

.profile-completion-hide-row {
  display: grid;
  gap: 8px;
  justify-items: start;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
}

.profile-completion-hide-button {
  min-width: min(100%, 320px);
  border-color: color-mix(in srgb, var(--blue) 72%, var(--border));
  background: color-mix(in srgb, var(--blue) 24%, var(--panel));
  color: #ffffff;
}

.profile-completion-hide-row small {
  color: var(--muted);
}

.dashboard-notice {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  min-height: 28px;
  padding: 6px 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

.dashboard-notice.success {
  border: 1px solid rgba(46, 160, 67, 0.7);
  background: rgba(46, 160, 67, 0.2);
  color: #c6f6d2;
}

.dashboard-notice.warning {
  border: 1px solid rgba(245, 158, 11, 0.78);
  background: rgba(146, 83, 6, 0.34);
  color: #ffe2ad;
}

.dashboard-notice.error {
  border: 1px solid rgba(255, 79, 88, 0.72);
  background: rgba(153, 27, 33, 0.28);
  color: #ffd0d3;
}

body[data-theme="day"] .dashboard-notice.success {
  border-color: #167a3a;
  background: #d8f8de;
  color: #052e16;
}

body[data-theme="day"] .dashboard-notice.warning {
  border-color: #d89a18;
  background: #fff2c7;
  color: #5f3b00;
}

body[data-theme="day"] .dashboard-notice.error {
  border-color: #b91c1c;
  background: #ffe1e3;
  color: #7f1d1d;
}

.dashboard-notice .btn.small {
  min-height: 28px;
  padding: 0 12px;
  border-radius: 8px;
  font-size: 12px;
}

.dashboard-wide {
  min-height: 134px;
}

.dashboard-divider {
  height: 1px;
  margin: 14px 0 12px;
  background: #2d2d2d;
}

body[data-theme="day"] .dashboard-divider {
  background: var(--border-soft);
}

.dashboard-actions {
  margin-top: 12px;
}

.dashboard-actions .btn {
  min-height: 46px;
  border-radius: 13px;
}

.admin-token-gift-panel {
  display: grid;
  gap: 14px;
  border-radius: 10px;
}

.admin-token-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.admin-token-grid .field.full {
  grid-column: 1 / -1;
}

.admin-token-results {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.admin-token-results .tiny-btn.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.admin-token-gift-panel .field input,
.admin-token-gift-panel .field select {
  border-radius: 6px;
}

.admin-token-gift-panel .btn {
  border-radius: 8px;
}

.admin-token-gift-panel .tiny-btn,
.admin-token-gift-panel .pill {
  border-radius: 6px;
}

.admin-token-gift-panel .dashboard-notice {
  max-width: 420px;
  padding: 8px 10px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  margin-top: 8px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.status-pill.gold {
  border: 1px solid #6fa8dc;
  background: #14314d;
  color: #e8f4ff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

body[data-theme="day"] .status-pill.gold {
  border-color: #f0b84a;
  background: #fff2c7;
  color: #6b4300;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.room-mini-list {
  display: grid;
  gap: 10px;
  margin-top: 8px;
}

.room-mini-list button {
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
  border: 1px solid #31445a;
  border-radius: 12px;
  background: #111821;
  color: #fff;
  cursor: pointer;
}

body[data-theme="day"] .room-mini-list button {
  border-color: var(--blue-border);
  background: #f8fbff;
  color: var(--text);
}

body[data-theme="day"] .room-mini-list span {
  color: var(--muted);
}

.room-mini-list span {
  font-size: 12px;
}

.match-card {
  display: grid;
  gap: 12px;
}

.match-card-bio {
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

body[data-theme="day"] .match-card-bio {
  color: #475569;
}

.vip-member-card {
  border-color: color-mix(in srgb, #d7ad55 48%, var(--border));
  background:
    linear-gradient(180deg, color-mix(in srgb, #d7ad55 10%, var(--panel-soft)) 0%, color-mix(in srgb, #d7ad55 4%, var(--panel)) 100%);
  box-shadow: 0 18px 44px color-mix(in srgb, #d7ad55 12%, var(--shadow));
}

body[data-theme="day"] .vip-member-card {
  border-color: #b8944c;
  background: linear-gradient(180deg, #fffaf0 0%, #f7fbff 82%);
  box-shadow: 0 16px 38px rgba(114, 78, 0, 0.11);
}

body.appearance-glass-goo .vip-member-card {
  border-color: color-mix(in srgb, #d7ad55 58%, rgba(255, 255, 255, 0.5));
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.18), rgba(215, 173, 85, 0.1) 38%, rgba(0, 0, 0, 0.12)),
    color-mix(in srgb, var(--panel) 76%, rgba(215, 173, 85, 0.12));
}

.vip-lifetime-card {
  box-shadow: inset 0 0 0 1px rgba(215, 173, 85, 0.1), 0 18px 44px color-mix(in srgb, #d7ad55 13%, var(--shadow));
}

.vip-member-card.good-match-card {
  border-color: color-mix(in srgb, #d7ad55 58%, var(--border)) !important;
  box-shadow: inset 0 0 0 1px rgba(215, 173, 85, 0.08), 0 16px 38px color-mix(in srgb, #d7ad55 12%, var(--shadow));
}

.match-card-photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border);
  border-radius: 8px;
  object-fit: cover;
  background: var(--panel-soft);
}

.match-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.profile-name-line {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.profile-name-text {
  min-width: 0;
  overflow-wrap: anywhere;
}

.vip-member-name {
  color: #f0d491;
  font-weight: 900;
}

body[data-theme="day"] .vip-member-name {
  color: #7a4b00;
}

.vip-crown {
  width: auto;
  min-width: 27px;
  height: 18px;
  flex: 0 0 auto;
  display: inline-grid;
  place-items: center;
  padding: 0 5px;
  border: 1px solid rgba(235, 204, 126, 0.72);
  border-radius: 999px;
  background: rgba(215, 173, 85, 0.14);
  color: #ffe8aa;
  font-size: 8px;
  font-weight: 950;
  letter-spacing: 0.04em;
  line-height: 1;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
}

.match-card.vip-member-card .match-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  padding-bottom: 2px;
}

.match-card.vip-member-card .match-top h2 {
  min-width: 0;
  margin-bottom: 0;
}

.match-card.vip-member-card .match-top strong {
  justify-self: start;
  margin-left: 35px;
  color: color-mix(in srgb, #f0d491 48%, var(--text));
  font-size: 12px;
}

.match-card.vip-member-card .profile-name-text {
  overflow: hidden;
  overflow-wrap: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.match-card.vip-member-card .match-card-photo {
  border-color: color-mix(in srgb, #d7ad55 42%, var(--border));
}

.pill.vip-pill {
  border-color: rgba(215, 173, 85, 0.64);
  background: rgba(215, 173, 85, 0.14);
  color: #ffe8aa;
}

.pill.vip-pill.lifetime,
.vip-crown.lifetime {
  border-color: rgba(235, 204, 126, 0.76);
  box-shadow: 0 0 0 2px rgba(215, 173, 85, 0.08);
}

.chat-vip-badge {
  display: inline-grid;
  place-items: center;
  min-width: 25px;
  height: 15px;
  padding: 0 4px;
  border: 1px solid rgba(215, 173, 85, 0.58);
  border-radius: 999px;
  background: rgba(215, 173, 85, 0.12);
  color: #ffe4a0;
  font-size: 7px;
  font-weight: 950;
  letter-spacing: 0.06em;
  line-height: 1;
  vertical-align: middle;
}

.chat-vip-badge.lifetime {
  border-color: rgba(235, 204, 126, 0.76);
  background: rgba(215, 173, 85, 0.17);
}

.moderator-name {
  display: inline-flex;
  gap: 5px;
  align-items: center;
}

body[data-theme="day"] .chat-vip-badge {
  border-color: #b8944c;
  background: #fff7e4;
  color: #65460e;
}

body[data-theme="day"] .pill.vip-pill {
  border-color: #cf8d00 !important;
  background: #fff0bd !important;
  color: #5c3700 !important;
  text-shadow: none !important;
}

.presence-dot {
  width: 12px;
  height: 12px;
  flex: 0 0 12px;
  border-radius: 999px;
  border: 2px solid var(--panel);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--text) 12%, transparent);
}

.presence-dot-online {
  background: #17ef45;
  box-shadow: 0 0 0 1px rgba(23, 239, 69, 0.35), 0 0 12px rgba(23, 239, 69, 0.48);
}

.presence-dot-away {
  background: #ffd43b;
  box-shadow: 0 0 0 1px rgba(255, 212, 59, 0.42), 0 0 10px rgba(255, 212, 59, 0.36);
}

.presence-dot-offline {
  background: #9aa5b1;
  box-shadow: 0 0 0 1px rgba(154, 165, 177, 0.24);
}

.friend-online-toasts {
  position: fixed;
  left: 50%;
  bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  z-index: 70;
  display: grid;
  gap: 8px;
  width: min(420px, calc(100vw - 28px));
  transform: translateX(-50%);
  pointer-events: none;
}

.direct-message-toasts {
  position: fixed;
  top: calc(14px + env(safe-area-inset-top, 0px));
  left: 50%;
  z-index: 80;
  display: grid;
  gap: 8px;
  width: min(420px, calc(100vw - 28px));
  transform: translateX(-50%);
  pointer-events: none;
}

.direct-message-toast {
  display: grid;
  gap: 2px;
  width: 100%;
  min-height: 58px;
  padding: 12px 16px;
  border: 1px solid var(--blue-border);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 94%, var(--blue) 10%);
  color: var(--text);
  text-align: left;
  box-shadow: 0 18px 42px var(--shadow);
  pointer-events: auto;
  animation: directMessageToast 1.5s ease forwards;
}

.direct-message-toast strong,
.direct-message-toast span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.direct-message-toast strong {
  font-size: 0.86rem;
  font-weight: 900;
}

.direct-message-toast span {
  font-size: 0.94rem;
}

body[data-theme="day"] .direct-message-toast {
  background: #eff6ff;
  color: #0f172a;
}

.friend-online-toast {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 10px 14px;
  border: 1px solid rgba(23, 239, 69, 0.48);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 92%, rgba(23, 239, 69, 0.16));
  color: var(--text);
  box-shadow: 0 16px 38px var(--shadow);
  animation: friendOnlineToast 3s ease forwards;
}

.friend-online-toast span:last-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.friend-online-toast strong {
  color: inherit;
  font-weight: 900;
}

body[data-theme="day"] .friend-online-toast {
  border-color: #167a3a;
  background: #ecfdf3;
  color: #052e16;
}

@keyframes friendOnlineToast {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  10%, 78% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(12px);
  }
}

@keyframes directMessageToast {
  0% {
    opacity: 0;
    transform: translateY(-120%);
  }
  14%, 78% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-120%);
  }
}

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

.pill {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--input);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.trust-badge-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 8px 0;
}

.trust-badge-strip.compact {
  margin: 4px 0;
  gap: 4px;
}

.trust-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 8px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  line-height: 1.1;
}

.trust-badge.success {
  border-color: rgba(63, 185, 80, 0.55);
  background: rgba(46, 160, 67, 0.16);
  color: #b7f7c8;
}

.trust-badge.vip {
  border-color: rgba(245, 193, 79, 0.65);
  background: rgba(245, 193, 79, 0.16);
  color: #ffe3a3;
}

.trust-badge.blue {
  border-color: var(--blue-border);
  background: rgba(65, 132, 228, 0.16);
  color: #cfe1ff;
}

.trust-badge.muted {
  color: var(--subtle);
}

body[data-theme="day"] .trust-badge {
  background: #f6f8fa;
  color: #57606a;
}

body[data-theme="day"] .trust-badge.success {
  background: #dafbe1;
  color: #116329;
}

body[data-theme="day"] .trust-badge.vip {
  background: #fff8c5;
  color: #7d4e00;
}

body[data-theme="day"] .trust-badge.blue {
  background: #ddf4ff;
  color: #0969da;
}

.compact-pill-list {
  gap: 6px;
}

.compact-pill-list .pill {
  min-height: 28px;
  padding: 4px 8px;
}

.auth-layout .pill-list {
  gap: 10px;
  margin-top: 12px;
  align-items: center;
}

.auth-layout .pill {
  min-height: 30px;
  padding: 8px 12px;
  line-height: 1.15;
}

.plate-badge {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 8px;
  border: 1px solid var(--blue-border);
  border-radius: 7px;
  background: color-mix(in srgb, var(--blue) 78%, #000 22%);
  color: var(--text);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
}

.progress {
  height: 15px;
  border-radius: 999px;
  background: var(--input);
  overflow: hidden;
}

.match-card .progress {
  width: calc(100% + 5px);
}

.progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #22c7ff 0%, #ffe866 48%, #ff3b5f 100%);
  box-shadow: 0 0 14px rgba(34, 199, 255, 0.24), 0 0 12px rgba(255, 59, 95, 0.18);
}

.message {
  padding: var(--chat-box-padding);
  border: 1px solid var(--border-soft);
  border-radius: var(--chat-box-border-radius);
  background: var(--panel-soft);
  font-size: var(--chat-box-font-size);
}

.message.mine {
  border-color: var(--blue-border);
  background: var(--blue);
}

.message-stats .stat strong {
  overflow-wrap: anywhere;
}

.messages-workspace {
  display: grid;
  grid-template-columns: minmax(240px, 300px) minmax(0, 1fr) minmax(240px, 300px);
  gap: 16px;
  align-items: stretch;
}

.messages-friend-rail,
.messages-thread-panel,
.message-profile-panel {
  min-width: 0;
  display: grid;
  gap: 16px;
  align-content: start;
}

.messages-thread-panel {
  min-height: 640px;
}

.messages-thread-panel .section-head {
  flex-wrap: wrap;
  align-items: flex-start;
}

.messages-thread-panel .section-head > div {
  min-width: 0;
  flex: 1 1 220px;
}

.messages-thread-panel .section-head h2,
.messages-thread-panel .section-head p {
  overflow-wrap: anywhere;
}

.messages-thread-panel .section-head .button-row {
  min-width: 0;
  max-width: 100%;
  flex: 1 1 170px;
  justify-content: flex-start;
  margin-top: 0;
}

.messages-thread-panel .section-head .btn {
  min-width: 0;
  max-width: 100%;
}

.tight-head {
  align-items: flex-start;
}

.tight-head h2,
.message-profile-head h2 {
  margin: 4px 0 0;
}

.messages-friend-list,
.direct-thread,
.message-interest-strip {
  display: grid;
  gap: 10px;
}

.messages-friend-list {
  max-height: 620px;
  overflow: auto;
  padding-right: 2px;
}

.message-friend-row {
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--panel-soft);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.message-friend-row.active,
.message-friend-row:hover {
  border-color: var(--blue-border);
  background: var(--blue);
}

.message-friend-row.vip-member-row {
  border-color: rgba(245, 185, 66, 0.62);
  background: color-mix(in srgb, var(--panel-soft) 82%, #f5b942 18%);
}

.message-friend-row.vip-member-row.active,
.message-friend-row.vip-member-row:hover {
  border-color: #f5b942;
  background: color-mix(in srgb, var(--blue) 72%, #f5b942 28%);
}

body[data-theme="day"] .message-friend-row.vip-member-row {
  border-color: #cf8d00;
  background: #fff6dc;
}

.message-friend-avatar,
.message-profile-photo {
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  background: var(--input);
  color: var(--text);
  font-weight: 900;
}

.message-friend-avatar {
  width: 42px;
  height: 42px;
  border-radius: 12px;
}

.message-friend-row.vip-member-row .message-friend-avatar {
  border-color: rgba(245, 185, 66, 0.78);
  background: rgba(245, 185, 66, 0.22);
  color: #ffe8aa;
}

body[data-theme="day"] .message-friend-row.vip-member-row .message-friend-avatar {
  background: #fff0bd;
  color: #5c3700;
}

.message-friend-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.message-friend-copy strong,
.message-friend-copy small,
.message-friend-meta small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-friend-copy small,
.message-friend-meta {
  color: var(--subtle);
  font-size: 12px;
}

.message-friend-meta {
  display: grid;
  gap: 5px;
  justify-items: end;
}

.message-friend-meta em {
  min-width: 24px;
  min-height: 24px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
}

.direct-thread {
  min-height: 340px;
  max-height: 520px;
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 82%, #000 18%);
}

.direct-thread .game-invite-message {
  border-color: color-mix(in srgb, var(--accent) 70%, #fff 10%);
  background: color-mix(in srgb, var(--accent) 18%, var(--panel) 82%);
}

.chess-table-chat-panel {
  min-height: 520px;
}

.chess-spectator-chat-window {
  min-height: 260px;
  max-height: 420px;
}

.chess-chat-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 96px;
  gap: 10px;
  margin-top: 10px;
}

.chess-chat-input-row input {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--input);
  color: var(--text);
  padding: 0 14px;
}

.chess-table-people {
  margin-top: 14px;
}

.messages-thread-panel .form-grid {
  margin-top: 4px;
}

.message-profile-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
  align-items: stretch;
}

.message-profile-panel .message-profile-head {
  grid-template-columns: minmax(0, 1fr);
}

.message-profile-photo-wrap,
.message-profile-details,
.message-profile-description {
  min-width: 0;
  border: 1px solid var(--border-soft);
  background: color-mix(in srgb, var(--panel-soft) 82%, var(--input) 18%);
}

.message-profile-photo-wrap,
.message-profile-details {
  min-height: 132px;
  border-radius: 14px;
}

.message-profile-panel .message-profile-photo-wrap,
.message-profile-panel .message-profile-details {
  min-height: 0;
}

.message-profile-photo-wrap {
  overflow: hidden;
}

.message-profile-head > div:not(.message-profile-photo-wrap):not(.message-profile-details) {
  display: contents;
}

.message-profile-head > div:not(.message-profile-photo-wrap):not(.message-profile-details) > .label,
.message-profile-head > div:not(.message-profile-photo-wrap):not(.message-profile-details) > h2 {
  grid-column: 2;
  min-width: 0;
}

.message-profile-head > div:not(.message-profile-photo-wrap):not(.message-profile-details) > p {
  grid-column: 1 / -1;
  width: 100%;
  margin: 0;
  padding: 14px;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  background: color-mix(in srgb, var(--panel-soft) 82%, var(--input) 18%);
  color: var(--muted);
  line-height: 1.55;
}

.message-profile-head > .message-profile-photo {
  grid-column: 1;
  grid-row: 1 / span 2;
}

.message-profile-details {
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 14px;
}

.message-profile-photo {
  width: 100%;
  height: 100%;
  min-height: 132px;
  border: 0;
  border-radius: 0;
  position: relative;
  overflow: hidden;
}

.message-profile-panel .message-profile-photo {
  aspect-ratio: 4 / 5;
  min-height: 240px;
}

.message-profile-photo.initial {
  font-size: 28px;
}

.message-profile-photo > span {
  position: relative;
  z-index: 1;
  font-size: 28px;
}

.message-profile-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
}

.photo-review-preview {
  min-height: 220px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: #0b111b;
}

.photo-review-preview img {
  object-fit: contain;
}

.message-profile-photo.photo-error img {
  display: none;
}

.message-profile-detail-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.message-profile-detail-list span {
  max-width: 100%;
  padding: 5px 8px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: var(--input);
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.message-profile-description {
  width: 100%;
  margin: 0;
  padding: 14px;
  border-radius: 14px;
  color: var(--muted);
  line-height: 1.55;
}

.message-interest-strip {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.message-interest-strip span {
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.compact-empty {
  min-height: 160px;
}

.direct-message-photo,
.message-photo-preview {
  width: min(100%, 420px);
  max-height: 260px;
  object-fit: cover;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
}

.profile-message-composer {
  display: grid;
  gap: 16px;
}

.profile-composer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.9fr);
  gap: 18px;
  align-items: start;
}

.profile-message-scrim {
  position: fixed;
  inset: 0;
  z-index: 80;
  border: 0;
  background: rgba(7, 13, 24, 0.48);
  cursor: pointer;
}

.profile-message-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 90;
  width: min(820px, 100vw);
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px 20px 24px;
  overflow-y: auto;
  overflow-x: hidden;
  border-left: 1px solid var(--border-soft);
  background: var(--panel);
  color: var(--text);
  box-shadow: -24px 0 60px rgba(0, 0, 0, 0.35);
  animation: oracleApplyDrawerIn 0.22s ease-out both;
}

.profile-message-drawer-head,
.profile-message-drawer-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.profile-message-drawer-head h2 {
  margin: 4px 0 0;
}

.profile-message-drawer-topline {
  justify-content: flex-end;
}

.profile-message-drawer .chat-rules-card {
  width: 100%;
}

.profile-message-drawer-grid {
  flex: 1 1 auto;
  min-height: 0;
}

.composer-main {
  display: grid;
  gap: 12px;
  align-content: start;
}

.profile-message-field span,
.profile-message-composer .card-pill-row strong {
  display: inline-flex;
  align-items: center;
  min-height: 18px;
  color: var(--text);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.2;
}

.profile-message-field {
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: 0;
}

.composer-main textarea[data-profile-message-body] {
  min-height: 300px;
  height: 300px;
  resize: vertical;
}

.profile-emoji-panel {
  display: grid;
  grid-template-rows: auto minmax(0, auto);
  gap: 12px;
  align-self: start;
  min-width: 0;
}

.profile-emoji-panel > .card-pill-row {
  margin-bottom: -5px;
}

.profile-icon-library {
  height: auto;
  min-height: 0;
  max-height: none;
  grid-template-columns: repeat(auto-fill, minmax(42px, 1fr));
  align-content: start;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.profile-icon-library::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.emoji-scroll-shell {
  display: grid;
  grid-template-rows: 32px minmax(0, 1fr) 32px;
  gap: 4px;
  align-content: start;
  height: var(--profile-emoji-shell-height, 300px);
  min-height: 220px;
  max-height: 520px;
}

.emoji-scroll-control {
  width: 100%;
  height: 32px;
  min-height: 32px;
  padding: 0 8px;
  border-radius: 8px;
  border-color: rgba(217, 169, 74, 0.55);
  background: rgba(152, 106, 22, 0.22);
  color: #ffe8b7;
  line-height: 1;
}

.dm-boundary-card {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(148, 163, 184, 0.42);
  border-radius: 8px;
  background: var(--panel-soft);
  background: color-mix(in srgb, var(--panel-soft) 84%, rgba(20, 184, 166, 0.16));
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16);
}

.dm-boundary-card h3,
.dm-boundary-card p {
  margin: 0;
}

.dm-boundary-card h3 {
  color: var(--text);
  font-size: 17px;
  font-weight: 900;
  line-height: 1.25;
}

.dm-boundary-card p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.dm-boundary-card[data-dm-boundary-mode="no_porn"],
.dm-boundary-card[data-dm-boundary-mode="clean_chat"] {
  border-color: rgba(248, 113, 113, 0.58);
  background: var(--panel-soft);
  background: color-mix(in srgb, var(--panel-soft) 84%, rgba(248, 113, 113, 0.15));
}

.dm-boundary-card[data-dm-boundary-mode="ask_first"],
.dm-boundary-card[data-dm-boundary-mode="no_surprise_photos"] {
  border-color: rgba(217, 169, 74, 0.58);
  background: var(--panel-soft);
  background: color-mix(in srgb, var(--panel-soft) 84%, rgba(217, 169, 74, 0.16));
}

.hidden-file {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

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

.activity-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: var(--input);
}

.activity-row.unread {
  border-color: var(--blue-border);
  background: var(--blue);
}

.activity-row h3,
.activity-row p {
  margin: 8px 0 0;
}

.activity-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.activity-actions span,
.activity-actions em {
  color: var(--subtle);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.connector-import-review {
  align-items: flex-start;
}

.connector-import-review > div:first-child {
  min-width: 0;
}

.connector-import-review-actions {
  align-items: stretch;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  min-width: min(320px, 100%);
}

.connector-import-review-actions textarea {
  grid-column: 1 / -1;
  min-height: 82px;
  resize: vertical;
  width: 100%;
}

@media (max-width: 760px) {
  .connector-import-review-actions {
    min-width: 0;
    width: 100%;
  }
}

.notification-feed {
  gap: 14px;
}

.notification-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.notification-head h2,
.notification-head p {
  margin: 0;
}

.notification-head p {
  margin-top: 8px;
}

.notification-row {
  padding: 16px;
  border-radius: 12px;
}

.notification-row.read {
  opacity: 0.78;
}

.notification-row-focus {
  outline: 2px solid var(--button-primary-border);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--button-primary-bg) 24%, transparent);
}

.notification-main {
  min-width: 0;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.notification-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid var(--blue-border);
  border-radius: 12px;
  background: color-mix(in srgb, var(--blue) 74%, #000 26%);
  color: var(--text);
  font-weight: 900;
}

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

.case-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.case-detail {
  min-width: 0;
  display: grid;
  gap: 12px;
  align-content: start;
  align-items: start;
  padding: 16px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--panel-soft);
}

.case-detail .pill-list {
  align-items: center;
  align-content: flex-start;
}

.case-detail .pill {
  min-height: 28px;
  padding: 4px 8px;
}

html body .case-detail .pill-list {
  align-items: flex-start !important;
  align-content: flex-start !important;
  gap: 6px !important;
  min-height: 0 !important;
}

html body .case-detail .pill-list > .pill {
  flex: 0 0 auto !important;
  align-self: flex-start !important;
  height: 26px !important;
  min-height: 26px !important;
  max-height: 26px !important;
  padding: 0 8px !important;
  border-radius: 8px !important;
  line-height: 1 !important;
}

.case-detail h3,
.case-detail p {
  margin: 0;
}

.admin-case-actions {
  gap: 8px;
  margin-top: 8px;
}

.admin-case-actions .btn {
  min-height: 36px;
}

.action-field {
  align-self: end;
}

.room-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: flex-start;
}

.room-card-head {
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
}

.pill.success {
  border-color: rgba(46, 160, 67, 0.55);
  background: rgba(46, 160, 67, 0.18);
  color: #b8f5c7;
}

body[data-theme="day"] .pill.success,
body[data-theme="day"] .panel .pill.success,
body[data-theme="day"] .pill-list .pill.success,
body[data-theme="day"] .profile-hero .pill.success,
body[data-theme="day"] .comment-reward-progress .pill.success,
body[data-theme="day"] .reward-pill,
body[data-theme="day"] .room-card .pill.success,
body[data-theme="day"] .room-card-head .pill.success {
  border-color: #167a3a !important;
  background: #c9f2d2 !important;
  color: #052e16 !important;
  text-shadow: none !important;
}

.pill.gold {
  border-color: rgba(217, 169, 74, 0.7);
  background: rgba(152, 106, 22, 0.34);
  color: #ffe8b7;
}

body[data-theme="day"] .pill.gold,
body[data-theme="day"] .pill.warning {
  border-color: #f0b84a !important;
  background: #fff2c7 !important;
  color: #6b4300 !important;
  text-shadow: none !important;
}

.card-pill-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 4px;
}

.reward-pill {
  width: fit-content;
  box-shadow: 0 0 0 1px rgba(46, 160, 67, 0.18), 0 10px 24px rgba(46, 160, 67, 0.12);
}

.comment-reward-pill {
  margin-top: 8px;
}

.comment-reward-progress {
  display: grid;
  gap: 8px;
  margin: 10px 0 14px;
  padding: 10px;
  border: 1px solid rgba(46, 160, 67, 0.4);
  border-radius: 8px;
  background: rgba(46, 160, 67, 0.08);
}

.comment-reward-progress div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.comment-reward-progress span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

body[data-theme="day"] .comment-reward-progress span.pill.success {
  border-color: #167a3a !important;
  background: #c9f2d2 !important;
  color: #052e16 !important;
}

.mini-progress {
  height: 8px;
  border-radius: 999px;
  background: var(--input);
  overflow: hidden;
}

.mini-progress span {
  display: block;
  height: 100%;
  background: #2ea043;
}

.pill.warning {
  border-color: rgba(187, 128, 9, 0.6);
  background: rgba(187, 128, 9, 0.18);
  color: #ffd58a;
}

.pill.blue {
  border-color: rgba(56, 139, 253, 0.55);
  background: rgba(56, 139, 253, 0.16);
  color: #b8d7ff;
}

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

.safety-controls {
  align-items: center;
  gap: 6px;
}

.button-row.safety-controls {
  justify-content: flex-start;
  margin-top: 10px;
}

.safety-controls-compact {
  justify-content: flex-start;
}

.live-actions .safety-controls,
.message-actions .safety-controls {
  margin-left: auto;
}

.safety-action-notice {
  padding: 8px 10px;
  border: 1px solid rgba(187, 128, 9, 0.42);
  border-radius: 8px;
  background: rgba(187, 128, 9, 0.12);
  color: #ffe3a3;
}

.muted-message-placeholder {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  min-height: 32px;
  padding: 8px 10px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--subtle);
  background: rgba(255, 255, 255, 0.04);
  font-size: 13px;
  font-weight: 750;
}

.event-participant-actions {
  display: grid;
  justify-items: end;
  gap: 6px;
}

body[data-theme="day"] .safety-action-notice {
  background: #fff8c5;
  color: #7d4e00;
}

body[data-theme="day"] .pill.blue {
  border-color: #0969da;
  background: #ddf4ff;
  color: #0550ae;
}

body[data-theme="day"] .muted-message-placeholder {
  background: #f6f8fa;
  color: #57606a;
}

.inline-actions .btn,
.live-actions .btn,
.message-actions .btn {
  min-height: 30px;
  padding: 0 10px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
}

.tiny-btn.danger {
  border-color: rgba(248, 81, 73, 0.55);
  background: rgba(248, 81, 73, 0.16);
  color: #ffd0cd;
}

.tiny-btn.gold {
  border-color: rgba(215, 173, 85, 0.58);
  background: rgba(215, 173, 85, 0.13);
  color: #ffe8aa;
}

.tiny-btn.gold:hover:not(:disabled) {
  border-color: rgba(235, 204, 126, 0.82);
  background: rgba(215, 173, 85, 0.2);
}

body[data-theme="day"] .tiny-btn.gold {
  border-color: #b8944c;
  background: #fff7e4;
  color: #65460e;
}

.admin-membership-summary {
  color: color-mix(in srgb, #e4c477 78%, var(--muted));
}

.admin-membership-toggle {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(215, 173, 85, 0.42);
  border-radius: 8px;
  background: rgba(215, 173, 85, 0.08);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.admin-membership-toggle input {
  appearance: none;
  position: relative;
  width: 30px;
  height: 16px;
  margin: 0;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: var(--input);
  cursor: inherit;
}

.admin-membership-toggle input::after {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--muted);
  content: "";
  transition: transform 160ms ease, background 160ms ease;
}

.admin-membership-toggle input:checked {
  border-color: #d7ad55;
  background: rgba(215, 173, 85, 0.3);
}

.admin-membership-toggle input:checked::after {
  background: #ffe8aa;
  transform: translateX(14px);
}

.admin-membership-toggle.disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

body[data-theme="day"] .tiny-btn.danger {
  border-color: #d1242f;
  background: #ffe2e5;
  color: #7f1d1d;
}

body[data-theme="day"] .tiny-btn.danger:disabled {
  opacity: 1;
  color: #7f1d1d;
}

.room-card-meta {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(72px, auto) minmax(0, 1fr);
  gap: 6px 12px;
  padding: 10px 0;
  border-top: 1px solid var(--border-soft);
  border-bottom: 1px solid var(--border-soft);
}

.room-card-meta span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 800;
}

.room-card-meta strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.room-card .pill-list {
  margin-bottom: 2px;
}

.owned-rooms-panel {
  display: grid;
  gap: 14px;
}

.owned-rooms-list {
  display: grid;
  gap: 8px;
}

.owned-room-row {
  min-height: 52px;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
}

.owned-room-main {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.owned-room-capacity {
  color: var(--subtle);
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.owned-room-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.event-card {
  display: grid;
  gap: 12px;
  align-self: start;
  align-content: start;
  padding: 20px;
}

.event-card-header,
.event-safety-labels,
.event-recommendation-reasons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.event-card-photo {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: var(--input);
}

.event-card-status {
  display: grid;
  gap: 4px;
  min-height: 0;
  padding: 9px 11px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: rgba(37, 37, 36, 0.56);
}

body[data-theme="day"] .event-card-status {
  background: #ffffff;
  border-color: var(--border);
}

.event-discovery-strip {
  display: grid;
  gap: 14px;
}

.event-suggestion-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.event-suggestion-card {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.event-suggestion-card h3,
.event-suggestion-card p {
  margin: 0;
}

.event-safety-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
}

.checkbox-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  font-size: 13px;
  font-weight: 800;
}

.checkbox-pill input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
}

.event-attendees-preview {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.event-attendees-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.event-attendees-head span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 800;
}

.event-attendee-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
}

.event-attendee-card {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: rgba(37, 37, 36, 0.52);
}

.event-attendee-card > .safety-controls {
  grid-column: 1 / -1;
}

.event-attendee-card strong,
.event-attendee-card span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.event-attendee-card span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 800;
}

.event-attendee-avatar {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--input);
  color: var(--text);
  font-weight: 900;
}

.event-attendee-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

body[data-theme="day"] .event-suggestion-card,
body[data-theme="day"] .event-attendees-preview,
body[data-theme="day"] .event-attendee-card {
  background: #ffffff;
  border-color: var(--border);
}

.event-detail-panel,
.event-chat-panel {
  display: grid;
  gap: 14px;
  align-content: start;
}

.event-detail-panel > h2 {
  margin-top: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--border-soft);
}

.event-detail-panel > h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.event-detail-panel .button-row,
.event-chat-panel .button-row {
  margin-top: 8px;
  margin-bottom: 4px;
}

.event-rsvp-controls {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 10px;
  align-items: end;
  margin-top: 12px;
}

.event-rsvp-controls .field {
  margin: 0;
}

.event-card h2,
.event-card p,
.event-card .pill-list,
.event-card .button-row {
  margin: 0;
}

.event-card .button-row {
  margin-top: 2px;
}

.event-card-status span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 800;
}

.translation-toolbar {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(170px, 220px);
  align-items: end;
  gap: 10px;
  margin: 14px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
}

.translation-toolbar .field {
  min-width: 0;
  margin: 0;
}

.translation-toolbar .btn {
  min-height: 42px;
  padding: 0 20px;
  border-radius: 12px;
}

.translation-toolbar > .small {
  grid-column: 1 / -1;
}

.private-translation-toolbar {
  grid-template-columns: minmax(0, 1fr);
}

.private-translation-toolbar .btn {
  width: 100%;
  min-width: 0;
}

.event-translation-toolbar {
  display: grid;
  grid-template-columns: minmax(210px, 1fr) auto auto;
  align-items: end;
  gap: 10px;
  margin: 0;
  padding-top: 0;
  border-top: 0;
}

.event-translation-toolbar .field {
  min-width: 0;
}

.event-translation-toolbar .btn {
  min-height: 40px;
  padding: 0 18px;
  border-radius: 10px;
}

.event-translation-toolbar .event-translation-toggle {
  padding: 0 16px;
}

.event-translation-cost {
  grid-column: 1 / -1;
  margin: 0 0 0 4px;
  color: #a7c3e6;
}

[data-event-filter-reset] {
  min-height: 44px;
  width: fit-content;
  padding: 0 24px;
  line-height: 1.2;
  border-radius: 12px;
}

.filters .button-row {
  align-items: center;
  margin-top: 18px;
}

.filters .pill-list {
  gap: 10px;
  margin-top: 10px;
}

.filters .pill {
  min-height: 30px;
  padding: 8px 12px;
}

.vip-upgrade-intro {
  display: grid;
  gap: 8px;
  padding: 26px;
}

.vip-upgrade-intro h2,
.vip-plan-card h2 {
  padding-bottom: 0;
}

.vip-upgrade-intro p {
  max-width: 780px;
}

.vip-plan-card {
  min-height: 318px;
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 26px 28px 28px;
  border-color: color-mix(in srgb, #f5b942 68%, var(--border));
  background:
    linear-gradient(180deg, color-mix(in srgb, #f5b942 15%, var(--panel-soft)) 0%, color-mix(in srgb, #f5b942 7%, var(--panel)) 100%);
}

body[data-theme="day"] .vip-plan-card {
  border-color: #cf8d00;
  background: linear-gradient(180deg, #fff6dc 0%, #f7fbff 78%);
}

.vip-plan-card .vip-pill {
  width: fit-content;
}

.vip-plan-price strong {
  display: block;
  color: var(--text);
  font-size: clamp(26px, 4vw, 36px);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.vip-benefit-list {
  gap: 10px;
  align-content: start;
}

.vip-benefit-list .pill {
  min-height: 32px;
  max-width: 100%;
  padding: 8px 12px;
  white-space: normal;
  line-height: 1.15;
}

.vip-plan-cta {
  width: fit-content;
  min-width: 160px;
  margin-top: 2px;
}

[data-vip-upgrade] {
  min-height: 42px;
  min-width: 100px;
  padding: 0 22px;
  border-radius: 12px;
  line-height: 1;
}

.vip-checkout-steps {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 318px;
  padding: 28px;
}

.vip-checkout-steps h2 {
  padding-bottom: 0;
}

.vip-step-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.vip-step-list li {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--panel-soft) 82%, transparent);
}

.vip-step-list li > span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, #f5b942 62%, var(--border));
  background: color-mix(in srgb, #f5b942 18%, var(--panel));
  color: var(--text);
  font-weight: 900;
}

.vip-step-list p {
  display: grid;
  gap: 4px;
  margin: 0;
  max-width: 100%;
}

.vip-step-list strong {
  color: var(--text);
  font-size: 16px;
  line-height: 1.2;
}

.vip-step-list small {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

body[data-theme="day"] .vip-step-list li {
  background: #f7fbff;
}

.room-card.active-room {
  border-color: var(--blue-border);
  background: linear-gradient(180deg, var(--blue) 0%, var(--panel) 100%);
}

.room-create-panel {
  display: flex;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}

.room-create-panel p {
  max-width: 680px;
}

.chat-console {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 16px;
  align-items: stretch;
}

.chat-main {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 0;
}

.chat-side {
  display: grid;
  gap: 14px;
  align-content: start;
}

.chat-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}

.chat-head-actions {
  margin-top: 0;
  flex-shrink: 0;
}

.chat-window {
  min-height: 440px;
  max-height: none;
  flex: 1 1 440px;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow: auto;
  padding: 14px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: #070a0e;
}

.chat-window.compact-chat {
  min-height: 240px;
  max-height: 340px;
}

.event-chat-panel .compact-chat {
  min-height: 214px;
  max-height: 214px;
  padding: 12px;
  border-radius: 6px;
  background: #05080b;
}

body[data-theme="day"] .event-chat-panel .compact-chat {
  background: #ffffff;
}

body[data-theme="day"] .chat-window {
  background: #eef3f8;
}

.chat-rules-card {
  width: min(720px, 100%);
  padding: 16px;
  border: 1px solid #ff6b6b;
  border-left: 6px solid #e01e37;
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(224, 30, 55, 0.22), rgba(120, 14, 25, 0.34));
  color: #fff;
  box-shadow: 0 12px 28px rgba(224, 30, 55, 0.14);
}

.chat-rules-card h2 {
  margin: 6px 0 8px;
}

.chat-rules-card p {
  color: #ffd8de;
}

.chat-rules-card ul {
  margin: 12px 0 14px;
  padding-left: 20px;
  display: grid;
  gap: 7px;
  color: #fff;
}

.chat-rules-card .label {
  color: #ffd8de;
}

.chat-rules-card .btn.primary {
  --chat-rules-action-top: #318cff;
  --chat-rules-action-bottom: #075dcc;
  width: 100%;
  min-height: 56px;
  justify-content: space-between;
  gap: 16px;
  padding: 0 16px 0 22px;
  border-color: rgba(158, 205, 255, 0.72);
  border-radius: 15px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.14), transparent 46%),
    linear-gradient(135deg, var(--chat-rules-action-top), var(--chat-rules-action-bottom));
  color: #ffffff;
  box-shadow: 0 10px 24px rgba(8, 82, 181, 0.26), inset 0 1px 0 rgba(255, 255, 255, 0.24);
  text-align: left;
  text-shadow: 0 1px 1px rgba(0, 26, 72, 0.34);
  transition: transform 160ms ease, box-shadow 160ms ease, filter 160ms ease;
}

.chat-rules-card .btn.primary::after {
  content: "\2192";
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  flex: 0 0 32px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  font-size: 20px;
  line-height: 1;
  text-shadow: none;
}

@media (hover: hover) {
  .chat-rules-card .btn.primary:hover {
    filter: brightness(1.06) saturate(1.05);
    transform: translateY(-1px);
    box-shadow: 0 13px 28px rgba(8, 82, 181, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.28);
  }
}

.chat-rules-card .btn.primary:focus-visible {
  outline: 3px solid rgba(91, 167, 255, 0.42);
  outline-offset: 3px;
}

.safety-first-chat-notice {
  margin: 12px 0;
  padding: 9px 11px;
  border: 1px solid rgba(255, 216, 222, 0.45);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.09);
  color: #ffffff;
  font-weight: 750;
}

body[data-theme="day"] .chat-rules-card {
  color: #111827;
}

body[data-theme="day"] .chat-rules-card h2,
body[data-theme="day"] .chat-rules-card p,
body[data-theme="day"] .chat-rules-card ul,
body[data-theme="day"] .chat-rules-card .label {
  color: #111827;
}

body[data-theme="day"] .chat-rules-card .btn.primary {
  color: #ffffff;
}

body[data-theme="day"] .safety-first-chat-notice {
  border-color: #bf8700;
  background: #fff8c5;
  color: #4d2d00;
}

.direct-thread .chat-rules-card {
  width: 100%;
}

.empty-state {
  align-self: center;
  justify-self: center;
  max-width: 320px;
  text-align: center;
  color: var(--subtle);
}

.empty-state h2 {
  margin-bottom: 8px;
  color: var(--text);
}

.live-message {
  display: grid;
  grid-template-columns: clamp(88px, 14%, 112px) minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.live-message.mine {
  grid-template-columns: clamp(88px, 14%, 112px) minmax(0, 1fr);
}

.live-message.mine .live-avatar {
  order: 0;
}

.live-message.mine .live-bubble {
  order: 0;
  border-color: var(--blue-border);
  background: var(--blue);
}

.live-message.agent-message .live-avatar,
.live-message.agent-message .live-bubble {
  border-color: var(--accent);
}

.live-message.agent-message .live-avatar {
  background: var(--accent);
  color: #fff;
}

.live-message.agent-message .live-bubble {
  background: rgba(177, 24, 24, 0.13);
}

.live-message.token-gift-message .live-avatar,
.live-message.token-gift-message .live-bubble {
  border-color: rgba(32, 200, 115, 0.55);
}

.live-message.token-gift-message .live-avatar {
  background: rgba(32, 200, 115, 0.16);
  color: #24d67e;
}

.live-message.token-gift-message .live-bubble,
.live-message.mine.token-gift-message .live-bubble {
  background: rgba(32, 200, 115, 0.13);
}

.live-message.token-gift-message .message-translation-primary {
  color: #24d67e;
}

.live-message.token-gift-message .plate-badge {
  border-color: rgba(32, 200, 115, 0.55);
}

.live-message.moderation-notice-message .live-avatar,
.live-message.moderation-notice-message .live-bubble {
  border-color: rgba(248, 81, 73, 0.62);
}

.live-message.moderation-notice-message .live-avatar {
  background: rgba(248, 81, 73, 0.16);
  color: #ffd0cd;
}

.live-message.moderation-notice-message .live-bubble,
.live-message.mine.moderation-notice-message .live-bubble {
  background: rgba(248, 81, 73, 0.13);
}

.live-message.moderation-notice-message .message-translation-primary,
.live-message.moderation-notice-message .moderator-name strong {
  color: #ffd0cd;
}

.live-message.moderation-notice-message .plate-badge {
  border-color: rgba(248, 81, 73, 0.62);
}

body[data-theme="day"] .live-message.moderation-notice-message .live-avatar,
body[data-theme="day"] .live-message.moderation-notice-message .live-bubble {
  border-color: #d1242f;
}

body[data-theme="day"] .live-message.moderation-notice-message .live-avatar {
  background: #ffe2e5;
  color: #7f1d1d;
}

body[data-theme="day"] .live-message.moderation-notice-message .live-bubble,
body[data-theme="day"] .live-message.mine.moderation-notice-message .live-bubble {
  background: #fff1f2;
  color: #07192d;
}

body[data-theme="day"] .live-message.moderation-notice-message .message-translation-primary,
body[data-theme="day"] .live-message.moderation-notice-message .moderator-name strong {
  color: #7f1d1d;
}

body[data-theme="day"] .live-message.moderation-notice-message .plate-badge {
  border-color: #d1242f;
  background: #ffe2e5;
  color: #7f1d1d;
}

.live-avatar,
.user-avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--input);
  color: var(--text);
  font-weight: 800;
}

.live-message > .live-avatar {
  width: 100%;
  height: auto;
  min-height: 0;
  aspect-ratio: 1 / 1;
  align-self: start;
}

.live-avatar.profile-photo-avatar {
  overflow: hidden;
  padding: 0;
  border-radius: 8px;
}

.live-avatar.profile-photo-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 8px;
  object-fit: cover;
}

.live-bubble {
  min-width: 0;
  padding: var(--chat-box-padding);
  border: 1px solid var(--border-soft);
  border-radius: var(--chat-box-border-radius);
  background: var(--panel-soft);
  font-size: var(--chat-box-font-size);
}

.live-bubble p {
  margin: 6px 0 0;
}

.event-chat-panel .live-message,
.event-chat-panel .live-message.mine {
  grid-template-columns: minmax(0, 1fr);
}

.event-chat-panel .live-avatar {
  display: none;
}

.event-chat-panel .live-message.mine .live-bubble {
  order: unset;
}

.event-chat-panel .live-bubble {
  width: min(100%, 398px);
  padding: var(--chat-box-padding);
  border-color: var(--blue-border);
  border-radius: var(--chat-box-border-radius);
  background: var(--blue);
}

.event-chat-panel .live-meta {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.live-message.deleted-message .live-bubble,
.live-message.mine.deleted-message .live-bubble,
.group-chat-panel .live-message.deleted-message .live-bubble,
.group-chat-panel .live-message.mine.deleted-message .live-bubble,
.event-chat-panel .live-message.deleted-message .live-bubble,
.event-chat-panel .live-message.mine.deleted-message .live-bubble {
  border-color: #8e949c !important;
  background: linear-gradient(180deg, #7d838b 0%, #666d75 100%) !important;
  box-shadow: none !important;
  color: #ffffff !important;
}

.live-message.deleted-message .live-meta,
.live-message.deleted-message .moderator-name,
.live-message.deleted-message .moderator-name strong,
.live-message.deleted-message .message-translation-primary,
.live-message.deleted-message .translation-note,
.live-message.deleted-message .deleted-stamp {
  color: #ffffff !important;
}

.live-message.deleted-message .plate-badge,
.live-message.deleted-message .translation-note.original-note {
  border-color: rgba(255, 255, 255, 0.34) !important;
  background: rgba(255, 255, 255, 0.12) !important;
  color: #ffffff !important;
}

.live-message.deleted-message .translation-note.original-note span {
  color: #ffffff !important;
}

.deleted-stamp {
  margin-top: 8px;
  font-size: 11px;
  font-weight: 800;
}

.deleted-message-body {
  margin-top: 8px;
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0;
}

.live-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--subtle);
  font-size: 12px;
}

.moderator-name {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  gap: 5px;
  color: var(--text);
}

.moderator-name strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.moderator-bolt {
  display: inline-grid;
  width: 14px;
  height: 14px;
  place-items: center;
  flex: 0 0 14px;
  color: #3da2ff;
  font-size: 12px;
  line-height: 1;
}

.translation-note {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

.message-translation-primary {
  margin: 7px 0 0;
  color: var(--text);
  font-size: inherit;
  font-weight: 800;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.message-mention,
.room-member-mention {
  color: #9bd8ff;
  font: inherit;
  font-weight: 800;
}

button.message-mention,
button.room-member-mention {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.live-message.mention-target-message .live-bubble {
  outline: 2px solid #55b8ff;
  outline-offset: 3px;
  animation: mention-target-pulse 1.6s ease-out 1;
}

@keyframes mention-target-pulse {
  0%, 55% { box-shadow: 0 0 0 8px rgba(85, 184, 255, 0.24); }
  100% { box-shadow: 0 0 0 0 rgba(85, 184, 255, 0); }
}

body.chat-hide-number-plate .chat-window .plate-badge,
body.chat-hide-number-plate .direct-thread .plate-badge {
  display: none;
}

body.chat-hide-translation .chat-window .translation-note,
body.chat-hide-translation .direct-thread .translation-note {
  display: none;
}

body.chat-hide-actions .chat-window .room-message-more,
body.chat-hide-actions .chat-window .live-actions,
body.chat-hide-actions .chat-window .message-actions,
body.chat-hide-actions .direct-thread .live-actions {
  display: none !important;
}

body.chat-hide-profile .chat-window .live-message,
body.chat-hide-profile .chat-window .live-message.mine,
body.chat-hide-profile .compact-chat .live-message,
body.chat-hide-profile .compact-chat .live-message.mine {
  grid-template-columns: minmax(0, 1fr);
}

body.chat-hide-profile .chat-window .live-avatar,
body.chat-hide-profile .compact-chat .live-avatar,
body.chat-hide-profile .chat-window .live-meta .moderator-name,
body.chat-hide-profile .compact-chat .live-meta .moderator-name,
body.chat-hide-profile .direct-thread .live-meta .moderator-name {
  display: none;
}

.translation-note.original-note {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  width: fit-content;
  max-width: 100%;
  gap: 7px;
  margin-top: 7px;
  padding: 5px 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.2);
  color: var(--subtle);
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.translation-note.original-note span {
  color: #34d475;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.live-message.mine .translation-note.original-note,
.message.mine .translation-note.original-note {
  background: rgba(255, 255, 255, 0.2);
}

body[data-theme="day"] .translation-note.original-note {
  border-color: rgba(31, 39, 51, 0.11);
  background: rgba(255, 255, 255, 0.2);
}

@media (max-width: 720px) {
  .translation-toolbar {
    grid-template-columns: 1fr;
  }

  .translation-toolbar .btn {
    width: 100%;
  }

  .event-translation-toolbar {
    grid-template-columns: 1fr;
  }

.event-translation-toolbar .btn {
    width: 100%;
  }

  .event-chat-panel .live-bubble {
    width: 100%;
  }

  .safety-controls {
    width: 100%;
    justify-content: flex-start;
  }

  .safety-controls .tiny-btn,
  .safety-controls .pill {
    flex: 1 1 auto;
    justify-content: center;
  }

  .event-participant-actions {
    justify-items: stretch;
  }
}

.live-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.live-actions .translation-note.original-note {
  margin-top: 0;
}

.live-actions > .tiny-btn:first-of-type,
.live-actions .message-actions {
  margin-left: auto;
}

.live-actions .message-actions {
  margin-top: 0;
}

.message-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
}

.admin-queue-counter-panel {
  padding: 14px;
}

.admin-queue-counter-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
}

.admin-queue-counter {
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
}

.admin-queue-counter span {
  display: block;
  color: var(--subtle);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.admin-queue-counter strong {
  display: block;
  margin-top: 4px;
  color: var(--text);
  font-size: 24px;
}

.tiny-btn {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.tiny-btn.delete-link {
  border-color: transparent;
  background: transparent;
  color: #ffb000 !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1.2;
  text-transform: uppercase;
}

.live-message.deleted-message .tiny-btn.delete-link {
  color: #ffb000 !important;
}

.chat-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 96px;
  gap: 10px;
}

.chat-input-row input {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--input);
  color: var(--text);
  padding: 0 14px;
}

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

.user-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: var(--input);
}

.user-row strong,
.user-row span {
  display: block;
}

.user-row span {
  color: var(--subtle);
  font-size: 12px;
}

.user-row .moderator-name,
.user-row .moderator-bolt {
  display: inline-flex;
}

.user-row .moderator-name {
  color: var(--text);
}

.user-row .moderator-name strong {
  display: inline;
}

.user-row .moderator-bolt {
  color: #3da2ff;
}

.chat-side .user-row {
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: start;
}

.chat-side .user-row > div:nth-child(2) {
  min-width: 0;
}

.chat-side .user-row .moderator-name,
.chat-side .user-row .moderator-name strong {
  max-width: 100%;
  white-space: normal;
  word-break: normal;
  overflow-wrap: anywhere;
}

.chat-side .user-row > .small {
  grid-column: 2;
  justify-self: start;
  margin-top: 2px;
}

.chat-side .user-row .inline-actions {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  justify-content: stretch;
  width: 100%;
  margin-top: 4px;
}

.chat-side .user-row .inline-actions .tiny-btn,
.chat-side .user-row .inline-actions .btn,
.chat-side .user-row .inline-actions .pill {
  width: 100%;
  min-width: 0;
  justify-content: center;
  text-align: center;
  white-space: normal;
}

.chat-side .user-row .inline-actions .gold {
  grid-column: 1 / -1;
}

.gift-box {
  display: grid;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
}

.gift-packs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.gift-pack {
  min-width: 0;
  padding: 0 6px;
}

.gift-pack.active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.gift-token-notice {
  margin: 0;
  color: #20c873;
  font-size: 0.9rem;
  font-weight: 800;
}

.field.compact {
  gap: 6px;
}

.field.compact input,
.field.compact select {
  min-height: 40px;
  border-radius: 10px;
}

.profile-hero {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 20px;
  align-items: center;
}

.public-profile-preview {
  grid-template-columns: minmax(220px, 0.42fr) minmax(0, 1fr);
  align-items: stretch;
  gap: 24px;
}

.profile-photo-frame {
  min-width: 0;
}

.profile-main-photo {
  width: 120px;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: var(--surface-soft);
}

.member-profile-hero {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
  gap: 24px;
}

.member-profile-media,
.member-profile-details {
  min-width: 0;
}

.member-profile-media {
  display: flex;
}

.member-profile-main-photo,
.member-profile-avatar {
  width: 100%;
  height: 100%;
  min-height: 430px;
  aspect-ratio: 4 / 5;
  border-radius: 8px;
}

.member-profile-main-photo {
  object-fit: cover;
}

.member-profile-avatar {
  display: grid;
  place-items: center;
  border: 1px solid var(--border-soft);
  background: var(--surface-soft);
  font-size: 64px;
}

.member-profile-details {
  display: grid;
  align-content: start;
  gap: 12px;
}

.member-profile-details > h2,
.member-profile-details > p,
.member-profile-details .pill-list,
.member-profile-details .compatibility-pills,
.member-profile-details .button-row {
  margin-top: 0;
  margin-bottom: 0;
}

.member-profile-details > h2 {
  font-size: clamp(30px, 3vw, 44px);
  line-height: 1.05;
}

.public-profile-preview .profile-main-photo,
.public-profile-preview .avatar {
  width: 100%;
  max-width: 360px;
  min-height: 320px;
  height: 100%;
  aspect-ratio: 4 / 5;
  justify-self: start;
}

.public-profile-preview .avatar {
  display: grid;
  place-items: center;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--surface-soft);
  font-size: 64px;
}

.profile-intro {
  min-width: 0;
  display: grid;
  gap: 14px;
  align-content: center;
}

.profile-intro h2 {
  margin-bottom: 0;
  font-size: calc(var(--title-size) + 8px);
  line-height: 1.05;
}

.profile-kicker,
.profile-primary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.profile-bio {
  max-width: 72ch;
  font-size: 1.05rem;
  line-height: 1.55;
}

.profile-quick-facts,
.profile-detail-list {
  display: grid;
  gap: 10px;
}

.profile-quick-facts {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.profile-quick-facts span,
.profile-detail-list div {
  min-width: 0;
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: color-mix(in srgb, var(--panel-soft) 84%, transparent);
}

.profile-quick-facts strong,
.profile-detail-list span {
  color: var(--subtle);
  font-size: 12px;
}

.profile-quick-facts em,
.profile-detail-list strong {
  color: var(--text);
  font-style: normal;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.profile-gallery-panel .section-head {
  margin-bottom: 14px;
}

.profile-gallery-grid .photo-card {
  gap: 0;
}

.profile-gallery-grid .photo-card img {
  aspect-ratio: 4 / 5;
}

.profile-preview {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: var(--surface-soft);
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.event-photo-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.photo-card {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.photo-card img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: var(--surface-soft);
}

.photo-card [data-photo-edit-index] {
  border-color: #60a5fa !important;
  background: linear-gradient(180deg, #2563eb, #1d4ed8) !important;
  color: #ffffff !important;
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.22);
}

.photo-card [data-photo-main] {
  border-color: #f9a8d4 !important;
  background: linear-gradient(180deg, #db2777, #be185d) !important;
  color: #ffffff !important;
  box-shadow: 0 10px 24px rgba(219, 39, 119, 0.22);
}

.photo-card [data-photo-remove] {
  border-color: #fb7185 !important;
  background: linear-gradient(180deg, #dc2626, #991b1b) !important;
  color: #ffffff !important;
  box-shadow: 0 10px 24px rgba(220, 38, 38, 0.22);
}

.group-composer,
.group-feed {
  display: grid;
  gap: 14px;
}

.profile-stream-composer,
.profile-stream-panel {
  display: grid;
  gap: 14px;
}

.profile-stream-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(240px, 25%, 330px);
  gap: 14px;
  align-items: start;
}

.profile-stream-main {
  min-width: 0;
  align-content: start;
}

.profile-stream-image-field {
  align-content: start;
}

.profile-stream-image-field .button-row {
  margin-top: 4px;
}

.profile-stream-icon-panel {
  display: grid;
  grid-template-rows: auto 32px minmax(0, 1fr) 32px;
  gap: 4px;
  min-width: 0;
  align-self: start;
  height: var(--profile-stream-icon-panel-height, 360px);
  min-height: 240px;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 84%, #000 16%);
  overflow: hidden;
}

.profile-stream-icon-scroll {
  width: 100%;
  height: 32px;
  min-height: 32px;
  padding: 0 8px;
  border-radius: 8px;
  border-color: var(--border-soft);
  background: var(--panel-soft);
  line-height: 1;
}

.profile-stream-icon-library {
  height: 100%;
  min-height: 0;
  max-height: 100%;
  grid-template-columns: repeat(auto-fill, minmax(42px, 1fr));
  align-content: start;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  overflow: auto;
}

.profile-stream-editor-grid {
  grid-template-columns: minmax(0, 1fr);
}

.profile-stream-editor .profile-stream-crop-stage {
  width: 100%;
  max-width: none;
}

.profile-stream-editor-controls {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.profile-stream-editor-controls .field {
  min-width: 0;
}

.profile-stream-editor-actions {
  grid-column: 1 / -1;
}

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

.form-grid .full,
.format-toolbar.full,
.icon-library.full {
  grid-column: 1 / -1;
}

.icon-library {
  max-height: 158px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(38px, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: color-mix(in srgb, var(--panel) 84%, #000 16%);
  overflow: auto;
}

.profile-stream-icon-panel {
  align-self: start !important;
  overflow: hidden !important;
}

.profile-stream-icon-panel > .icon-library.profile-stream-icon-library {
  height: 100% !important;
  min-height: 0 !important;
  max-height: 100% !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
}

.icon-choice {
  min-height: 36px;
  padding: 0;
  font-size: 17px;
}

.icon-choice:hover {
  border-color: var(--blue-border);
  background: var(--blue);
}

.emoji-scroll-shell > .icon-library.profile-icon-library {
  height: 100% !important;
  min-height: 0 !important;
  max-height: 100% !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
}

.group-post-card {
  display: grid;
  gap: 12px;
}

.group-comments {
  display: grid;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--border-soft);
}

.group-comment {
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: color-mix(in srgb, var(--panel) 82%, #000 18%);
}

.group-comment p {
  margin: 6px 0 0;
}

.rich-text strong {
  font-weight: 800;
}

.rich-text em {
  font-style: italic;
}

.comment-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  font-size: calc(var(--content-size) + 2px);
}

.comment-row input {
  width: 100%;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  font: inherit;
  outline: none;
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--panel-soft) 70%, transparent);
}

.comment-row input::placeholder {
  color: var(--subtle);
  opacity: 1;
}

.comment-row input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent);
}

.comment-row .tiny-btn {
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  font-size: inherit;
}

.group-chat-panel {
  align-content: start;
  display: grid;
  gap: 14px;
}

.group-chat-panel .chat-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}

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

.group-chat-panel .chat-head .pill-list {
  align-items: center;
}

.group-chat-panel .chat-head .pill {
  min-height: 30px;
  line-height: 1;
}

.group-chat-window {
  min-height: 360px;
}

.group-chat-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 96px;
  gap: 10px;
}

.group-chat-input-row input {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 0 14px;
  background: var(--input);
  color: var(--text);
  font: inherit;
}

.event-chat-panel .group-chat-input-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.event-chat-panel .group-chat-input-row input,
.event-chat-panel .group-chat-input-row .btn {
  min-height: 42px;
  border-radius: 10px;
}

.event-chat-panel .group-chat-input-row .btn {
  min-width: 86px;
  padding: 0 20px;
}

.group-chat-members {
  max-height: 260px;
  overflow: auto;
}

.group-image-preview img,
.feed-image {
  width: 100%;
  max-height: 360px;
  object-fit: cover;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.profile-stream-crop-preview img {
  display: block;
  width: 100%;
  height: auto !important;
  max-height: none !important;
  object-fit: contain !important;
  border-radius: 8px;
  background: var(--surface-soft);
}

.profile-stream-card .feed-image {
  height: auto;
  max-height: none;
  object-fit: contain;
  border-radius: 8px;
  background: var(--surface-soft);
}

.image-editor {
  display: grid;
  gap: 18px;
}

.editor-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: start;
}

.editor-head p {
  margin: 6px 0 0;
}

.editor-badge {
  max-width: 220px;
  padding: 8px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  color: var(--subtle);
  font-size: 12px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.image-editor-grid {
  display: grid;
  grid-template-columns: minmax(240px, 360px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.crop-stage {
  width: 100%;
  max-width: 360px;
  padding: 10px;
  border: 1px dashed var(--border-strong);
  border-radius: 8px;
  background: var(--surface-soft);
}

.crop-stage canvas {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border-soft);
  border-radius: 6px;
  background: #0f141b;
  cursor: grab;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
}

.crop-stage canvas.is-dragging {
  cursor: grabbing;
}

.editor-controls input[type="range"] {
  width: 100%;
  min-height: 40px;
  padding: 0;
}

.photo-crop-mode-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.photo-crop-mode-row .tiny-btn.primary {
  border-color: var(--button-primary-border);
  background: var(--button-primary-bg);
  color: var(--button-primary-text);
}

.editor-controls .full {
  grid-column: 1 / -1;
}

.profile-stream-editor .profile-stream-editor-grid {
  grid-template-columns: minmax(0, 1fr) !important;
}

.profile-stream-editor .profile-stream-crop-stage {
  width: 100% !important;
  max-width: none !important;
}

.profile-stream-editor .profile-stream-crop-stage canvas {
  width: 100% !important;
}

.profile-stream-editor .profile-stream-editor-controls {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.profile-stream-editor .profile-stream-editor-controls .field {
  min-width: 0;
}

.profile-stream-editor .photo-crop-mode-row,
.profile-stream-editor .profile-stream-editor-actions {
  grid-column: 1 / -1 !important;
}

.questionnaire-panel {
  display: grid;
  gap: 18px;
}

.question-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: start;
}

.question-head h2 {
  margin-top: 6px;
}

.question-progress {
  width: min(220px, 100%);
  display: grid;
  gap: 8px;
  text-align: right;
}

.question-progress strong {
  font-size: 28px;
}

.question-profile-control {
  display: grid;
  gap: 12px;
}

.question-mode-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.question-mode-button,
.category-toggle {
  min-width: 0;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: var(--input);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.question-mode-button {
  display: grid;
  gap: 4px;
  padding: 12px;
}

.question-mode-button small {
  color: var(--muted);
  font-weight: 800;
}

.question-mode-button.active,
.category-toggle.active {
  border-color: var(--blue-border);
  background: var(--blue);
}

.question-default-toggle {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: var(--input);
  padding: 10px 12px;
  color: var(--text);
  font-weight: 800;
  cursor: pointer;
}

.question-default-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.question-default-switch {
  position: relative;
  width: 46px;
  height: 26px;
  flex: 0 0 46px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: rgba(15, 23, 42, 0.72);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  transition: background 0.18s ease, border-color 0.18s ease;
}

.question-default-switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #e5f7ff;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.35);
  transition: transform 0.18s ease, background 0.18s ease;
}

.question-default-toggle input:focus-visible + .question-default-switch {
  outline: 2px solid var(--blue-border);
  outline-offset: 3px;
}

.question-default-toggle input:checked + .question-default-switch {
  border-color: rgba(34, 211, 238, 0.72);
  background: linear-gradient(90deg, #22d3ee, #f7e26b, #ff4d79);
}

.question-default-toggle input:checked + .question-default-switch::after {
  transform: translateX(20px);
  background: #ffffff;
}

.question-default-toggle > span:not(.question-default-switch) {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.question-default-toggle small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
}

.question-default-toggle.default-on {
  border-color: var(--border-soft);
  background: var(--input);
  color: var(--text);
}

.question-default-toggle.default-on small {
  color: var(--muted);
}

.category-toggle-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.category-toggle {
  min-height: 48px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 10px;
}

.category-toggle strong {
  min-width: 0;
  font-size: 13px;
  line-height: 1.25;
}

.category-toggle-check {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  border: 1px solid var(--border-soft);
  background: var(--panel);
  color: var(--accent);
  font-weight: 900;
}

.category-toggle:disabled {
  cursor: default;
  opacity: 1;
}

.category-toggle.default-locked {
  border-color: var(--border-soft);
  background: var(--input);
  color: var(--text);
}

.category-toggle.default-locked.active {
  border-color: var(--blue-border);
  background: var(--blue);
  color: var(--text);
}

.category-toggle.default-locked .category-toggle-check {
  border-color: #9ca3af;
  background: rgba(156, 163, 175, 0.18);
  color: transparent;
}

.category-toggle.default-locked.active .category-toggle-check {
  border-color: #d97706;
  background: #f59e0b;
  color: #111827;
}

.question-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.question-editor {
  min-width: 0;
  display: grid;
  gap: 16px;
  scroll-margin-top: 16px;
}

.question-editor h3,
.category-list h3 {
  margin: 0;
}

.question-editor h3 {
  font-size: 24px;
  line-height: 1.28;
}

.question-choices {
  display: grid;
  gap: 10px;
}

.question-choice {
  width: 100%;
  min-height: 68px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: var(--input);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.question-choice span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--panel);
  color: var(--muted);
  font-weight: 800;
}

.question-choice strong {
  min-width: 0;
  line-height: 1.35;
}

.question-choice.active {
  border-color: var(--blue-border);
  background: var(--blue);
}

.iq-hero {
  position: relative;
  isolation: isolate;
  min-height: 330px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 28px;
  align-items: center;
  overflow: hidden;
  padding: clamp(24px, 5vw, 56px);
  border-color: color-mix(in srgb, var(--blue) 62%, var(--border));
  background:
    radial-gradient(circle at 82% 20%, color-mix(in srgb, var(--blue) 38%, transparent) 0%, transparent 30%),
    radial-gradient(circle at 8% 100%, color-mix(in srgb, var(--red) 22%, transparent) 0%, transparent 36%),
    linear-gradient(135deg, color-mix(in srgb, var(--panel) 84%, var(--blue) 16%) 0%, var(--panel) 68%);
}

.iq-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.16;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px);
  background-size: 38px 38px;
  mask-image: linear-gradient(90deg, transparent, #000 62%);
}

.iq-hero-copy {
  display: grid;
  gap: 14px;
  align-content: center;
}

.iq-hero-copy h2,
.iq-result-copy h2 {
  margin: 0;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.iq-hero-copy p,
.iq-result-copy p {
  max-width: 700px;
  margin: 0;
  font-size: 17px;
  line-height: 1.55;
}

.iq-hero-facts,
.iq-result-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.iq-hero-facts span,
.iq-result-facts span {
  display: grid;
  gap: 2px;
  min-width: 112px;
  padding: 10px 13px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: color-mix(in srgb, var(--panel) 78%, transparent);
  color: var(--muted);
  font-size: 12px;
}

.iq-hero-facts b,
.iq-result-facts b {
  color: var(--text);
  font-size: 18px;
}

.iq-orbit {
  position: relative;
  width: min(250px, 100%);
  aspect-ratio: 1;
  justify-self: center;
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--blue) 64%, var(--border));
  border-radius: 50%;
  background:
    radial-gradient(circle, color-mix(in srgb, var(--blue) 34%, var(--panel)) 0 28%, transparent 29%),
    color-mix(in srgb, var(--panel-soft) 82%, transparent);
  box-shadow: 0 24px 70px color-mix(in srgb, var(--blue) 24%, var(--shadow));
}

.iq-orbit::before,
.iq-orbit::after {
  content: "";
  position: absolute;
  inset: 18%;
  border: 1px dashed color-mix(in srgb, var(--blue-soft) 46%, transparent);
  border-radius: 50%;
}

.iq-orbit::after {
  inset: -1px;
  border-style: solid;
  opacity: 0.38;
}

.iq-orbit strong {
  position: relative;
  z-index: 2;
  color: #ffffff;
  font-size: 42px;
  letter-spacing: -0.06em;
}

.iq-orbit span {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
  color: var(--blue-soft);
  font-weight: 900;
  box-shadow: 0 12px 28px var(--shadow);
}

.iq-orbit span:nth-child(1) { top: 3%; left: 18%; }
.iq-orbit span:nth-child(2) { top: 22%; right: -3%; }
.iq-orbit span:nth-child(3) { right: 13%; bottom: 3%; }
.iq-orbit span:nth-child(4) { left: -3%; bottom: 20%; }

.iq-intro-grid h2,
.iq-result-grid h2 {
  margin: 8px 0;
}

.iq-credit-key,
.iq-category-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.iq-credit-key span,
.iq-category-chips span {
  padding: 8px 11px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: var(--panel-soft);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
}

.iq-credit-key .correct {
  border-color: rgba(67, 217, 154, 0.52);
  color: #79efb8;
}

.iq-credit-key .partial {
  border-color: rgba(245, 185, 66, 0.58);
  color: #ffd36a;
}

.iq-credit-key .wrong {
  border-color: rgba(255, 103, 120, 0.52);
  color: #ff9aa7;
}

body[data-theme="day"] .iq-credit-key .correct { color: #087648; }
body[data-theme="day"] .iq-credit-key .partial { color: #8a5a00; }
body[data-theme="day"] .iq-credit-key .wrong { color: #b42335; }

.iq-start-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px 24px;
  align-items: center;
}

.iq-start-panel strong {
  font-size: 24px;
}

.iq-start-panel p {
  margin: 4px 0 0;
}

.iq-start-panel > small,
.iq-start-panel .dashboard-notice {
  grid-column: 1 / -1;
}

.iq-history-list,
.iq-review-list,
.iq-category-bars {
  display: grid;
  gap: 10px;
}

.iq-history-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid var(--border-soft);
}

.iq-history-row > span {
  display: grid;
  gap: 3px;
}

.iq-history-row > span:last-child {
  text-align: right;
}

.iq-history-row strong {
  font-size: 17px;
}

.iq-history-row small {
  color: var(--muted);
}

.iq-test-toolbar {
  position: sticky;
  top: 10px;
  z-index: 15;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px 20px;
  align-items: center;
  border-color: color-mix(in srgb, var(--blue) 55%, var(--border));
  background: color-mix(in srgb, var(--panel) 92%, transparent);
  backdrop-filter: blur(18px);
}

.iq-test-toolbar > div:first-child {
  display: grid;
  gap: 4px;
}

.iq-test-toolbar > div:first-child strong {
  font-size: 22px;
}

.iq-live-stats {
  display: flex;
  gap: 8px;
}

.iq-live-stats span {
  min-width: 86px;
  display: grid;
  gap: 2px;
  padding: 8px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: var(--panel-soft);
}

.iq-live-stats small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.iq-live-stats b {
  font-variant-numeric: tabular-nums;
}

.iq-overall-progress {
  grid-column: 1 / -1;
  height: 8px;
  margin: 0;
}

.iq-test-toolbar .dashboard-notice {
  grid-column: 1 / -1;
  margin: 0;
}

.iq-question-map {
  display: grid;
  grid-template-columns: repeat(18, minmax(30px, 1fr));
  gap: 6px;
}

.iq-question-map button {
  min-width: 0;
  height: 36px;
  padding: 0;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--muted);
  font-weight: 800;
  cursor: pointer;
}

.iq-question-map button.answered {
  border-color: color-mix(in srgb, #43d99a 68%, var(--border));
  color: #79efb8;
}

.iq-question-map button.active {
  border-color: var(--blue-border);
  background: var(--blue);
  color: #ffffff;
  box-shadow: 0 8px 20px color-mix(in srgb, var(--blue) 26%, transparent);
}

body[data-theme="day"] .iq-question-map button.answered { color: #087648; }

.iq-question-card {
  min-height: 520px;
  display: grid;
  gap: 16px;
  align-content: start;
  scroll-margin-top: 150px;
  padding: clamp(20px, 4vw, 42px);
}

.iq-question-card h2 {
  max-width: 900px;
  margin: 0;
  font-size: clamp(24px, 4vw, 36px);
  line-height: 1.22;
}

.iq-question-card > p {
  max-width: 780px;
  margin: -6px 0 0;
  color: var(--muted);
}

.iq-question-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.iq-visual {
  min-height: 116px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  align-items: center;
  margin: 4px 0;
  padding: 20px;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  background:
    radial-gradient(circle at 50% 0%, color-mix(in srgb, var(--blue) 18%, transparent), transparent 58%),
    var(--panel-soft);
}

.iq-visual b {
  color: var(--muted);
  font-size: 20px;
}

.iq-visual-token {
  min-width: 58px;
  min-height: 54px;
  display: grid;
  place-items: center;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 11px;
  background: var(--panel);
  color: var(--text);
  font-size: clamp(18px, 3vw, 27px);
  font-weight: 900;
  box-shadow: 0 8px 20px var(--shadow);
}

.iq-visual-matrix,
.iq-visual-machine {
  display: grid;
  width: min(440px, 100%);
  margin-inline: auto;
}

.iq-visual-row {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(60px, 1fr);
  gap: 8px;
  align-items: center;
}

.iq-visual-machine .iq-visual-row {
  grid-template-columns: minmax(70px, 1fr) auto minmax(70px, 1fr);
  grid-auto-flow: initial;
}

.iq-visual-quote {
  min-height: 0;
  justify-content: flex-start;
  margin-inline: 0;
  color: var(--text);
  font-size: clamp(20px, 3vw, 28px);
  font-weight: 800;
  line-height: 1.5;
  text-align: left;
}

.iq-visual-counters .iq-visual-token {
  min-width: 48px;
  width: 48px;
  min-height: 48px;
  height: 48px;
  padding: 0;
  border-radius: 50%;
  color: #ffffff;
}

.iq-counter-r { background: #d93b55; }
.iq-counter-b { background: #2377d9; }

.iq-answer-choices {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.iq-answer-choices .question-choice {
  min-height: 78px;
  border-radius: 12px;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.iq-answer-choices .question-choice:hover:not(:disabled) {
  transform: translateY(-2px);
  border-color: var(--blue-border);
}

.iq-answer-choices .question-choice.active {
  border-color: color-mix(in srgb, var(--blue-soft) 80%, var(--blue-border));
  background: linear-gradient(135deg, color-mix(in srgb, var(--blue) 86%, var(--panel)) 0%, color-mix(in srgb, var(--blue) 62%, var(--panel)) 100%);
  box-shadow: 0 12px 30px color-mix(in srgb, var(--blue) 24%, transparent);
}

.iq-answer-choices .question-choice.active span {
  background: #ffffff;
  color: var(--blue);
}

.iq-test-actions {
  display: grid;
  grid-template-columns: auto minmax(150px, 1fr) auto auto;
  gap: 10px;
  align-items: center;
}

.iq-test-actions > span {
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.iq-test-actions .btn:disabled,
.iq-answer-choices .question-choice:disabled {
  opacity: 0.52;
  cursor: not-allowed;
}

.iq-result-hero {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: clamp(24px, 5vw, 56px);
  align-items: center;
  padding: clamp(24px, 5vw, 52px);
  overflow: hidden;
  background:
    radial-gradient(circle at 12% 50%, color-mix(in srgb, var(--blue) 30%, transparent) 0%, transparent 32%),
    linear-gradient(135deg, color-mix(in srgb, var(--panel) 86%, var(--blue) 14%), var(--panel));
}

.iq-score-ring {
  width: min(260px, 100%);
  aspect-ratio: 1;
  display: grid;
  place-content: center;
  justify-self: center;
  gap: 5px;
  border: 12px solid color-mix(in srgb, var(--blue) 72%, var(--panel-soft));
  border-radius: 50%;
  background: var(--panel);
  text-align: center;
  box-shadow:
    0 0 0 1px var(--blue-border),
    0 24px 70px color-mix(in srgb, var(--blue) 26%, var(--shadow)),
    inset 0 0 42px color-mix(in srgb, var(--blue) 12%, transparent);
}

.iq-score-ring span,
.iq-score-ring small {
  color: var(--muted);
  font-weight: 800;
}

.iq-score-ring strong {
  color: var(--text);
  font-size: clamp(58px, 9vw, 82px);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.iq-result-copy {
  display: grid;
  gap: 14px;
}

.iq-result-counts .stat {
  border-top: 3px solid var(--border);
}

.iq-result-counts .iq-stat-correct { border-top-color: #43d99a; }
.iq-result-counts .iq-stat-partial { border-top-color: #f5b942; }
.iq-result-counts .iq-stat-wrong { border-top-color: #ff6778; }

.iq-category-bars > div {
  display: grid;
  gap: 6px;
}

.iq-category-bars > div > span {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
}

.iq-category-bars em {
  color: var(--blue-soft);
  font-style: normal;
  font-weight: 900;
}

.iq-category-bars .progress {
  height: 9px;
  margin: 0;
}

.iq-category-bars .progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--blue-soft));
}

.iq-result-method {
  align-content: start;
}

.iq-review-item {
  border: 1px solid var(--border-soft);
  border-left: 4px solid var(--border);
  border-radius: 10px;
  background: var(--panel-soft);
  overflow: hidden;
}

.iq-review-item.correct { border-left-color: #43d99a; }
.iq-review-item.partial { border-left-color: #f5b942; }
.iq-review-item.wrong,
.iq-review-item.unanswered { border-left-color: #ff6778; }

.iq-review-item summary {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  padding: 14px;
  cursor: pointer;
  list-style: none;
}

.iq-review-item summary::-webkit-details-marker {
  display: none;
}

.iq-review-item summary > span {
  min-width: 0;
  line-height: 1.35;
}

.iq-review-item summary > strong {
  flex: 0 0 auto;
  font-size: 12px;
}

.iq-review-item.correct summary > strong { color: #79efb8; }
.iq-review-item.partial summary > strong { color: #ffd36a; }
.iq-review-item.wrong summary > strong,
.iq-review-item.unanswered summary > strong { color: #ff9aa7; }

body[data-theme="day"] .iq-review-item.correct summary > strong { color: #087648; }
body[data-theme="day"] .iq-review-item.partial summary > strong { color: #8a5a00; }
body[data-theme="day"] .iq-review-item.wrong summary > strong,
body[data-theme="day"] .iq-review-item.unanswered summary > strong { color: #b42335; }

.iq-review-item > div {
  display: grid;
  gap: 8px;
  padding: 0 14px 14px;
  border-top: 1px solid var(--border-soft);
}

.iq-review-item p {
  max-width: none;
  margin: 10px 0 0;
}

.iq-review-item small {
  color: var(--muted);
  line-height: 1.5;
}

@media (max-width: 900px) {
  .iq-hero,
  .iq-result-hero {
    grid-template-columns: minmax(0, 1fr) 220px;
  }

  .iq-question-map {
    grid-template-columns: repeat(9, minmax(30px, 1fr));
  }

  .iq-result-counts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .iq-hero,
  .iq-result-hero {
    grid-template-columns: 1fr;
    padding: 22px;
  }

  .iq-hero {
    min-height: 0;
  }

  .iq-orbit {
    width: 190px;
    margin-block: 10px;
  }

  .iq-orbit strong {
    font-size: 34px;
  }

  .iq-orbit span {
    width: 38px;
    height: 38px;
    border-radius: 11px;
  }

  .iq-hero-copy h2,
  .iq-result-copy h2 {
    font-size: 34px;
  }

  .iq-hero-facts span,
  .iq-result-facts span {
    flex: 1 1 90px;
    min-width: 0;
  }

  .iq-start-panel,
  .iq-test-toolbar,
  .iq-test-actions {
    grid-template-columns: 1fr;
  }

  .iq-start-panel .button-row,
  .iq-start-panel .btn,
  .iq-test-actions .btn {
    width: 100%;
  }

  .iq-test-toolbar {
    top: 6px;
  }

  .iq-live-stats {
    width: 100%;
  }

  .iq-live-stats span {
    flex: 1 1 0;
  }

  .iq-question-map {
    grid-template-columns: repeat(6, minmax(34px, 1fr));
  }

  .iq-question-card {
    min-height: 0;
    padding: 18px;
    scroll-margin-top: 215px;
  }

  .iq-question-card h2 {
    font-size: 25px;
  }

  .iq-visual {
    min-height: 100px;
    gap: 7px;
    padding: 14px 10px;
  }

  .iq-visual-token {
    min-width: 46px;
    min-height: 46px;
    padding: 7px 9px;
    font-size: 18px;
  }

  .iq-visual-row {
    grid-auto-columns: minmax(46px, 1fr);
  }

  .iq-answer-choices {
    grid-template-columns: 1fr;
  }

  .iq-answer-choices .question-choice {
    min-height: 68px;
  }

  .iq-test-actions > span {
    order: -1;
  }

  .iq-test-actions .btn.primary {
    order: 5;
  }

  .iq-score-ring {
    width: 220px;
  }

  .iq-result-counts,
  .iq-result-grid {
    grid-template-columns: 1fr;
  }

  .iq-review-item summary {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .iq-review-item summary > strong {
    flex-basis: auto;
  }
}

.question-importance {
  display: grid;
  gap: 10px;
}

.question-importance-label {
  font-weight: 800;
}

.question-importance-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.importance-button {
  min-height: 76px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 8px 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: var(--input);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.importance-button strong,
.importance-button small {
  min-width: 0;
}

.importance-button small {
  grid-column: 2;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.25;
}

.importance-check {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: var(--panel);
  color: var(--muted);
  font-weight: 900;
}

.importance-button.active {
  border-color: var(--blue-border);
  background: var(--blue);
}

.importance-button.active .importance-check {
  border-color: var(--blue-border);
  background: var(--panel);
  color: var(--accent);
}

.compatibility-pills {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 10px 0;
}

.compatibility-pill {
  min-width: 0;
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  font-weight: 900;
}

.compatibility-pill strong {
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
}

.compatibility-pill.active {
  border-color: var(--blue-border);
  background: var(--blue);
}

.compatibility-pill.high-match {
  position: relative;
  z-index: 1;
  overflow: hidden;
  border: 1px solid rgba(215, 139, 164, 0.72) !important;
  background: linear-gradient(145deg, rgba(116, 48, 73, 0.88), rgba(70, 35, 50, 0.94)) !important;
  box-shadow: 0 6px 16px rgba(5, 8, 14, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
  transform: none;
  animation: none;
}

.compatibility-pill.high-match strong,
.compatibility-pill.high-match > span {
  color: #ffffff;
}

.compatibility-pill.high-match strong {
  color: #f0c5d2;
}

.compatibility-pill.high-match em {
  color: #e7b2c2;
  font-size: 9px;
  font-weight: 900;
  font-style: normal;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-shadow: none;
}

body[data-theme="day"] .compatibility-pill.high-match {
  border-color: rgba(170, 91, 119, 0.58) !important;
  background: linear-gradient(145deg, #faedf1, #f4dfe6) !important;
  box-shadow: 0 5px 14px rgba(91, 39, 58, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.8) !important;
  color: #552438 !important;
}

body[data-theme="day"] .compatibility-pill.high-match strong,
body[data-theme="day"] .compatibility-pill.high-match > span {
  color: #552438;
}

body[data-theme="day"] .compatibility-pill.high-match em {
  color: #8d4560;
}

.match-explanation-panel {
  overflow: hidden;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: color-mix(in srgb, var(--input) 72%, var(--panel) 28%);
}

.match-explanation-panel summary {
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  cursor: pointer;
  color: var(--text);
  font-weight: 900;
  list-style: none;
}

.match-explanation-panel summary::-webkit-details-marker {
  display: none;
}

.match-explanation-panel summary strong {
  color: var(--accent);
  font-size: 14px;
}

.match-explanation-body {
  display: grid;
  gap: 10px;
  padding: 0 12px 12px;
}

.match-explanation-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 8px;
}

.match-explanation-stats span {
  min-width: 0;
  display: grid;
  gap: 2px;
  padding: 8px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--panel-soft);
}

.match-explanation-stats small,
.match-explanation-muted {
  color: var(--muted);
}

.match-explanation-stats strong {
  min-width: 0;
  overflow-wrap: anywhere;
  color: var(--text);
  font-size: 13px;
}

.match-explanation-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.match-explanation-chips span {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 5px 8px;
  border: 1px solid var(--blue-border);
  border-radius: 999px;
  background: color-mix(in srgb, var(--blue) 36%, var(--panel) 64%);
  color: var(--text);
  font-size: 12px;
  font-weight: 800;
}

.match-explanation-bars {
  display: grid;
  gap: 8px;
}

.match-explanation-bar {
  display: grid;
  gap: 5px;
}

.match-explanation-bar > div:first-child {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
}

.match-explanation-bar > div:first-child span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.match-explanation-bar .mini-progress {
  height: 8px;
}

.match-explanation-rank {
  display: grid;
  gap: 6px;
}

.match-explanation-rank > strong {
  color: var(--muted);
  font-size: 12px;
}

.question-compare-scrim {
  position: fixed;
  inset: 0;
  z-index: 80;
  border: 0;
  background: rgba(7, 13, 24, 0.45);
  cursor: pointer;
}

.oracle-apply-scrim {
  position: fixed;
  inset: 0;
  z-index: 80;
  border: 0;
  background: rgba(7, 13, 24, 0.48);
  cursor: pointer;
}

.oracle-apply-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 90;
  width: min(620px, 100vw);
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px 18px 24px;
  overflow-y: auto;
  overflow-x: hidden;
  border-left: 1px solid var(--border-soft);
  background: var(--panel);
  color: var(--text);
  box-shadow: -24px 0 60px rgba(0, 0, 0, 0.35);
  animation: oracleApplyDrawerIn 0.22s ease-out both;
}

.oracle-apply-drawer .form-grid {
  flex: 0 0 auto;
  align-content: start;
}

.oracle-apply-drawer > .button-row {
  flex: 0 0 auto;
  padding-top: 4px;
}

.oracle-enroll-card {
  display: grid;
  gap: 12px;
}

.oracle-reader-card {
  padding: 16px 16px 18px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

.oracle-reader-card.active {
  border-color: var(--button-blue-border);
  box-shadow: 0 0 0 2px rgba(90, 140, 190, 0.16);
}

.oracle-viewing-pill {
  border-color: var(--button-blue-border);
  background: var(--button-blue-bg);
  color: var(--button-blue-text);
}

.oracle-reader-card .message-photo-preview {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  margin: 0;
}

.oracle-reader-card h2,
.oracle-reader-card p,
.oracle-reader-card .pill-list,
.oracle-reader-card .button-row {
  margin-top: 0;
  margin-bottom: 0;
}

.oracle-reader-card .button-row {
  width: 100%;
  margin-top: 4px;
}

.oracle-reader-card .dashboard-actions .btn {
  flex: 1 1 130px;
}

.oracle-request-panel {
  display: grid;
  gap: 16px;
}

.oracle-request-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.42fr);
  gap: 16px;
  align-items: start;
}

.oracle-request-main {
  display: grid;
  gap: 12px;
}

.oracle-request-main textarea[data-oracle-question] {
  min-height: 170px;
}

.oracle-reading-description {
  margin: 0;
  padding: 12px 14px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--panel-soft);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.oracle-request-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.oracle-payment-box {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--panel-soft);
}

.oracle-payment-box h3 {
  margin: 0;
  font-size: 28px;
}

.oracle-payment-box p {
  margin: 0;
  color: var(--muted);
}

.oracle-payment-box .table-list {
  gap: 5px;
  margin: 0;
}

.oracle-payment-box .table-list div {
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 8px;
  min-height: 0;
  padding: 6px 8px;
  border-bottom: 1px solid var(--border-soft);
  background: transparent;
}

.oracle-payment-box .table-list strong {
  line-height: 1.2;
}

.oracle-payment-box .full-width {
  margin-top: 2px;
}

.full-width {
  width: 100%;
}

@keyframes oracleApplyDrawerIn {
  from {
    opacity: 0;
    transform: translateX(36px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.question-compare-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 90;
  width: min(760px, 100vw);
  height: 100vh;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr);
  gap: 12px;
  padding: 18px;
  overflow: hidden;
  border-left: 1px solid var(--border-soft);
  background: var(--panel);
  color: var(--text);
  box-shadow: -24px 0 60px rgba(0, 0, 0, 0.35);
}

.question-compare-head,
.question-answer-slide-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
}

.question-compare-head h2,
.question-answer-slide-head h3 {
  margin: 4px 0 0;
}

.question-compare-legend {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.compare-chip {
  min-width: 0;
  padding: 7px 9px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 900;
}

.compare-chip.very,
.compare-answer-card.very {
  border-color: rgba(255, 79, 112, 0.72);
  background: rgba(255, 79, 112, 0.14);
}

.compare-chip.care,
.compare-answer-card.care {
  border-color: rgba(255, 196, 76, 0.78);
  background: rgba(255, 196, 76, 0.18);
}

.compare-chip.not,
.compare-answer-card.not {
  border-color: rgba(75, 201, 142, 0.72);
  background: rgba(75, 201, 142, 0.15);
}

.compare-chip.missing,
.compare-answer-card.missing,
.compare-answer-card.locked,
.question-compare-row.has-missing {
  border-color: rgba(132, 145, 166, 0.58);
  background: rgba(132, 145, 166, 0.12);
}

.compare-answer-card.locked strong {
  color: var(--muted);
}

.question-compare-list {
  min-height: 0;
  display: grid;
  gap: 10px;
  overflow: auto;
  padding-right: 4px;
}

.question-compare-row {
  position: relative;
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
}

.question-compare-anchor {
  position: absolute;
  top: -10px;
  left: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
  pointer-events: none;
}

.question-compare-question {
  display: grid;
  gap: 4px;
}

.question-compare-question small,
.compare-answer-card small {
  color: var(--muted);
  font-weight: 900;
}

.question-compare-answers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.compare-answer-card {
  min-width: 0;
  display: grid;
  gap: 6px;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
}

.compare-answer-card strong {
  line-height: 1.3;
}

.question-compare-actions {
  display: flex;
  justify-content: flex-end;
}

.question-answer-slide {
  position: absolute;
  inset: auto 18px 18px 18px;
  max-height: min(78vh, 720px);
  display: grid;
  gap: 12px;
  overflow: auto;
  padding: 14px;
  border: 1px solid var(--blue-border);
  border-radius: 10px;
  background: var(--panel);
  box-shadow: 0 -18px 54px rgba(0, 0, 0, 0.34);
}

.question-choices.compact {
  gap: 8px;
}

.question-choices.compact .question-choice {
  min-height: 52px;
}

.question-importance-options.compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.category-list {
  display: grid;
  gap: 8px;
}

.category-list button {
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.category-list button:hover {
  border-color: var(--blue-border);
  background: var(--blue);
}

.score-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.score-card {
  min-width: 0;
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
}

.score-card strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.score-card span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 800;
}

.score-track {
  height: 8px;
  border-radius: 999px;
  background: var(--panel);
  overflow: hidden;
}

.score-track i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--score-color, #f6e148);
}

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

.answered-question-list .section-head {
  padding-top: 4px;
}

.answered-question-list .table-list div {
  grid-template-columns: minmax(0, 1.4fr) minmax(160px, 0.8fr) auto;
  align-items: start;
}

.answered-question-list .table-list span {
  min-width: 0;
  display: grid;
  gap: 4px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.answered-question-list .table-list small {
  color: var(--subtle);
  font-size: 11px;
  font-weight: 800;
}

.answered-question-list .table-list strong {
  min-width: 0;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.avatar {
  width: 120px;
  height: 120px;
  display: grid;
  place-items: center;
  border-radius: 24px;
  border: 1px solid var(--blue-border);
  background: var(--blue);
  color: var(--text);
  font-size: 48px;
  font-weight: 800;
  text-transform: uppercase;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.interest-category-list {
  display: grid;
  gap: 18px;
  margin-top: 14px;
}

.interest-picker-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.interest-picker-heading h2,
.interest-picker-heading p {
  margin-top: 0;
}

.interest-picker-heading [data-interest-selected-count] {
  flex: 0 0 auto;
  position: sticky;
  top: 12px;
}

.interest-search {
  max-width: 560px;
  margin-top: 18px;
}

.interest-search-empty {
  color: var(--blue-text);
}

.interest-category {
  display: grid;
  gap: 8px;
}

.interest-category h3 {
  margin: 0;
  color: var(--blue-text);
  font-size: 18px;
  line-height: 1.25;
}

body:not([data-theme="day"]) .page-route-me-edit .interest-category h3 {
  padding: 8px 12px;
  border-left: 3px solid var(--page-accent);
  border-radius: 0 10px 10px 0;
  background: linear-gradient(90deg, color-mix(in srgb, var(--page-accent) 13%, transparent), transparent 82%);
  color: color-mix(in srgb, var(--page-accent) 38%, #ffffff);
  text-shadow: 0 1px 12px color-mix(in srgb, var(--page-accent) 22%, transparent);
  letter-spacing: .01em;
}

.interest-category[hidden],
.interest-check[hidden],
.interest-search-empty[hidden] {
  display: none;
}

.interest-category .checkbox-grid {
  margin-top: 0;
}

.interest-check span {
  line-height: 1.2;
}

.shared-interest-strip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.shared-interest-strip span {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border: 1px solid rgba(46, 160, 67, 0.55);
  border-radius: 999px;
  background: rgba(46, 160, 67, 0.16);
  color: #d4f8dc;
  font-size: 12px;
  font-weight: 800;
}

.shared-interest-strip .shared-interest-label {
  border-color: rgba(111, 168, 220, 0.65);
  background: rgba(20, 49, 77, 0.78);
  color: #e8f4ff;
}

.shared-interest-strip.empty span {
  border-color: var(--border-soft);
  background: var(--input);
  color: var(--subtle);
}

body[data-theme="day"] .shared-interest-strip span {
  border-color: rgba(46, 160, 67, 0.42);
  background: #eaffef;
  color: #116329;
}

body[data-theme="day"] .shared-interest-strip .shared-interest-label {
  border-color: #b8d3ee;
  background: #e9f4ff;
  color: #214e77;
}

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

.step-list span,
.step-list button {
  min-height: 44px;
  display: flex;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  font-weight: 800;
  text-align: left;
}

.step-list button {
  cursor: pointer;
}

.onboarding-step-list button {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 2px 10px;
}

.upload-zone {
  min-height: 220px;
  display: grid;
  align-content: center;
  gap: 10px;
  border-style: dashed;
}

.draw-studio {
  position: relative;
  display: block;
  min-width: 0;
}

.draw-board,
.draw-controls {
  display: grid;
  gap: 14px;
}

.draw-topbar {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: start;
}

.draw-topbar h2,
.draw-controls h2 {
  margin-bottom: 4px;
}

.draw-toolbar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.draw-quick-text {
  flex: 1 1 100%;
  display: grid;
  grid-template-columns: auto minmax(220px, 1fr) auto;
  align-items: center;
  gap: 8px 10px;
  padding: 10px 12px;
  border: 1px solid color-mix(in srgb, var(--accent, #13bdd1) 70%, var(--border));
  border-radius: 11px;
  background: color-mix(in srgb, var(--input) 88%, var(--accent, #13bdd1) 12%);
  color: var(--text);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent, #13bdd1) 12%, transparent);
}

.draw-quick-text span {
  font-size: .8rem;
  font-weight: 800;
}

.draw-quick-text input {
  min-height: 42px;
  width: 100%;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  padding: 9px 11px;
  font: inherit;
}

.draw-quick-text input:focus {
  border-color: var(--accent, #13bdd1);
  outline: 3px solid color-mix(in srgb, var(--accent, #13bdd1) 20%, transparent);
}

.draw-quick-text small {
  color: var(--muted);
  font-size: .72rem;
  font-weight: 700;
}

@media (max-width: 700px) {
  .draw-quick-text {
    grid-template-columns: 1fr;
  }
}

.draw-scopebar {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 10px;
  margin: 12px 0;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  background: color-mix(in srgb, var(--input) 82%, transparent);
}

.draw-scopebar label {
  display: grid;
  gap: 4px;
  min-width: min(100%, 280px);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.draw-scopebar select {
  min-height: 38px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  padding: 7px 10px;
  font: inherit;
  font-weight: 800;
}

.draw-viewbar {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.draw-canvas-frame {
  position: relative;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  overflow: hidden;
  background:
    linear-gradient(var(--border-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--border-soft) 1px, transparent 1px),
    var(--input);
  background-size: 28px 28px;
}

.draw-tools-float {
  position: absolute;
  top: 10px;
  right: 58px;
  z-index: 6;
  width: 38px;
  height: 38px;
  display: grid;
  place-content: center;
  gap: 4px;
  border: 1px solid var(--blue-border);
  border-radius: 8px;
  background: var(--blue);
  color: var(--text);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.24);
  cursor: pointer;
}

.draw-tools-float span {
  width: 16px;
  height: 2px;
  border-radius: 99px;
  background: currentColor;
}

.draw-canvas-frame:fullscreen {
  display: grid;
  place-items: center;
  padding: 18px;
  background: #05080d;
}

.draw-canvas-frame:fullscreen .draw-canvas {
  width: min(96vw, calc(96vh * 1.714));
  max-height: 92vh;
}

.draw-canvas {
  position: relative;
  width: 100%;
  aspect-ratio: 12 / 7;
  min-height: 420px;
  touch-action: none;
  color: var(--subtle);
  font-weight: 800;
  overflow: hidden;
  cursor: grab;
}

.draw-canvas.panning {
  cursor: grabbing;
}

.draw-viewport {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  transform-origin: center center;
  will-change: transform;
}

.draw-canvas canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: crosshair;
  pointer-events: none;
}

.draw-canvas canvas.active {
  pointer-events: auto;
}

.draw-wall-canvas {
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: auto !important;
  cursor: crosshair;
}

.draw-canvas.panning .draw-wall-canvas,
.draw-wall-canvas:active {
  cursor: grabbing;
}

.draw-vector-studio .draw-canvas-frame {
  background: #050912;
}

.draw-vector-studio .draw-canvas {
  min-height: 540px;
  background: #050912;
}

.draw-controls {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 35;
  width: min(390px, 100vw);
  height: 100vh;
  max-height: 100vh;
  grid-template-rows: auto minmax(0, 1fr);
  padding: 18px;
  border-radius: 0;
  border-top: 0;
  border-right: 0;
  border-bottom: 0;
  transform: translateX(110%);
  opacity: 0;
  pointer-events: none;
  transition: transform 240ms cubic-bezier(.2, .8, .2, 1), opacity 180ms ease;
  overflow: hidden;
}

.draw-controls.open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

.draw-controls-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-soft);
}

.draw-controls-head h2 {
  margin-bottom: 4px;
}

.draw-controls-scroll {
  display: grid;
  gap: 14px;
  overflow-y: auto;
  padding-right: 4px;
}

.draw-controls h3 {
  margin: 4px 0 -6px;
}

.draw-coordinate-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.draw-coordinate-grid span,
.draw-bounds {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
}

.draw-coordinate-grid small,
.draw-bounds span {
  color: var(--subtle);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.draw-coordinate-grid strong,
.draw-bounds strong {
  color: var(--text);
  font-family: Courier, monospace;
  font-size: 13px;
}

.draw-bounds {
  margin: 2px 0 12px;
}

.draw-fullscreen-btn,
.draw-exit-fullscreen-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 5;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  border: 1px solid var(--blue-border);
  background: var(--blue);
  color: var(--text);
  font-weight: 900;
  cursor: pointer;
}

.draw-exit-fullscreen-btn {
  display: none;
  background: var(--red);
  border-color: var(--red-border);
}

.draw-fullscreen-tools {
  display: none;
}

.draw-canvas-frame:fullscreen .draw-fullscreen-btn {
  display: none;
}

.draw-canvas-frame:fullscreen .draw-exit-fullscreen-btn {
  display: grid;
}

.draw-canvas-frame:fullscreen .draw-fullscreen-tools {
  position: absolute;
  left: 16px;
  top: 16px;
  right: 64px;
  z-index: 6;
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  pointer-events: none;
}

.draw-glass-tools {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 8px;
  border: 1px solid rgba(115, 168, 224, 0.42);
  border-radius: 8px;
  background: rgba(10, 15, 22, 0.58);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(10px);
  pointer-events: auto;
}

.draw-glass-tools .pill {
  background: rgba(25, 31, 39, 0.72);
}

.draw-glass-settings label {
  display: grid;
  gap: 3px;
  min-width: 92px;
  color: var(--text);
  font-size: 11px;
  font-weight: 900;
}

.draw-glass-settings input,
.draw-glass-settings select {
  min-height: 30px;
  border-radius: 8px;
  border: 1px solid rgba(115, 168, 224, 0.35);
  background: rgba(37, 37, 36, 0.78);
  color: var(--text);
  font-weight: 800;
}

.draw-glass-settings input[type="range"] {
  width: 128px;
}

.draw-glass-settings input[type="color"] {
  width: 48px;
  padding: 2px;
}

.draw-glass-settings.wide label {
  min-width: 146px;
}

.draw-colour-palette {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 14px;
}

.draw-glass-tools.draw-colour-palette {
  margin: 0;
}

.draw-colour-swatch {
  width: 30px;
  height: 30px;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  background: var(--swatch);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.28);
  cursor: pointer;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.draw-colour-swatch:hover,
.draw-colour-swatch:focus-visible,
.draw-colour-swatch.active {
  transform: scale(1.14);
  border-color: #fff;
  box-shadow: 0 0 0 3px rgba(0, 201, 220, 0.35), 0 5px 16px rgba(0, 0, 0, 0.35);
  outline: none;
}

.draw-text-field {
  grid-column: 1 / -1;
}

.draw-text-field input {
  width: 100%;
}

.draw-presence-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.draw-presence-list .pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.draw-presence-list .pill i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--presence-colour);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--presence-colour) 25%, transparent);
}

.draw-minimap {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 5;
  width: 190px;
  height: 120px;
  border: 1px solid rgba(126, 214, 225, 0.72);
  border-radius: 10px;
  background: rgba(4, 10, 18, 0.92);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.38);
  cursor: crosshair;
}

.draw-bookmark-list {
  display: grid;
  gap: 8px;
  margin: 10px 0 18px;
}

.draw-bookmark-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px;
}

.draw-bookmark-row .tiny-btn:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: left;
}

.draw-snapshot-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.draw-snapshot-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 7px;
  align-items: center;
  padding: 9px;
  border: 1px solid var(--border-soft);
  border-radius: 9px;
  background: color-mix(in srgb, var(--input) 84%, transparent);
}

.draw-snapshot-row div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.draw-snapshot-row span {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.draw-reactions {
  display: flex !important;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}

.draw-reaction {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 36px;
  min-height: 28px;
  padding: 3px 7px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: var(--input);
  color: var(--text);
  cursor: pointer;
  font: inherit;
  font-weight: 900;
}

.draw-reaction:hover,
.draw-reaction:focus-visible,
.draw-reaction.active {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 18%, var(--input));
  outline: none;
}

.draw-reaction span {
  color: var(--muted);
  font-size: 10px;
}

.draw-selection-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  margin: 10px 0;
  padding: 10px;
  border: 1px solid rgba(0, 229, 255, 0.7);
  border-radius: 10px;
  background: rgba(0, 201, 220, 0.1);
  box-shadow: inset 3px 0 0 #00e5ff;
}

.draw-selection-bar > div {
  display: grid;
  gap: 2px;
  min-width: min(100%, 210px);
  margin-right: auto;
}

.draw-selection-bar span {
  color: var(--muted);
  font-size: 11px;
}

.draw-context-menu {
  position: absolute;
  z-index: 12;
  display: grid;
  gap: 8px;
  width: min(220px, calc(100% - 16px));
  padding: 11px;
  border: 1px solid rgba(0, 229, 255, 0.78);
  border-radius: 11px;
  background: rgba(5, 13, 22, 0.96);
  color: #fff;
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(12px);
}

.draw-context-menu > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.draw-context-menu small {
  color: rgba(230, 245, 250, 0.72);
}

.draw-context-close {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: transparent;
  color: #fff;
  cursor: pointer;
  font-size: 20px;
}

@media (max-width: 640px) {
  .draw-minimap {
    width: 132px;
    height: 84px;
    right: 8px;
    bottom: 8px;
  }
}

.draw-layer-list,
.draw-saved-list {
  display: grid;
  gap: 8px;
}

.draw-layer-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 8px;
  align-items: center;
  padding: 8px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
}

.draw-layer-row.selected {
  border-color: var(--blue-border);
  background: var(--blue);
}

.draw-saved-thumb {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 8px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  text-align: left;
  font-weight: 800;
}

.draw-saved-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.draw-saved-thumb img {
  width: 74px;
  aspect-ratio: 12 / 7;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--border-soft);
}

.draw-vector-list {
  display: grid;
  gap: 8px;
}

.draw-vector-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
}

.draw-vector-row div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.draw-vector-row strong,
.draw-vector-row span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.draw-vector-row span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 800;
}

.game-shell {
  display: grid;
  gap: 14px;
}

.game-shell-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 14px;
}

.game-feature {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.game-feature h2 {
  margin-top: 10px;
}

.game-frame {
  display: block;
  width: 100%;
  max-width: 100%;
  min-height: 680px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: #0b1020;
}

.chess-frame {
  min-height: 760px;
}

.checkers-frame {
  min-height: 860px;
  background: #0c1018;
}

@media (max-width: 760px) {
  .checkers-frame {
    min-height: 1120px;
  }
}

.golf-frame {
  min-height: 760px;
}

.numerology-frame {
  min-height: 780px;
}

.numerology-chart-frame {
  min-height: 900px;
}

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

.compact-list {
  margin-top: 10px;
}

.table-list div,
.table-list a {
  min-height: 46px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 14px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--input);
  color: var(--text);
  text-decoration: none;
}

.table-list a:hover {
  border-color: var(--blue-border);
  background: var(--blue);
}

.table-list.compact-list div {
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
}

.table-list em {
  color: var(--subtle);
  font-style: normal;
  font-size: 12px;
  font-weight: 800;
}

.table-list .stacked-action {
  display: grid;
  justify-items: end;
  gap: 4px;
  white-space: nowrap;
}

.table-list .stacked-action small {
  color: var(--subtle);
  font-size: 11px;
  font-weight: 800;
}

.referral-card,
.invite-panel {
  display: grid;
  gap: 16px;
}

.referral-hof-panel {
  display: grid;
  gap: 16px;
}

.referral-hof-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.referral-hof-card {
  --hof-accent: #7c3aed;
  --hof-soft: rgba(124, 58, 237, 0.24);
  min-height: 126px;
  display: grid;
  align-content: space-between;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--hof-accent);
  border-radius: 8px;
  background: linear-gradient(135deg, var(--hof-soft), rgba(15, 23, 42, 0.72));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.referral-hof-card.is-gold {
  --hof-accent: #d4af37;
  --hof-soft: rgba(212, 175, 55, 0.34);
}

.referral-hof-card.is-royal {
  --hof-accent: #4169e1;
  --hof-soft: rgba(65, 105, 225, 0.34);
}

.referral-hof-card.is-grass {
  --hof-accent: #2f9e44;
  --hof-soft: rgba(47, 158, 68, 0.34);
}

.referral-hof-card.is-empty {
  border-style: dashed;
  opacity: 0.72;
}

.referral-hof-rank {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.referral-hof-rank span {
  display: inline-grid;
  min-width: 38px;
  min-height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--hof-accent);
  color: #fff;
  font-weight: 900;
}

.referral-hof-rank em {
  color: var(--text);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  text-align: right;
}

.referral-hof-card strong {
  color: var(--text);
  font-size: 18px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.referral-hof-count {
  color: var(--subtle);
  font-size: 13px;
  font-weight: 800;
}

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

.referral-invite-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 10px;
}

.referral-row-number {
  min-width: 38px;
  min-height: 42px;
  justify-content: center;
}

.copy-field {
  min-height: 46px;
  display: flex;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--blue-border);
  border-radius: 8px;
  background: var(--blue);
  color: var(--text);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.referral-share-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(220px, 0.6fr);
  gap: 14px;
  align-items: stretch;
}

.referral-link-stack,
.referral-rate-card {
  min-width: 0;
  display: grid;
  gap: 12px;
}

.referral-code-card,
.referral-rate-card div,
.referral-invite-stats div,
.referral-explainer div {
  min-width: 0;
  display: grid;
  gap: 5px;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--surface-soft);
}

.referral-code-card span,
.referral-rate-card span,
.referral-invite-stats span,
.referral-explainer span {
  color: var(--muted);
  font-size: 13px;
}

.referral-code-card strong {
  color: var(--text);
  font-size: 26px;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.referral-rate-card strong,
.referral-invite-stats strong {
  color: var(--text);
  font-size: 24px;
  line-height: 1.05;
}

.referral-rate-card em {
  color: var(--subtle);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.referral-share-buttons {
  align-items: stretch;
}

.referral-invite-stats,
.referral-explainer {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.referral-explainer strong {
  color: var(--text);
  font-size: 15px;
}

.referral-qr-card {
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(260px, 50%) minmax(240px, 1fr);
  align-items: stretch;
  gap: 18px;
}

.referral-qr-frame {
  aspect-ratio: 1 / 1;
  display: grid;
  place-items: center;
  padding: 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: #fff;
}

.referral-qr-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: pixelated;
}

.referral-qr-card .small {
  margin: 0;
}

.referral-qr-instructions {
  display: grid;
  align-content: center;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--surface-soft);
}

.referral-qr-instructions h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.2;
}

.referral-qr-instructions ol {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 20px;
}

.referral-qr-instructions li {
  color: var(--text);
  line-height: 1.5;
}

.referral-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  padding-top: 10px;
  border-top: 1px solid var(--border-soft);
}

.referral-stats div {
  display: grid;
  gap: 4px;
}

.referral-stats span {
  color: var(--muted);
  font-size: 13px;
}

.referral-stats strong {
  font-size: 18px;
}

body[data-theme="day"] .referral-hof-panel,
body[data-theme="day"] .referral-card,
body[data-theme="day"] .invite-panel {
  color: #0f172a;
}

body[data-theme="day"] .referral-hof-card {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--hof-accent) 20%, #ffffff 80%) 0%, #f8fbff 62%, #eef4fb 100%);
  border-color: color-mix(in srgb, var(--hof-accent) 72%, #334155 28%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 12px 26px rgba(15, 23, 42, 0.1);
}

body[data-theme="day"] .referral-hof-card.is-gold {
  background:
    linear-gradient(135deg, #fff1b8 0%, #fff9e8 58%, #f8fbff 100%);
}

body[data-theme="day"] .referral-hof-card.is-royal {
  background:
    linear-gradient(135deg, #dbe7ff 0%, #f4f7ff 58%, #f8fbff 100%);
}

body[data-theme="day"] .referral-hof-card.is-grass {
  background:
    linear-gradient(135deg, #d8f8de 0%, #f0fff4 58%, #f8fbff 100%);
}

body[data-theme="day"] .referral-hof-rank span {
  color: #ffffff;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
}

body[data-theme="day"] .referral-hof-rank em,
body[data-theme="day"] .referral-hof-card strong {
  color: #0f172a;
}

body[data-theme="day"] .referral-hof-count {
  color: #334155;
}

body[data-theme="day"] .referral-code-card,
body[data-theme="day"] .referral-rate-card div {
  border-color: #334155;
  background: linear-gradient(180deg, #111827 0%, #0b1220 100%);
  color: #f8fafc;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 10px 22px rgba(15, 23, 42, 0.18);
}

body[data-theme="day"] .referral-code-card span,
body[data-theme="day"] .referral-rate-card span,
body[data-theme="day"] .referral-rate-card em {
  color: #cbd5e1;
}

body[data-theme="day"] .referral-code-card strong,
body[data-theme="day"] .referral-rate-card strong {
  color: #ffffff;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.28);
}

body[data-theme="day"] .referral-code-card strong {
  letter-spacing: 0.02em;
}

body[data-theme="day"] .copy-field {
  border-color: #0891b2;
  background: #ecfeff;
  color: #0f172a;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

body[data-theme="day"] .referral-invite-stats div,
body[data-theme="day"] .referral-explainer div,
body[data-theme="day"] .referral-qr-instructions {
  border-color: #c9d1dc;
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.07);
}

body[data-theme="day"] .referral-invite-stats span,
body[data-theme="day"] .referral-explainer span,
body[data-theme="day"] .referral-stats span,
body[data-theme="day"] .referral-qr-card .small {
  color: #475569;
}

body[data-theme="day"] .referral-invite-stats strong,
body[data-theme="day"] .referral-explainer strong,
body[data-theme="day"] .referral-stats strong,
body[data-theme="day"] .referral-qr-instructions h3,
body[data-theme="day"] .referral-qr-instructions li {
  color: #0f172a;
}

.check-card {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--input);
  color: var(--text);
  font-family: var(--field-font-family);
  font-size: var(--field-font-size);
  font-weight: var(--font-weight);
}

.check-card input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
}

.small {
  color: var(--subtle);
  font-size: 13px;
}

.footer-nav {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  align-content: flex-start;
  padding: 12px 0 0;
  min-height: 0;
  border-top: 1px solid var(--border-soft);
}

.footer-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  height: 40px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--panel);
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.footer-nav a:hover {
  border-color: var(--blue-border);
  color: var(--text);
}

@media (max-width: 860px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .app-shell.sidebar-collapsed {
    grid-template-columns: minmax(0, 1fr);
  }

  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    align-self: start;
    height: 100vh;
    max-height: 100vh;
    padding: 22px 18px;
    width: 250px;
    overflow-y: auto;
    border-right: 1px solid var(--border-soft);
    border-bottom: 0;
  }

  .main {
    grid-column: 1;
    padding: 16px 56px 28px 28px;
    min-width: 0;
    overflow-x: hidden;
  }

  .sidebar-collapsed .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 250px;
    height: 100vh;
    padding: 22px 18px;
    transform: translateX(-110%);
    opacity: 0;
    pointer-events: none;
    border-right: 1px solid var(--border-soft);
    border-bottom: 0;
  }

  .brand img {
    width: 150px;
  }

  .nav {
    grid-template-columns: 1fr;
    padding-right: 0;
    width: auto;
  }

  .nav a {
    width: 280px !important;
    max-width: 100% !important;
    justify-content: flex-start;
  }

  .nav a span:last-child {
    display: none;
  }

  .theme-box {
    margin-top: 0;
  }

  .theme-toggle {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
  }

  .theme-toggle span:last-child {
    min-width: 58px;
    margin-left: 0;
  }

  .owned-room-row {
    grid-template-columns: 1fr;
  }

  .owned-room-actions {
    justify-content: flex-start;
  }

  .grid.cols-4,
  .grid.cols-3,
  .grid.cols-2,
  .friend-card,
  .appearance-body,
  .appearance-background-row,
  .dealbreaker-row,
  .dealbreaker-row.age-row,
  .admin-token-grid,
  .dashboard-grid,
  .profile-stream-layout,
  .form-grid,
  .auth-layout,
  .section-head,
  .public-cta-panel,
  .referral-stats,
  .referral-share-layout,
  .referral-invite-stats,
  .referral-explainer,
  .referral-invite-row,
  .referral-hof-grid,
  .token-cost-preview-lines,
  .messages-workspace,
  .chat-console,
  .draw-studio,
  .profile-hero,
  .profile-quick-facts,
  .profile-composer-grid,
  .photo-grid,
  .checkbox-grid,
  .question-layout,
  .oracle-request-layout,
  .answered-question-list .table-list div,
  .case-grid,
  .score-grid {
    grid-template-columns: 1fr;
  }

  .member-profile-hero {
    grid-template-columns: 1fr;
  }

  .member-profile-main-photo,
  .member-profile-avatar {
    min-height: 280px;
    aspect-ratio: 4 / 3;
  }

  .profile-stream-icon-library {
    height: auto;
    max-height: 150px !important;
  }

  .profile-stream-icon-panel {
    height: auto !important;
    min-height: 0 !important;
  }

  .referral-qr-card {
    grid-template-columns: 1fr;
  }

  .profile-stream-icon-panel > .icon-library.profile-stream-icon-library {
    height: auto !important;
    max-height: 150px !important;
  }

  .profile-stream-editor .profile-stream-editor-controls {
    grid-template-columns: 1fr !important;
  }

  .friend-profile-photo {
    min-height: 220px;
    aspect-ratio: 4 / 3;
  }

  .appearance-background-action-grid {
    grid-template-columns: 1fr;
  }

  .chat-head,
  .question-head,
  .live-message,
  .live-message.mine,
  .chat-input-row,
  .chess-chat-input-row,
  .group-chat-input-row,
  .activity-row {
    grid-template-columns: 1fr;
  }

  .notification-head,
  .notification-main {
    grid-template-columns: 1fr;
  }

  .notification-head {
    display: grid;
  }

  .password-control {
    grid-template-columns: 1fr;
  }

  .editor-head,
  .image-editor-grid {
    grid-template-columns: 1fr;
  }

  .editor-head {
    display: grid;
  }

  .chat-head,
  .room-create-panel,
  .question-head,
  .section-head {
    display: grid;
  }

  .question-progress {
    text-align: left;
  }

  .question-mode-options,
  .category-toggle-grid,
  .compatibility-pills,
  .question-compare-legend,
  .question-compare-answers,
  .question-importance-options.compact {
    grid-template-columns: 1fr;
  }

  .question-importance-options {
    grid-template-columns: 1fr;
  }

  .question-compare-drawer {
    padding: 14px;
  }

  .profile-message-drawer {
    padding: 14px;
  }

  .oracle-apply-drawer {
    padding: 14px;
  }

  .question-answer-slide {
    inset: auto 10px 10px 10px;
  }

  .live-message.mine .live-avatar,
  .live-message.mine .live-bubble {
    order: unset;
  }

  .live-message > .live-avatar {
    width: 72px;
  }

  .avatar {
    width: 96px;
    height: 96px;
    border-radius: 20px;
    font-size: 38px;
  }

  .public-profile-preview .profile-main-photo,
  .public-profile-preview .avatar {
    max-width: none;
    min-height: 260px;
    height: auto;
  }

  .page {
    width: 100%;
    max-width: 100%;
  }

  .messages-thread-panel {
    min-height: 0;
  }

  .messages-friend-list,
  .direct-thread {
    max-height: none;
  }

  .message-friend-row {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .message-profile-head {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .message-profile-panel .message-profile-head {
    grid-template-columns: minmax(0, 1fr);
  }

  .message-profile-photo-wrap,
  .message-profile-details {
    min-height: 118px;
  }

  .message-profile-photo {
    min-height: 118px;
  }

  .message-profile-panel .message-profile-photo {
    min-height: 220px;
  }

  .message-friend-meta {
    grid-column: 2;
    justify-items: start;
    grid-auto-flow: column;
    justify-content: start;
  }
}

body.appearance-panel-glass .hero,
body.appearance-panel-glass .panel,
body.appearance-panel-glass .card,
body.appearance-panel-glass .filters,
body.appearance-panel-glass .sidebar,
body.appearance-panel-glass .appearance-control-group,
body.appearance-panel-glass .appearance-preview,
body.appearance-panel-glass .message,
body.appearance-panel-glass .room-card,
body.appearance-panel-glass .event-card,
body.appearance-panel-glass .group-card,
body.appearance-panel-glass .marketplace-card,
body.appearance-panel-glass .oracle-reader-card,
body.appearance-panel-glass .profile-message-drawer,
body.appearance-panel-glass .oracle-apply-drawer,
body.appearance-panel-glass .question-compare-drawer,
body.appearance-panel-glass .pwa-install-banner {
  background: linear-gradient(
    145deg,
    color-mix(in srgb, var(--panel-glass-tint) var(--panel-glass-opacity), transparent),
    color-mix(in srgb, var(--panel-glass-tint) var(--panel-glass-opacity), rgba(0, 0, 0, 0.08))
  ) !important;
  border-color: color-mix(in srgb, var(--panel-glass-tint) 42%, var(--border));
  backdrop-filter: blur(var(--panel-glass-blur)) saturate(1.08);
  -webkit-backdrop-filter: blur(var(--panel-glass-blur)) saturate(1.08);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  body.appearance-panel-glass .hero,
  body.appearance-panel-glass .panel,
  body.appearance-panel-glass .card,
  body.appearance-panel-glass .filters,
  body.appearance-panel-glass .sidebar,
  body.appearance-panel-glass .profile-message-drawer,
  body.appearance-panel-glass .oracle-apply-drawer,
  body.appearance-panel-glass .question-compare-drawer {
    background: color-mix(in srgb, var(--panel-glass-tint) var(--panel-glass-opacity), var(--panel)) !important;
  }
}

@media (min-width: 861px) and (max-width: 1260px) {
  .messages-workspace {
    grid-template-columns: minmax(220px, 300px) minmax(0, 1fr);
  }

  .message-profile-panel {
    grid-column: 1 / -1;
  }

  .message-profile-panel .message-profile-photo {
    min-height: 280px;
    max-height: 440px;
  }
}

.marketplace-toolbar,
.marketplace-editor,
.marketplace-detail {
  display: grid;
  gap: 18px;
}

.marketplace-grid {
  align-items: stretch;
}

.marketplace-card {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 14px;
  min-height: 100%;
}

.marketplace-card-media {
  position: relative;
}

.marketplace-card-photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  object-fit: cover;
  background: color-mix(in srgb, var(--panel) 74%, var(--blue) 26%);
  border: 1px solid var(--blue-border);
}

.marketplace-card-photo.placeholder {
  display: grid;
  place-items: center;
  color: var(--text);
  font-weight: 800;
  letter-spacing: 0;
}

.marketplace-image-count {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.82);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}

.marketplace-card-body {
  display: grid;
  gap: 10px;
  align-content: start;
}

.marketplace-card-body h2,
.marketplace-detail-copy h2,
.marketplace-connector h2 {
  margin: 0;
  overflow-wrap: anywhere;
}

.marketplace-card-body p,
.marketplace-detail-copy p {
  overflow-wrap: anywhere;
}

.marketplace-price-row {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.marketplace-price-row strong,
.marketplace-detail-price {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  padding: 4px 10px;
  border: 1px solid #fecdd3;
  border-radius: 999px;
  background: #fff1f2;
  color: #7f1d1d;
  font-size: 20px;
  font-weight: 900;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.marketplace-table .button-row {
  justify-content: flex-end;
}

.marketplace-connector {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  align-content: start;
}

.marketplace-connector-live {
  border-color: color-mix(in srgb, var(--blue-border) 65%, #55d6be 35%);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--panel) 95%, var(--blue) 5%), color-mix(in srgb, var(--panel) 94%, #55d6be 6%));
}

.marketplace-connector-copy,
.marketplace-connector-actions,
.marketplace-connector-meta {
  display: grid;
  gap: 10px;
}

.marketplace-connector-copy > p,
.marketplace-connector-copy > .field {
  margin: 0;
}

.marketplace-connector-meta {
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
}

.marketplace-connector-meta span {
  padding: 8px 10px;
  border: 1px solid var(--blue-border);
  border-radius: 8px;
  background: color-mix(in srgb, var(--panel) 88%, var(--blue) 12%);
  font-size: 12px;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.marketplace-connector-actions {
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  width: 100%;
  min-width: 0;
  margin-top: auto;
}

.marketplace-connector-actions .btn {
  width: 100%;
  min-width: 0;
  padding-inline: 14px;
  text-align: center;
}

.marketplace-connector-connect .marketplace-connector-actions {
  grid-template-columns: 1fr;
}

.marketplace-connector-connect {
  border-color: color-mix(in srgb, var(--blue-border) 70%, var(--blue) 30%);
}

.marketplace-editor-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(112px, 1fr));
  gap: 10px;
}

.marketplace-editor-thumb {
  display: grid;
  gap: 8px;
}

.marketplace-editor-thumb img {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--blue-border);
}

.marketplace-detail {
  grid-template-columns: minmax(240px, 0.9fr) minmax(0, 1.1fr);
  align-items: start;
}

.marketplace-detail-media img,
.marketplace-detail-media .marketplace-card-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--blue-border);
}

.marketplace-detail-gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.marketplace-detail-gallery img {
  aspect-ratio: 1 / 1;
}

.marketplace-detail-copy {
  display: grid;
  gap: 14px;
}

.seller-strip {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid var(--blue-border);
  background: color-mix(in srgb, var(--panel) 82%, var(--blue) 18%);
}

.danger-text {
  color: var(--red);
}

@media (max-width: 860px) {
  .marketplace-detail,
  .marketplace-connector {
    grid-template-columns: 1fr;
  }

  .marketplace-connector-meta {
    grid-template-columns: 1fr;
  }

  .marketplace-connector-actions {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }

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

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

  .recommendation-category-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .marketplace-table .button-row,
  .marketplace-price-row,
  .seller-strip {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .menu-float {
    top: 10px;
    left: 10px;
    z-index: 40;
  }

  .sidebar,
  .sidebar-collapsed .sidebar {
    width: 100vw;
    max-width: 100vw;
    padding: 72px 18px 22px;
  }

  .sidebar {
    transform: translateX(0);
  }

  .sidebar-collapsed .sidebar {
    transform: translateX(-100%);
  }

  .brand img {
    width: 170px;
  }

  .nav {
    width: 100%;
  }

  .nav a,
  .theme-toggle {
    width: 100% !important;
    max-width: 100% !important;
  }

  .main {
    padding: 64px 14px 116px;
  }

  .profile-completion-head {
    display: grid;
  }

  .profile-completion-head .btn {
    width: 100%;
  }

  .profile-completion-checklist {
    grid-template-columns: 1fr;
  }

  .recommendation-grid {
    grid-template-columns: 1fr;
  }

  .recommendation-people-grid {
    grid-template-columns: 1fr;
  }

  .dashboard-recommendations-stack {
    gap: 14px;
  }

  .recommendation-category-head,
  .recommendation-category-title {
    align-items: flex-start;
  }

  .recommendation-category-title {
    gap: 11px;
  }

  .recommendation-category-icon {
    flex-basis: 42px;
    width: 42px;
    height: 42px;
    border-radius: 13px;
    font-size: 17px;
  }

  .recommendation-category-list {
    grid-template-columns: 1fr;
  }

  .recommendation-category-panel .recommendation-item {
    min-height: 0;
  }

  .recommendation-browse-button {
    width: 100%;
  }

  .recommendation-member-card {
    padding: 14px;
  }

  .recommendation-member-card .recommendation-actions .btn {
    flex: 1 1 auto;
  }

  .friend-online-toasts {
    bottom: calc(86px + env(safe-area-inset-bottom, 0px));
  }

  .pwa-install-banner {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: 12px;
    z-index: 42;
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) auto auto;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border: 1px solid var(--blue-border);
    border-radius: 14px;
    background: color-mix(in srgb, var(--panel) 94%, #000 6%);
    box-shadow: 0 18px 42px var(--shadow);
  }

  .pwa-install-banner img {
    width: 44px;
    height: 44px;
    border-radius: 8px;
    object-fit: cover;
  }

  .pwa-install-banner div {
    min-width: 0;
    display: grid;
    gap: 2px;
  }

  .pwa-install-banner strong,
  .pwa-install-banner span,
  .pwa-install-banner em {
    overflow-wrap: anywhere;
  }

  .pwa-install-banner strong {
    color: var(--text);
    font-size: 14px;
    line-height: 1.15;
  }

  .pwa-install-banner span,
  .pwa-install-banner em {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
    line-height: 1.25;
  }

  .pwa-install-banner .btn.small,
  .pwa-install-banner .tiny-btn {
    margin: 0;
    white-space: nowrap;
  }
}

@media (max-width: 860px) {
  .app-shell {
    transition: none;
  }

  .friend-online-toast,
  .direct-message-toast {
    animation: none;
  }

  .l2c-preloader,
  .l2c-preloader *,
  .l2c-preloader::before,
  .l2c-preloader::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focused room chat interface */
.room-mobile-head,
.room-message-more {
  display: none;
}

@media (min-width: 641px) {
  .room-chat-console .live-bubble {
    position: relative;
    padding-right: calc(var(--chat-box-padding) + 36px);
  }

  .room-chat-console .room-message-more {
    position: absolute;
    top: max(4px, var(--chat-box-padding));
    right: max(4px, var(--chat-box-padding));
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: color-mix(in srgb, var(--input) 84%, transparent);
    color: var(--muted);
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
  }

  .room-chat-console .live-actions {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    z-index: 7;
    width: max-content;
    max-width: min(520px, calc(100vw - 120px));
    box-sizing: border-box;
    padding: 8px;
    border: 1px solid var(--border-soft);
    border-radius: 10px;
    background: color-mix(in srgb, var(--panel) 96%, #101722 4%);
    box-shadow: 0 12px 32px rgba(0, 0, 0, .3);
    overflow: hidden;
  }

  .room-chat-console .live-message.actions-open .live-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 6px;
  }

  .room-chat-console .live-message.actions-open .live-bubble {
    z-index: 6;
  }

  .room-chat-console .live-actions > .tiny-btn:first-of-type,
  .room-chat-console .live-actions .message-actions,
  .room-chat-console .live-actions .safety-controls {
    margin-left: 0;
  }

  .room-chat-console .live-actions .translation-note.original-note {
    flex: 1 1 100%;
    width: 100%;
    margin-top: 0;
  }

  body.chat-hide-actions .room-chat-console .live-bubble {
    padding-right: var(--chat-box-padding);
  }
}

.room-chat-composer {
  grid-template-columns: 44px minmax(0, 1fr) 50px;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--border-soft);
  border-radius: 24px;
  background: color-mix(in srgb, var(--panel) 88%, transparent);
}

.room-attach-button,
.room-send-button,
.room-mobile-back,
.room-mobile-settings {
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.room-attach-button {
  width: 44px;
  height: 44px;
}

.room-attach-button:disabled {
  opacity: 1;
  cursor: default;
}

.room-attach-button svg,
.room-send-button svg,
.room-mobile-settings svg,
.chat-display-option-icon svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.room-composer-field {
  min-width: 0;
  position: relative;
}

.room-chat-composer .room-composer-field input {
  min-height: 46px;
  padding: 0 54px 0 16px;
  border-radius: 23px;
}

.room-composer-field > span {
  position: absolute;
  top: 50%;
  right: 16px;
  translate: 0 -50%;
  color: var(--subtle);
  font-size: 12px;
  pointer-events: none;
}

.room-mention-menu {
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(100% + 10px);
  z-index: 45;
  max-height: min(320px, 52vh);
  overflow-y: auto;
  padding: 8px;
  border: 1px solid rgba(38, 190, 236, 0.42);
  border-radius: 16px;
  background: rgba(5, 25, 35, 0.98);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(18px);
}

.room-mention-menu[hidden],
.room-mention-menu [hidden] {
  display: none !important;
}

.room-mention-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 7px 8px;
  color: #eafaff;
}

.room-mention-menu-head span {
  color: #8eb8c4;
  font-size: 0.75rem;
}

.room-mention-menu > button {
  width: 100%;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border: 0;
  border-radius: 11px;
  color: #effcff;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.room-mention-menu > button:hover,
.room-mention-menu > button[aria-selected="true"] {
  background: rgba(24, 163, 211, 0.2);
  outline: 1px solid rgba(57, 199, 240, 0.34);
}

.room-mention-avatar {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #041820;
  background: linear-gradient(145deg, #91ebff, #28bde9);
  font-weight: 800;
}

.room-mention-menu > button > span:nth-child(2) {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.room-mention-menu > button small {
  overflow: hidden;
  color: #91bdc8;
  text-overflow: ellipsis;
}

.room-mention-menu > button em {
  color: #7bdcf4;
  font-size: 0.72rem;
  font-style: normal;
}

.room-mention-empty {
  margin: 0;
  padding: 12px 8px;
  color: #9fc3cc;
  text-align: center;
}

.room-send-button {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: linear-gradient(145deg, #238cff, #0759e8);
  color: #fff;
  box-shadow: 0 8px 20px rgba(16, 101, 238, 0.32);
}

.room-send-button:disabled {
  opacity: .46;
  cursor: not-allowed;
}

.chat-display-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  border: 0;
  background: rgba(0, 5, 12, .58);
  backdrop-filter: blur(3px);
}

.chat-display-sheet {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 121;
  width: min(100%, 590px);
  max-height: min(86dvh, 760px);
  overflow-y: auto;
  translate: -50% 0;
  padding: 12px 28px calc(28px + env(safe-area-inset-bottom, 0px));
  border: 1px solid var(--border-soft);
  border-bottom: 0;
  border-radius: 30px 30px 0 0;
  background: color-mix(in srgb, var(--panel) 96%, #101a26 4%);
  box-shadow: 0 -24px 70px rgba(0, 0, 0, .44);
  animation: chat-sheet-in .22s ease-out;
}

@keyframes chat-sheet-in {
  from { transform: translateY(24px); opacity: .55; }
}

.chat-sheet-grabber {
  width: 54px;
  height: 6px;
  margin: 0 auto 20px;
  border-radius: 999px;
  background: var(--subtle);
  opacity: .72;
}

.chat-sheet-heading h2 {
  margin: 0;
  font-size: 27px;
  line-height: 1.1;
}

.chat-sheet-heading p {
  margin: 8px 0 18px;
  color: var(--muted);
}

.chat-display-options {
  display: grid;
}

.chat-display-option {
  min-height: 66px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border-bottom: 1px solid var(--border-soft);
}

.chat-display-option:last-child {
  border-bottom: 0;
}

.chat-display-option-icon {
  display: grid;
  place-items: center;
  color: var(--muted);
}

.chat-display-option strong {
  font-size: 16px;
}

.chat-switch {
  width: 58px;
  height: 34px;
  padding: 4px;
  border: 0;
  border-radius: 999px;
  background: color-mix(in srgb, var(--input) 90%, #fff 10%);
  cursor: pointer;
  transition: background .18s ease;
}

.chat-switch span {
  display: block;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #dbe2eb;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .28);
  transition: translate .18s ease;
}

.chat-switch.is-on {
  background: #1877f2;
}

.chat-switch.is-on span {
  translate: 24px 0;
  background: #fff;
}

.chat-message-size {
  margin-top: 18px;
}

.chat-message-size > span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-weight: 800;
}

.chat-size-segments {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  overflow: hidden;
  border: 1px solid var(--border-soft);
  border-radius: 16px;
  background: var(--input);
}

.chat-size-segments button {
  min-height: 52px;
  border: 0;
  border-right: 1px solid var(--border-soft);
  background: transparent;
  color: var(--muted);
  font-weight: 850;
  cursor: pointer;
}

.chat-size-segments button:last-child {
  border-right: 0;
}

.chat-size-segments button.is-active {
  border-radius: 14px;
  background: linear-gradient(145deg, #238cff, #0759e8);
  color: #fff;
}

.chat-sheet-actions {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-top: 26px;
}

.chat-reset-button,
.chat-done-button {
  min-height: 48px;
  padding: 0 20px;
  border: 0;
  border-radius: 12px;
  font-weight: 850;
  cursor: pointer;
}

.chat-reset-button {
  padding-left: 4px;
  background: transparent;
  color: #3d98ff;
}

.chat-done-button {
  min-width: 132px;
  background: linear-gradient(145deg, #238cff, #0759e8);
  color: #fff;
}

body.chat-hide-date-stamp .room-chat-console .live-meta > span:last-child {
  display: none;
}

body.chat-hide-profile .chat-window .live-meta .moderator-name,
body.chat-hide-profile .compact-chat .live-meta .moderator-name,
body.chat-hide-profile .direct-thread .live-meta .moderator-name {
  display: inline-flex;
}

@media (max-width: 640px) {
  .page:has(.room-chat-console:not(.room-chat-mobile-hidden)) > .hero,
  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .menu-float,
  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .footer-nav,
  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .pwa-install-banner {
    display: none !important;
  }

  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .sidebar {
    transform: translateX(-100%) !important;
    opacity: 0;
    pointer-events: none;
  }

  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .app-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .main {
    grid-column: 1;
  }

  .main:has(.room-chat-console:not(.room-chat-mobile-hidden)) {
    padding-top: 0;
  }

  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .room-overview-stats,
  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .room-overview-create,
  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .room-overview-owned,
  body:has(.room-chat-console:not(.room-chat-mobile-hidden)) .room-directory-grid,
  .room-chat-console > .chat-side,
  .room-chat-console .chat-head-copy,
  .room-chat-console .chat-head-actions,
  .room-chat-console > .chat-main > .translation-toolbar,
  .room-chat-console > .chat-main > .settings-panel,
  .room-chat-console > .chat-main > .token-cost-preview-shell,
  .room-chat-console > .chat-main > .token-cost-preview {
    display: none !important;
  }

  .room-chat-console {
    display: block;
    margin: 0 -14px -116px;
  }

  .room-chat-console.room-chat-mobile-hidden {
    display: none;
  }

  .room-chat-console > .chat-main {
    min-height: calc(100dvh - 64px);
    gap: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: color-mix(in srgb, var(--bg) 96%, #07111d 4%);
    box-shadow: none;
    backdrop-filter: none;
  }

  .room-chat-console .chat-head {
    position: sticky;
    top: 0;
    z-index: 6;
    display: block;
    border-bottom: 1px solid var(--border-soft);
    background: color-mix(in srgb, var(--panel) 95%, transparent);
    backdrop-filter: blur(18px);
  }

  .room-mobile-head {
    min-height: 76px;
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) 52px;
    align-items: center;
    padding: 10px 10px;
  }

  .room-mobile-head h2 {
    margin: 0;
    font-size: 21px;
    line-height: 1.1;
  }

  .room-mobile-head p {
    display: flex;
    gap: 8px;
    align-items: center;
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 13px;
  }

  .room-mobile-head p span {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #21c85a;
    box-shadow: 0 0 0 3px rgba(33, 200, 90, .1);
  }

  .room-mobile-back,
  .room-mobile-settings {
    width: 44px;
    height: 44px;
    color: var(--text);
  }

  .room-mobile-back span {
    font-size: 34px;
    font-weight: 300;
    line-height: 1;
  }

  .room-chat-console .chat-window {
    min-height: calc(100dvh - 76px);
    max-height: calc(100dvh - 76px);
    flex: 1 1 auto;
    gap: 18px;
    padding: 22px 16px 96px;
    border: 0;
    border-radius: 0;
    background: transparent;
    scrollbar-width: none;
  }

  .room-chat-console .chat-window::-webkit-scrollbar {
    display: none;
  }

  .room-chat-console .live-message,
  .room-chat-console .live-message.mine {
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 9px;
  }

  .room-chat-console .live-message > .live-avatar {
    width: 34px;
    height: 34px;
    aspect-ratio: 1;
    border-radius: 50%;
  }

  .room-chat-console .live-avatar.profile-photo-avatar,
  .room-chat-console .live-avatar.profile-photo-avatar img {
    border-radius: 50%;
  }

  .room-chat-console .live-bubble {
    position: relative;
    width: fit-content;
    max-width: calc(100vw - 82px);
    padding: 0 30px 0 0;
    border: 0;
    background: transparent;
  }

  .room-chat-console .live-meta {
    min-height: 22px;
    justify-content: flex-start;
    gap: 7px;
    color: var(--subtle);
  }

  .room-chat-console .live-meta .moderator-name {
    padding-inline-start: var(--chat-box-padding);
  }

  .room-chat-console .moderator-name,
  .room-chat-console .moderator-name strong {
    color: #61a9ff;
    font-size: 14px;
  }

  .room-chat-console .plate-badge {
    min-height: 18px;
    padding: 1px 5px;
    font-size: 9px;
  }

  .room-chat-console .message-translation-primary,
  .room-chat-console .deleted-message-body {
    width: fit-content;
    max-width: 100%;
    margin-top: 3px;
    padding: var(--chat-box-padding);
    border: 1px solid var(--border-soft);
    border-radius: var(--chat-box-border-radius);
    background: color-mix(in srgb, var(--input) 88%, #243447 12%);
    color: var(--text);
    font-weight: 650;
    line-height: 1.38;
  }

  .room-chat-console .live-message.mine .message-translation-primary {
    border-color: var(--blue-border);
    background: color-mix(in srgb, var(--blue) 88%, #1b4f90 12%);
  }

  .room-message-more {
    position: absolute;
    top: 21px;
    right: 0;
    width: 28px;
    height: 42px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 24px;
    cursor: pointer;
  }

  .room-chat-console .live-actions {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: auto;
    z-index: 7;
    width: max-content;
    max-width: min(280px, calc(100vw - 88px));
    box-sizing: border-box;
    margin: 0;
    padding: 4px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: color-mix(in srgb, var(--panel) 96%, #101722 4%);
    box-shadow: 0 10px 28px rgba(0, 0, 0, .28);
    overflow: hidden;
  }

  .room-chat-console .live-message.actions-open .live-actions {
    display: flex;
    align-items: stretch;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 4px;
  }

  .room-chat-console .live-message.actions-open .live-bubble {
    z-index: 6;
  }

  body.chat-hide-actions .room-chat-console .live-bubble {
    padding-right: 0;
  }

  .room-chat-console .live-actions .tiny-btn {
    flex: 0 0 auto;
    width: auto;
    min-width: 0;
    max-width: 100%;
    min-height: 32px;
    padding: 0 10px;
    border-radius: 6px;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .room-chat-console .live-actions .tiny-btn.delete-link {
    padding: 0 10px;
    border: 1px solid var(--border-soft);
    background: var(--input);
  }

  .room-chat-console .translation-note.original-note {
    flex: 1 1 100%;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    margin: 0;
    padding: 4px 6px;
    border: 0;
    background: transparent;
  }

  body.chat-hide-profile .room-chat-console .live-message,
  body.chat-hide-profile .room-chat-console .live-message.mine {
    grid-template-columns: minmax(0, 1fr);
  }

  body.chat-hide-profile .room-chat-console .live-bubble {
    max-width: calc(100vw - 32px);
  }

  .room-chat-composer {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    z-index: 8;
    min-height: 66px;
    border-radius: 34px;
    background: color-mix(in srgb, var(--panel) 94%, transparent);
    box-shadow: 0 14px 36px rgba(0, 0, 0, .32);
    backdrop-filter: blur(18px);
  }

  .chat-display-sheet {
    width: 100%;
    padding: 12px 20px calc(24px + env(safe-area-inset-bottom, 0px));
    border-left: 0;
    border-right: 0;
  }

  .chat-sheet-heading h2 {
    font-size: 25px;
  }

  .chat-size-segments button {
    min-width: 0;
    padding: 0 6px;
    font-size: 13px;
  }

  .chat-sheet-actions {
    margin-top: 22px;
  }

  .chat-reset-button,
  .chat-done-button {
    padding: 0 14px;
  }
}

/* Colour-led profile showcase */
.profile-showcase {
  position: relative;
  overflow: hidden;
  padding: clamp(18px, 3vw, 30px);
  border-color: color-mix(in srgb, #ff5c88 30%, var(--border));
  background:
    radial-gradient(circle at 92% 4%, rgba(255, 92, 136, .17), transparent 34%),
    radial-gradient(circle at 8% 100%, rgba(93, 169, 255, .14), transparent 38%),
    color-mix(in srgb, var(--panel) 94%, transparent);
  box-shadow: 0 20px 48px rgba(0, 0, 0, .18);
}

.profile-showcase-member.vip-member-card {
  border-color: color-mix(in srgb, #d7ad55 50%, var(--border));
  background:
    radial-gradient(circle at 92% 4%, rgba(215, 173, 85, .13), transparent 36%),
    radial-gradient(circle at 8% 100%, rgba(93, 169, 255, .08), transparent 38%),
    color-mix(in srgb, var(--panel) 95%, rgba(215, 173, 85, .05));
  box-shadow: 0 20px 48px rgba(0, 0, 0, .2), inset 0 0 0 1px rgba(215, 173, 85, .04);
}

.profile-showcase-member.vip-lifetime-card {
  box-shadow: 0 20px 48px rgba(0, 0, 0, .2), inset 0 0 0 1px rgba(235, 204, 126, .12);
}

.profile-showcase-member.member-mode-chatable:not(.vip-member-card) {
  border-color: color-mix(in srgb, #5da9ff 46%, var(--border));
  background:
    radial-gradient(circle at 92% 4%, rgba(93, 169, 255, .14), transparent 36%),
    radial-gradient(circle at 8% 100%, rgba(75, 214, 210, .08), transparent 38%),
    color-mix(in srgb, var(--panel) 95%, rgba(93, 169, 255, .05));
}

.profile-showcase-member.member-mode-friendable:not(.vip-member-card) {
  border-color: color-mix(in srgb, #4bd6a2 44%, var(--border));
  background:
    radial-gradient(circle at 92% 4%, rgba(75, 214, 162, .14), transparent 36%),
    radial-gradient(circle at 8% 100%, rgba(93, 169, 255, .07), transparent 38%),
    color-mix(in srgb, var(--panel) 95%, rgba(75, 214, 162, .05));
}

.profile-showcase::after {
  position: absolute;
  right: -80px;
  bottom: -105px;
  width: 250px;
  height: 250px;
  border: 1px solid rgba(255, 255, 255, .055);
  border-radius: 50%;
  box-shadow: 0 0 0 34px rgba(255, 255, 255, .018), 0 0 0 68px rgba(255, 255, 255, .012);
  content: "";
  pointer-events: none;
}

.profile-showcase > * {
  position: relative;
  z-index: 1;
}

.profile-photo-stage,
.member-profile-media {
  position: relative;
  align-self: stretch;
}

.profile-showcase-own .profile-main-photo,
.profile-showcase-own .avatar,
.profile-showcase-member .member-profile-main-photo,
.profile-showcase-member .member-profile-avatar {
  border: 1px solid color-mix(in srgb, #ff658e 38%, var(--border));
  border-radius: 20px;
  box-shadow: 0 20px 46px rgba(0, 0, 0, .28);
}

.profile-showcase-member.vip-member-card .member-profile-main-photo,
.profile-showcase-member.vip-member-card .member-profile-avatar {
  border-color: color-mix(in srgb, #d7ad55 58%, var(--border));
}

.profile-showcase-member.member-mode-chatable:not(.vip-member-card) .member-profile-main-photo,
.profile-showcase-member.member-mode-chatable:not(.vip-member-card) .member-profile-avatar {
  border-color: color-mix(in srgb, #5da9ff 52%, var(--border));
}

.profile-showcase-member.member-mode-friendable:not(.vip-member-card) .member-profile-main-photo,
.profile-showcase-member.member-mode-friendable:not(.vip-member-card) .member-profile-avatar {
  border-color: color-mix(in srgb, #4bd6a2 50%, var(--border));
}

.profile-showcase-own .profile-main-photo,
.profile-showcase-own .avatar {
  max-width: none;
  min-height: 390px;
  object-fit: cover;
}

.profile-photo-review {
  position: absolute;
  right: 14px;
  bottom: 14px;
  left: 14px;
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 9px 11px;
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 999px;
  background: rgba(10, 13, 19, .78);
  color: #e7edf7;
  font-size: 11px;
  font-weight: 850;
  line-height: 1.2;
  backdrop-filter: blur(12px);
}

.profile-photo-review svg {
  width: 20px;
  flex: 0 0 20px;
  fill: none;
  stroke: #5da9ff;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.profile-photo-review.is-approved {
  border-color: rgba(75, 214, 162, .48);
  background: rgba(11, 58, 44, .82);
}

.profile-photo-review.is-approved svg { stroke: #67e8b9; }
.profile-photo-review.is-pending svg { stroke: #f6c85f; }
.profile-photo-review.is-rejected svg { stroke: #ff7d86; }

.profile-showcase-eyebrow {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  color: #ff8eaa;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.profile-showcase-eyebrow span:last-child {
  padding: 5px 8px;
  border: 1px solid color-mix(in srgb, #5da9ff 35%, var(--border));
  border-radius: 999px;
  background: rgba(93, 169, 255, .08);
  color: #aaceff;
  letter-spacing: .06em;
  text-transform: none;
}

.profile-showcase .profile-intro h2,
.profile-showcase .member-profile-details > h2 {
  font-size: clamp(34px, 5vw, 56px);
  letter-spacing: -.045em;
}

.profile-showcase .profile-bio,
.profile-showcase .member-profile-details > p {
  color: var(--muted);
}

.profile-showcase .profile-kicker .pill {
  border-color: color-mix(in srgb, #a58bff 28%, var(--border));
  background: rgba(165, 139, 255, .075);
}

.profile-showcase .profile-kicker .pill.gold {
  border-color: rgba(246, 200, 95, .42);
  background: rgba(246, 200, 95, .1);
  color: #ffe09a;
}

.profile-showcase .profile-quick-facts {
  gap: 9px;
}

.profile-showcase .profile-quick-facts span {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: rgba(255, 255, 255, .035);
}

.profile-showcase .profile-quick-facts span::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 2px;
  background: #ff658e;
  content: "";
}

.profile-showcase .profile-quick-facts span:nth-child(2)::before { background: #5da9ff; }
.profile-showcase .profile-quick-facts span:nth-child(3)::before { background: #a58bff; }
.profile-showcase .profile-quick-facts span:nth-child(4)::before { background: #4bd6a2; }

.profile-primary-actions .btn,
.profile-showcase .member-profile-details > .button-row .btn {
  min-height: 42px;
  border-radius: 12px;
}

.profile-colour-grid .panel,
.profile-interests-panel,
.profile-signals-panel,
.profile-story-panel,
.profile-connection-panel,
.profile-locked-panel,
.profile-gallery-panel {
  position: relative;
  overflow: hidden;
  border-radius: 16px;
}

.profile-colour-grid .panel::before,
.profile-interests-panel::before,
.profile-signals-panel::before,
.profile-story-panel::before,
.profile-connection-panel::before,
.profile-locked-panel::before,
.profile-gallery-panel::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, #ff658e, #ff9db6);
  content: "";
}

.profile-connection-panel::before { background: linear-gradient(90deg, #5da9ff, #83d3ff); }
.profile-interests-panel::before { background: linear-gradient(90deg, #a58bff, #e394ff); }
.profile-signals-panel::before { background: linear-gradient(90deg, #4bd6a2, #8fe8c5); }
.profile-gallery-panel::before { background: linear-gradient(90deg, #f6c85f, #ff8b6a); }
.profile-locked-panel::before { background: linear-gradient(90deg, #8f98a8, #5da9ff); }

.profile-story-panel {
  background: radial-gradient(circle at 100% 0, rgba(255, 101, 142, .09), transparent 36%), var(--panel-surface);
}

.profile-connection-panel {
  background: radial-gradient(circle at 100% 0, rgba(93, 169, 255, .1), transparent 36%), var(--panel-surface);
}

.profile-interests-panel {
  background: radial-gradient(circle at 100% 0, rgba(165, 139, 255, .1), transparent 36%), var(--panel-surface);
}

.profile-signals-panel {
  background: radial-gradient(circle at 100% 0, rgba(75, 214, 162, .09), transparent 36%), var(--panel-surface);
}

.profile-panel-kicker {
  display: block;
  margin-bottom: 7px;
  color: #ff8eaa;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.profile-connection-panel .profile-panel-kicker { color: #8fc4ff; }
.profile-interests-panel .profile-panel-kicker { color: #c2b3ff; }
.profile-signals-panel .profile-panel-kicker { color: #73dfb8; }
.profile-locked-panel .profile-panel-kicker { color: #aaceff; }

.profile-gallery-panel .profile-gallery-grid .photo-card {
  overflow: hidden;
  border: 1px solid color-mix(in srgb, #f6c85f 28%, var(--border));
  border-radius: 14px;
  box-shadow: 0 13px 28px rgba(0, 0, 0, .17);
}

.profile-gallery-panel .profile-gallery-grid img {
  transition: transform .25s ease;
}

.profile-gallery-panel .profile-gallery-grid .photo-card:hover img {
  transform: scale(1.025);
}

.member-profile-media {
  overflow: visible;
}

.member-match-medallion {
  position: absolute;
  right: 16px;
  bottom: 16px;
  display: grid;
  width: 82px;
  height: 82px;
  place-items: center;
  align-content: center;
  border: 2px solid rgba(255, 255, 255, .66);
  border-radius: 50%;
  background: conic-gradient(from 210deg, rgba(255, 92, 136, .94), rgba(165, 139, 255, .94), rgba(93, 169, 255, .94));
  color: #fff;
  box-shadow: 0 13px 34px rgba(0, 0, 0, .36);
  text-align: center;
}

.member-match-medallion strong {
  font-size: 21px;
  line-height: 1;
}

.member-match-medallion small {
  margin-top: 3px;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.member-match-medallion.good-match-medallion {
  border-color: #ffd7df;
  background: radial-gradient(circle at 32% 24%, #ff748f, var(--red) 58%, #7a001c);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--red) 52%, transparent), 0 0 28px color-mix(in srgb, var(--red) 66%, transparent), 0 13px 34px rgba(0, 0, 0, .36);
}

.profile-showcase-member .profile-achievements {
  border-color: color-mix(in srgb, #a58bff 28%, var(--border));
  background: rgba(165, 139, 255, .055);
}

body[data-theme="day"] .profile-showcase,
body[data-theme="day"] .profile-story-panel,
body[data-theme="day"] .profile-connection-panel,
body[data-theme="day"] .profile-interests-panel,
body[data-theme="day"] .profile-signals-panel {
  box-shadow: 0 14px 32px rgba(27, 40, 63, .08);
}

body[data-theme="day"] .profile-photo-review {
  background: rgba(20, 28, 42, .8);
  color: #fff;
}

body[data-theme="day"] .profile-showcase .profile-kicker .pill.gold {
  color: #7d4e00;
}

@media (max-width: 860px) {
  .profile-showcase-own,
  .profile-showcase-member {
    grid-template-columns: 1fr;
  }

  .profile-showcase-own .profile-main-photo,
  .profile-showcase-own .avatar,
  .profile-showcase-member .member-profile-main-photo,
  .profile-showcase-member .member-profile-avatar {
    width: 100%;
    max-width: none;
    min-height: 0;
    aspect-ratio: 4 / 5;
  }
}

@media (max-width: 640px) {
  .profile-showcase {
    padding: 14px;
    border-radius: 18px;
  }

  .profile-showcase .profile-quick-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-photo-review {
    right: 10px;
    bottom: 10px;
    left: 10px;
  }

  .member-match-medallion {
    right: 12px;
    bottom: 12px;
    width: 70px;
    height: 70px;
  }
}

/* Colour-led member dashboard */
.dashboard-welcome-showcase {
  position: relative;
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 142px;
  gap: clamp(20px, 3vw, 34px);
  align-items: center;
  overflow: hidden;
  padding: clamp(22px, 4vw, 38px);
  border-color: color-mix(in srgb, #ff5c88 34%, var(--border));
  border-radius: 22px;
  background:
    radial-gradient(circle at 92% 8%, rgba(255, 92, 136, .2), transparent 34%),
    radial-gradient(circle at 7% 100%, rgba(93, 169, 255, .16), transparent 38%),
    color-mix(in srgb, var(--panel) 94%, transparent);
  box-shadow: 0 22px 52px rgba(0, 0, 0, .2);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.dashboard-welcome-showcase:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, #ff5c88 62%, var(--border));
  box-shadow: 0 26px 58px rgba(0, 0, 0, .24);
}

.dashboard-welcome-showcase::after {
  position: absolute;
  right: -76px;
  bottom: -106px;
  width: 250px;
  height: 250px;
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 50%;
  box-shadow: 0 0 0 34px rgba(255, 255, 255, .018), 0 0 0 68px rgba(255, 255, 255, .012);
  content: "";
  pointer-events: none;
}

.dashboard-welcome-showcase > * {
  position: relative;
  z-index: 1;
}

.dashboard-welcome-visual {
  position: relative;
  width: 150px;
  height: 184px;
}

.dashboard-welcome-visual img,
.dashboard-welcome-avatar {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  border: 1px solid color-mix(in srgb, #ff658e 45%, var(--border));
  border-radius: 20px;
  background:
    radial-gradient(circle at 65% 20%, rgba(255, 255, 255, .16), transparent 28%),
    linear-gradient(145deg, #753c88, #365a92);
  box-shadow: 0 18px 42px rgba(0, 0, 0, .32);
  color: #fff;
  font-size: 60px;
  font-weight: 900;
  object-fit: cover;
}

.dashboard-presence-dot {
  position: absolute;
  right: -5px;
  bottom: 18px;
  width: 20px;
  height: 20px;
  border: 4px solid var(--panel);
  border-radius: 50%;
  background: #4bd6a2;
  box-shadow: 0 0 16px rgba(75, 214, 162, .58);
}

.dashboard-welcome-copy {
  display: grid;
  min-width: 0;
  gap: 12px;
}

.dashboard-welcome-eyebrow {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 14px;
  color: #ff8eaa;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.dashboard-welcome-copy h2 {
  margin: 0;
  font-size: clamp(34px, 5vw, 54px);
  font-weight: 400;
  line-height: .98;
  letter-spacing: -.045em;
}

.dashboard-welcome-copy h2 strong {
  color: #fff;
  font-weight: 900;
}

.dashboard-welcome-copy > p {
  max-width: 56ch;
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.dashboard-welcome-copy .profile-achievements {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.dashboard-welcome-copy .profile-achievements-label {
  display: none;
}

.dashboard-welcome-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.dashboard-welcome-pills span {
  padding: 7px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: rgba(255, 255, 255, .045);
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.dashboard-welcome-pills span:nth-child(1) { border-color: rgba(246, 200, 95, .32); }
.dashboard-welcome-pills span:nth-child(2) { border-color: rgba(93, 169, 255, .34); }
.dashboard-welcome-pills span:nth-child(3) { border-color: rgba(165, 139, 255, .34); }

.dashboard-welcome-pills strong {
  color: var(--text);
  font-size: 13px;
}

.dashboard-unread-messages {
  display: grid;
  gap: 8px;
  max-width: 660px;
  padding: 12px;
  border: 1px solid rgba(93, 169, 255, .3);
  border-radius: 14px;
  background: rgba(13, 28, 48, .46);
}

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

.dashboard-unread-head > strong {
  font-size: 13px;
}

.dashboard-unread-head > span {
  color: #8fc7ff;
  font-size: 11px;
  font-weight: 800;
}

.dashboard-unread-list {
  display: grid;
  gap: 6px;
}

.dashboard-unread-list > button {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border-soft);
  border-radius: 11px;
  background: rgba(255, 255, 255, .045);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.dashboard-unread-list > button:hover {
  border-color: var(--blue-border);
  background: var(--blue);
}

.dashboard-unread-avatar {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 9px;
  background: var(--blue);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}

.dashboard-unread-list > button > span:nth-child(2) {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.dashboard-unread-list small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dashboard-unread-list em {
  display: grid;
  min-width: 24px;
  min-height: 24px;
  place-items: center;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

body[data-theme="day"] .dashboard-unread-messages {
  background: rgba(239, 247, 255, .9);
}

.dashboard-welcome-actions {
  margin-top: 2px;
}

.dashboard-welcome-actions .btn {
  min-height: 42px;
  border-radius: 12px;
}

.dashboard-completion-orbit {
  --dashboard-progress: 0%;
  position: relative;
  display: grid;
  width: 142px;
  height: 142px;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(#ff5c88 var(--dashboard-progress), rgba(255, 255, 255, .1) 0);
  box-shadow: 0 18px 54px rgba(0, 0, 0, .28), 0 0 36px rgba(240, 77, 120, .16);
}

.dashboard-completion-orbit::before {
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: inherit;
  background: var(--panel);
  content: "";
}

.dashboard-completion-orbit div {
  position: relative;
  display: grid;
  gap: 2px;
  text-align: center;
}

.dashboard-completion-orbit strong {
  font-size: 31px;
  letter-spacing: -.04em;
}

.dashboard-completion-orbit span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.dashboard-page > .profile-completion-panel {
  position: relative;
  overflow: hidden;
  border-color: color-mix(in srgb, #a58bff 26%, var(--border));
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0, rgba(165, 139, 255, .1), transparent 34%),
    var(--panel-surface);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.dashboard-page > .profile-completion-panel:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, #a58bff 58%, var(--border));
  box-shadow: 0 20px 42px rgba(0, 0, 0, .2);
}

.dashboard-page > .profile-completion-panel::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, #ff658e, #a58bff, #5da9ff);
  content: "";
}

.dashboard-page > .profile-completion-panel .profile-completion-meter {
  height: 8px;
  background: rgba(255, 255, 255, .07);
}

.dashboard-page > .profile-completion-panel .profile-completion-meter span {
  background: linear-gradient(90deg, #ff658e, #a58bff, #5da9ff, #4bd6a2);
  box-shadow: 0 0 15px rgba(165, 139, 255, .35);
}

.dashboard-metrics-grid {
  align-items: stretch;
}

.dashboard-metric-card {
  --dashboard-card-accent: #ff658e;
  position: relative;
  display: flex;
  min-width: 0;
  min-height: 282px;
  flex-direction: column;
  align-items: stretch;
  overflow: hidden;
  border-color: color-mix(in srgb, var(--dashboard-card-accent) 30%, var(--border));
  border-radius: 18px;
  background:
    radial-gradient(circle at 92% 3%, color-mix(in srgb, var(--dashboard-card-accent) 18%, transparent), transparent 38%),
    var(--panel-surface);
  box-shadow: 0 14px 34px rgba(0, 0, 0, .14);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.dashboard-metric-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--dashboard-card-accent), color-mix(in srgb, var(--dashboard-card-accent) 35%, white));
  content: "";
}

.dashboard-metric-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--dashboard-card-accent) 62%, var(--border));
  box-shadow: 0 20px 42px rgba(0, 0, 0, .2);
}

.dashboard-tone-gold { --dashboard-card-accent: #f6c85f; }
.dashboard-tone-blue { --dashboard-card-accent: #5da9ff; }
.dashboard-tone-violet { --dashboard-card-accent: #a58bff; }
.dashboard-tone-mint { --dashboard-card-accent: #4bd6a2; }
.dashboard-tone-coral { --dashboard-card-accent: #ff8b6a; }
.dashboard-tone-rose { --dashboard-card-accent: #ff658e; }

.dashboard-card-top {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  margin-bottom: 18px;
}

.dashboard-card-icon {
  display: grid;
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--dashboard-card-accent) 46%, transparent);
  border-radius: 14px;
  background: color-mix(in srgb, var(--dashboard-card-accent) 14%, transparent);
  color: var(--dashboard-card-accent);
}

.dashboard-card-icon svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.dashboard-card-kicker {
  color: color-mix(in srgb, var(--dashboard-card-accent) 78%, white);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .1em;
  text-align: right;
  text-transform: uppercase;
}

.dashboard-metric-card h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 750;
}

.dashboard-metric-card h2 strong {
  display: inline-block;
  margin-top: 4px;
  color: var(--text);
  font-size: clamp(28px, 4vw, 38px);
  letter-spacing: -.04em;
}

.dashboard-metric-card p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
}

.dashboard-metric-card .dashboard-actions {
  margin-top: auto;
  padding-top: 16px;
}

.dashboard-metric-card .dashboard-actions .btn {
  min-height: 38px;
  border-radius: 11px;
}

.dashboard-split-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.dashboard-split-metrics span {
  display: grid;
  gap: 3px;
  padding: 12px;
  border: 1px solid color-mix(in srgb, var(--dashboard-card-accent) 25%, var(--border));
  border-radius: 12px;
  background: color-mix(in srgb, var(--dashboard-card-accent) 7%, transparent);
}

.dashboard-split-metrics small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.dashboard-split-metrics strong {
  color: var(--text);
  font-size: 28px;
  letter-spacing: -.035em;
}

.dashboard-metric-card .room-mini-list {
  margin-top: 12px;
}

.dashboard-metric-card .room-mini-list button {
  border-color: color-mix(in srgb, var(--dashboard-card-accent) 24%, var(--border));
  background: color-mix(in srgb, var(--dashboard-card-accent) 7%, var(--input));
}

.dashboard-page .recommendation-panel,
.dashboard-page .profile-stream-composer,
.dashboard-page .profile-stream-panel,
.dashboard-page .dashboard-wide,
.dashboard-page .dashboard-grid-small .dashboard-card {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  box-shadow: 0 13px 30px rgba(0, 0, 0, .12);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.dashboard-page .profile-stream-composer:hover,
.dashboard-page .profile-stream-panel:hover,
.dashboard-page > .dashboard-wide:hover,
.dashboard-page .dashboard-grid-small .dashboard-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--page-accent, #5da9ff) 55%, var(--border));
  box-shadow: 0 20px 42px rgba(0, 0, 0, .2);
}

.dashboard-page .recommendation-panel::before,
.dashboard-page .profile-stream-composer::before,
.dashboard-page .profile-stream-panel::before,
.dashboard-page .dashboard-wide::before,
.dashboard-page .dashboard-grid-small .dashboard-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  content: "";
}

.dashboard-page .recommendation-panel::before { background: linear-gradient(90deg, #a58bff, #e394ff); }
.dashboard-page .recommendation-category-panel::before { background: linear-gradient(90deg, var(--recommendation-accent), color-mix(in srgb, var(--recommendation-accent) 52%, white)); }
.dashboard-page .profile-stream-composer::before { background: linear-gradient(90deg, #5da9ff, #83d3ff); }
.dashboard-page .profile-stream-panel::before { background: linear-gradient(90deg, #4bd6a2, #8fe8c5); }
.dashboard-page .dashboard-wide::before { background: linear-gradient(90deg, #ff8b6a, #ff658e); }
.dashboard-page .dashboard-grid-small .dashboard-card:nth-child(1)::before { background: linear-gradient(90deg, #ff658e, #ff9db6); }
.dashboard-page .dashboard-grid-small .dashboard-card:nth-child(2)::before { background: linear-gradient(90deg, #5da9ff, #83d3ff); }
.dashboard-page .dashboard-grid-small .dashboard-card:nth-child(3)::before { background: linear-gradient(90deg, #a58bff, #e394ff); }
.dashboard-page .dashboard-grid-small .dashboard-card:nth-child(4)::before { background: linear-gradient(90deg, #4bd6a2, #8fe8c5); }

body[data-theme="day"] .dashboard-welcome-showcase,
body[data-theme="day"] .dashboard-metric-card,
body[data-theme="day"] .dashboard-page > .profile-completion-panel {
  box-shadow: 0 14px 34px rgba(27, 40, 63, .09);
}

body[data-theme="day"] .dashboard-welcome-copy h2 strong {
  color: var(--text);
}

body[data-theme="day"] .dashboard-completion-orbit::before {
  background: #fff;
}

body[data-theme="day"] .dashboard-card-kicker {
  color: color-mix(in srgb, var(--dashboard-card-accent) 72%, #182032);
}

@media (max-width: 920px) {
  .dashboard-welcome-showcase {
    grid-template-columns: 130px minmax(0, 1fr);
  }

  .dashboard-welcome-visual {
    width: 130px;
    height: 160px;
  }

  .dashboard-completion-orbit {
    grid-column: 1 / -1;
    justify-self: end;
    width: 112px;
    height: 112px;
    margin-top: -126px;
  }

  .dashboard-completion-orbit strong {
    font-size: 25px;
  }
}

@media (max-width: 700px) {
  .dashboard-welcome-showcase {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 16px;
  }

  .dashboard-welcome-visual {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }

  .dashboard-welcome-visual img,
  .dashboard-welcome-avatar {
    border-radius: 16px;
  }

  .dashboard-welcome-copy h2 {
    font-size: clamp(32px, 11vw, 44px);
  }

  .dashboard-completion-orbit {
    position: absolute;
    top: 108px;
    right: 28px;
    width: 92px;
    height: 92px;
    margin: 0;
    border: 1px solid rgba(255, 255, 255, .16);
    box-shadow: 0 12px 34px rgba(0, 0, 0, .38), 0 0 28px rgba(240, 77, 120, .2);
  }

  .dashboard-completion-orbit::before {
    inset: 6px;
  }

  .dashboard-completion-orbit strong {
    font-size: 22px;
  }

  .dashboard-welcome-actions .btn {
    flex: 1 1 145px;
  }
}

@media (max-width: 640px) {
  .dashboard-page {
    gap: 14px;
  }

  .dashboard-metric-card {
    min-height: 250px;
  }

  .dashboard-page > .profile-completion-panel {
    padding: 16px;
  }

  .dashboard-page > .profile-completion-panel .profile-completion-head {
    align-items: flex-start;
  }
}

/* Locked Love2Chat colour system across every page family */
.page-polished {
  --page-accent: #ff658e;
  --page-accent-2: #5da9ff;
  --page-accent-3: #a58bff;
  --page-accent-soft: color-mix(in srgb, var(--page-accent) 12%, transparent);
  --page-accent-border: color-mix(in srgb, var(--page-accent) 30%, var(--border));
}

.page-family-public {
  --page-accent: #ff658e;
  --page-accent-2: #5da9ff;
  --page-accent-3: #a58bff;
}

.page-family-auth {
  --page-accent: #a58bff;
  --page-accent-2: #ff658e;
  --page-accent-3: #5da9ff;
}

.page-family-member {
  --page-accent: #ff658e;
  --page-accent-2: #5da9ff;
  --page-accent-3: #4bd6a2;
}

.member-profile-mode-chatable {
  --page-accent: #5da9ff;
  --page-accent-2: #79c2ff;
  --page-accent-3: #4bd6d2;
}

.member-profile-mode-friendable {
  --page-accent: #4bd6a2;
  --page-accent-2: #76e2ba;
  --page-accent-3: #5da9ff;
}

.member-profile-mode-lovable {
  --page-accent: #ff658e;
  --page-accent-2: #ff8eab;
  --page-accent-3: #a58bff;
}

.member-profile-mode-loading {
  --page-accent: #8b96a8;
  --page-accent-2: #5da9ff;
  --page-accent-3: #4bd6a2;
}

.page-family-profile {
  --page-accent: #ff658e;
  --page-accent-2: #a58bff;
  --page-accent-3: #5da9ff;
}

.page-family-chat {
  --page-accent: #5da9ff;
  --page-accent-2: #4bd6a2;
  --page-accent-3: #a58bff;
}

.page-family-community {
  --page-accent: #a58bff;
  --page-accent-2: #ff658e;
  --page-accent-3: #4bd6a2;
}

.page-family-marketplace {
  --page-accent: #f6c85f;
  --page-accent-2: #ff8b6a;
  --page-accent-3: #ff658e;
}

.page-family-games {
  --page-accent: #a58bff;
  --page-accent-2: #5da9ff;
  --page-accent-3: #ff658e;
}

.page-family-wallet {
  --page-accent: #f6c85f;
  --page-accent-2: #4bd6a2;
  --page-accent-3: #ff8b6a;
}

.page-family-vip {
  --page-accent: #f6c85f;
  --page-accent-2: #ff658e;
  --page-accent-3: #a58bff;
}

.page-family-safety {
  --page-accent: #4bd6a2;
  --page-accent-2: #5da9ff;
  --page-accent-3: #f6c85f;
}

.page-family-admin {
  --page-accent: #ff8b6a;
  --page-accent-2: #a58bff;
  --page-accent-3: #5da9ff;
}

.page-family-help {
  --page-accent: #5da9ff;
  --page-accent-2: #4bd6a2;
  --page-accent-3: #a58bff;
}

.page-family-local {
  --page-accent: #4bd6a2;
  --page-accent-2: #f6c85f;
  --page-accent-3: #5da9ff;
}

.page-family-system {
  --page-accent: #5da9ff;
  --page-accent-2: #a58bff;
  --page-accent-3: #ff8b6a;
}

.page-hero {
  position: relative;
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  gap: clamp(20px, 4vw, 38px);
  align-items: center;
  overflow: hidden;
  min-height: 260px;
  padding: clamp(26px, 5vw, 46px);
  border-color: var(--page-accent-border);
  border-radius: 22px;
  background:
    radial-gradient(circle at 92% 8%, color-mix(in srgb, var(--page-accent) 19%, transparent), transparent 34%),
    radial-gradient(circle at 4% 100%, color-mix(in srgb, var(--page-accent-2) 15%, transparent), transparent 39%),
    var(--panel-surface);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 22px 52px rgba(0, 0, 0, .2);
}

.page-hero::after {
  position: absolute;
  right: -72px;
  bottom: -104px;
  width: 246px;
  height: 246px;
  border: 1px solid rgba(255, 255, 255, .055);
  border-radius: 50%;
  box-shadow: 0 0 0 34px rgba(255, 255, 255, .018), 0 0 0 68px rgba(255, 255, 255, .012);
  content: "";
  pointer-events: none;
}

.page-hero > * {
  position: relative;
  z-index: 1;
}

.page-hero-emoticon,
.page-content-emoticon,
.feature-preview-emoticon,
.feature-fallback-emoticon,
.directory-emoticon {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--page-accent) 48%, var(--border));
  background:
    radial-gradient(circle at 32% 22%, rgba(255, 255, 255, .16), transparent 32%),
    color-mix(in srgb, var(--page-accent) 14%, var(--panel));
  box-shadow: 0 16px 34px color-mix(in srgb, var(--page-accent) 18%, transparent);
  font-family: "Segoe UI Emoji", "Apple Color Emoji", sans-serif;
  line-height: 1;
}

.page-hero-emoticon {
  width: 112px;
  height: 112px;
  border-radius: 28px;
  font-size: 48px;
  transform: rotate(-3deg);
}

.page-hero-emoticon::before {
  position: absolute;
  inset: 7px;
  border: 1px solid color-mix(in srgb, var(--page-accent) 36%, transparent);
  border-radius: 22px;
  content: "";
}

.page-hero-copy {
  display: grid;
  max-width: 820px;
  gap: 10px;
}

.page-hero-copy > .label {
  color: color-mix(in srgb, var(--page-accent) 76%, white);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.page-hero h1 {
  max-width: 900px;
  padding: 0;
  color: var(--text);
  font-size: clamp(38px, 6vw, 64px);
  font-weight: 900;
  line-height: .98;
  letter-spacing: -.05em;
}

.page-hero p {
  max-width: 68ch;
  margin: 2px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.page-hero .button-row {
  margin-top: 8px;
}

.page-hero .btn {
  min-height: 42px;
  border-radius: 12px;
}

.page-polished:not(.dashboard-page) > .panel:not(.profile-showcase):not(.badge-collection-hero):not(.game-shell):not(.draw-studio),
.page-polished:not(.dashboard-page) > .grid > .panel,
.page-polished .auth-layout > .panel {
  position: relative;
  overflow: hidden;
  border-color: color-mix(in srgb, var(--page-accent) 23%, var(--border));
  border-radius: 18px;
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--page-accent) 8%, transparent), transparent 34%),
    linear-gradient(180deg, var(--panel-soft-surface), var(--panel-surface));
  box-shadow: 0 14px 34px rgba(0, 0, 0, .13);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.page-polished:not(.dashboard-page) > .panel:not(.profile-showcase):not(.badge-collection-hero):not(.game-shell):not(.draw-studio):hover,
.page-polished:not(.dashboard-page) > .grid > .panel:hover,
.page-polished .auth-layout > .panel:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--page-accent) 55%, var(--border));
  box-shadow: 0 20px 42px rgba(0, 0, 0, .2);
}

.page-polished:not(.dashboard-page) > .panel:not(.profile-showcase):not(.badge-collection-hero):not(.game-shell):not(.draw-studio)::before,
.page-polished:not(.dashboard-page) > .grid > .panel::before,
.page-polished .auth-layout > .panel::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--page-accent), color-mix(in srgb, var(--page-accent-2) 76%, white));
  content: "";
}

.page-polished > .grid > .panel:nth-child(2)::before,
.page-polished .auth-layout > .panel:nth-child(2)::before {
  background: linear-gradient(90deg, var(--page-accent-2), color-mix(in srgb, var(--page-accent-3) 72%, white));
}

.page-polished > .grid > .panel:nth-child(3)::before,
.page-polished .auth-layout > .panel:nth-child(3)::before {
  background: linear-gradient(90deg, var(--page-accent-3), color-mix(in srgb, var(--page-accent) 68%, white));
}

.page-content-card {
  display: grid;
  min-height: 230px;
  gap: 10px;
  align-content: start;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.page-content-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--page-accent) 55%, var(--border));
  box-shadow: 0 20px 42px rgba(0, 0, 0, .2);
}

.page-content-emoticon,
.feature-preview-emoticon {
  width: 48px;
  height: 48px;
  margin-bottom: 4px;
  border-radius: 14px;
  color: color-mix(in srgb, var(--page-accent) 84%, white);
  font-family: var(--font-body);
  font-size: 23px;
  font-weight: 900;
}

.page-content-card:nth-child(2) .page-content-emoticon,
.feature-preview-card:nth-child(2) .feature-preview-emoticon {
  border-color: color-mix(in srgb, var(--page-accent-2) 46%, var(--border));
  background: color-mix(in srgb, var(--page-accent-2) 13%, var(--panel));
  color: color-mix(in srgb, var(--page-accent-2) 84%, white);
}

.page-content-card:nth-child(3) .page-content-emoticon,
.feature-preview-card:nth-child(3) .feature-preview-emoticon {
  border-color: color-mix(in srgb, var(--page-accent-3) 46%, var(--border));
  background: color-mix(in srgb, var(--page-accent-3) 13%, var(--panel));
  color: color-mix(in srgb, var(--page-accent-3) 84%, white);
}

.page-polished .feature-preview-card {
  position: relative;
  display: grid;
  min-height: 250px;
  gap: 10px;
  align-content: start;
  overflow: hidden;
  border-color: var(--page-accent-border);
  border-radius: 16px;
  background:
    radial-gradient(circle at 100% 0, var(--page-accent-soft), transparent 38%),
    var(--panel-soft-surface);
  box-shadow: 0 13px 30px rgba(0, 0, 0, .14);
}

.page-polished .feature-preview-card .btn {
  align-self: end;
  margin-top: auto;
}

.feature-preview-emoticon {
  font-family: "Segoe UI Emoji", "Apple Color Emoji", sans-serif;
  font-size: 22px;
}

.page-polished .public-cta-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 26px;
  align-items: center;
  padding: clamp(22px, 4vw, 34px);
  border-color: color-mix(in srgb, var(--page-accent-2) 35%, var(--border));
  background:
    radial-gradient(circle at 100% 20%, color-mix(in srgb, var(--page-accent-2) 16%, transparent), transparent 35%),
    radial-gradient(circle at 0 100%, color-mix(in srgb, var(--page-accent) 11%, transparent), transparent 38%),
    var(--panel-surface);
}

.page-polished .public-cta-panel h2 {
  max-width: 720px;
  font-size: clamp(24px, 4vw, 36px);
  line-height: 1.12;
  letter-spacing: -.035em;
}

.page-polished .public-cta-panel > .button-row {
  justify-content: flex-end;
}

.directory-showcase,
.feature-fallback-showcase {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 20px;
  align-items: center;
  padding: clamp(22px, 4vw, 34px);
}

.directory-emoticon,
.feature-fallback-emoticon {
  width: 70px;
  height: 70px;
  border-radius: 20px;
  font-size: 31px;
}

.page-polished .chip-list {
  gap: 9px;
  margin-top: 16px;
}

.page-polished .chip,
.page-polished .pill {
  border-color: color-mix(in srgb, var(--page-accent) 24%, var(--border));
  background: color-mix(in srgb, var(--page-accent) 7%, var(--panel-soft));
}

.page-polished .section-head {
  position: relative;
}

.page-polished .section-head > div > .label,
.page-polished .panel > .label {
  color: color-mix(in srgb, var(--page-accent) 76%, white);
}

.page-polished .activity-row,
.page-polished .table-list > div,
.page-polished .check-card,
.page-polished .case-detail,
.page-polished .stat,
.page-polished .room-card,
.page-polished .recommendation-item,
.page-polished .group-post-card,
.page-polished .comment-row,
.page-polished .gift-box,
.page-polished .oracle-option-field,
.page-polished .compare-answer-card {
  border-color: color-mix(in srgb, var(--page-accent) 20%, var(--border-soft));
  border-radius: 13px;
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--page-accent) 7%, transparent), transparent 40%),
    color-mix(in srgb, var(--input) 92%, transparent);
}

.page-polished .activity-row:hover,
.page-polished .room-card:hover,
.page-polished .recommendation-item:hover {
  border-color: color-mix(in srgb, var(--page-accent) 46%, var(--border));
}

/* Keep answer-comparison cards coloured by the saved importance value.
   These must follow the generic polished-card rule above so it cannot
   flatten every importance level into the same page-accent colour. */
.page-polished .compare-answer-card.very {
  border-color: rgba(255, 79, 112, 0.78);
  background: rgba(255, 79, 112, 0.14);
  box-shadow: inset 3px 0 0 rgba(255, 79, 112, 0.92);
}

.page-polished .compare-answer-card.care {
  border-color: rgba(255, 196, 76, 0.82);
  background: rgba(255, 196, 76, 0.18);
  box-shadow: inset 3px 0 0 rgba(255, 196, 76, 0.95);
}

.page-polished .compare-answer-card.not {
  border-color: rgba(75, 201, 142, 0.78);
  background: rgba(75, 201, 142, 0.15);
  box-shadow: inset 3px 0 0 rgba(75, 201, 142, 0.92);
}

.page-polished .compare-answer-card.missing,
.page-polished .compare-answer-card.locked {
  border-color: rgba(132, 145, 166, 0.62);
  background: rgba(132, 145, 166, 0.12);
  box-shadow: inset 3px 0 0 rgba(132, 145, 166, 0.72);
}

.page-polished .field input,
.page-polished .field select,
.page-polished .field textarea,
.page-polished input,
.page-polished select,
.page-polished textarea {
  border-radius: 11px;
}

.page-polished .field input:focus,
.page-polished .field select:focus,
.page-polished .field textarea:focus,
.page-polished input:focus,
.page-polished select:focus,
.page-polished textarea:focus {
  border-color: color-mix(in srgb, var(--page-accent) 62%, var(--border));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--page-accent) 13%, transparent);
  outline: none;
}

.page-polished .btn {
  border-radius: 11px;
}

.page-polished .btn.blue {
  border-color: color-mix(in srgb, var(--page-accent-2) 48%, var(--button-blue-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--page-accent-2) 16%, var(--button-blue-bg)), var(--button-blue-bg));
}

.page-polished .btn.gold {
  border-color: color-mix(in srgb, #f6c85f 58%, var(--button-gold-border));
}

.appearance-button-samples .btn {
  cursor: default;
  pointer-events: none;
  user-select: none;
}

.page-polished .empty-state,
.page-polished .compact-empty {
  border: 1px dashed color-mix(in srgb, var(--page-accent) 35%, var(--border));
  border-radius: 14px;
  background: color-mix(in srgb, var(--page-accent) 6%, transparent);
}

.page-family-auth .auth-layout {
  gap: 18px;
}

.page-family-auth .auth-layout > .panel {
  padding: clamp(22px, 4vw, 34px);
}

.page-family-chat .room-card,
.page-family-chat .chat-head,
.page-family-chat .chat-window,
.page-family-chat .direct-thread,
.page-family-chat .message {
  border-color: color-mix(in srgb, var(--page-accent) 25%, var(--border));
}

.page-family-chat .room-card {
  background:
    radial-gradient(circle at 100% 0, rgba(93, 169, 255, .12), transparent 38%),
    var(--panel-surface);
  box-shadow: 0 13px 30px rgba(0, 0, 0, .14);
}

.page-family-community .group-post-card,
.page-family-community .group-composer,
.page-family-community .group-feed {
  border-color: color-mix(in srgb, var(--page-accent) 27%, var(--border));
  border-radius: 16px;
}

.page-family-marketplace .marketplace-card,
.page-family-marketplace .marketplace-table,
.page-family-marketplace .marketplace-card-photo {
  border-color: color-mix(in srgb, var(--page-accent) 30%, var(--border));
  border-radius: 16px;
}

.page-family-marketplace .marketplace-card {
  overflow: hidden;
  background:
    radial-gradient(circle at 100% 0, rgba(246, 200, 95, .12), transparent 40%),
    var(--panel-surface);
  box-shadow: 0 15px 34px rgba(0, 0, 0, .16);
}

.page-family-games .game-shell,
.page-family-games .game-frame,
.page-family-games .chess-frame,
.page-family-games .iq-question-card {
  border-color: color-mix(in srgb, var(--page-accent) 32%, var(--border));
  border-radius: 18px;
  box-shadow: 0 16px 38px rgba(0, 0, 0, .18);
}

.page-family-games .game-shell-head {
  border-bottom-color: color-mix(in srgb, var(--page-accent-2) 28%, var(--border));
}

.page-family-wallet .case-detail,
.page-family-wallet .stat,
.page-family-wallet .gift-box,
.page-family-vip .vip-plan-cta {
  border-color: color-mix(in srgb, var(--page-accent) 31%, var(--border));
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--page-accent) 12%, transparent), transparent 42%),
    var(--panel-soft);
}

.page-family-vip .vip-upgrade-intro,
.page-family-vip .vip-plan-cta {
  border-radius: 18px;
  box-shadow: 0 16px 38px rgba(0, 0, 0, .18);
}

body[data-theme="night"] .page-family-vip .vip-plan-cta {
  border-color: rgba(246, 200, 95, .72);
  background: linear-gradient(145deg, rgba(132, 82, 18, .94), rgba(66, 41, 14, .96));
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .52);
  box-shadow:
    inset 0 1px 0 rgba(255, 239, 196, .16),
    0 10px 24px rgba(0, 0, 0, .32);
}

body[data-theme="night"] .page-family-vip .vip-plan-cta:hover:not(:disabled) {
  border-color: #ffe09a;
  background: linear-gradient(145deg, rgba(164, 104, 23, .98), rgba(82, 49, 14, .98));
  color: #fff;
  transform: translateY(-1px);
}

body[data-theme="night"] .page-family-vip .vip-plan-cta:focus-visible {
  outline: 3px solid rgba(255, 224, 154, .38);
  outline-offset: 2px;
}

.page-family-safety .panel,
.page-family-admin .panel {
  border-color: color-mix(in srgb, var(--page-accent) 25%, var(--border));
}

.page-family-admin .activity-row,
.page-family-safety .activity-row {
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--page-accent) 8%, transparent), transparent 38%),
    var(--input);
}

.page-family-profile .questionnaire-panel,
.page-family-profile .appearance-glass-card,
.page-family-profile .translation-preferences-panel,
.page-family-profile .photo-card {
  border-color: color-mix(in srgb, var(--page-accent) 26%, var(--border));
  border-radius: 17px;
  box-shadow: 0 14px 32px rgba(0, 0, 0, .14);
}

.page-route-settings-delete .page-hero {
  --page-accent: #ff7d86;
  --page-accent-2: #ff8b6a;
}

.page-route-settings-delete > .panel,
.page-route-failed > .panel {
  border-color: color-mix(in srgb, #ff7d86 35%, var(--border));
}

body[data-theme="day"] .page-hero,
body[data-theme="day"] .page-polished:not(.dashboard-page) > .panel,
body[data-theme="day"] .page-polished:not(.dashboard-page) > .grid > .panel,
body[data-theme="day"] .page-polished .auth-layout > .panel {
  box-shadow: 0 14px 34px rgba(27, 40, 63, .09);
}

body[data-theme="day"] .page-hero-copy > .label,
body[data-theme="day"] .page-polished .section-head > div > .label,
body[data-theme="day"] .page-polished .panel > .label {
  color: color-mix(in srgb, var(--page-accent) 70%, #182032);
}

body[data-theme="day"] .page-hero-emoticon,
body[data-theme="day"] .page-content-emoticon,
body[data-theme="day"] .feature-preview-emoticon,
body[data-theme="day"] .feature-fallback-emoticon,
body[data-theme="day"] .directory-emoticon {
  background:
    radial-gradient(circle at 32% 22%, rgba(255, 255, 255, .72), transparent 34%),
    color-mix(in srgb, var(--page-accent) 10%, #fff);
}

body[data-theme="day"] .page-polished .activity-row,
body[data-theme="day"] .page-polished .table-list > div,
body[data-theme="day"] .page-polished .check-card,
body[data-theme="day"] .page-polished .case-detail,
body[data-theme="day"] .page-polished .stat {
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--page-accent) 7%, transparent), transparent 42%),
    #fff;
}

/* Oracle reader setup: compact, balanced glass cards for reading offers. */
.oracle-reader-profile-panel {
  padding: clamp(18px, 2.6vw, 28px);
}

.oracle-reader-profile-panel > .section-head {
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid color-mix(in srgb, var(--page-accent) 20%, var(--border-soft));
}

.oracle-reader-profile-panel > .form-grid {
  gap: 14px;
}

.oracle-reading-type-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.page-polished .oracle-reading-type-card {
  gap: 10px;
  padding: 15px;
  border-color: color-mix(in srgb, var(--page-accent) 28%, var(--border));
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--page-accent) 11%, transparent), transparent 42%),
    linear-gradient(155deg, var(--panel-soft-surface), var(--panel-surface));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035), 0 12px 26px rgba(0, 0, 0, .1);
  backdrop-filter: blur(12px) saturate(1.06);
  -webkit-backdrop-filter: blur(12px) saturate(1.06);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.page-polished .oracle-reading-type-card:hover,
.page-polished .oracle-reading-type-card:focus-within {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--page-accent) 56%, var(--border));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05), 0 17px 34px rgba(0, 0, 0, .16);
}

.oracle-reading-type-card .field {
  gap: 6px;
  margin: 0;
}

.oracle-reading-type-card select {
  min-height: 40px;
}

.oracle-reading-type-card textarea {
  min-height: 96px;
}

.oracle-reader-pricing-note {
  margin: 14px 0 0;
  padding: 11px 13px;
  border: 1px solid color-mix(in srgb, var(--page-accent-2) 22%, var(--border-soft));
  border-radius: 11px;
  background: color-mix(in srgb, var(--page-accent-2) 6%, transparent);
  line-height: 1.5;
}

.oracle-reader-profile-actions {
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid color-mix(in srgb, var(--page-accent) 18%, var(--border-soft));
}

@media (max-width: 1040px) {
  .oracle-reading-type-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .oracle-reader-profile-panel {
    padding: 16px;
  }

  .oracle-reading-type-grid {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-top: 16px;
  }

  .oracle-reader-profile-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .oracle-reader-profile-actions > .btn,
  .oracle-reader-profile-actions > .check-card {
    width: 100%;
  }

  .page-hero {
    grid-template-columns: 82px minmax(0, 1fr);
    min-height: 220px;
    gap: 18px;
    padding: 24px;
  }

  .page-hero-emoticon {
    width: 78px;
    height: 78px;
    border-radius: 21px;
    font-size: 34px;
  }

  .page-hero-emoticon::before {
    inset: 5px;
    border-radius: 17px;
  }

  .page-hero h1 {
    font-size: clamp(34px, 9vw, 48px);
  }

  .page-polished .public-cta-panel {
    grid-template-columns: 1fr;
  }

  .page-polished .public-cta-panel > .button-row {
    justify-content: flex-start;
  }
}

@media (max-width: 520px) {
  .page-polished {
    gap: 14px;
  }

  .page-hero {
    grid-template-columns: 1fr;
    gap: 16px;
    min-height: 0;
    padding: 18px;
    border-radius: 18px;
  }

  .page-hero-emoticon {
    width: 68px;
    height: 68px;
    font-size: 30px;
  }

  .page-hero-copy {
    gap: 8px;
  }

  .page-hero h1 {
    font-size: clamp(32px, 12vw, 43px);
  }

  .page-hero p {
    font-size: 14px;
  }

  .directory-showcase,
  .feature-fallback-showcase {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .directory-emoticon,
  .feature-fallback-emoticon {
    width: 58px;
    height: 58px;
    border-radius: 17px;
    font-size: 26px;
  }

  .page-content-card {
    min-height: 0;
  }

  .page-polished .public-cta-panel {
    padding: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .dashboard-welcome-showcase,
  .dashboard-page > .profile-completion-panel,
  .page-polished:not(.dashboard-page) > .panel:not(.profile-showcase):not(.badge-collection-hero):not(.game-shell):not(.draw-studio),
  .page-polished:not(.dashboard-page) > .grid > .panel,
  .page-polished .auth-layout > .panel,
  .dashboard-page .profile-stream-composer,
  .dashboard-page .profile-stream-panel,
  .dashboard-page > .dashboard-wide,
  .dashboard-page .dashboard-grid-small .dashboard-card,
  .page-content-card,
  .dashboard-metric-card,
  .dashboard-recommendations-stack > .dashboard-card,
  .badge-card,
  .profile-gallery-panel .profile-gallery-grid img {
    transition: none;
  }

  .dashboard-welcome-showcase:hover,
  .dashboard-page > .profile-completion-panel:hover,
  .page-polished:not(.dashboard-page) > .panel:not(.profile-showcase):not(.badge-collection-hero):not(.game-shell):not(.draw-studio):hover,
  .page-polished:not(.dashboard-page) > .grid > .panel:hover,
  .page-polished .auth-layout > .panel:hover,
  .dashboard-page .profile-stream-composer:hover,
  .dashboard-page .profile-stream-panel:hover,
  .dashboard-page > .dashboard-wide:hover,
  .dashboard-page .dashboard-grid-small .dashboard-card:hover,
  .page-content-card:hover,
  .dashboard-metric-card:hover,
  .dashboard-recommendations-stack > .dashboard-card:hover,
  .dashboard-recommendations-stack > .dashboard-card:focus-within,
  .badge-card:hover {
    transform: none;
  }
}

.report-page-intro,
.report-section-head,
.report-chat-header,
.report-attachment-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.report-page-intro {
  margin-bottom: 16px;
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--cyan) 16%, transparent), transparent 44%),
    var(--panel);
}

.report-workspace {
  display: grid;
  grid-template-columns: minmax(230px, 300px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.report-case-sidebar {
  position: sticky;
  top: 16px;
}

.report-case-list {
  display: grid;
  gap: 8px;
  margin-top: 16px;
  max-height: 66vh;
  overflow: auto;
}

.report-case-row {
  display: grid;
  gap: 4px;
  width: 100%;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel-soft);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.report-case-row:hover,
.report-case-row.active {
  border-color: var(--cyan);
  background: color-mix(in srgb, var(--cyan) 11%, var(--panel-soft));
}

.report-case-row span,
.report-case-row small,
.report-chat-message-head span,
.report-chat-message-head time {
  color: var(--muted);
  font-size: .78rem;
}

.report-main-column {
  display: grid;
  gap: 16px;
  min-width: 0;
}

.report-create-panel.is-collapsed {
  display: none;
}

.report-image-preview {
  display: block;
  width: min(100%, 520px);
  max-height: 360px;
  margin: 14px 0;
  border: 1px solid var(--border);
  border-radius: 14px;
  object-fit: contain;
  background: rgba(0, 0, 0, .2);
}

.report-image-preview.compact {
  max-height: 220px;
}

.report-chat-panel {
  padding: 0;
  overflow: hidden;
}

.report-chat-header {
  padding: 18px;
  border-bottom: 1px solid var(--border);
  background: var(--panel-soft);
}

.report-chat-stream {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 320px;
  max-height: 58vh;
  padding: 18px;
  overflow: auto;
}

.report-linked-evidence {
  display: grid;
  gap: 10px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--gold) 5%, var(--panel));
}

.report-submission-summary {
  display: grid;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--cyan) 4%, var(--panel));
}

.report-submission-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.report-submission-title h3 {
  margin: 2px 0 0;
}

.report-submission-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.report-submission-grid > div {
  min-width: 0;
  padding: 11px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  background: var(--panel-soft);
}

.report-submission-grid > .full {
  grid-column: 1 / -1;
}

.report-submission-grid dt {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.report-submission-grid dd {
  margin: 0;
  color: var(--text);
  font-weight: 700;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.report-staff-shortcuts {
  justify-content: flex-end;
  margin-top: 10px;
}

.report-linked-evidence-title,
.report-linked-message-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.report-linked-evidence-title {
  justify-content: space-between;
}

.report-linked-evidence-title h3 {
  margin: 2px 0 0;
}

.report-linked-message {
  padding: 12px 14px;
  border: 1px solid color-mix(in srgb, var(--gold) 30%, var(--border));
  border-radius: 14px;
  background: var(--panel-soft);
  color: var(--text);
}

.report-linked-message-head time {
  margin-left: auto;
  color: var(--muted);
  font-size: .78rem;
}

.report-linked-message p {
  margin: 9px 0 6px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.report-linked-message small,
.report-linked-message-head > span:not(.plate-badge) {
  color: var(--muted);
}

.report-chat-message {
  align-self: flex-start;
  width: min(82%, 680px);
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 16px 16px 16px 5px;
  background: var(--panel-soft);
}

.report-chat-message.mine {
  align-self: flex-end;
  border-color: color-mix(in srgb, var(--cyan) 45%, var(--border));
  border-radius: 16px 16px 5px 16px;
  background: color-mix(in srgb, var(--cyan) 13%, var(--panel-soft));
}

.report-chat-message.system {
  align-self: center;
  width: auto;
  border-style: dashed;
  border-radius: 999px;
  text-align: center;
}

.report-chat-message-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 7px;
}

.report-chat-message-head time {
  margin-left: auto;
}

.report-chat-message p {
  margin: 8px 0 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.report-evidence-link {
  display: grid;
  gap: 6px;
  margin-top: 12px;
  padding: 10px;
  border: 1px solid color-mix(in srgb, var(--cyan) 30%, var(--border));
  border-radius: 14px;
  background: color-mix(in srgb, var(--input) 82%, transparent);
  color: var(--cyan);
  text-decoration: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
}

.report-evidence-link img {
  width: min(100%, 520px);
  max-height: 380px;
  margin-inline: auto;
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  object-fit: contain;
  background: color-mix(in srgb, var(--bg) 85%, black);
}

.report-evidence-link span {
  width: fit-content;
  padding: 5px 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--cyan) 13%, var(--panel));
  color: color-mix(in srgb, var(--cyan) 82%, var(--text));
  font-size: .78rem;
  font-weight: 800;
}

.report-chat-composer {
  padding: 16px 18px 18px;
  border-top: 1px solid var(--border);
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--cyan) 5%, var(--panel-soft)), var(--panel-soft));
  box-shadow: 0 -10px 28px rgba(0, 0, 0, .08);
}

.report-chat-composer textarea {
  width: 100%;
  min-height: 104px;
  margin-bottom: 12px;
  padding: 13px 15px;
  border: 1px solid color-mix(in srgb, var(--cyan) 25%, var(--border-soft));
  border-radius: 14px;
  outline: none;
  background: var(--input);
  color: var(--text);
  caret-color: var(--cyan);
  resize: vertical;
  box-shadow:
    inset 0 1px 2px rgba(0, 0, 0, .16),
    0 0 0 1px rgba(255, 255, 255, .02);
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

.report-chat-composer textarea::placeholder {
  color: var(--subtle);
  opacity: 1;
}

.report-chat-composer textarea:hover {
  border-color: color-mix(in srgb, var(--cyan) 45%, var(--border));
}

.report-chat-composer textarea:focus {
  border-color: var(--cyan);
  background: color-mix(in srgb, var(--cyan) 4%, var(--input));
  box-shadow:
    inset 0 1px 2px rgba(0, 0, 0, .14),
    0 0 0 3px color-mix(in srgb, var(--cyan) 20%, transparent);
}

.report-chat-composer .report-attachment-row {
  padding: 10px;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  background: color-mix(in srgb, var(--input) 64%, transparent);
}

.report-chat-composer [data-report-chat-send] {
  min-width: 130px;
  margin-left: auto;
}

.report-chat-ended {
  margin: 0;
  padding: 16px 18px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  text-align: center;
}

.notice-banner {
  margin-top: 14px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel-soft);
  color: var(--text);
  box-shadow: 0 8px 22px rgba(0, 0, 0, .12);
}

body[data-theme="night"] .report-chat-composer textarea {
  background: #102b35;
  border-color: #286779;
  color: #f8fafc;
}

body[data-theme="night"] .report-chat-composer textarea:focus {
  background: #123440;
  border-color: #54d7f3;
}

body[data-theme="day"] .report-chat-composer {
  background: linear-gradient(180deg, #f7fafc, #edf3f7);
  box-shadow: 0 -8px 24px rgba(35, 54, 75, .07);
}

body[data-theme="day"] .report-chat-composer textarea {
  border-color: #b9c9d5;
  background: #fff;
  color: #172033;
  box-shadow: inset 0 1px 2px rgba(30, 48, 68, .08);
}

body[data-theme="day"] .report-chat-composer textarea:focus {
  border-color: #087f9b;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(8, 127, 155, .14);
}

body[data-theme="day"] .report-evidence-link {
  border-color: #bfd3dc;
  background: #f7fafc;
  box-shadow: 0 8px 20px rgba(35, 54, 75, .06);
}

body[data-theme="day"] .report-evidence-link img {
  background: #e8eef2;
}

body[data-theme="day"] .report-linked-evidence {
  background: #fffaf0;
}

body[data-theme="day"] .report-submission-summary {
  background: #f6fbfd;
}

body[data-theme="day"] .report-submission-grid > div {
  border-color: #cad8e0;
  background: #fff;
  box-shadow: 0 4px 12px rgba(35, 54, 75, .04);
}

body[data-theme="day"] .report-linked-message {
  border-color: #dccb9c;
  background: #fff;
  box-shadow: 0 6px 16px rgba(74, 57, 22, .06);
}

@media (max-width: 820px) {
  .report-workspace {
    grid-template-columns: 1fr;
  }

  .report-case-sidebar {
    position: static;
  }

  .report-case-list {
    max-height: 260px;
  }

  .report-page-intro,
  .report-chat-header,
  .report-section-head,
  .report-attachment-row {
    align-items: stretch;
    flex-direction: column;
  }

  .report-chat-message {
    width: 94%;
  }

  .report-submission-grid {
    grid-template-columns: 1fr;
  }

  .report-submission-grid > .full {
    grid-column: auto;
  }

  .report-chat-composer [data-report-chat-send] {
    width: 100%;
    margin-left: 0;
  }
}
.message-repository-panel {
  display: grid;
  gap: 16px;
}

.moderation-active-queue {
  scroll-margin-top: 18px;
  border-radius: 18px;
  transition: box-shadow .25s ease, transform .25s ease;
}

.moderation-active-queue.is-queue-focused {
  box-shadow: 0 0 0 2px var(--accent, #13bdd1), 0 0 28px rgba(19, 189, 209, .24);
}

@media (prefers-reduced-motion: reduce) {
  .moderation-active-queue { transition: none; }
}

.message-repository-filters {
  display: grid;
  grid-template-columns: minmax(130px, .7fr) minmax(220px, 1.5fr) repeat(3, minmax(130px, .7fr)) auto;
  gap: 12px;
  align-items: end;
}

.message-repository-table-wrap {
  overflow: auto;
  max-height: 560px;
  border: 1px solid var(--border, rgba(105, 205, 218, .35));
  border-radius: 14px;
  background: rgba(3, 22, 29, .22);
}

.message-repository-table {
  width: 100%;
  min-width: 920px;
  border-collapse: collapse;
}

.message-repository-table th,
.message-repository-table td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--border, rgba(105, 205, 218, .25));
  text-align: left;
  vertical-align: top;
}

.message-repository-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: var(--text, #eefcff);
  background: var(--panel-strong, #123744);
}

.message-repository-table td small {
  display: block;
  margin-top: 4px;
  color: var(--muted, #a9c5ca);
}

.message-repository-body {
  min-width: 260px;
  max-width: 520px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.message-active-label { color: #45e0b7 !important; }
.message-history-label { color: #ffc76b !important; }
.message-repository-admin-actions { justify-content: flex-end; }

body.day-mode .message-repository-table-wrap,
[data-theme="day"] .message-repository-table-wrap {
  background: rgba(255, 255, 255, .72);
}

body.day-mode .message-repository-table th,
[data-theme="day"] .message-repository-table th {
  color: #17333b;
  background: #dceff2;
}

@media (max-width: 1050px) {
  .message-repository-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  .message-repository-filters { grid-template-columns: 1fr; }
}

.draw-game-card,
.draw-competition-create {
  display: grid;
  gap: 10px;
  margin: 8px 0 14px;
  padding: 14px;
  border: 1px solid color-mix(in srgb, var(--accent, #13bdd1) 45%, var(--border));
  border-radius: 14px;
  background: linear-gradient(145deg, color-mix(in srgb, var(--panel-soft) 88%, #00c9dc 12%), var(--panel-soft));
}

.draw-game-card.competition,
.draw-competition-create {
  border-color: color-mix(in srgb, #f4a340 68%, var(--border));
  box-shadow: inset 3px 0 0 #f4a340;
}

.draw-game-head,
.draw-game-entry,
.draw-game-guess {
  display: flex;
  gap: 9px;
  align-items: center;
  justify-content: space-between;
}

.draw-game-head h4,
.draw-competition-create h4 {
  margin: 6px 0 0;
}

.draw-game-prompt {
  margin: 0;
  padding: 12px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--input) 82%, transparent);
  color: var(--text);
  font-weight: 700;
}

.draw-game-entries,
.draw-game-guesses {
  display: grid;
  gap: 8px;
}

.draw-game-entry {
  padding: 9px 10px;
  border: 1px solid var(--border-soft, var(--border));
  border-radius: 11px;
  background: color-mix(in srgb, var(--panel) 78%, transparent);
}

.draw-game-entry.winner {
  border-color: #f4a340;
  box-shadow: 0 0 0 2px color-mix(in srgb, #f4a340 18%, transparent);
}

.draw-game-entry > div {
  display: grid;
  gap: 2px;
  min-width: 0;
  margin-right: auto;
}

.draw-game-entry span,
.draw-game-guesses span {
  color: var(--muted);
  font-size: .8rem;
}

.draw-game-guess input {
  flex: 1;
  min-width: 0;
}

.draw-competition-create textarea {
  min-height: 82px;
  resize: vertical;
}

body.day-mode .draw-game-card,
body.day-mode .draw-competition-create,
[data-theme="day"] .draw-game-card,
[data-theme="day"] .draw-competition-create {
  background: linear-gradient(145deg, #ffffff, #edf8fa);
  box-shadow: 0 8px 22px rgba(34, 69, 78, .08);
}

@media (max-width: 640px) {
  .draw-game-head,
  .draw-game-entry,
  .draw-game-guess {
    align-items: stretch;
    flex-direction: column;
  }

  .draw-game-entry .tiny-btn,
  .draw-game-guess .btn {
    width: 100%;
  }
}
