/* Speech bubble — sits above the head (JS sets --tg-speech-x/y from head rect) */
.tg-speech {
  position: absolute;
  left: var(--tg-speech-x, 50%);
  top: var(--tg-speech-y, 8%);
  bottom: auto;
  right: auto;
  z-index: 24;
  width: max-content;
  max-width: min(88%, 17.5rem);
  transform: translate(-50%, -100%);
  pointer-events: none;
  color: var(--tg-mist, #e8f4f1);
}

.tg-speech[hidden] {
  display: none !important;
}

.tg-speech__cloud {
  position: relative;
  padding: 0.55rem 0.8rem 0.6rem;
  border-radius: 1.15rem;
  background:
    linear-gradient(160deg, rgba(14, 36, 42, 0.94), rgba(7, 22, 28, 0.92));
  border: 1px solid color-mix(in srgb, var(--tg-lime, #c8f542) 38%, transparent);
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.38),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  text-align: center;
}

.tg-speech__text {
  margin: 0;
  font-size: 0.86rem;
  line-height: 1.35;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.tg-speech__tail {
  display: block;
  width: 0.72rem;
  height: 0.72rem;
  margin: -0.28rem auto 0;
  background: rgba(7, 22, 28, 0.94);
  border-right: 1px solid color-mix(in srgb, var(--tg-lime, #c8f542) 38%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--tg-lime, #c8f542) 38%, transparent);
  transform: rotate(45deg);
  box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.18);
}

.tg-speech[data-tone="need"] .tg-speech__cloud {
  border-color: color-mix(in srgb, var(--tg-amber, #fbbf24) 55%, transparent);
}

.tg-speech[data-tone="warm"] .tg-speech__cloud {
  border-color: color-mix(in srgb, var(--tg-lime, #c8f542) 55%, transparent);
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.38),
    0 0 22px color-mix(in srgb, var(--tg-lime, #c8f542) 18%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tg-speech.is-enter {
  animation: tg-speech-pop 0.48s cubic-bezier(0.22, 1.2, 0.36, 1) both;
}

.tg-speech.is-enter .tg-speech__cloud {
  animation: tg-speech-cloud 0.42s cubic-bezier(0.22, 1.15, 0.36, 1) both;
}

.tg-speech.is-typing .tg-speech__text::after {
  content: "";
  display: inline-block;
  width: 0.35em;
  height: 1em;
  margin-left: 0.1em;
  vertical-align: -0.1em;
  background: color-mix(in srgb, var(--tg-lime, #c8f542) 70%, transparent);
  border-radius: 1px;
  animation: tg-speech-caret 0.7s steps(1) infinite;
}

.tg-speech.is-poke {
  animation: tg-speech-poke 0.45s cubic-bezier(0.22, 1.1, 0.36, 1);
}

@keyframes tg-speech-pop {
  0% {
    opacity: 0;
    transform: translate(-50%, -92%) scale(0.86);
  }
  60% {
    opacity: 1;
    transform: translate(-50%, -102%) scale(1.03);
  }
  100% {
    opacity: 1;
    transform: translate(-50%, -100%) scale(1);
  }
}

@keyframes tg-speech-cloud {
  0% { filter: blur(2px); }
  100% { filter: none; }
}

@keyframes tg-speech-caret {
  50% { opacity: 0; }
}

@keyframes tg-speech-poke {
  0% { transform: translate(-50%, -100%) scale(1); }
  40% { transform: translate(-50%, -108%) scale(1.05); }
  100% { transform: translate(-50%, -100%) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
  .tg-speech.is-enter,
  .tg-speech.is-enter .tg-speech__cloud,
  .tg-speech.is-poke,
  .tg-speech.is-typing .tg-speech__text::after {
    animation: none !important;
  }
}

.tg-sideblock {
  margin-top: 1.1rem;
  padding-top: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.tg-sideblock__title {
  margin: 0 0 0.55rem;
  font-family: var(--tg-font-display);
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.tg-traits {
  display: grid;
  gap: 0.55rem;
}

.tg-traits__lead {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--tg-muted);
}

.tg-traits__lead strong {
  color: var(--tg-mist, #e8f4f1);
  font-weight: 700;
}

.tg-traits__list {
  display: grid;
  gap: 0.4rem;
}

.tg-trait {
  display: grid;
  gap: 0.35rem;
  padding: 0.55rem 0.65rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(0, 0, 0, 0.16);
}

.tg-trait.is-dominant {
  border-color: color-mix(in srgb, var(--tg-lime, #c8f542) 42%, transparent);
  background: color-mix(in srgb, var(--tg-lime, #c8f542) 7%, rgba(0, 0, 0, 0.16));
}

.tg-trait__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.65rem;
  min-width: 0;
}

.tg-trait__name {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  min-width: 0;
  flex: 1 1 auto;
  font-size: 0.8rem;
  font-weight: 650;
  line-height: 1.25;
  color: var(--tg-mist, #e8f4f1);
  overflow-wrap: anywhere;
}

.tg-trait__badge {
  flex: 0 0 auto;
  font-size: 0.7rem;
  line-height: 1;
  color: var(--tg-lime, #c8f542);
}

.tg-trait__value {
  flex: 0 0 auto;
  min-width: 2ch;
  font-size: 0.78rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  letter-spacing: 0.02em;
  text-align: right;
  color: var(--tg-teal, #5eead4);
}

.tg-trait.is-dominant .tg-trait__value {
  color: var(--tg-lime, #c8f542);
}

.tg-trait__bar {
  height: 0.45rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  overflow: hidden;
}

.tg-trait__fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--tg-teal, #5eead4), var(--tg-lime, #c8f542));
}

.tg-trait__fill--playful {
  background: linear-gradient(90deg, #f0abfc, #c8f542);
}

.tg-trait__fill--studious {
  background: linear-gradient(90deg, #67e8f9, #5eead4);
}

.tg-trait__fill--tidy {
  background: linear-gradient(90deg, #a5b4fc, #99f6e4);
}

.tg-trait__fill--ambitious {
  background: linear-gradient(90deg, #fbbf24, #f97316);
}

.tg-trait__fill--social {
  background: linear-gradient(90deg, #5eead4, #34d399);
}

.tg-quests {
  display: grid;
  gap: 0.55rem;
}

.tg-quest {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.85rem;
  padding: 0.65rem 0.75rem;
  background: rgba(0, 0, 0, 0.15);
}

.tg-quest__title {
  font-size: 0.88rem;
  margin-bottom: 0.3rem;
}

.tg-quest__meta {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--tg-muted);
  margin-bottom: 0.45rem;
}

.tg-quest.is-done {
  border-color: rgba(200, 245, 66, 0.35);
}

.tg-careers,
.tg-minigames {
  display: grid;
  gap: 0.55rem;
}

.tg-career,
.tg-minigame-card,
.tg-season-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.85rem;
  padding: 0.65rem 0.75rem;
  background: rgba(0, 0, 0, 0.15);
}

.tg-career.is-active {
  border-color: rgba(94, 234, 212, 0.4);
}

.tg-career__title,
.tg-minigame-card__title {
  font-size: 0.88rem;
  margin-bottom: 0.25rem;
}

.tg-career__meta,
.tg-minigame-card__meta,
.tg-season-card__meta {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--tg-muted);
  margin-bottom: 0.45rem;
}

.tg-career__ranks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.4rem;
}

.tg-career__rank {
  font-size: 0.7rem;
  padding: 0.15rem 0.4rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.tg-career__rank.is-claimable {
  border-color: rgba(200, 245, 66, 0.45);
  color: var(--tg-lime, #c8f542);
}

.tg-career__rank.is-claimed {
  opacity: 0.55;
}

.tg-minigame-card__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

.tg-minigame-card__badge {
  flex-shrink: 0;
  font-size: 0.65rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 0.15rem 0.4rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--tg-muted);
}

.tg-minigame-card__badge--care {
  border-color: rgba(94, 234, 212, 0.4);
  color: var(--tg-teal, #5eead4);
}

.tg-minigame-card__badge--earn {
  border-color: rgba(246, 211, 106, 0.45);
  color: #f6d36a;
}

.tg-minigame-card--care {
  border-color: rgba(94, 234, 212, 0.18);
}

.tg-minigame-card--earn {
  border-color: rgba(246, 211, 106, 0.16);
}

.tg-minigame-card__badge--multi {
  border-color: rgba(96, 165, 250, 0.45);
  color: #93c5fd;
}

.tg-minigame-card--multi {
  border-color: rgba(96, 165, 250, 0.22);
}

.tg-minigame-card__stars {
  color: #f6d36a;
  letter-spacing: 0.08em;
}

.tg-minigame-card__diff select {
  font: inherit;
  font-size: 0.72rem;
  color: inherit;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.45rem;
  padding: 0.15rem 0.35rem;
}

.tg-minigame-card__lead,
.tg-season-card__lead {
  font-size: 0.78rem;
  color: var(--tg-muted);
  margin: 0 0 0.5rem;
}

.tg-season-card__drop {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.5rem;
}

.tg-season-card__drop img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.tg-season-card.is-claimable {
  border-color: rgba(245, 158, 11, 0.45);
  box-shadow: 0 0 0 1px rgba(163, 230, 53, 0.12) inset;
}

.tg-mind-attention {
  margin: 0 0 0.75rem;
  padding: 0.7rem 0.9rem;
  border-radius: 0.9rem;
  border: 1px solid rgba(45, 212, 191, 0.28);
  background: linear-gradient(120deg, rgba(15, 118, 110, 0.35), rgba(12, 36, 48, 0.75));
}

.tg-mind-attention[hidden],
.tg-adventure-banner[hidden],
.tg-climate-strip[hidden],
.tg-reflect-banner[hidden],
.tg-daily-banner[hidden],
.tg-claim-banner[hidden],
.tg-recover-strip[hidden] {
  display: none !important;
}

.tg-claim-banner {
  margin: 0 0 0.65rem;
  padding: 0.55rem 0.85rem;
  border-radius: 1rem;
  border: 1px solid rgba(245, 158, 11, 0.38);
  background: linear-gradient(120deg, rgba(120, 53, 15, 0.4), rgba(15, 118, 110, 0.32));
  font-size: 0.88rem;
  color: #fde68a;
  cursor: pointer;
}

.tg-claim-banner__chip {
  appearance: none;
  display: inline-flex;
  align-items: center;
  margin: 0.15rem 0.25rem 0.15rem 0;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(253, 230, 138, 0.45);
  background: rgba(120, 53, 15, 0.35);
  font: inherit;
  font-weight: 600;
  font-size: 0.8rem;
  color: #fde68a;
  cursor: pointer;
}

.tg-claim-banner__chip:hover,
.tg-claim-banner__chip:focus-visible {
  border-color: rgba(253, 230, 138, 0.8);
  outline: none;
}

.tg-adventure-banner__stake {
  margin: 0.25rem 0 0;
  font-size: 0.78rem;
  color: rgba(253, 230, 138, 0.95);
}

.tg-inbox-actor {
  color: #99f6e4;
  text-decoration: underline;
  text-underline-offset: 0.12em;
}

.tg-recover-strip {
  margin: 0 0 0.65rem;
  padding: 0.5rem 0.85rem;
  border-radius: 1rem;
  border: 1px solid rgba(45, 212, 191, 0.3);
  background: linear-gradient(120deg, rgba(15, 118, 110, 0.35), rgba(12, 36, 48, 0.7));
  font-size: 0.84rem;
  color: rgba(204, 251, 241, 0.95);
}

.tg-snack-warn-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0 0 0.5rem;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  border: 1px solid rgba(248, 113, 113, 0.4);
  background: rgba(127, 29, 29, 0.35);
  font-size: 0.75rem;
  color: #fecaca;
}

.tg-room-comfort {
  margin: 0.35rem 0 0;
  font-size: 0.75rem;
  color: rgba(167, 243, 208, 0.9);
}

.tg-heirloom-card {
  margin: 0.75rem 0;
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(245, 158, 11, 0.35);
  background: linear-gradient(140deg, rgba(120, 53, 15, 0.4), rgba(15, 23, 42, 0.75));
}

.tg-heirloom-card__title {
  margin: 0 0 0.45rem;
  font-size: 0.95rem;
  color: #fde68a;
}

.tg-adventure-banner__postcard {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
  color: rgba(224, 242, 254, 0.92);
  font-style: italic;
}

.tg-daily-banner {
  margin: 0 0 0.85rem;
  padding: 0.8rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(245, 158, 11, 0.4);
  background: linear-gradient(120deg, rgba(120, 53, 15, 0.45), rgba(15, 118, 110, 0.35));
  display: grid;
  gap: 0.45rem;
}

.tg-daily-banner__title {
  font-size: 0.95rem;
  color: #fde68a;
}

.tg-daily-banner__meta {
  margin: 0;
  font-size: 0.78rem;
  color: rgba(236, 252, 203, 0.9);
}

.tg-card.is-level-locked {
  border-color: rgba(245, 158, 11, 0.28);
}

.tg-card__hint {
  margin: 0.2rem 0 0;
  font-size: 0.72rem;
  color: rgba(253, 230, 138, 0.9);
}

.tg-climate-strip {
  margin: 0 0 0.65rem;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.78rem;
  border: 1px solid rgba(45, 212, 191, 0.22);
  background: rgba(8, 28, 36, 0.72);
  color: rgba(236, 252, 203, 0.92);
}

.tg-climate-strip__label {
  color: var(--tg-muted);
}

.tg-climate-strip[data-climate="rain"] {
  border-color: rgba(56, 189, 248, 0.35);
}

.tg-climate-strip[data-climate="night"] {
  border-color: rgba(163, 230, 53, 0.22);
}

.tg-climate-strip[data-climate="storm"] {
  border-color: rgba(251, 113, 133, 0.4);
}

.tg-climate-strip.is-urgent {
  border-color: rgba(251, 113, 133, 0.55);
  box-shadow: inset 0 0 0 1px rgba(251, 113, 133, 0.2);
}

.tg-climate-strip__effect {
  color: var(--tg-muted);
  font-size: 0.72rem;
}

.tg-for-them-badge {
  position: absolute;
  top: 0.4rem;
  left: 0.4rem;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.12rem 0.35rem;
  border-radius: 999px;
  background: rgba(13, 148, 136, 0.85);
  color: #ecfccb;
  border: 1px solid rgba(45, 212, 191, 0.45);
}

.tg-card.is-for-them .tg-card__preview {
  position: relative;
}

.tg-minigame-card__badge--rec {
  background: rgba(13, 148, 136, 0.35);
  color: #ecfccb;
}

.tg-chip.is-preferred {
  box-shadow: inset 0 0 0 1px rgba(45, 212, 191, 0.45);
}

.tg-mind-card__tastes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  margin: 0.35rem 0;
}

.tg-mind-card__tastes-label {
  font-size: 0.72rem;
  color: var(--tg-muted);
  margin-right: 0.15rem;
}

.tg-reflect-banner {
  margin: 0 0 0.85rem;
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(245, 158, 11, 0.35);
  background: linear-gradient(135deg, rgba(120, 53, 15, 0.4), rgba(12, 36, 48, 0.92));
  display: grid;
  gap: 0.55rem;
}

.tg-reflect-banner__title {
  font-size: 0.95rem;
  color: #fde68a;
}

.tg-reflect-banner__story {
  margin: 0;
  font-size: 0.84rem;
  color: rgba(236, 252, 203, 0.92);
}

.tg-reflect-banner__choices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.tg-care-cell {
  margin: 0.25rem 0 0.15rem;
  padding: 0.55rem 0.65rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(45, 212, 191, 0.18);
  background: rgba(7, 22, 28, 0.55);
  display: grid;
  gap: 0.35rem;
}

.tg-care-cell__row {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.74rem;
  color: var(--tg-muted);
}

.tg-care-cell__dots {
  letter-spacing: 0.08em;
  color: #a3e635;
}

.tg-care-cell__dots[data-kind="miss"] {
  color: #fbbf24;
}

#tg-stage[data-climate="rain"] {
  filter: saturate(1.05) brightness(0.98);
}

#tg-stage[data-climate="night"] {
  filter: brightness(0.92) saturate(1.08);
}

#tg-stage[data-climate="dawn"] {
  filter: saturate(1.1) hue-rotate(-6deg);
}

.tg-mind-attention__text {
  margin: 0;
  font-size: 0.86rem;
  color: #ecfccb;
}

.tg-adventure-banner {
  margin: 0 0 0.85rem;
  padding: 0.8rem 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(163, 230, 53, 0.3);
  background: linear-gradient(135deg, rgba(20, 83, 45, 0.45), rgba(12, 36, 48, 0.9));
  display: grid;
  gap: 0.5rem;
}

.tg-adventure-banner__title {
  font-size: 0.95rem;
  color: #ecfccb;
}

.tg-adventure-banner__meta {
  margin: 0;
  font-size: 0.78rem;
  color: rgba(226, 232, 240, 0.85);
}

.tg-mind-card {
  display: grid;
  gap: 0.45rem;
}

.tg-mind-card__row {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.8rem;
  color: var(--tg-muted);
}

.tg-mind-card__row strong {
  color: #ecfccb;
}

.tg-mind-card__insight {
  margin: 0.2rem 0 0;
  font-size: 0.84rem;
  color: rgba(236, 252, 203, 0.92);
}

.tg-mind-card__favs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.tg-mind__chip {
  font-size: 0.7rem;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--tg-lime, #c8f542);
}

.tg-season-banner {
  position: relative;
  margin: 0 0 0.85rem;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid rgba(245, 158, 11, 0.35);
  background:
    linear-gradient(135deg, rgba(15, 118, 110, 0.55), rgba(12, 36, 48, 0.92) 55%, rgba(120, 53, 15, 0.45));
  animation: tg-season-in 0.45s ease both;
}

.tg-season-banner[hidden] {
  display: none !important;
}

.tg-season-banner__glow {
  position: absolute;
  inset: -40% auto auto 40%;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(200, 245, 66, 0.28), transparent 70%);
  pointer-events: none;
  animation: tg-season-pulse 3.2s ease-in-out infinite;
}

.tg-season-banner__body {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.85rem;
  align-items: center;
  padding: 0.85rem 1rem;
}

.tg-season-banner__kicker {
  margin: 0;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(236, 252, 203, 0.8);
}

.tg-season-banner__title {
  margin: 0.15rem 0 0.25rem;
  font-size: 1.05rem;
  color: #ecfccb;
}

.tg-season-banner__blurb,
.tg-season-banner__timer {
  margin: 0;
  font-size: 0.78rem;
  color: rgba(226, 232, 240, 0.85);
}

.tg-season-banner__timer {
  margin-top: 0.25rem;
  color: #fbbf24;
}

.tg-season-banner__drop {
  display: grid;
  justify-items: center;
  gap: 0.4rem;
}

.tg-season-banner__drop img {
  width: 52px;
  height: 52px;
  object-fit: contain;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.35));
}

@keyframes tg-season-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

@keyframes tg-season-pulse {
  0%, 100% { opacity: 0.55; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); }
}

@media (max-width: 640px) {
  .tg-season-banner__body {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tg-season-banner,
  .tg-season-banner__glow {
    animation: none;
  }
}

.tg-minigame-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(4, 12, 18, 0.72);
  backdrop-filter: blur(6px);
}

.tg-minigame-overlay[hidden] {
  display: none !important;
}

.tg-minigame-panel {
  width: min(420px, 100%);
  border-radius: 1.1rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(165deg, rgba(18, 36, 48, 0.98), rgba(8, 18, 26, 0.98));
  padding: 0.9rem 1rem 1rem;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
}

.tg-minigame-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}

.tg-minigame-panel__head-main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.65rem;
  min-width: 0;
}

.tg-minigame-panel__title {
  margin: 0;
  font-size: 1.05rem;
}

.tg-minigame-panel__kind {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.12rem 0.4rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--tg-muted);
}

.tg-minigame-panel__kind--care {
  border-color: rgba(94, 234, 212, 0.45);
  color: var(--tg-teal, #5eead4);
}

.tg-minigame-panel__kind--earn {
  border-color: rgba(246, 211, 106, 0.45);
  color: #f6d36a;
}

.tg-minigame-panel__lead {
  margin: 0 0 0.5rem;
  font-size: 0.82rem;
  color: var(--tg-muted);
}

.tg-minigame-panel__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.85rem;
  font-size: 0.85rem;
  margin-bottom: 0.55rem;
}

.tg-minigame-stars {
  color: #f6d36a;
  letter-spacing: 0.1em;
}

.tg-minigame-stage {
  min-height: 200px;
  border-radius: 0.85rem;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  position: relative;
}

.tg-minigame-result {
  margin-top: 0.65rem;
  text-align: center;
}

.tg-minigame-result__stars {
  margin: 0;
  font-size: 1.45rem;
  color: #f6d36a;
  letter-spacing: 0.14em;
}

.tg-minigame-result__score,
.tg-minigame-result__hint {
  margin: 0.25rem 0 0;
  font-size: 0.82rem;
  color: var(--tg-muted);
}

.tg-minigame-panel__foot {
  margin-top: 0.75rem;
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
}

.tg-btn--ghost {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: inherit;
}

.tg-mg-spark {
  display: grid;
  grid-template-columns: repeat(var(--tg-mg-cols, 4), 1fr);
  gap: 0.4rem;
  padding: 0.65rem;
}

.tg-mg-spark__cell {
  aspect-ratio: 1;
  border-radius: 0.55rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(94, 234, 212, 0.08);
  color: var(--tg-lime, #c8f542);
  font-size: 1.15rem;
  cursor: pointer;
}

.tg-mg-spark__cell.is-matched {
  opacity: 0.35;
  pointer-events: none;
}

.tg-mg-pulse {
  position: relative;
  width: 140px;
  height: 140px;
  margin: 1.2rem auto;
  display: grid;
  place-items: center;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.tg-mg-pulse__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(94, 234, 212, 0.35);
  transform: scale(0.65);
  transition: transform 0.35s ease, border-color 0.2s ease;
}

.tg-mg-pulse.is-hot .tg-mg-pulse__ring {
  transform: scale(1);
  border-color: rgba(200, 245, 66, 0.85);
}

.tg-mg-pulse__core {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #fff7, var(--tg-teal, #5eead4));
}

.tg-mg-pulse.is-hit .tg-mg-pulse__core {
  transform: scale(1.12);
}

.tg-mg-rush,
.tg-mg-bubbles {
  position: relative;
  height: 200px;
}

.tg-mg-rush__bit,
.tg-mg-bubbles__bit {
  position: absolute;
  border: 0;
  background: transparent;
  font-size: 1.35rem;
  cursor: pointer;
  animation-timing-function: linear;
  animation-fill-mode: forwards;
}

.tg-mg-rush__bit {
  top: -12%;
  animation-name: tg-mg-fall;
}

.tg-mg-bubbles__bit {
  bottom: -10%;
  color: rgba(125, 211, 252, 0.95);
  animation-name: tg-mg-rise;
}

.tg-mg-bubbles__bit.is-pop {
  transform: scale(1.25);
  opacity: 0;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.tg-mg-rush__bit.is-coin {
  color: #f6d36a;
}

.tg-mg-rush__bit.is-junk {
  color: #f87171;
}

.tg-mg-echo {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
  padding: 0.85rem;
  min-height: 200px;
}

.tg-mg-echo__pad {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 0.85rem;
  min-height: 72px;
  cursor: pointer;
  transition: transform 0.12s ease, filter 0.12s ease, background 0.12s ease;
}

.tg-mg-echo__pad--0 { background: rgba(94, 234, 212, 0.18); }
.tg-mg-echo__pad--1 { background: rgba(200, 245, 66, 0.16); }
.tg-mg-echo__pad--2 { background: rgba(125, 211, 252, 0.18); }
.tg-mg-echo__pad--3 { background: rgba(251, 146, 60, 0.18); }

.tg-mg-echo__pad.is-lit {
  filter: brightness(1.45);
  transform: scale(0.97);
}

.tg-mg-echo.is-demo .tg-mg-echo__pad {
  pointer-events: none;
}

.tg-mg-echo.is-miss {
  animation: tg-mg-shake 0.28s ease;
}

@keyframes tg-mg-fall {
  from {
    transform: translateY(0);
    opacity: 1;
  }
  to {
    transform: translateY(220px);
    opacity: 0.85;
  }
}

@keyframes tg-mg-rise {
  from {
    transform: translateY(0) scale(0.85);
    opacity: 0.85;
  }
  to {
    transform: translateY(-220px) scale(1.05);
    opacity: 0.35;
  }
}

@keyframes tg-mg-shake {
  0%,
  100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

/* ---- Dice pick (Farm Obebubik → solo) ---- */
.tg-dice {
  display: grid;
  gap: 0.55rem;
  padding: 0.65rem;
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.35s ease, transform 0.45s cubic-bezier(0.2, 0.85, 0.25, 1);
}

.tg-dice.is-visible {
  opacity: 1;
  transform: scale(1);
}

.tg-dice__header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
  font-size: 0.82rem;
}

.tg-dice__title { font-weight: 650; }
.tg-dice__picks { color: var(--tg-muted); font-variant-numeric: tabular-nums; }

.tg-dice__timer {
  position: relative;
  height: 0.45rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.tg-dice__timer span {
  position: absolute;
  right: 0;
  top: -1.15rem;
  font-size: 0.72rem;
  color: var(--tg-muted);
}

.tg-dice__timer-fill {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--tg-teal, #5eead4), var(--tg-lime, #c8f542));
  transition: width 0.2s linear;
}

.tg-dice__board-wrap {
  display: grid;
  grid-template-columns: 1fr minmax(6.5rem, 7.5rem);
  gap: 0.65rem;
  align-items: start;
}

.tg-dice__board {
  display: grid;
  grid-template-columns: repeat(var(--tg-dice-side, 5), 1fr);
  gap: 3px;
  aspect-ratio: 1;
  max-width: min(100%, 22rem);
}

.tg-dice__cell {
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.35rem;
  background: rgba(15, 23, 42, 0.55);
  color: #e2e8f0;
  font-size: clamp(0.55rem, 2.1vw, 0.78rem);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  padding: 0;
}

.tg-dice.is-picking .tg-dice__cell:hover {
  border-color: rgba(94, 234, 212, 0.55);
}

.tg-dice__cell.is-selected {
  background: rgba(94, 234, 212, 0.28);
  border-color: rgba(94, 234, 212, 0.85);
  color: #ecfeff;
  box-shadow: inset 0 0 0 1px rgba(200, 245, 66, 0.35);
}

.tg-dice.is-locked .tg-dice__cell,
.tg-dice.is-reveal .tg-dice__cell {
  pointer-events: none;
}

.tg-dice.is-reveal .tg-dice__cell:not(.is-winning):not(.is-hit) {
  opacity: 0.35;
}

.tg-dice__cell.is-winning {
  background: rgba(59, 130, 246, 0.45);
  border-color: #60a5fa;
}

.tg-dice__cell.is-hit {
  background: rgba(34, 197, 94, 0.5);
  border-color: #4ade80;
  animation: tg-dice-hit 0.75s ease-in-out 2;
}

.tg-dice__side {
  display: grid;
  gap: 0.45rem;
}

.tg-dice__hint {
  margin: 0;
  font-size: 0.75rem;
  color: var(--tg-muted);
  line-height: 1.35;
}

.tg-dice__reward {
  text-align: center;
  font-weight: 700;
  padding: 0.4rem;
  border-radius: 0.55rem;
  background: rgba(94, 234, 212, 0.12);
}

.tg-dice__reward.is-jackpot {
  color: var(--tg-lime, #c8f542);
  animation: tg-dice-jackpot 0.85s ease-in-out infinite;
}

.tg-dice.is-outro {
  animation: tg-dice-outro 1s ease-in-out infinite;
}

@keyframes tg-dice-hit {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

@keyframes tg-dice-jackpot {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.25); }
}

@keyframes tg-dice-outro {
  0%, 100% { filter: drop-shadow(0 0 0 transparent); }
  50% { filter: drop-shadow(0 0 12px rgba(200, 245, 66, 0.35)); }
}

/* ---- Fortune wheel ---- */
.tg-wheel {
  display: grid;
  place-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0.5rem 1rem;
}

.tg-wheel__wrap {
  position: relative;
  width: min(100%, 16.5rem);
  aspect-ratio: 1;
  --spin-intensity: 0;
}

.tg-wheel__aura {
  position: absolute;
  inset: -8%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(200, 245, 66, 0.18), transparent 70%);
  animation: tg-wheel-aura 8s linear infinite;
  opacity: calc(0.45 + var(--spin-intensity) * 0.55);
}

.tg-wheel__pointer {
  position: absolute;
  top: -0.15rem;
  left: 50%;
  z-index: 3;
  width: 0;
  height: 0;
  border-left: 0.55rem solid transparent;
  border-right: 0.55rem solid transparent;
  border-top: 0.95rem solid var(--tg-lime, #c8f542);
  transform: translateX(-50%);
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
}

.tg-wheel__disk {
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 0 24px rgba(0, 0, 0, 0.35), 0 8px 28px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.tg-wheel__labels {
  position: absolute;
  inset: 0;
}

.tg-wheel__label {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 4.2rem;
  margin-left: -2.1rem;
  margin-top: -0.55rem;
  transform-origin: 50% 50%;
  text-align: center;
  font-size: 0.62rem;
  font-weight: 650;
  color: #0f172a;
  pointer-events: none;
}

.tg-wheel__label span {
  display: block;
  transform: rotate(90deg);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.35);
}

.tg-wheel__hub {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 2;
  width: 2.4rem;
  height: 2.4rem;
  margin: -1.2rem 0 0 -1.2rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 30% 30%, #fff8, #0f172a 70%);
  border: 2px solid rgba(200, 245, 66, 0.65);
  color: var(--tg-lime, #c8f542);
  font-size: 0.95rem;
}

.tg-wheel__wrap.is-spinning .tg-wheel__hub {
  animation: tg-wheel-hub 0.45s linear infinite;
}

.tg-wheel__prize {
  margin: 0;
  min-height: 1.2rem;
  font-weight: 700;
  text-align: center;
}

.tg-wheel__prize.is-win { color: var(--tg-teal, #5eead4); }
.tg-wheel__prize.is-jackpot {
  color: var(--tg-lime, #c8f542);
  animation: tg-dice-jackpot 0.85s ease-in-out infinite;
}

.tg-wheel__spin { min-width: 8rem; }

@keyframes tg-wheel-aura {
  to { transform: rotate(360deg); }
}

@keyframes tg-wheel-hub {
  to { transform: rotate(360deg); }
}

@media (max-width: 520px) {
  .tg-dice__board-wrap {
    grid-template-columns: 1fr;
  }

  .tg-dice__side {
    grid-template-columns: 1fr 1fr;
    align-items: center;
  }

  .tg-dice__hint {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tg-mg-rush__bit,
  .tg-mg-bubbles__bit {
    animation-duration: 1.4s !important;
  }

  .tg-dice,
  .tg-dice__cell.is-hit,
  .tg-dice__reward.is-jackpot,
  .tg-dice.is-outro,
  .tg-wheel__aura,
  .tg-wheel__hub {
    animation: none !important;
    transition: none !important;
  }

  .tg-mg-pulse__ring,
  .tg-mg-echo__pad,
  .tg-mg-bubbles__bit.is-pop {
    transition: none;
  }

  .tg-mg-echo.is-miss {
    animation: none;
  }
}

.tg-legacy {
  display: grid;
  gap: 0.65rem;
}

.tg-legacy__lead {
  margin: 0;
  font-size: 0.78rem;
  color: var(--tg-muted);
}

.tg-legacy__tree {
  display: grid;
  gap: 0.4rem;
}

.tg-legacy-node {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.45rem 0.55rem;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.75rem;
  padding: 0.5rem 0.65rem;
  background: rgba(0, 0, 0, 0.15);
}

.tg-legacy-node__gen {
  font-size: 0.68rem;
  color: var(--tg-teal, #5eead4);
  border: 1px solid rgba(94, 234, 212, 0.35);
  border-radius: 999px;
  padding: 0.1rem 0.4rem;
}

.tg-legacy-node__name {
  font-size: 0.85rem;
}

.tg-legacy-node__meta {
  grid-column: 2 / -1;
  font-size: 0.72rem;
  color: var(--tg-muted);
}

.tg-legacy__heirloom,
.tg-legacy__legends {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 0.55rem;
}

.tg-legacy__legends-title,
.tg-legacy__heirloom-title {
  font-size: 0.8rem;
  margin: 0 0 0.4rem;
}

.tg-legend {
  display: grid;
  gap: 0.15rem;
  padding: 0.4rem 0.5rem;
  border-radius: 0.55rem;
  border: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 0.35rem;
  opacity: 0.45;
}

.tg-legend.is-unlocked {
  opacity: 1;
  border-color: rgba(200, 245, 66, 0.35);
}

.tg-legend__title {
  font-size: 0.8rem;
}

.tg-legend__lead {
  font-size: 0.72rem;
  color: var(--tg-muted);
}

.tg-memories {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
  max-height: 180px;
  overflow: auto;
}

.tg-memories li {
  font-size: 0.8rem;
  color: var(--tg-muted);
  padding-left: 0.7rem;
  border-left: 2px solid rgba(45, 212, 191, 0.45);
}

.tg-light-overlay {
  position: absolute;
  inset: 0;
  z-index: 11;
  pointer-events: none;
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  mix-blend-mode: soft-light;
  opacity: 0.85;
  transition: opacity 0.45s ease, background-image 0.45s ease;
}

.tg-stage-frame[data-lighting="night"] .tg-light-overlay {
  mix-blend-mode: multiply;
  opacity: 1;
}

.tg-stage-frame[data-lighting="dusk"] .tg-light-overlay {
  mix-blend-mode: color-burn;
  opacity: 0.7;
}

.tg-habitat-controls {
  display: grid;
  gap: 0.85rem;
  margin: 0.9rem 0 1.1rem;
}

.tg-control-block .tg-sideblock__title {
  margin-bottom: 0.4rem;
}

.tg-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

/* Perspective floor plane — logical 4×3 grid, foreshortened for depth */
.tg-room-preview {
  position: absolute;
  inset: auto 4% 4% 4%;
  z-index: 12;
  height: 38%;
  pointer-events: none;
  opacity: 0.92;
  perspective: 900px;
  perspective-origin: 50% 0%;
  transform-style: preserve-3d;
}

.tg-room-preview__plane {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 0.2rem 0.35rem;
  width: 100%;
  height: 100%;
  transform: rotateX(52deg) scale(1.08);
  transform-origin: 50% 100%;
  transform-style: preserve-3d;
}

.tg-room-preview__cell {
  border-radius: 0.35rem;
  background:
    linear-gradient(180deg, rgba(7, 22, 28, 0.08), rgba(7, 22, 28, 0.32));
  border: 1px solid rgba(94, 234, 212, 0.12);
  display: grid;
  place-items: end center;
  align-content: end;
  position: relative;
  overflow: visible;
  min-height: 0;
}

.tg-room-preview__cell img {
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
  object-position: bottom center;
  pointer-events: none;
  transform: rotateX(-52deg) translateY(-6%);
  transform-origin: 50% 100%;
}

.tg-room-grid {
  position: absolute;
  inset: auto 3% 5% 3%;
  z-index: 12;
  height: 48%;
  pointer-events: auto;
  perspective: 1000px;
  perspective-origin: 50% 0%;
  transform-style: preserve-3d;
}

.tg-room-grid__plane {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 0.28rem 0.4rem;
  width: 100%;
  height: 100%;
  transform: rotateX(50deg) scale(1.1);
  transform-origin: 50% 100%;
  transform-style: preserve-3d;
}

.tg-room-cell {
  border: 1px dashed rgba(200, 245, 66, 0.28);
  border-radius: 0.4rem;
  background:
    linear-gradient(180deg, rgba(7, 22, 28, 0.12), rgba(7, 22, 28, 0.38));
  display: grid;
  place-items: end center;
  align-content: end;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  padding: 0.15rem;
  position: relative;
  z-index: 0;
  overflow: visible;
  min-height: 0;
  transform-style: preserve-3d;
}

.tg-room-cell--span {
  border-style: solid;
  border-color: color-mix(in srgb, var(--tg-teal) 40%, transparent);
}

.tg-room-cell:hover,
.tg-room-cell.is-selected {
  border-color: rgba(200, 245, 66, 0.55);
  background: rgba(200, 245, 66, 0.08);
}

.tg-room-grid.is-place-mode .tg-room-cell {
  border-style: solid;
  border-color: rgba(200, 245, 66, 0.38);
  animation: tg-cell-pulse 1.6s ease-in-out infinite;
}

.tg-room-grid.is-place-mode .tg-room-cell.is-ghost-ok {
  animation: none;
  border-color: color-mix(in srgb, var(--tg-lime) 70%, transparent);
  background: color-mix(in srgb, var(--tg-lime) 18%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--tg-lime) 35%, transparent);
}

.tg-room-grid.is-place-mode .tg-room-cell.is-ghost-bad {
  animation: none;
  border-color: color-mix(in srgb, var(--tg-amber) 70%, transparent);
  background: color-mix(in srgb, var(--tg-amber) 16%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--tg-amber) 30%, transparent);
}

.tg-room-grid.is-clear-mode .tg-room-cell.is-selected {
  border-color: rgba(255, 107, 74, 0.65);
  background: rgba(255, 107, 74, 0.12);
}

.tg-card__meta {
  font-size: 0.72rem;
  color: var(--tg-muted);
  font-weight: 700;
  letter-spacing: 0.04em;
}

@keyframes tg-cell-pulse {
  0%, 100% { background: rgba(200, 245, 66, 0.05); }
  50% { background: rgba(200, 245, 66, 0.14); }
}

@media (prefers-reduced-motion: reduce) {
  .tg-room-grid.is-place-mode .tg-room-cell {
    animation: none;
  }
}

.tg-room-cell img {
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
  object-position: bottom center;
  pointer-events: none;
  /* Counter-rotate so furniture stands upright on the tilted floor */
  transform: rotateX(-50deg) translateY(-8%);
  transform-origin: 50% 100%;
}

.tg-room-grid [data-row="0"],
.tg-room-preview [data-row="0"] {
  z-index: 1;
}

.tg-room-grid [data-row="1"],
.tg-room-preview [data-row="1"] {
  z-index: 2;
}

.tg-room-grid [data-row="2"],
.tg-room-preview [data-row="2"] {
  z-index: 3;
}

@media (prefers-reduced-motion: reduce) {
  .tg-room-grid__plane,
  .tg-room-preview__plane {
    transform: none;
  }

  .tg-room-cell img,
  .tg-room-preview__cell img {
    transform: none;
  }
}

.tg-card.is-selected-furn {
  border-color: rgba(200, 245, 66, 0.55);
  box-shadow: 0 0 0 1px rgba(200, 245, 66, 0.22) inset;
}

.tg-profile .tg-panel {
  gap: 1rem;
}

.tg-lead--sm {
  margin: 0 0 0.75rem;
  font-size: 0.92rem;
  opacity: 0.82;
}

.tg-next__chips--follow {
  margin-top: 0.65rem;
}

.tg-field--wide {
  max-width: none;
  width: 100%;
}

.tg-profile-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

.tg-profile-stat {
  padding: 0.7rem 0.85rem;
  border-radius: 12px;
  background: color-mix(in srgb, var(--tg-ink, #07161c) 72%, transparent);
  border: 1px solid color-mix(in srgb, var(--tg-teal, #14b8a6) 35%, transparent);
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.tg-profile-stat__n {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--tg-lime, #ecfccb);
  line-height: 1.1;
}

.tg-profile-stat__l {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--tg-mist, #99f6e4) 80%, transparent);
}

.tg-gift-wallet {
  margin: 0 0 0.65rem;
  font-size: 0.9rem;
  color: var(--tg-lime, #ecfccb);
}

.tg-gifts {
  display: grid;
  gap: 0.55rem;
}

.tg-gift-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.4rem 0.75rem;
  align-items: center;
  padding: 0.7rem 0.85rem;
  border-radius: 12px;
  background: color-mix(in srgb, var(--tg-ink, #07161c) 65%, transparent);
  border: 1px solid color-mix(in srgb, var(--tg-teal, #14b8a6) 28%, transparent);
}

.tg-gift-card__title {
  font-weight: 600;
  color: var(--tg-mist, #f0fdfa);
}

.tg-gift-card__meta {
  grid-column: 1 / -1;
  font-size: 0.82rem;
  color: color-mix(in srgb, var(--tg-mist, #99f6e4) 78%, transparent);
}

.tg-gift-card .is-gated {
  opacity: 0.72;
}

.tg-gift-feed {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}

.tg-gift-feed li {
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  background: color-mix(in srgb, var(--tg-ink, #07161c) 58%, transparent);
  border: 1px solid color-mix(in srgb, var(--tg-teal, #14b8a6) 22%, transparent);
  font-size: 0.9rem;
}

.tg-gift-feed__who {
  color: var(--tg-lime, #a3e635);
  font-weight: 600;
}

.tg-friend-list,
.tg-guestbook,
.tg-visit-feed__list {
  list-style: none;
  margin: 0.65rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.45rem;
}

.tg-friend-list__row,
.tg-guestbook li,
.tg-visit-feed__list li {
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  background: color-mix(in srgb, var(--tg-ink, #07161c) 58%, transparent);
  border: 1px solid color-mix(in srgb, var(--tg-teal, #14b8a6) 22%, transparent);
  font-size: 0.9rem;
}

.tg-friend-list__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.tg-friend-list__meta {
  background: transparent;
  border: none;
  padding: 0;
  font-size: 0.82rem;
  color: color-mix(in srgb, var(--tg-mist, #99f6e4) 72%, transparent);
}

.tg-friend-list__link,
.tg-guestbook__link,
.tg-visit-feed__link {
  color: var(--tg-lime, #a3e635);
  text-decoration: none;
}

.tg-guestbook__who,
.tg-visit-feed__who {
  color: var(--tg-lime, #a3e635);
  font-weight: 600;
}

.tg-visit-feed__label {
  margin: 0.75rem 0 0;
  font-size: 0.82rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--tg-mist, #99f6e4) 78%, transparent);
}

.tg-share-cta {
  margin-top: 0.65rem;
}

@media (max-width: 720px) {
  .tg-social-dock .tg-btn {
    width: 100%;
  }
}
