/*
Theme Name: Tradefy Platform
Theme URI: https://example.com/tradefy
Author: Tradefy
Author URI: https://example.com
Description: Trading platform theme with landing page, member area placeholders, live chat layout, and results tracking UI.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
Text Domain: tradefy
*/

:root {
  --tf-font: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  --tf-radius-xl: 32px;
  --tf-radius-lg: 24px;
  --tf-radius-md: 18px;
  --tf-radius-sm: 14px;
  --tf-shell-width: 1240px;
  --tf-transition: 180ms ease;
}

html[data-theme="light"] {
  --tf-bg: #f6f3ec;
  --tf-bg-soft: #fffaf1;
  --tf-surface: rgba(255, 255, 255, 0.84);
  --tf-surface-strong: #ffffff;
  --tf-surface-muted: rgba(250, 244, 232, 0.9);
  --tf-text: #171411;
  --tf-text-soft: #5f564d;
  --tf-border: rgba(184, 149, 73, 0.24);
  --tf-gold: #b89549;
  --tf-gold-soft: rgba(184, 149, 73, 0.14);
  --tf-gold-strong: #8d6a22;
  --tf-shadow: 0 24px 60px rgba(32, 20, 4, 0.09);
  --tf-glow: radial-gradient(circle at top right, rgba(184, 149, 73, 0.28), transparent 38%);
}

html[data-theme="dark"] {
  --tf-bg: #090909;
  --tf-bg-soft: #111111;
  --tf-surface: rgba(18, 18, 18, 0.88);
  --tf-surface-strong: #171717;
  --tf-surface-muted: rgba(24, 24, 24, 0.95);
  --tf-text: #f5f1e6;
  --tf-text-soft: #b8b0a1;
  --tf-border: rgba(201, 160, 74, 0.24);
  --tf-gold: #d5af4d;
  --tf-gold-soft: rgba(213, 175, 77, 0.12);
  --tf-gold-strong: #f1d17d;
  --tf-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  --tf-glow: radial-gradient(circle at top right, rgba(213, 175, 77, 0.18), transparent 36%);
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--tf-font);
  color: var(--tf-text);
  background:
    radial-gradient(circle at left top, rgba(255, 255, 255, 0.04), transparent 28%),
    var(--tf-glow),
    linear-gradient(180deg, var(--tf-bg-soft) 0%, var(--tf-bg) 100%);
  line-height: 1.6;
}

body.admin-bar .tf-site-header {
  top: 32px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
}

button,
input,
textarea,
select {
  font: inherit;
}

.tf-site-shell {
  min-height: 100vh;
}

.tf-container {
  width: min(calc(100% - 32px), var(--tf-shell-width));
  margin: 0 auto;
}

.tf-site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(18px);
  background: rgba(10, 10, 10, 0.35);
  border-bottom: 1px solid var(--tf-border);
}

html[data-theme="light"] .tf-site-header {
  background: rgba(246, 243, 236, 0.78);
}

.tf-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 0;
}

.tf-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.tf-brand-mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  font-weight: 800;
  color: #0d0d0d;
  background: linear-gradient(135deg, var(--tf-gold-strong) 0%, var(--tf-gold) 100%);
  box-shadow: var(--tf-shadow);
}

.tf-brand-text strong,
.tf-brand-text span {
  display: block;
}

.tf-brand-text strong {
  font-size: 0.98rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tf-brand-text span {
  color: var(--tf-text-soft);
  font-size: 0.83rem;
}

.tf-header-nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.tf-nav-list {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tf-nav-list a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--tf-text-soft);
  font-weight: 600;
}

.tf-nav-list a:hover,
.tf-nav-list a:focus {
  color: var(--tf-text);
}

.tf-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.tf-header-chat-badge {
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: #c96868;
  box-shadow: 0 10px 24px rgba(201, 104, 104, 0.28);
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1;
}

.tf-theme-toggle,
.tf-button,
.tf-mini-button {
  border: 0;
  border-radius: 999px;
  transition:
    transform var(--tf-transition),
    background-color var(--tf-transition),
    color var(--tf-transition),
    border-color var(--tf-transition);
}

.tf-theme-toggle {
  min-width: 46px;
  height: 46px;
  color: var(--tf-text);
  background: var(--tf-surface);
  border: 1px solid var(--tf-border);
  cursor: pointer;
}

.tf-theme-toggle:hover,
.tf-theme-toggle:focus,
.tf-button:hover,
.tf-button:focus,
.tf-mini-button:hover,
.tf-mini-button:focus {
  transform: translateY(-1px);
}

.tf-button,
.tf-mini-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 20px;
  font-weight: 700;
  cursor: pointer;
}

.tf-button-primary {
  color: #0c0c0c;
  background: linear-gradient(135deg, var(--tf-gold-strong) 0%, var(--tf-gold) 100%);
  box-shadow: var(--tf-shadow);
}

.tf-button-secondary {
  color: var(--tf-text);
  background: var(--tf-surface);
  border: 1px solid var(--tf-border);
}

.tf-button-ghost {
  color: var(--tf-text-soft);
  background: transparent;
  border: 1px solid var(--tf-border);
}

.tf-site-main {
  padding: 32px 0 72px;
}

.tf-hero {
  padding: 28px 0 18px;
}

.tf-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(330px, 0.75fr);
  gap: 24px;
}

.tf-panel,
.tf-stat-card,
.tf-feature-card,
.tf-step-card,
.tf-results-panel,
.tf-access-panel,
.tf-chat-shell,
.tf-page-shell,
.tf-empty-state,
.tf-journal-card {
  border: 1px solid var(--tf-border);
  border-radius: var(--tf-radius-lg);
  background: var(--tf-surface);
  box-shadow: var(--tf-shadow);
}

.tf-panel,
.tf-results-panel,
.tf-access-panel,
.tf-page-shell,
.tf-empty-state,
.tf-journal-card {
  padding: 28px;
}

.tf-hero-copy {
  padding: 38px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.03), transparent),
    var(--tf-surface);
}

.tf-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--tf-gold-soft);
  color: var(--tf-gold-strong);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tf-hero-title,
.tf-page-title,
.tf-section-title {
  margin: 18px 0 12px;
  line-height: 1;
}

.tf-hero-title {
  font-size: clamp(2.9rem, 8vw, 5.6rem);
}

.tf-page-title {
  font-size: clamp(2rem, 5vw, 3.4rem);
}

.tf-section-title {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
}

.tf-lead,
.tf-section-copy,
.tf-muted {
  color: var(--tf-text-soft);
}

.tf-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.tf-hero-points {
  display: grid;
  gap: 14px;
}

.tf-point {
  padding: 18px 20px;
  border-radius: var(--tf-radius-md);
  border: 1px solid var(--tf-border);
  background: var(--tf-surface-muted);
}

.tf-point strong,
.tf-feature-card h3,
.tf-step-card h3,
.tf-stat-card strong,
.tf-journal-card h3 {
  display: block;
  margin-bottom: 8px;
  font-size: 1.05rem;
}

.tf-point span,
.tf-feature-card p,
.tf-step-card p,
.tf-journal-card p {
  color: var(--tf-text-soft);
}

.tf-grid {
  display: grid;
  gap: 20px;
}

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

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

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

.tf-feature-card,
.tf-step-card,
.tf-stat-card {
  padding: 24px;
}

.tf-stat-card {
  min-height: 170px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03) 0%, transparent 100%),
    var(--tf-surface);
}

.tf-stat-label {
  margin-bottom: 14px;
  color: var(--tf-text-soft);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tf-stat-value {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  line-height: 1;
}

.tf-section {
  padding: 26px 0;
}

.tf-section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.tf-step-index {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--tf-gold-strong), var(--tf-gold));
  color: #0c0c0c;
  font-weight: 800;
}

.tf-preview-card {
  padding: 24px;
  border-radius: var(--tf-radius-lg);
  border: 1px solid var(--tf-border);
  background: linear-gradient(180deg, var(--tf-surface) 0%, transparent 180%);
}

.tf-preview-card + .tf-preview-card {
  margin-top: 20px;
}

.tf-preview-row,
.tf-summary-row,
.tf-journal-row,
.tf-chat-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.tf-preview-row + .tf-preview-row,
.tf-summary-row + .tf-summary-row,
.tf-journal-row + .tf-journal-row,
.tf-chat-row + .tf-chat-row {
  margin-top: 14px;
}

.tf-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--tf-gold-soft);
  color: var(--tf-gold-strong);
  font-size: 0.82rem;
  font-weight: 800;
}

.tf-chip-positive {
  background: rgba(30, 177, 98, 0.14);
  color: #1ea75f;
}

.tf-chip-neutral {
  background: rgba(122, 122, 122, 0.16);
  color: var(--tf-text-soft);
}

.tf-chip-warning {
  background: rgba(230, 168, 24, 0.14);
  color: #d39a12;
}

.tf-cta-banner {
  padding: 36px;
  background:
    radial-gradient(circle at top right, rgba(213, 175, 77, 0.15), transparent 34%),
    linear-gradient(135deg, var(--tf-surface) 0%, var(--tf-surface-muted) 100%);
}

.tf-cta-banner h2 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
}

.tf-access-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 22px;
}

.tf-access-list {
  margin: 0;
  padding-left: 18px;
  color: var(--tf-text-soft);
}

.tf-access-list li + li {
  margin-top: 10px;
}

.tf-page-hero {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.tf-page-shell {
  overflow: hidden;
}

.tf-card-stack {
  display: grid;
  gap: 20px;
}

.tf-member-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: 22px;
}

.tf-member-onboarding {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
  padding: 22px 24px;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 20px;
  background:
    radial-gradient(circle at right top, rgba(208, 168, 79, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.018), rgba(255, 255, 255, 0)),
    rgba(10, 10, 10, 0.76);
}

html[data-theme="light"] .tf-member-onboarding {
  background:
    radial-gradient(circle at right top, rgba(184, 140, 42, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.94)),
    #ffffff;
}

.tf-member-onboarding-copy {
  max-width: 42rem;
}

.tf-member-onboarding-copy h2 {
  margin: 8px 0 10px;
  font-size: clamp(1.3rem, 2vw, 1.8rem);
  font-weight: 300;
  letter-spacing: -0.05em;
}

.tf-member-onboarding-copy p {
  margin: 0;
  color: var(--tf-text-soft);
  font-size: 0.92rem;
  line-height: 1.7;
}

.tf-member-onboarding-actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.tf-member-onboarding-actions .tf-button {
  min-height: 48px;
  min-width: 168px;
}

.tf-sidebar-stack {
  display: grid;
  gap: 20px;
}

.tf-list {
  margin: 0;
  padding-left: 18px;
}

.tf-list li + li {
  margin-top: 10px;
}

.tf-mini-button {
  min-height: 42px;
  padding: 0 16px;
}

.tf-chat-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  overflow: hidden;
}

.tf-chat-sidebar,
.tf-chat-main {
  padding: 24px;
}

.tf-chat-sidebar {
  border-right: 1px solid var(--tf-border);
  background: var(--tf-surface-muted);
}

.tf-room-card {
  padding: 14px 16px;
  border-radius: var(--tf-radius-sm);
  border: 1px solid var(--tf-border);
  background: var(--tf-surface);
}

.tf-room-card + .tf-room-card {
  margin-top: 12px;
}

.tf-room-card-active {
  background: var(--tf-gold-soft);
}

.tf-chat-main {
  display: grid;
  gap: 18px;
}

.tf-chat-feed {
  display: grid;
  gap: 18px;
}

.tf-message {
  max-width: 680px;
  padding: 18px 20px;
  border-radius: 20px;
  border: 1px solid var(--tf-border);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0)),
    var(--tf-surface-muted);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.14);
}

.tf-message-own {
  margin-left: auto;
  background:
    linear-gradient(135deg, rgba(208, 168, 79, 0.18), rgba(208, 168, 79, 0.08)),
    var(--tf-gold-soft);
}

.tf-message-system {
  max-width: 100%;
  background:
    linear-gradient(135deg, rgba(208, 168, 79, 0.14), rgba(208, 168, 79, 0.04)),
    rgba(255, 255, 255, 0.02);
}

.tf-message-meta {
  margin-bottom: 6px;
  color: var(--tf-text-soft);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tf-chat-composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
}

.tf-chat-composer textarea {
  min-height: 94px;
  padding: 14px 16px;
  border: 1px solid var(--tf-border);
  border-radius: var(--tf-radius-md);
  color: var(--tf-text);
  background: var(--tf-surface-muted);
  resize: vertical;
}

.tf-results-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 22px;
}

.tf-results-table {
  width: 100%;
  border-collapse: collapse;
}

.tf-results-table th,
.tf-results-table td {
  padding: 14px 0;
  border-bottom: 1px solid var(--tf-border);
  text-align: left;
}

.tf-results-table th {
  color: var(--tf-text-soft);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tf-results-table td:last-child,
.tf-results-table th:last-child {
  text-align: right;
}

.tf-rr-positive {
  color: #1ea75f;
  font-weight: 800;
}

.tf-rr-negative {
  color: #d65757;
  font-weight: 800;
}

.tf-note {
  padding: 14px 16px;
  border-radius: var(--tf-radius-sm);
  border: 1px dashed var(--tf-border);
  color: var(--tf-text-soft);
}

.tf-site-footer {
  padding: 34px 0 42px;
  border-top: 1px solid var(--tf-border);
}

.tf-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--tf-text-soft);
}

.tf-footer-row p {
  margin: 0;
}

.tf-post-grid {
  display: grid;
  gap: 18px;
}

.tf-article-card {
  padding: 24px;
  border: 1px solid var(--tf-border);
  border-radius: var(--tf-radius-lg);
  background: var(--tf-surface);
  box-shadow: var(--tf-shadow);
}

.tf-article-card h2,
.tf-article-card h1 {
  margin-top: 0;
}

.tf-article-meta {
  color: var(--tf-text-soft);
  font-size: 0.88rem;
}

@media (max-width: 1100px) {
  .tf-hero-grid,
  .tf-member-grid,
  .tf-results-layout,
  .tf-access-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 900px) {
  .tf-header-row,
  .tf-page-hero,
  .tf-section-head,
  .tf-footer-row {
    display: grid;
    justify-content: initial;
  }

  .tf-chat-shell {
    grid-template-columns: 1fr;
  }

  .tf-chat-sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--tf-border);
  }

  .tf-grid-3,
  .tf-grid-2 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  body.admin-bar .tf-site-header {
    top: 46px;
  }

  .tf-header-actions,
  .tf-header-nav,
  .tf-nav-list {
    flex-wrap: wrap;
  }

  .tf-grid-4 {
    grid-template-columns: 1fr;
  }

  .tf-hero-copy,
  .tf-panel,
  .tf-results-panel,
  .tf-access-panel,
  .tf-page-shell,
  .tf-journal-card,
  .tf-empty-state,
  .tf-cta-banner {
    padding: 22px;
  }

  .tf-hero-title {
    font-size: 2.8rem;
  }
}

/* Refined minimal direction */

:root {
  --tf-font: "Jost", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --tf-radius-xl: 22px;
  --tf-radius-lg: 14px;
  --tf-radius-md: 10px;
  --tf-radius-sm: 8px;
}

html[data-theme="light"] {
  --tf-bg: #ffffff;
  --tf-bg-soft: #ffffff;
  --tf-surface: transparent;
  --tf-surface-strong: #ffffff;
  --tf-surface-muted: rgba(255, 255, 255, 0.72);
  --tf-text: #0d0d0d;
  --tf-text-soft: #6a6a6a;
  --tf-border: rgba(184, 140, 42, 0.22);
  --tf-gold: #b88c2a;
  --tf-gold-soft: rgba(184, 140, 42, 0.1);
  --tf-gold-strong: #9f7417;
  --tf-shadow: none;
  --tf-glow: radial-gradient(circle at 84% 14%, rgba(184, 140, 42, 0.18), transparent 34%);
}

html[data-theme="dark"] {
  --tf-bg: #000000;
  --tf-bg-soft: #000000;
  --tf-surface: transparent;
  --tf-surface-strong: #000000;
  --tf-surface-muted: rgba(255, 255, 255, 0.02);
  --tf-text: #ffffff;
  --tf-text-soft: #b5b0a8;
  --tf-border: rgba(208, 168, 79, 0.22);
  --tf-gold: #d0a84f;
  --tf-gold-soft: rgba(208, 168, 79, 0.1);
  --tf-gold-strong: #e4c57b;
  --tf-shadow: none;
  --tf-glow: radial-gradient(circle at 84% 14%, rgba(208, 168, 79, 0.12), transparent 34%);
}

body {
  font-family: var(--tf-font);
  font-weight: 300;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  background:
    radial-gradient(circle at left top, rgba(255, 255, 255, 0.02), transparent 24%),
    var(--tf-glow),
    linear-gradient(180deg, var(--tf-bg) 0%, var(--tf-bg-soft) 100%);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 300;
  letter-spacing: -0.05em;
}

.tf-site-header {
  background: rgba(0, 0, 0, 0.88);
  border-bottom: 1px solid var(--tf-border);
  backdrop-filter: blur(10px);
}

html[data-theme="light"] .tf-site-header {
  background: rgba(255, 255, 255, 0.92);
}

.tf-header-row {
  padding: 14px 0;
}

.tf-brand {
  gap: 10px;
}

.tf-brand-mark {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--tf-gold);
  box-shadow: none;
}

.tf-brand-text strong {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tf-brand-text span {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tf-nav-list {
  gap: 16px;
}

.tf-nav-list a {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.tf-header-actions {
  gap: 10px;
}

.tf-theme-toggle {
  min-width: auto;
  height: 40px;
  min-width: 40px;
  padding: 0 12px;
  background: transparent;
}

.tf-theme-icon {
  display: inline-block;
  font-size: 1rem;
  line-height: 1;
}

.tf-button,
.tf-mini-button {
  min-height: 46px;
  padding: 0 18px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.tf-button-primary {
  color: #000000;
  background: var(--tf-gold);
  box-shadow: none;
}

.tf-button-secondary,
.tf-button-ghost {
  color: var(--tf-text);
  background: transparent;
  border: 1px solid var(--tf-border);
}

.tf-button-danger {
  color: #d87373;
  background: transparent;
  border: 1px solid rgba(216, 115, 115, 0.36);
}

.tf-button-danger:hover,
.tf-button-danger:focus {
  border-color: rgba(216, 115, 115, 0.54);
  color: #f09a9a;
}

.tf-panel,
.tf-stat-card,
.tf-feature-card,
.tf-step-card,
.tf-results-panel,
.tf-access-panel,
.tf-chat-shell,
.tf-page-shell,
.tf-empty-state,
.tf-journal-card,
.tf-preview-card,
.tf-article-card {
  background: transparent;
  box-shadow: none;
}

.tf-kicker {
  min-height: auto;
  padding: 0;
  background: transparent;
  color: var(--tf-gold);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
}

.tf-page-title {
  font-size: clamp(1.9rem, 4vw, 3rem);
}

.tf-section-title {
  font-size: clamp(1.4rem, 3vw, 2rem);
}

.tf-site-main {
  padding: 10px 0 56px;
}

.tf-home-hero {
  padding: 52px 0 28px;
}

.tf-home-heading {
  max-width: 760px;
  margin-bottom: 34px;
}

.tf-home-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 0.95fr);
  gap: 28px;
  align-items: start;
}

.tf-home-title {
  margin: 16px 0 14px;
  font-size: clamp(2.7rem, 6vw, 5.2rem);
  line-height: 0.98;
  letter-spacing: -0.065em;
  font-weight: 300;
}

.tf-home-copy {
  max-width: 38rem;
  margin: 0;
  color: var(--tf-text-soft);
  font-size: 1.04rem;
  line-height: 1.75;
}

.tf-home-stack {
  display: grid;
  gap: 16px;
}

.tf-home-card {
  display: block;
  padding: 24px 28px;
  border: 1px solid var(--tf-border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.02);
  transition:
    transform var(--tf-transition),
    border-color var(--tf-transition),
    background-color var(--tf-transition);
}

html[data-theme="light"] .tf-home-card {
  background: rgba(255, 255, 255, 0.92);
}

.tf-home-card:hover,
.tf-home-card:focus {
  transform: translateY(-2px);
  border-color: rgba(208, 168, 79, 0.48);
}

.tf-home-card-active {
  background: linear-gradient(135deg, rgba(208, 168, 79, 0.14) 0%, rgba(255, 255, 255, 0.02) 100%);
}

.tf-home-card-tag,
.tf-home-panel-kicker {
  display: block;
  margin-bottom: 10px;
  color: var(--tf-gold);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tf-home-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.42rem;
  line-height: 1.25;
  font-weight: 500;
  letter-spacing: -0.04em;
}

.tf-home-card span:last-child {
  color: var(--tf-text-soft);
  font-size: 0.98rem;
  line-height: 1.7;
}

.tf-home-panel {
  padding: 36px;
  border: 1px solid var(--tf-border);
  border-radius: 22px;
  background:
    radial-gradient(circle at top right, rgba(208, 168, 79, 0.12), transparent 44%),
    rgba(255, 255, 255, 0.02);
}

html[data-theme="light"] .tf-home-panel {
  background:
    radial-gradient(circle at top right, rgba(184, 140, 42, 0.14), transparent 44%),
    #ffffff;
}

.tf-home-panel h2 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 4vw, 3.15rem);
  line-height: 1.05;
  letter-spacing: -0.055em;
  font-weight: 300;
}

.tf-home-panel p {
  margin: 0;
  color: var(--tf-text-soft);
  font-size: 1rem;
  line-height: 1.75;
}

.tf-home-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
}

.tf-home-login,
.tf-home-signup {
  min-height: 54px;
  font-size: 0.96rem;
}

.tf-home-login {
  min-width: 142px;
}

.tf-home-signup {
  min-width: 232px;
}

.tf-home-statline {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--tf-border);
}

.tf-home-stat {
  padding: 16px 18px 18px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(208, 168, 79, 0.12);
}

html[data-theme="light"] .tf-home-stat {
  background: rgba(247, 244, 236, 0.9);
}

.tf-home-stat span {
  display: block;
  margin-bottom: 10px;
  color: var(--tf-text-soft);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.tf-home-stat strong {
  display: block;
  color: var(--tf-text);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
  letter-spacing: -0.06em;
  font-weight: 500;
}

@media (max-width: 1100px) {
  .tf-home-shell {
    grid-template-columns: 1fr;
  }

  .tf-member-onboarding {
    display: grid;
    justify-content: initial;
  }
}

@media (max-width: 720px) {
  .tf-home-hero {
    padding-top: 36px;
  }

  .tf-home-panel {
    padding: 26px;
  }

  .tf-home-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .tf-member-onboarding-actions {
    display: grid;
  }

  .tf-home-login,
  .tf-home-signup {
    width: 100%;
    justify-content: center;
  }

  .tf-home-statline {
    grid-template-columns: 1fr;
    gap: 18px;
  }
}

/* Live chat MVP */

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

.tf-chat-live {
  min-height: 720px;
}

.tf-chat-shell {
  grid-template-columns: 340px minmax(0, 1fr);
  background:
    radial-gradient(circle at top left, rgba(213, 175, 77, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.06));
}

.tf-chat-sidebar-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.tf-chat-sidebar-head h3 {
  margin: 0 0 6px;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.tf-chat-sidebar-head p {
  margin: 0;
}

.tf-chat-sidebar {
  padding: 30px 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0)),
    var(--tf-surface-muted);
  box-shadow: inset -1px 0 0 rgba(208, 168, 79, 0.08);
}

.tf-chat-room-list {
  display: grid;
  gap: 14px;
  align-content: start;
}

button.tf-room-card {
  width: 100%;
  text-align: left;
  cursor: pointer;
  position: relative;
  min-height: 104px;
  padding: 18px 18px 16px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01)),
    rgba(11, 11, 11, 0.74);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.16);
  transition:
    transform var(--tf-transition),
    border-color var(--tf-transition),
    box-shadow var(--tf-transition),
    background-color var(--tf-transition);
}

button.tf-room-card:hover,
button.tf-room-card:focus {
  transform: translateY(-2px);
  border-color: rgba(208, 168, 79, 0.34);
  box-shadow: 0 22px 46px rgba(0, 0, 0, 0.22);
}

.tf-room-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.04rem;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.tf-room-card span {
  display: block;
  line-height: 1.6;
}

.tf-room-card-meta {
  margin-top: 14px;
  color: var(--tf-gold);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.tf-room-card-active {
  border-color: rgba(208, 168, 79, 0.58);
  background:
    linear-gradient(180deg, rgba(208, 168, 79, 0.16), rgba(255, 255, 255, 0.02)),
    rgba(14, 14, 14, 0.82);
  box-shadow:
    0 24px 54px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.tf-room-card-unread {
  border-color: rgba(201, 104, 104, 0.64);
  box-shadow:
    0 0 0 1px rgba(201, 104, 104, 0.18),
    0 20px 44px rgba(201, 104, 104, 0.12);
}

.tf-room-card-unread .tf-room-card-meta {
  color: #c96868;
}

.tf-room-card-locked {
  opacity: 0.76;
}

.tf-chat-add-month,
.tf-chat-next-month,
.tf-trade-edit {
  min-height: 38px;
}

.tf-chat-main {
  min-height: 720px;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  padding: 30px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.015), rgba(255, 255, 255, 0)),
    rgba(8, 8, 8, 0.22);
}

.tf-chat-main-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--tf-border);
}

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

.tf-chat-room-title {
  margin: 10px 0 6px;
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 400;
  letter-spacing: -0.05em;
}

.tf-chat-room-description {
  margin: 0;
  max-width: 42rem;
}

.tf-chat-status {
  min-height: 20px;
  color: var(--tf-text-soft);
  font-size: 0.76rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tf-chat-status[data-tone="success"] {
  color: var(--tf-gold);
}

.tf-chat-status[data-tone="error"] {
  color: #c96868;
}

.tf-chat-status[data-tone="warning"] {
  color: #d39a12;
}

.tf-chat-feed {
  min-height: 0;
  max-height: 520px;
  overflow-y: auto;
  padding: 4px 10px 4px 0;
  align-content: start;
}

.tf-chat-feed::-webkit-scrollbar {
  width: 8px;
}

.tf-chat-feed::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(208, 168, 79, 0.24);
}

.tf-message {
  width: min(100%, 760px);
}

.tf-trade-message-block {
  width: min(100%, 620px);
}

.tf-message-body {
  color: var(--tf-text);
  line-height: 1.7;
  word-break: break-word;
}

.tf-trade-card {
  border: 1px solid var(--tf-border);
  border-left: 3px solid var(--tf-gold);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
  overflow: hidden;
  width: 100%;
}

html[data-theme="light"] .tf-trade-card {
  background: rgba(255, 255, 255, 0.94);
}

.tf-trade-card-shell {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  padding: 16px 18px;
}

.tf-trade-card-shell-no-image {
  grid-template-columns: minmax(0, 1fr);
}

.tf-trade-card-content {
  min-width: 0;
}

.tf-trade-card-image {
  display: block;
  padding: 0;
  width: 112px;
  height: 84px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--tf-border);
  background: transparent;
  cursor: zoom-in;
}

.tf-trade-card-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.tf-trade-card-meta {
  margin-bottom: 10px;
  color: var(--tf-text-soft);
  font-size: 0.82rem;
  font-weight: 700;
}

.tf-trade-card-head {
  padding: 0;
}

.tf-trade-card-title {
  font-size: 0.96rem;
  font-weight: 500;
  letter-spacing: -0.03em;
  text-transform: uppercase;
}

.tf-trade-card-body {
  padding: 10px 0 0;
}

.tf-trade-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px 14px;
}

.tf-trade-card-detail {
  display: grid;
  gap: 3px;
}

.tf-trade-card-detail span {
  color: var(--tf-text-soft);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.tf-trade-card-detail strong {
  font-size: 0.94rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-trade-card-notes {
  margin: 10px 0 0;
  color: var(--tf-text-soft);
  font-size: 0.84rem;
  line-height: 1.6;
}

.tf-trade-live-panel {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(208, 168, 79, 0.18);
}

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

.tf-trade-live-head span {
  color: var(--tf-gold);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.tf-trade-live-head strong {
  color: var(--tf-text-soft);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.tf-trade-live-sparkline {
  display: block;
  width: 100%;
  height: 56px;
  overflow: visible;
}

.tf-trade-live-sparkline path {
  transition:
    stroke var(--tf-transition),
    fill var(--tf-transition);
}

.tf-trade-live-sparkline [data-live-sparkline-area] {
  fill: rgba(208, 168, 79, 0.1);
}

.tf-trade-live-sparkline [data-live-sparkline-line] {
  fill: none;
  stroke: rgba(208, 168, 79, 0.9);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tf-trade-live-sparkline.is-positive [data-live-sparkline-area] {
  fill: rgba(30, 167, 95, 0.12);
}

.tf-trade-live-sparkline.is-positive [data-live-sparkline-line] {
  stroke: #1ea75f;
}

.tf-trade-live-sparkline.is-negative [data-live-sparkline-area] {
  fill: rgba(214, 87, 87, 0.12);
}

.tf-trade-live-sparkline.is-negative [data-live-sparkline-line] {
  stroke: #d65757;
}

.tf-trade-live-sparkline.is-flat [data-live-sparkline-area] {
  fill: rgba(208, 168, 79, 0.08);
}

.tf-trade-live-sparkline.is-flat [data-live-sparkline-line] {
  stroke: rgba(208, 168, 79, 0.55);
}

.tf-trade-live-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.tf-trade-live-cell {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border: 1px solid rgba(208, 168, 79, 0.16);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

html[data-theme="light"] .tf-trade-live-cell {
  background: rgba(248, 244, 236, 0.78);
}

.tf-trade-live-cell span {
  color: var(--tf-text-soft);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.tf-trade-live-cell strong {
  font-size: 0.96rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.tf-trade-card-footer {
  padding: 12px 0 0;
  align-items: end;
  flex-wrap: wrap;
}

.tf-trade-card-result {
  display: grid;
  gap: 4px;
}

.tf-trade-card-result strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.tf-trade-editor {
  padding: 22px;
  border: 1px solid var(--tf-border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.02);
}

.tf-trade-editor-head,
.tf-results-panel-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
}

.tf-trade-editor-head h3 {
  margin: 8px 0 0;
  font-size: 1.4rem;
  font-weight: 400;
  letter-spacing: -0.04em;
}

.tf-trade-editor-form {
  display: grid;
  gap: 18px;
  margin-top: 18px;
}

.tf-trade-editor-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.tf-trade-editor-note {
  max-width: 42rem;
  font-size: 0.8rem;
  line-height: 1.6;
}

.tf-trade-editor-buttons {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

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

.tf-chat-compose-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tf-chat-compose-modes {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.tf-chat-mode {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--tf-border);
  border-radius: 999px;
  color: var(--tf-text-soft);
  background: transparent;
  cursor: pointer;
  transition:
    border-color var(--tf-transition),
    color var(--tf-transition),
    background-color var(--tf-transition);
}

.tf-chat-mode-active {
  color: var(--tf-text);
  border-color: rgba(208, 168, 79, 0.54);
  background: rgba(208, 168, 79, 0.1);
}

.tf-chat-trade-fields {
  display: grid;
  gap: 14px;
}

.tf-chat-trade-notes {
  min-height: 120px;
  padding-top: 14px;
  padding-bottom: 14px;
  resize: vertical;
}

.tf-chat-file-input {
  padding-top: 12px;
  padding-bottom: 12px;
}

.tf-chat-composer {
  grid-template-columns: 1fr;
  gap: 14px;
  padding-top: 18px;
  border-top: 1px solid var(--tf-border);
}

.tf-chat-composer textarea {
  min-height: 118px;
}

.tf-chat-composer textarea:disabled,
.tf-chat-composer button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.tf-chat-composer-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tf-chat-composer-actions .tf-muted {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.tf-results-filter {
  width: min(100%, 280px);
}

.tf-results-panel-head {
  margin-bottom: 18px;
}

.tf-portfolio-notice {
  margin-bottom: 22px;
}

.tf-portfolio-notice-error {
  border-color: rgba(201, 104, 104, 0.36);
  color: #d87373;
}

.tf-portfolio-form {
  display: grid;
  gap: 18px;
}

.tf-portfolio-selection-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.tf-portfolio-action-form {
  display: flex;
  justify-content: flex-end;
}

.tf-portfolio-action-form .tf-mini-button {
  min-width: 132px;
}

[data-portfolio-toggle]:disabled {
  cursor: progress;
  opacity: 0.72;
}

.tf-portfolio-select-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 160px;
  padding: 10px 16px;
  border: 1px solid var(--tf-border);
  border-radius: 999px;
  cursor: pointer;
  transition:
    border-color var(--tf-transition),
    background-color var(--tf-transition),
    color var(--tf-transition);
}

.tf-portfolio-select-pill:hover {
  border-color: rgba(208, 168, 79, 0.48);
}

.tf-portfolio-select-pill input {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: var(--tf-gold);
}

.tf-portfolio-select-pill span {
  display: inline-block;
  font-weight: 500;
}

.tf-portfolio-select-pill:has(input:checked) {
  border-color: rgba(208, 168, 79, 0.58);
  background: rgba(208, 168, 79, 0.1);
}

.tf-results-calendar-panel {
  margin-top: 22px;
  overflow-x: auto;
}

.tf-trades-notice {
  margin-bottom: 18px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--tf-text-soft);
  box-shadow: none;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tf-trades-notice[data-tone="success"] {
  border-style: solid;
  border-color: rgba(30, 167, 95, 0.28);
  color: #1ea75f;
}

.tf-trades-notice[data-tone="error"] {
  border-style: solid;
  border-color: rgba(214, 87, 87, 0.28);
  color: #d65757;
}

.tf-trades-shell .tf-chat-main {
  grid-template-rows: auto auto auto auto minmax(0, 1fr);
  align-content: start;
}

.tf-trades-shell {
  display: block;
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.tf-trades-sidebar {
  display: none;
}

.tf-trades-main {
  padding: 0;
  background: transparent;
}

.tf-trades-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.tf-trades-overview-item {
  display: grid;
  gap: 5px;
  padding: 12px 14px;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
}

html[data-theme="light"] .tf-trades-overview-item {
  background: rgba(249, 245, 236, 0.82);
}

.tf-trades-overview-item span {
  color: var(--tf-text-soft);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.tf-trades-overview-item strong {
  font-size: 0.84rem;
  font-weight: 400;
  letter-spacing: -0.03em;
}

.tf-trades-month-pills {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.tf-trades-month-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--tf-border);
  border-radius: 999px;
  color: var(--tf-text-soft);
  background: rgba(255, 255, 255, 0.02);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition:
    border-color var(--tf-transition),
    background-color var(--tf-transition),
    color var(--tf-transition),
    transform var(--tf-transition);
}

html[data-theme="light"] .tf-trades-month-pill {
  background: rgba(255, 255, 255, 0.88);
}

.tf-trades-month-pill:hover,
.tf-trades-month-pill:focus {
  transform: translateY(-1px);
  border-color: rgba(208, 168, 79, 0.44);
  color: var(--tf-text);
}

.tf-trades-month-pill strong {
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
}

.tf-trades-month-pill span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 7px;
  border-radius: 999px;
  background: var(--tf-gold-soft);
  color: var(--tf-gold-strong);
  font-size: 0.62rem;
  font-weight: 700;
  line-height: 1;
}

.tf-trades-month-pill-active {
  color: #000000;
  border-color: rgba(208, 168, 79, 0.58);
  background: var(--tf-gold);
}

.tf-trades-month-pill-active span {
  color: #000000;
  background: rgba(255, 255, 255, 0.28);
}

.tf-trades-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  padding-top: 2px;
}

.tf-trades-filter-group {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.tf-trades-filter {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--tf-border);
  border-radius: 999px;
  color: var(--tf-text-soft);
  background: rgba(255, 255, 255, 0.02);
  cursor: pointer;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition:
    border-color var(--tf-transition),
    background-color var(--tf-transition),
    color var(--tf-transition),
    transform var(--tf-transition);
}

html[data-theme="light"] .tf-trades-filter {
  background: rgba(255, 255, 255, 0.88);
}

.tf-trades-filter:hover,
.tf-trades-filter:focus {
  transform: translateY(-1px);
  border-color: rgba(208, 168, 79, 0.44);
  color: var(--tf-text);
}

.tf-trades-filter span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 7px;
  border-radius: 999px;
  color: var(--tf-gold-strong);
  background: var(--tf-gold-soft);
  font-size: 0.62rem;
  font-weight: 700;
}

.tf-trades-filter-active {
  color: #000000;
  border-color: rgba(208, 168, 79, 0.58);
  background: var(--tf-gold);
}

.tf-trades-filter-active span {
  color: #000000;
  background: rgba(255, 255, 255, 0.28);
}

.tf-trades-filter-meta {
  font-size: 0.76rem;
}

.tf-trades-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(232px, 1fr));
  gap: 12px;
  align-content: start;
}

.tf-trades-grid > .tf-note {
  grid-column: 1 / -1;
}

.tf-trade-grid-card {
  display: grid;
  gap: 10px;
  min-height: 214px;
  padding: 12px;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01)),
    rgba(8, 8, 8, 0.84);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 16px 30px rgba(0, 0, 0, 0.14);
}

html[data-theme="light"] .tf-trade-grid-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(249, 246, 239, 0.94)),
    #ffffff;
}

.tf-trade-grid-card-open {
  border-color: rgba(208, 168, 79, 0.2);
}

.tf-trade-grid-card-pending {
  border-color: rgba(208, 168, 79, 0.24);
  background:
    linear-gradient(180deg, rgba(208, 168, 79, 0.05), rgba(255, 255, 255, 0.01)),
    rgba(8, 8, 8, 0.84);
}

.tf-trade-grid-card-closed {
  border-color: rgba(255, 255, 255, 0.08);
}

.tf-trade-grid-top,
.tf-trade-grid-foot,
.tf-trade-grid-live-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.tf-trade-grid-title-block {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.tf-trade-grid-top strong {
  display: block;
  margin-top: 1px;
  font-size: 0.76rem;
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.18;
}

.tf-trade-grid-asset {
  display: block;
  color: var(--tf-gold);
  font-size: 0.52rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tf-trade-grid-stamp {
  display: block;
  color: var(--tf-text-soft);
  font-size: 0.56rem;
  font-weight: 500;
  letter-spacing: 0.06em;
}

.tf-trade-grid-levels {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.tf-trade-grid-levels div,
.tf-trade-grid-live-cell {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 7px 8px;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.02);
}

html[data-theme="light"] .tf-trade-grid-levels div,
html[data-theme="light"] .tf-trade-grid-live-cell {
  background: rgba(249, 245, 236, 0.78);
}

.tf-trade-grid-levels span,
.tf-trade-grid-live-cell span,
.tf-trade-grid-live-head span {
  color: var(--tf-text-soft);
  font-size: 0.46rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.tf-trade-grid-levels strong,
.tf-trade-grid-live-cell strong,
.tf-trade-grid-foot strong {
  font-size: clamp(0.6rem, 0.74vw, 0.72rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.05;
  font-variant-numeric: tabular-nums lining-nums;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.tf-trade-grid-live {
  display: grid;
  gap: 6px;
  padding: 8px;
  border: 1px solid rgba(208, 168, 79, 0.16);
  border-radius: 10px;
  background: rgba(208, 168, 79, 0.05);
}

.tf-trade-grid-live-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
}

.tf-trade-grid-live-head strong {
  color: var(--tf-text);
  font-size: 0.66rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-trade-grid-live-head small {
  display: block;
  color: var(--tf-text-soft);
  font-size: 0.5rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.tf-trade-grid-live-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.tf-trade-grid-foot {
  margin-top: auto;
  padding-top: 4px;
  align-items: end;
  justify-content: flex-start;
}

.tf-trade-grid-result {
  display: grid;
  gap: 4px;
}

.tf-trade-grid-foot .tf-muted {
  font-size: 0.56rem;
  line-height: 1.4;
}

.tf-trade-grid-card .tf-chip {
  min-height: 20px;
  padding: 0 8px;
  font-size: 0.52rem;
  font-weight: 700;
}

.tf-results-calendar {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 12px;
  min-width: 700px;
}

.tf-results-calendar-weekday {
  color: var(--tf-text-soft);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.tf-results-calendar-day {
  min-height: 116px;
  padding: 14px;
  border: 1px solid var(--tf-border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

html[data-theme="light"] .tf-results-calendar-day {
  background: rgba(255, 255, 255, 0.92);
}

.tf-results-calendar-day strong {
  display: block;
  margin-top: auto;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: -0.03em;
}

.tf-results-calendar-day-empty {
  border-style: dashed;
  background: transparent;
  opacity: 0.42;
}

.tf-results-calendar-date {
  color: var(--tf-text-soft);
  font-size: 0.88rem;
}

.tf-results-overview-shell {
  gap: 18px;
}

.tf-results-overview-head {
  gap: 16px;
  align-items: start;
}

.tf-results-section-copy {
  max-width: 68ch;
}

.tf-results-overview-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.tf-results-month-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tf-results-month-pill {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--tf-border);
  border-radius: 999px;
  color: var(--tf-text-soft);
  background: rgba(255, 255, 255, 0.02);
  transition:
    border-color var(--tf-transition),
    background-color var(--tf-transition),
    color var(--tf-transition),
    transform var(--tf-transition);
}

html[data-theme="light"] .tf-results-month-pill {
  background: rgba(255, 255, 255, 0.92);
}

.tf-results-month-pill:hover,
.tf-results-month-pill:focus {
  color: var(--tf-text);
  border-color: rgba(208, 168, 79, 0.44);
  transform: translateY(-1px);
}

.tf-results-month-pill span {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.08em;
}

.tf-results-month-pill strong {
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-results-month-pill-active {
  color: #000000;
  border-color: rgba(208, 168, 79, 0.58);
  background: var(--tf-gold);
}

.tf-results-month-pill-active:hover,
.tf-results-month-pill-active:focus {
  color: #000000;
}

.tf-results-journal-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 22px;
  align-items: start;
}

.tf-results-table-wrap {
  overflow-x: auto;
}

.tf-results-selected-note {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--tf-text-soft);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.tf-results-selected-note strong {
  color: var(--tf-text);
  font-size: inherit;
  font-weight: 500;
}

.tf-results-month-sidebar {
  position: sticky;
  top: 92px;
}

.tf-results-month-list {
  display: grid;
  gap: 10px;
}

.tf-results-month-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--tf-border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.02);
  transition:
    border-color var(--tf-transition),
    background-color var(--tf-transition),
    transform var(--tf-transition);
}

html[data-theme="light"] .tf-results-month-link {
  background: rgba(255, 255, 255, 0.92);
}

.tf-results-month-link:hover,
.tf-results-month-link:focus {
  border-color: rgba(208, 168, 79, 0.42);
  transform: translateY(-1px);
}

.tf-results-month-link-active {
  border-color: rgba(208, 168, 79, 0.48);
  background: rgba(208, 168, 79, 0.09);
}

.tf-results-month-link > div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.tf-results-month-link strong {
  font-size: 0.84rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-results-month-link span {
  color: var(--tf-text-soft);
  font-size: 0.68rem;
  line-height: 1.45;
}

.tf-results-month-link em {
  font-style: normal;
  font-size: 0.76rem;
  font-weight: 500;
  white-space: nowrap;
}

.tf-results-calendar-panel {
  overflow: visible;
}

.tf-results-calendar-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.tf-results-calendar-wrap {
  overflow-x: auto;
}

.tf-results-calendar-day {
  position: relative;
  overflow: visible;
}

.tf-results-calendar-day-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.tf-results-calendar-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  color: var(--tf-gold-strong);
  background: var(--tf-gold-soft);
  font-size: 0.66rem;
  font-weight: 700;
  line-height: 1;
}

.tf-results-calendar-day-has-trades {
  cursor: help;
}

.tf-results-calendar-tooltip {
  position: absolute;
  left: 12px;
  bottom: calc(100% + 10px);
  z-index: 8;
  width: min(290px, calc(100vw - 48px));
  padding: 14px;
  border: 1px solid rgba(208, 168, 79, 0.2);
  border-radius: 16px;
  color: var(--tf-text);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015)),
    rgba(10, 10, 10, 0.96);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.28);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition:
    opacity var(--tf-transition),
    transform var(--tf-transition);
}

html[data-theme="light"] .tf-results-calendar-tooltip {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.96)),
    #ffffff;
  box-shadow: 0 18px 42px rgba(44, 32, 14, 0.12);
}

.tf-results-calendar-day-has-trades:hover .tf-results-calendar-tooltip,
.tf-results-calendar-day-has-trades:focus .tf-results-calendar-tooltip,
.tf-results-calendar-day-has-trades:focus-within .tf-results-calendar-tooltip {
  opacity: 1;
  transform: translateY(0);
}

.tf-results-calendar-tooltip-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.tf-results-calendar-tooltip-head strong {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 500;
}

.tf-results-calendar-tooltip-head span {
  color: var(--tf-text-soft);
  font-size: 0.68rem;
  white-space: nowrap;
}

.tf-results-calendar-tooltip-list {
  display: grid;
  gap: 10px;
}

.tf-results-calendar-tooltip-item {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.tf-results-calendar-tooltip-item > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.tf-results-calendar-tooltip-item strong {
  margin: 0;
  font-size: 0.76rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-results-calendar-tooltip-item span {
  color: var(--tf-text-soft);
  font-size: 0.66rem;
  line-height: 1.45;
}

.tf-results-calendar-tooltip-item em {
  font-style: normal;
  font-size: 0.68rem;
  font-weight: 500;
  white-space: nowrap;
}

.tf-lightbox {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(0, 0, 0, 0.86);
}

.tf-lightbox-stage {
  width: 100%;
  height: 100%;
  padding: 64px 28px 28px;
  display: grid;
  place-items: center;
}

.tf-lightbox-stage img {
  display: block;
  max-width: min(100%, 1180px);
  max-height: calc(100vh - 120px);
  border-radius: 16px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

.tf-lightbox-close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 1;
  width: 44px;
  height: 44px;
  border: 1px solid var(--tf-border);
  border-radius: 999px;
  color: var(--tf-text);
  background: rgba(12, 12, 12, 0.7);
  cursor: pointer;
}

body.tf-lightbox-open {
  overflow: hidden;
}

/* Live chat refinement */

.tf-chat-live.tf-chat-shell {
  grid-template-columns: 286px minmax(0, 1fr);
  min-height: 760px;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 28px;
  background:
    radial-gradient(circle at top right, rgba(208, 168, 79, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.018), rgba(255, 255, 255, 0)),
    #080808;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.22);
}

html[data-theme="light"] .tf-chat-live.tf-chat-shell {
  background:
    radial-gradient(circle at top right, rgba(208, 168, 79, 0.08), transparent 30%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(249, 246, 239, 0.96)),
    #ffffff;
  box-shadow: 0 24px 56px rgba(35, 28, 15, 0.08);
}

.tf-chat-live .tf-chat-sidebar {
  padding: 26px 18px 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0)),
    rgba(13, 13, 13, 0.92);
  box-shadow: inset -1px 0 0 rgba(208, 168, 79, 0.1);
}

html[data-theme="light"] .tf-chat-live .tf-chat-sidebar {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(250, 246, 239, 0.98)),
    #faf7f1;
  box-shadow: inset -1px 0 0 rgba(208, 168, 79, 0.16);
}

.tf-chat-live .tf-chat-sidebar-head {
  margin-bottom: 16px;
}

.tf-chat-live .tf-chat-sidebar-head h3 {
  margin: 0 0 4px;
  font-size: 0.92rem;
  font-weight: 400;
  letter-spacing: -0.03em;
}

.tf-chat-live .tf-chat-sidebar-head p {
  font-size: 0.78rem;
  line-height: 1.55;
}

.tf-chat-live .tf-chat-room-list {
  gap: 10px;
}

.tf-chat-live button.tf-room-card {
  min-height: 92px;
  padding: 15px 16px 14px;
  border: 1px solid rgba(208, 168, 79, 0.12);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.008)),
    rgba(10, 10, 10, 0.88);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 14px 30px rgba(0, 0, 0, 0.16);
}

html[data-theme="light"] .tf-chat-live button.tf-room-card {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.94)),
    #ffffff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 12px 24px rgba(35, 28, 15, 0.06);
}

.tf-chat-live button.tf-room-card:hover,
.tf-chat-live button.tf-room-card:focus {
  transform: translateY(-1px);
  border-color: rgba(208, 168, 79, 0.3);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 18px 36px rgba(0, 0, 0, 0.18);
}

.tf-chat-live .tf-room-card strong {
  margin-bottom: 5px;
  font-size: 0.88rem;
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 1.18;
}

.tf-chat-live .tf-room-card .tf-muted {
  font-size: 0.76rem;
  line-height: 1.5;
}

.tf-chat-live .tf-room-card-meta {
  margin-top: 11px;
  font-size: 0.58rem;
  letter-spacing: 0.18em;
}

.tf-chat-live .tf-room-card-active {
  border-color: rgba(208, 168, 79, 0.48);
  background:
    linear-gradient(180deg, rgba(208, 168, 79, 0.13), rgba(255, 255, 255, 0.015)),
    rgba(13, 13, 13, 0.94);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 20px 40px rgba(0, 0, 0, 0.2);
}

.tf-chat-live .tf-room-card-unread {
  border-color: rgba(201, 104, 104, 0.54);
  box-shadow:
    0 0 0 1px rgba(201, 104, 104, 0.12),
    0 16px 34px rgba(201, 104, 104, 0.08);
}

.tf-chat-live .tf-chat-main {
  min-height: 760px;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 14px;
  padding: 24px 24px 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.01), rgba(255, 255, 255, 0)),
    transparent;
}

.tf-chat-live .tf-chat-main-head {
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(208, 168, 79, 0.12);
}

.tf-chat-live .tf-chat-room-title {
  margin: 8px 0 4px;
  font-size: clamp(1.22rem, 2.1vw, 1.58rem);
  font-weight: 400;
  letter-spacing: -0.05em;
}

.tf-chat-live .tf-chat-room-description {
  max-width: none;
  font-size: 0.84rem;
  line-height: 1.58;
}

.tf-chat-live .tf-chat-status {
  min-height: 18px;
  font-size: 0.62rem;
  letter-spacing: 0.22em;
}

.tf-chat-stage {
  display: grid;
  min-height: 0;
}

.tf-chat-stage-admin {
  grid-template-columns: minmax(0, 1fr) 364px;
  gap: 20px;
  align-items: start;
}

.tf-chat-thread {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 16px;
  min-width: 0;
  min-height: 0;
}

.tf-chat-admin-rail {
  display: grid;
  gap: 16px;
  align-content: start;
  min-width: 0;
  position: sticky;
  top: 92px;
}

.tf-chat-admin-card,
.tf-chat-live .tf-trade-editor {
  padding: 18px;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.008)),
    rgba(12, 12, 12, 0.88);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 18px 42px rgba(0, 0, 0, 0.16);
}

html[data-theme="light"] .tf-chat-admin-card,
html[data-theme="light"] .tf-chat-live .tf-trade-editor {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.94)),
    #ffffff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 18px 38px rgba(35, 28, 15, 0.06);
}

.tf-chat-admin-card.is-disabled {
  opacity: 0.78;
}

.tf-chat-admin-card-head,
.tf-chat-live .tf-trade-editor-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.tf-chat-admin-card-head h3,
.tf-chat-live .tf-trade-editor-head h3 {
  margin: 8px 0 0;
  font-size: 1.02rem;
  font-weight: 400;
  letter-spacing: -0.04em;
}

.tf-chat-admin-card-head .tf-muted {
  max-width: 18rem;
  font-size: 0.76rem;
  line-height: 1.55;
}

.tf-chat-trade-panel-form,
.tf-chat-live .tf-trade-editor-form {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.tf-chat-live .tf-chat-trade-grid,
.tf-chat-live .tf-trade-editor-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.tf-chat-live .tf-login-field {
  gap: 7px;
}

.tf-chat-live .tf-login-field span {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.18em;
}

.tf-chat-live .tf-login-input {
  min-height: 46px;
  padding: 0 14px;
  border-radius: 14px;
  font-size: 0.88rem;
  font-weight: 300;
  background: rgba(255, 255, 255, 0.018);
}

html[data-theme="light"] .tf-chat-live .tf-login-input {
  background: rgba(255, 255, 255, 0.96);
}

.tf-chat-live textarea.tf-login-input,
.tf-chat-live .tf-chat-trade-notes {
  min-height: 94px;
  padding: 14px;
  line-height: 1.55;
}

.tf-chat-live .tf-chat-file-input {
  padding-top: 10px;
  padding-bottom: 10px;
}

.tf-chat-admin-actions,
.tf-chat-live .tf-trade-editor-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.tf-chat-admin-actions .tf-muted,
.tf-chat-live .tf-trade-editor-note {
  max-width: 18rem;
  font-size: 0.72rem;
  line-height: 1.55;
}

.tf-chat-live .tf-chat-feed {
  display: grid;
  gap: 12px;
  align-content: start;
  min-height: 560px;
  max-height: min(70vh, 860px);
  padding: 4px 6px 4px 0;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.tf-chat-live .tf-message,
.tf-chat-live .tf-trade-message-block {
  width: 100%;
  max-width: none;
}

.tf-chat-live .tf-message {
  padding: 14px 16px;
  border: 1px solid rgba(208, 168, 79, 0.12);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.028), rgba(255, 255, 255, 0.01)),
    rgba(13, 13, 13, 0.82);
  box-shadow: none;
}

html[data-theme="light"] .tf-chat-live .tf-message {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.9)),
    #ffffff;
}

.tf-chat-live .tf-message-own {
  margin-left: 0;
  border-color: rgba(208, 168, 79, 0.26);
  background:
    linear-gradient(180deg, rgba(208, 168, 79, 0.08), rgba(255, 255, 255, 0.01)),
    rgba(15, 15, 15, 0.9);
}

.tf-chat-live .tf-message-system {
  background:
    linear-gradient(180deg, rgba(208, 168, 79, 0.1), rgba(255, 255, 255, 0.012)),
    rgba(14, 14, 14, 0.88);
}

.tf-chat-live .tf-message-meta,
.tf-chat-live .tf-trade-card-meta {
  margin-bottom: 8px;
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.2em;
}

.tf-chat-live .tf-message-body {
  font-size: 0.92rem;
  font-weight: 300;
  line-height: 1.72;
}

.tf-chat-live .tf-trade-card {
  border-left-width: 2px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.026), rgba(255, 255, 255, 0.008)),
    rgba(13, 13, 13, 0.84);
  box-shadow: none;
}

.tf-chat-live .tf-trade-card-shell {
  gap: 16px;
  padding: 16px 18px;
}

.tf-chat-live .tf-trade-card-image {
  width: 104px;
  height: 78px;
  border-radius: 12px;
}

.tf-chat-live .tf-trade-card-title {
  font-size: 0.96rem;
  font-weight: 400;
  letter-spacing: -0.03em;
}

.tf-chat-live .tf-trade-card-grid,
.tf-chat-live .tf-trade-live-grid {
  gap: 8px;
}

.tf-chat-live .tf-trade-card-detail span,
.tf-chat-live .tf-trade-live-cell span {
  font-size: 0.54rem;
  letter-spacing: 0.16em;
}

.tf-chat-live .tf-trade-card-detail strong,
.tf-chat-live .tf-trade-live-cell strong {
  font-size: 0.82rem;
  font-weight: 400;
}

.tf-chat-live .tf-trade-card-notes {
  margin-top: 12px;
  font-size: 0.8rem;
  line-height: 1.6;
}

.tf-chat-live .tf-trade-live-panel {
  gap: 8px;
  margin-top: 12px;
  padding-top: 12px;
}

.tf-chat-live .tf-trade-live-head span {
  font-size: 0.56rem;
}

.tf-chat-live .tf-trade-live-head strong {
  font-size: 0.66rem;
  letter-spacing: 0.06em;
}

.tf-chat-live .tf-trade-live-cell {
  padding: 9px 10px;
  border-radius: 10px;
}

.tf-chat-live .tf-trade-card-footer {
  padding-top: 10px;
}

.tf-chat-live .tf-trade-card-result strong {
  font-size: 0.84rem;
  font-weight: 400;
}

.tf-chat-live .tf-chat-message-composer {
  display: grid;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid rgba(208, 168, 79, 0.12);
}

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

.tf-chat-message-meta .tf-muted {
  font-size: 0.68rem;
  line-height: 1.5;
}

.tf-chat-message-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.tf-chat-message-box textarea {
  min-height: 96px;
  max-height: 220px;
  padding: 16px 18px;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.018);
  color: var(--tf-text);
  font-size: 0.92rem;
  font-weight: 300;
  line-height: 1.68;
  resize: vertical;
}

html[data-theme="light"] .tf-chat-message-box textarea {
  background: rgba(255, 255, 255, 0.98);
}

.tf-chat-message-box .tf-chat-composer-actions {
  justify-content: flex-end;
}

.tf-chat-message-box .tf-button {
  min-width: 124px;
  min-height: 54px;
}

@media (max-width: 1180px) {
  .tf-chat-stage-admin {
    grid-template-columns: 1fr;
  }

  .tf-chat-admin-rail {
    position: static;
  }
}

@media (max-width: 900px) {
  .tf-results-overview-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tf-results-journal-layout {
    grid-template-columns: 1fr;
  }

  .tf-results-month-sidebar {
    position: static;
    top: auto;
  }

  .tf-results-calendar-head {
    align-items: stretch;
  }
}

@media (max-width: 640px) {
  .tf-results-overview-stats {
    grid-template-columns: 1fr;
  }

  .tf-results-month-pill {
    width: 100%;
  }

  .tf-results-month-link {
    padding: 13px 14px;
  }

  .tf-results-calendar-tooltip {
    left: 0;
    width: min(260px, calc(100vw - 36px));
  }
}

@media (max-width: 900px) {
  .tf-chat-live.tf-chat-shell {
    grid-template-columns: 1fr;
  }

  .tf-chat-live .tf-chat-sidebar {
    box-shadow: inset 0 -1px 0 rgba(208, 168, 79, 0.1);
  }

  .tf-chat-live .tf-chat-feed {
    min-height: 460px;
    max-height: 58vh;
  }
}

@media (max-width: 720px) {
  .tf-chat-live .tf-chat-main {
    padding: 18px;
  }

  .tf-chat-message-box,
  .tf-chat-live .tf-chat-main-head,
  .tf-chat-live .tf-chat-admin-card-head,
  .tf-chat-live .tf-trade-editor-head,
  .tf-chat-admin-actions,
  .tf-chat-live .tf-trade-editor-actions {
    grid-template-columns: 1fr;
    display: grid;
    justify-content: initial;
  }

  .tf-chat-live .tf-chat-trade-grid,
  .tf-chat-live .tf-trade-editor-grid,
  .tf-chat-live .tf-trade-card-grid,
  .tf-chat-live .tf-trade-live-grid {
    grid-template-columns: 1fr;
  }

  .tf-chat-live .tf-chat-feed {
    min-height: 360px;
    max-height: 52vh;
  }
}

@media (max-width: 900px) {
  .tf-chat-main {
    min-height: auto;
  }

  .tf-chat-feed {
    max-height: 420px;
  }

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

  .tf-trades-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  }
}

@media (max-width: 720px) {
  .tf-chat-live {
    min-height: auto;
  }

  .tf-chat-main-head,
  .tf-chat-compose-top,
  .tf-chat-composer-actions {
    display: grid;
    justify-content: initial;
  }

  .tf-trade-editor-grid,
  .tf-chat-trade-grid,
  .tf-trade-card-grid,
  .tf-trade-live-grid,
  .tf-trade-grid-levels,
  .tf-trade-grid-live-row {
    grid-template-columns: 1fr;
  }

  .tf-trade-card-shell {
    grid-template-columns: 1fr;
  }

  .tf-trade-card-image {
    width: 100%;
    height: 180px;
  }

  .tf-chat-feed {
    max-height: 360px;
    padding-right: 2px;
  }

  .tf-trades-toolbar,
  .tf-trade-grid-top,
  .tf-trade-grid-foot,
  .tf-trade-grid-live-head {
    display: grid;
    justify-content: initial;
  }

  .tf-trades-stats {
    grid-template-columns: 1fr;
  }

  .tf-trades-grid {
    grid-template-columns: 1fr;
  }

  .tf-results-calendar {
    min-width: 620px;
  }

  .tf-lightbox-stage {
    padding: 72px 16px 16px;
  }
}

/* Login route */

.tf-login-wrap {
  padding-top: 42px;
}

.tf-login-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 0.9fr);
  gap: 36px;
  align-items: start;
}

.tf-login-copy {
  max-width: 42rem;
}

.tf-login-copy .tf-page-title {
  margin-bottom: 16px;
}

.tf-login-points {
  display: grid;
  gap: 14px;
  margin-top: 28px;
}

.tf-login-point {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--tf-border);
}

.tf-login-point strong {
  display: block;
  margin-bottom: 4px;
  font-size: 1.02rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.tf-login-point span {
  color: var(--tf-text-soft);
}

.tf-login-panel {
  padding: 30px;
  border: 1px solid var(--tf-border);
  border-radius: 18px;
  background:
    radial-gradient(circle at top right, rgba(208, 168, 79, 0.1), transparent 38%),
    rgba(255, 255, 255, 0.02);
}

html[data-theme="light"] .tf-login-panel {
  background:
    radial-gradient(circle at top right, rgba(184, 140, 42, 0.12), transparent 38%),
    rgba(255, 255, 255, 0.96);
}

.tf-login-panel h2 {
  margin: 0 0 8px;
  font-size: 1.7rem;
  font-weight: 400;
  letter-spacing: -0.04em;
}

.tf-login-panel > p {
  margin: 0 0 24px;
}

.tf-login-alert {
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 1px solid rgba(201, 104, 104, 0.32);
  border-radius: 12px;
  color: #c96868;
  background: rgba(201, 104, 104, 0.08);
}

.tf-login-alert-success {
  border-color: rgba(30, 167, 95, 0.28);
  color: #1ea75f;
  background: rgba(30, 167, 95, 0.08);
}

.tf-login-form {
  display: grid;
  gap: 16px;
}

.tf-login-field {
  display: grid;
  gap: 8px;
}

.tf-login-field span {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.tf-login-input {
  width: 100%;
  min-height: 54px;
  padding: 0 16px;
  border: 1px solid var(--tf-border);
  border-radius: 12px;
  color: var(--tf-text);
  background: rgba(255, 255, 255, 0.02);
  outline: none;
  transition:
    border-color var(--tf-transition),
    background-color var(--tf-transition);
}

html[data-theme="light"] .tf-login-input {
  background: rgba(255, 255, 255, 0.98);
}

.tf-login-input:focus {
  border-color: rgba(208, 168, 79, 0.54);
}

.tf-login-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.tf-login-check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--tf-text-soft);
}

.tf-login-check input {
  width: 16px;
  height: 16px;
  accent-color: var(--tf-gold);
}

.tf-login-meta a {
  color: var(--tf-text-soft);
}

.tf-login-submit {
  width: 100%;
  min-height: 54px;
  margin-top: 4px;
}

.tf-login-footer {
  display: grid;
  gap: 12px;
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--tf-border);
}

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

@media (max-width: 720px) {
  .tf-login-wrap {
    padding-top: 26px;
  }

  .tf-login-panel {
    padding: 24px;
  }

  .tf-login-meta {
    display: grid;
    justify-content: initial;
  }
}

/* Minimal refinement */

.tf-site-header {
  border-bottom: 1px solid rgba(208, 168, 79, 0.12);
  background: rgba(6, 6, 6, 0.78);
  backdrop-filter: blur(22px);
}

html[data-theme="light"] .tf-site-header {
  background: rgba(255, 255, 255, 0.88);
}

.tf-header-row {
  gap: 18px;
  padding: 11px 0;
}

.tf-brand {
  gap: 9px;
}

.tf-brand-mark {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--tf-gold);
  box-shadow: 0 0 0 5px rgba(208, 168, 79, 0.08);
}

html[data-theme="light"] .tf-brand-mark {
  box-shadow: 0 0 0 5px rgba(208, 168, 79, 0.12);
}

.tf-brand-text strong {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
}

.tf-brand-text span {
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  opacity: 0.84;
}

.tf-header-nav {
  gap: 14px;
}

.tf-nav-list {
  gap: 14px;
}

.tf-nav-list a {
  position: relative;
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.18em;
}

.tf-nav-list a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -8px;
  height: 1px;
  background: currentColor;
  opacity: 0;
  transform: scaleX(0.35);
  transition:
    opacity var(--tf-transition),
    transform var(--tf-transition);
}

.tf-nav-list a:hover::after,
.tf-nav-list a:focus::after {
  opacity: 0.75;
  transform: scaleX(1);
}

.tf-header-actions {
  gap: 8px;
}

.tf-theme-toggle {
  width: 36px;
  height: 36px;
  min-width: 36px;
  padding: 0;
}

.tf-button,
.tf-mini-button {
  min-height: 38px;
  padding: 0 14px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tf-page-title {
  font-size: clamp(1.72rem, 3vw, 2.42rem);
}

.tf-section-copy {
  font-size: 0.9rem;
  line-height: 1.65;
}

.tf-site-main {
  padding: 8px 0 44px;
}

.tf-chat-page-shell {
  width: min(calc(100% - 20px), 1760px);
  margin: 0 auto;
}

.tf-chat-page-section {
  padding: 4px 0 0;
}

.tf-chat-live.tf-chat-shell {
  height: calc(100vh - 96px);
  min-height: 720px;
  grid-template-columns: 248px minmax(0, 1fr);
  overflow: hidden;
  border-radius: 30px;
}

body.admin-bar .tf-chat-live.tf-chat-shell {
  height: calc(100vh - 128px);
}

.tf-chat-live .tf-chat-sidebar {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 0;
  padding: 18px 14px 16px;
}

.tf-chat-live .tf-chat-room-list {
  overflow-y: auto;
  padding-right: 4px;
}

.tf-chat-live .tf-chat-main {
  height: 100%;
  min-height: 0;
  padding: 16px 16px 14px;
  grid-template-rows: auto auto minmax(0, 1fr);
}

.tf-chat-live .tf-chat-main-head {
  padding-bottom: 12px;
}

.tf-chat-live .tf-chat-room-title {
  font-size: clamp(1.08rem, 1.9vw, 1.34rem);
}

.tf-chat-live .tf-chat-room-description {
  font-size: 0.78rem;
  max-width: 48rem;
}

.tf-chat-live .tf-chat-status {
  font-size: 0.56rem;
}

.tf-chat-workspace {
  display: grid;
  grid-template-columns: minmax(360px, 0.92fr) minmax(430px, 1fr);
  gap: 16px;
  min-height: 0;
  height: 100%;
}

.tf-chat-signals-column,
.tf-chat-discussion-column {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  border: 1px solid rgba(208, 168, 79, 0.12);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.018), rgba(255, 255, 255, 0)),
    rgba(9, 9, 9, 0.72);
}

html[data-theme="light"] .tf-chat-signals-column,
html[data-theme="light"] .tf-chat-discussion-column {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.92)),
    #ffffff;
}

.tf-chat-column-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px 14px;
  border-bottom: 1px solid rgba(208, 168, 79, 0.1);
}

.tf-chat-column-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tf-chat-panel-title {
  margin: 7px 0 0;
  font-size: 0.98rem;
  font-weight: 400;
  letter-spacing: -0.04em;
}

.tf-chat-panel-copy {
  margin: 6px 0 0;
  max-width: 24rem;
  font-size: 0.74rem;
  line-height: 1.55;
}

.tf-chat-live .tf-chat-admin-card,
.tf-chat-live .tf-trade-editor {
  margin: 12px 14px 0;
  padding: 13px 14px;
  border-radius: 17px;
}

.tf-chat-live .tf-chat-trade-toggle[aria-expanded="true"] {
  border-color: rgba(208, 168, 79, 0.38);
  background: rgba(208, 168, 79, 0.1);
}

.tf-chat-live .tf-chat-trade-panel {
  overflow: visible;
}

.tf-chat-live .tf-trade-editor {
  overflow: visible;
}

.tf-chat-live .tf-chat-trade-panel .tf-kicker {
  font-size: 0.54rem;
  letter-spacing: 0.2em;
}

.tf-chat-live .tf-trade-editor .tf-kicker {
  font-size: 0.52rem;
  letter-spacing: 0.18em;
}

.tf-chat-live .tf-chat-trade-panel .tf-chat-admin-card-head h3 {
  margin-top: 5px;
  font-size: 0.9rem;
}

.tf-chat-live .tf-trade-editor-head h3 {
  margin-top: 4px;
  font-size: 0.88rem;
}

.tf-chat-live .tf-chat-trade-panel .tf-chat-admin-card-head .tf-muted {
  max-width: none;
  font-size: 0.68rem;
  line-height: 1.48;
}

.tf-chat-live .tf-trade-editor-head .tf-mini-button {
  min-height: 34px;
  padding: 0 12px;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
}

.tf-chat-live .tf-chat-feed {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
  padding: 14px 16px 16px;
  overflow-y: auto;
}

.tf-chat-live .tf-chat-trade-feed {
  gap: 14px;
}

.tf-chat-live .tf-chat-message-feed {
  gap: 10px;
}

.tf-chat-live .tf-chat-message-composer {
  flex: 0 0 auto;
  padding: 14px 16px 16px;
  border-top: 1px solid rgba(208, 168, 79, 0.1);
  background: rgba(255, 255, 255, 0.012);
}

html[data-theme="light"] .tf-chat-live .tf-chat-message-composer {
  background: rgba(255, 255, 255, 0.72);
}

.tf-chat-live .tf-chat-message-meta {
  margin-bottom: 10px;
}

.tf-chat-live .tf-chat-message-meta .tf-muted {
  font-size: 0.64rem;
}

.tf-chat-live .tf-chat-message-box {
  grid-template-columns: minmax(0, 1fr) 110px;
  align-items: stretch;
}

.tf-chat-live .tf-chat-message-box textarea {
  min-height: 84px;
  border-radius: 16px;
  font-size: 0.86rem;
}

.tf-chat-live .tf-chat-message-box .tf-button {
  min-width: 0;
  min-height: 84px;
  border-radius: 16px;
}

.tf-chat-live .tf-message {
  padding: 12px 14px;
  border-radius: 16px;
}

.tf-chat-live .tf-message-meta,
.tf-chat-live .tf-trade-card-meta {
  font-size: 0.54rem;
  letter-spacing: 0.18em;
}

.tf-chat-live .tf-message-body {
  font-size: 0.86rem;
  line-height: 1.7;
}

.tf-chat-live .tf-trade-card-shell {
  padding: 15px 16px;
}

.tf-chat-live .tf-trade-card-title {
  font-size: 0.9rem;
}

.tf-chat-live .tf-trade-card-detail span,
.tf-chat-live .tf-trade-live-cell span {
  font-size: 0.5rem;
}

.tf-chat-live .tf-trade-card-detail strong,
.tf-chat-live .tf-trade-live-cell strong {
  font-size: 0.78rem;
}

.tf-chat-live .tf-note {
  padding: 14px 15px;
  border: 1px solid rgba(208, 168, 79, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
  font-size: 0.78rem;
  line-height: 1.55;
}

html[data-theme="light"] .tf-chat-live .tf-note {
  background: rgba(255, 255, 255, 0.92);
}

.tf-chat-live .tf-chat-trade-panel-form {
  gap: 10px;
  margin-top: 12px;
}

.tf-chat-live .tf-trade-editor-form {
  gap: 10px;
  margin-top: 12px;
}

.tf-chat-live .tf-chat-trade-panel .tf-chat-trade-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.tf-chat-live .tf-trade-editor .tf-chat-trade-grid,
.tf-chat-live .tf-trade-editor-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.tf-chat-live .tf-chat-trade-panel .tf-login-field {
  gap: 5px;
}

.tf-chat-live .tf-trade-editor .tf-login-field {
  gap: 4px;
}

.tf-chat-live .tf-chat-trade-panel .tf-login-field span {
  font-size: 0.53rem;
  letter-spacing: 0.16em;
}

.tf-chat-live .tf-trade-editor .tf-login-field span {
  font-size: 0.5rem;
  letter-spacing: 0.15em;
}

.tf-chat-live .tf-chat-trade-panel .tf-login-input {
  min-height: 40px;
  padding: 0 12px;
  border-radius: 12px;
  font-size: 0.79rem;
}

.tf-chat-live .tf-trade-editor .tf-login-input {
  min-height: 38px;
  padding: 0 10px;
  border-radius: 11px;
  font-size: 0.75rem;
}

.tf-chat-live .tf-chat-trade-panel textarea.tf-login-input,
.tf-chat-live .tf-chat-trade-panel .tf-chat-trade-notes {
  min-height: 74px;
  padding: 11px 12px;
  line-height: 1.45;
}

.tf-chat-live .tf-trade-editor textarea.tf-login-input,
.tf-chat-live .tf-trade-editor .tf-chat-trade-notes {
  min-height: 62px;
  padding: 9px 10px;
  line-height: 1.38;
}

.tf-chat-live .tf-chat-trade-panel .tf-chat-file-input {
  min-height: 40px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.tf-chat-trade-extras {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 10px;
  align-items: start;
}

.tf-chat-trade-side-tools {
  display: grid;
  gap: 10px;
  align-content: start;
}

.tf-chat-trade-image-field .tf-login-input {
  width: 100%;
}

.tf-chat-live .tf-chat-trade-panel .tf-chat-admin-actions {
  align-items: stretch;
  justify-content: initial;
  gap: 8px;
}

.tf-chat-live .tf-chat-trade-panel .tf-chat-admin-actions .tf-muted {
  max-width: none;
  font-size: 0.64rem;
  line-height: 1.45;
}

.tf-chat-live .tf-chat-trade-panel .tf-chat-admin-actions .tf-button {
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  font-size: 0.69rem;
  letter-spacing: 0.16em;
}

.tf-chat-live .tf-trade-editor-note {
  max-width: none;
  font-size: 0.62rem;
  line-height: 1.42;
}

.tf-chat-live .tf-trade-editor-actions {
  align-items: center;
  gap: 10px;
}

.tf-chat-live .tf-trade-editor-buttons {
  gap: 8px;
  justify-content: flex-end;
}

.tf-chat-live .tf-trade-editor-buttons .tf-button {
  min-height: 36px;
  padding: 0 11px;
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  flex: 0 1 auto;
  white-space: nowrap;
}

@media (max-width: 1320px) {
  .tf-chat-workspace {
    grid-template-columns: minmax(320px, 0.92fr) minmax(380px, 1fr);
  }

  .tf-chat-live .tf-chat-trade-panel .tf-chat-trade-grid,
  .tf-chat-live .tf-trade-editor .tf-chat-trade-grid,
  .tf-chat-live .tf-trade-editor-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tf-chat-trade-extras {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1180px) {
  .tf-chat-page-shell {
    width: min(calc(100% - 16px), 1760px);
  }

  .tf-chat-live.tf-chat-shell {
    height: auto;
    min-height: 0;
    grid-template-columns: 220px minmax(0, 1fr);
  }

  body.admin-bar .tf-chat-live.tf-chat-shell {
    height: auto;
  }

  .tf-chat-workspace {
    grid-template-columns: 1fr;
    height: auto;
  }

  .tf-chat-signals-column,
  .tf-chat-discussion-column {
    min-height: 420px;
  }

  .tf-chat-live .tf-chat-trade-panel .tf-chat-trade-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .tf-header-row,
  .tf-header-nav,
  .tf-header-actions {
    gap: 8px;
  }

  .tf-nav-list a {
    font-size: 0.62rem;
    letter-spacing: 0.14em;
  }

  .tf-chat-live.tf-chat-shell {
    grid-template-columns: 1fr;
  }

  .tf-chat-live .tf-chat-sidebar {
    max-height: 220px;
  }

  .tf-chat-live .tf-chat-message-box {
    grid-template-columns: 1fr;
  }

  .tf-chat-live .tf-chat-message-box .tf-button {
    min-height: 46px;
  }
}

/* Header / controls refinement */

.tf-site-header .tf-brand-text strong {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.24em;
}

.tf-site-header .tf-brand-text span {
  font-size: 0.56rem;
  letter-spacing: 0.16em;
}

.tf-site-header .tf-nav-list a {
  font-size: 0.64rem;
  font-weight: 400;
  letter-spacing: 0.18em;
  color: color-mix(in srgb, var(--tf-text-soft) 88%, white 12%);
}

.tf-site-header .tf-nav-list a:hover,
.tf-site-header .tf-nav-list a:focus {
  color: var(--tf-text);
}

.tf-site-header .tf-mini-button,
.tf-site-header .tf-button {
  min-height: 34px;
  padding: 0 12px;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.16em;
}

.tf-site-header .tf-button-primary {
  background: linear-gradient(135deg, rgba(213, 175, 77, 0.9), rgba(213, 175, 77, 0.78));
}

.tf-site-header .tf-button-ghost {
  color: var(--tf-text-soft);
  border-color: rgba(208, 168, 79, 0.18);
}

.tf-site-header .tf-theme-toggle {
  width: 34px;
  height: 34px;
  min-width: 34px;
  border-color: rgba(208, 168, 79, 0.16);
}

.tf-header-chat-badge {
  min-width: 17px;
  height: 17px;
  padding: 0 5px;
  margin-left: 6px;
  border: 1px solid rgba(208, 168, 79, 0.26);
  color: var(--tf-gold);
  background: rgba(208, 168, 79, 0.08);
  box-shadow: none;
  font-size: 0.54rem;
  font-weight: 600;
}

html[data-theme="light"] .tf-header-chat-badge {
  background: rgba(208, 168, 79, 0.12);
}

select.tf-login-input,
select[data-trade-field],
select[data-trade-editor-field],
select[data-trade-editor-status] {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  color: var(--tf-text);
  background-color: rgba(255, 255, 255, 0.02);
  background-image:
    linear-gradient(45deg, transparent 50%, var(--tf-gold) 50%),
    linear-gradient(135deg, var(--tf-gold) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) calc(50% - 2px),
    calc(100% - 12px) calc(50% - 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 34px;
  cursor: pointer;
}

html[data-theme="light"] select.tf-login-input,
html[data-theme="light"] select[data-trade-field],
html[data-theme="light"] select[data-trade-editor-field],
html[data-theme="light"] select[data-trade-editor-status] {
  background-color: rgba(255, 255, 255, 0.98);
}

select.tf-login-input option,
select[data-trade-field] option,
select[data-trade-editor-field] option,
select[data-trade-editor-status] option {
  color: var(--tf-text);
  background: #121212;
}

html[data-theme="light"] select.tf-login-input option,
html[data-theme="light"] select[data-trade-field] option,
html[data-theme="light"] select[data-trade-editor-field] option,
html[data-theme="light"] select[data-trade-editor-status] option {
  background: #ffffff;
}

.tf-room-card,
.tf-chat-live .tf-room-card {
  color: var(--tf-text);
}

.tf-chat-live .tf-room-card strong,
.tf-chat-live .tf-room-card .tf-muted,
.tf-chat-live .tf-room-card-meta {
  color: inherit;
}

.tf-chat-live .tf-room-card .tf-muted {
  color: var(--tf-text-soft);
}

.tf-chat-live .tf-room-card-meta {
  color: var(--tf-gold);
}

.tf-chat-live .tf-room-card-active,
.tf-chat-live .tf-room-card-active strong,
.tf-chat-live .tf-room-card-active .tf-muted,
.tf-chat-live .tf-room-card-active .tf-room-card-meta {
  color: var(--tf-text);
}

.tf-chat-live .tf-room-card-active .tf-muted {
  color: color-mix(in srgb, var(--tf-text-soft) 78%, white 22%);
}

.tf-chat-live .tf-room-card-active .tf-room-card-meta {
  color: var(--tf-gold-strong);
}

/* Results refinement */

.tf-results-section-anchor {
  scroll-margin-top: 92px;
}

.tf-results-section-loading {
  opacity: 0.62;
  pointer-events: none;
  transition: opacity var(--tf-transition);
}

.tf-results-calendar-panel {
  padding: 22px 22px 24px;
}

.tf-results-calendar-head {
  margin-bottom: 14px;
}

.tf-results-calendar-wrap {
  margin-top: 4px;
  padding-bottom: 4px;
}

.tf-results-calendar {
  gap: 8px;
  min-width: 620px;
}

.tf-results-calendar-weekday {
  padding: 0 4px;
  font-size: 0.56rem;
  font-weight: 500;
  letter-spacing: 0.18em;
}

.tf-results-calendar-day {
  min-height: 88px;
  padding: 10px 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.015);
}

html[data-theme="light"] .tf-results-calendar-day {
  background: rgba(255, 255, 255, 0.9);
}

.tf-results-calendar-day strong {
  margin-top: 10px;
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-results-calendar-day-empty {
  border-color: transparent;
  background: transparent;
  opacity: 0.16;
}

.tf-results-calendar-date {
  font-size: 0.72rem;
}

.tf-results-calendar-count {
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  font-size: 0.54rem;
  font-weight: 600;
}

.tf-results-calendar-tooltip {
  left: 8px;
  bottom: calc(100% + 8px);
  width: min(250px, calc(100vw - 40px));
  padding: 12px;
  border-radius: 14px;
}

.tf-results-calendar-tooltip-head {
  margin-bottom: 10px;
}

.tf-results-calendar-tooltip-head strong {
  font-size: 0.72rem;
  font-weight: 500;
}

.tf-results-calendar-tooltip-head span {
  font-size: 0.62rem;
}

.tf-results-calendar-tooltip-list {
  gap: 8px;
}

.tf-results-calendar-tooltip-item strong {
  font-size: 0.72rem;
}

.tf-results-calendar-tooltip-item span,
.tf-results-calendar-tooltip-item em {
  font-size: 0.62rem;
}

.tf-results-calendar-tooltip {
  display: none !important;
}

.tf-results-calendar-floating-tooltip {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  width: min(250px, calc(100vw - 40px));
  padding: 12px;
  border: 1px solid rgba(208, 168, 79, 0.2);
  border-radius: 14px;
  color: var(--tf-text);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015)),
    rgba(10, 10, 10, 0.96);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.28);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition:
    opacity var(--tf-transition),
    transform var(--tf-transition);
}

html[data-theme="light"] .tf-results-calendar-floating-tooltip {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.96)),
    #ffffff;
  box-shadow: 0 18px 42px rgba(44, 32, 14, 0.12);
}

.tf-results-calendar-floating-tooltip-visible {
  opacity: 1;
  transform: translateY(0);
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-head strong {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 500;
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-head span {
  color: var(--tf-text-soft);
  font-size: 0.62rem;
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-list {
  display: grid;
  gap: 8px;
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-item {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-item > div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-item strong {
  font-size: 0.72rem;
}

.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-item span,
.tf-results-calendar-floating-tooltip .tf-results-calendar-tooltip-item em {
  font-size: 0.62rem;
}

@media (max-width: 720px) {
  .tf-results-section-anchor {
    scroll-margin-top: 74px;
  }

  .tf-results-calendar-panel {
    padding: 18px;
  }

  .tf-results-calendar {
    min-width: 560px;
  }

.tf-results-calendar-day {
    min-height: 74px;
    padding: 9px;
  }
}

/* Live chat mobile refinement */

.tf-chat-mobile-toolbar {
  display: none;
}

.tf-chat-mobile-sheet-backdrop {
  display: none;
}

@media (max-width: 980px) {
  body.tf-chat-mobile-sheet-open {
    overflow: hidden;
  }

  .tf-chat-page-shell {
    width: min(calc(100% - 12px), 1760px);
  }

  .tf-chat-page-section {
    padding-top: 0;
  }

  .tf-chat-live.tf-chat-shell {
    display: block;
    height: auto;
    min-height: 0;
    border-radius: 22px;
  }

  body.admin-bar .tf-chat-live.tf-chat-shell {
    height: auto;
  }

  .tf-chat-live .tf-chat-sidebar {
    display: block;
    padding: 12px 12px 10px;
    border-right: 0;
    border-bottom: 1px solid rgba(208, 168, 79, 0.1);
    background: transparent;
    max-height: none;
  }

  .tf-chat-live .tf-chat-sidebar-head {
    margin-bottom: 10px;
    align-items: center;
  }

  .tf-chat-live .tf-chat-sidebar-head h3 {
    font-size: 0.8rem;
    letter-spacing: 0.08em;
  }

  .tf-chat-live .tf-chat-sidebar-head p {
    font-size: 0.62rem;
  }

  .tf-chat-live .tf-chat-room-list {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(164px, 78vw);
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0 2px 2px 0;
    scroll-snap-type: x proximity;
  }

  .tf-chat-live button.tf-room-card {
    min-height: 94px;
    padding: 12px 12px 11px;
    text-align: left;
    scroll-snap-align: start;
  }

  .tf-chat-live .tf-room-card strong {
    font-size: 0.84rem;
  }

  .tf-chat-live .tf-room-card .tf-muted {
    font-size: 0.66rem;
    line-height: 1.45;
  }

  .tf-chat-live .tf-room-card-meta {
    font-size: 0.58rem;
    letter-spacing: 0.16em;
  }

  .tf-chat-live .tf-chat-main {
    padding: 12px;
    height: auto;
    min-height: 0;
    grid-template-rows: auto auto auto minmax(0, 1fr);
  }

  .tf-chat-live .tf-chat-main-head {
    display: grid;
    gap: 10px;
    padding-bottom: 10px;
  }

  .tf-chat-live .tf-chat-room-title {
    font-size: 1rem;
    line-height: 1.15;
  }

  .tf-chat-live .tf-chat-room-description {
    max-width: none;
    font-size: 0.72rem;
    line-height: 1.55;
  }

  .tf-chat-live .tf-chat-status {
    margin-bottom: 2px;
    font-size: 0.6rem;
    letter-spacing: 0.14em;
  }

  .tf-chat-mobile-toolbar {
    display: block;
    margin-bottom: 12px;
  }

  .tf-chat-mobile-view-switch {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .tf-chat-mobile-view-button {
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid rgba(208, 168, 79, 0.18);
    border-radius: 999px;
    color: var(--tf-text-soft);
    background: rgba(255, 255, 255, 0.02);
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
  }

  .tf-chat-mobile-view-button.is-active {
    color: #000000;
    border-color: rgba(208, 168, 79, 0.5);
    background: var(--tf-gold);
  }

  html[data-theme="light"] .tf-chat-mobile-view-button {
    background: rgba(255, 255, 255, 0.92);
  }

  .tf-chat-workspace {
    display: block;
    height: auto;
    min-height: 0;
  }

  .tf-chat-live[data-mobile-panel="signals"] .tf-chat-discussion-column {
    display: none;
  }

  .tf-chat-live[data-mobile-panel="chat"] .tf-chat-signals-column {
    display: none;
  }

  .tf-chat-signals-column,
  .tf-chat-discussion-column {
    min-height: calc(100dvh - 250px);
    border-radius: 20px;
  }

  .tf-chat-column-head {
    padding: 14px 14px 12px;
  }

  .tf-chat-panel-title {
    font-size: 0.9rem;
  }

  .tf-chat-panel-copy {
    max-width: none;
    font-size: 0.68rem;
    line-height: 1.5;
  }

  .tf-chat-live .tf-chat-admin-card,
  .tf-chat-live .tf-trade-editor {
    position: fixed;
    inset: auto 10px 10px 10px;
    top: max(72px, env(safe-area-inset-top) + 16px);
    z-index: 46;
    margin: 0;
    padding: 14px 14px 16px;
    overflow: auto;
    border-radius: 20px;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0)),
      rgba(12, 12, 12, 0.98);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
  }

  html[data-theme="light"] .tf-chat-live .tf-chat-admin-card,
  html[data-theme="light"] .tf-chat-live .tf-trade-editor {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 244, 236, 0.98)),
      #ffffff;
  }

  .tf-chat-mobile-sheet-backdrop:not([hidden]) {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 45;
    background: rgba(0, 0, 0, 0.58);
    backdrop-filter: blur(8px);
  }

  .tf-chat-live .tf-chat-admin-card-head,
  .tf-chat-live .tf-trade-editor-head {
    position: sticky;
    top: -14px;
    z-index: 2;
    margin: -14px -14px 12px;
    padding: 14px 14px 12px;
    background: inherit;
    border-bottom: 1px solid rgba(208, 168, 79, 0.1);
  }

  .tf-chat-live .tf-chat-feed {
    max-height: none;
    padding: 12px;
  }

  .tf-chat-live .tf-chat-message-feed {
    min-height: calc(100dvh - 390px);
    max-height: calc(100dvh - 390px);
    padding-bottom: 96px;
  }

  .tf-chat-live .tf-chat-trade-feed {
    min-height: calc(100dvh - 308px);
    max-height: calc(100dvh - 308px);
  }

  .tf-chat-live .tf-message,
  .tf-chat-live .tf-trade-card-shell {
    border-radius: 14px;
  }

  .tf-chat-live .tf-message {
    padding: 11px 12px;
  }

  .tf-chat-live .tf-message-body {
    font-size: 0.82rem;
    line-height: 1.62;
  }

  .tf-chat-live .tf-trade-card-title {
    font-size: 0.84rem;
  }

  .tf-chat-live .tf-trade-card-detail strong,
  .tf-chat-live .tf-trade-live-cell strong {
    font-size: 0.74rem;
  }

  .tf-chat-live .tf-trade-card-detail span,
  .tf-chat-live .tf-trade-live-cell span {
    font-size: 0.48rem;
  }

  .tf-chat-live .tf-chat-message-composer {
    position: sticky;
    bottom: 0;
    z-index: 3;
    padding: 10px 12px 12px;
    background:
      linear-gradient(180deg, rgba(10, 10, 10, 0.1), rgba(10, 10, 10, 0.94) 32%);
    backdrop-filter: blur(14px);
  }

  html[data-theme="light"] .tf-chat-live .tf-chat-message-composer {
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0.96) 32%);
  }

  .tf-chat-live .tf-chat-message-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
  }

  .tf-chat-live .tf-chat-message-meta .tf-muted {
    font-size: 0.58rem;
    letter-spacing: 0.1em;
  }

  .tf-chat-live .tf-chat-message-box {
    grid-template-columns: minmax(0, 1fr) 84px;
    gap: 8px;
  }

  .tf-chat-live .tf-chat-message-box textarea {
    min-height: 70px;
    padding: 12px 13px;
    font-size: 0.82rem;
  }

  .tf-chat-live .tf-chat-message-box .tf-button {
    min-height: 70px;
    padding: 0 10px;
    font-size: 0.62rem;
    letter-spacing: 0.16em;
  }

  .tf-chat-live .tf-chat-trade-panel .tf-chat-trade-grid,
  .tf-chat-live .tf-trade-editor .tf-chat-trade-grid,
  .tf-chat-live .tf-trade-editor-grid {
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .tf-chat-trade-extras {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

@media (max-width: 560px) {
  .tf-chat-live .tf-chat-room-list {
    grid-auto-columns: minmax(152px, 82vw);
  }

  .tf-chat-live .tf-chat-message-feed {
    min-height: calc(100dvh - 400px);
    max-height: calc(100dvh - 400px);
  }

  .tf-chat-live .tf-chat-trade-feed {
    min-height: calc(100dvh - 326px);
    max-height: calc(100dvh - 326px);
  }

  .tf-chat-live .tf-chat-message-box {
    grid-template-columns: 1fr;
  }

  .tf-chat-live .tf-chat-message-box .tf-button {
    min-height: 44px;
  }

  .tf-chat-live .tf-trade-card-grid,
  .tf-chat-live .tf-trade-live-grid {
    grid-template-columns: 1fr;
  }
}

/* Trade proofs */

.tf-results-proof-link {
  color: var(--tf-text);
  text-decoration: underline;
  text-decoration-color: rgba(208, 168, 79, 0.34);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

.tf-results-proof-link:hover,
.tf-results-proof-link:focus {
  color: var(--tf-gold);
  text-decoration-color: currentColor;
}

.tf-proof-notice {
  margin-bottom: 16px;
}

.tf-proof-month-pills {
  margin-bottom: 18px;
}

.tf-proofs-shell {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.tf-proofs-sidebar {
  position: sticky;
  top: 92px;
}

.tf-proofs-trade-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.tf-proofs-trade-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--tf-border);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.02);
  transition:
    border-color var(--tf-transition),
    background-color var(--tf-transition),
    transform var(--tf-transition);
}

html[data-theme="light"] .tf-proofs-trade-link {
  background: rgba(255, 255, 255, 0.92);
}

.tf-proofs-trade-link:hover,
.tf-proofs-trade-link:focus {
  border-color: rgba(208, 168, 79, 0.42);
  transform: translateY(-1px);
}

.tf-proofs-trade-link-active {
  border-color: rgba(208, 168, 79, 0.52);
  background: rgba(208, 168, 79, 0.1);
}

.tf-proofs-trade-link > div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.tf-proofs-trade-link strong {
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-proofs-trade-link span {
  color: var(--tf-text-soft);
  font-size: 0.66rem;
  line-height: 1.45;
}

.tf-proofs-trade-link em {
  font-style: normal;
  color: var(--tf-text-soft);
  font-size: 0.64rem;
  white-space: nowrap;
}

.tf-proof-upload-panel {
  padding-bottom: 22px;
}

.tf-proof-upload-form {
  display: grid;
  gap: 14px;
}

.tf-proof-upload-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.8fr);
  gap: 14px;
}

.tf-proof-upload-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.tf-proof-upload-actions .tf-muted {
  font-size: 0.76rem;
}

.tf-proof-group {
  padding: 20px;
  border: 1px solid var(--tf-border);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.02);
}

html[data-theme="light"] .tf-proof-group {
  background: rgba(255, 255, 255, 0.92);
}

.tf-proof-group-active {
  border-color: rgba(208, 168, 79, 0.5);
  box-shadow: inset 0 0 0 1px rgba(208, 168, 79, 0.16);
}

.tf-proof-group-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.tf-proof-group-title {
  display: inline-block;
  margin-bottom: 6px;
  font-size: 1rem;
  font-weight: 400;
  letter-spacing: -0.03em;
}

.tf-proof-group-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tf-proof-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 14px;
}

.tf-proof-card {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 16px;
  color: var(--tf-text);
  background: rgba(255, 255, 255, 0.02);
  text-align: left;
  cursor: pointer;
  transition:
    border-color var(--tf-transition),
    transform var(--tf-transition);
}

.tf-proof-card:hover,
.tf-proof-card:focus {
  border-color: rgba(208, 168, 79, 0.42);
  transform: translateY(-1px);
}

.tf-proof-card-image-wrap {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
}

.tf-proof-card-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tf-proof-card-meta {
  display: grid;
  gap: 4px;
}

.tf-proof-card-meta strong {
  font-size: 0.76rem;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.tf-proof-card-meta em {
  font-style: normal;
  color: var(--tf-text-soft);
  font-size: 0.62rem;
}

@media (max-width: 980px) {
  .tf-proofs-shell {
    grid-template-columns: 1fr;
  }

  .tf-proofs-sidebar {
    position: static;
  }
}

@media (max-width: 720px) {
  .tf-proof-upload-grid {
    grid-template-columns: 1fr;
  }

  .tf-proof-upload-actions,
  .tf-proof-group-head {
    display: grid;
    justify-content: initial;
  }

  .tf-proof-grid {
    grid-template-columns: 1fr;
  }
}

.tf-proof-summary-grid {
  margin-bottom: 18px;
}

.tf-proof-summary-grid .tf-stat-card {
  padding: 16px 18px;
  min-height: 0;
}

.tf-proof-summary-grid .tf-stat-label {
  font-size: 0.62rem;
  letter-spacing: 0.16em;
}

.tf-proof-summary-grid .tf-stat-value {
  font-size: 1.18rem;
  letter-spacing: -0.04em;
}

.tf-proof-summary-grid .tf-stat-card p {
  margin-top: 6px;
  font-size: 0.68rem;
  line-height: 1.55;
}

.tf-proof-browser {
  margin-top: 18px;
}

.tf-chip-negative {
  color: #f18e8e;
  background: rgba(197, 74, 74, 0.16);
  border-color: rgba(197, 74, 74, 0.24);
}

.tf-proof-product-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.tf-proof-product-card {
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(208, 168, 79, 0.12);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.02);
}

html[data-theme="light"] .tf-proof-product-card {
  background: rgba(255, 255, 255, 0.94);
}

.tf-proof-product-card-active {
  border-color: rgba(208, 168, 79, 0.42);
  box-shadow: inset 0 0 0 1px rgba(208, 168, 79, 0.12);
}

.tf-proof-product-card-top {
  display: grid;
  gap: 10px;
}

.tf-proof-product-card-heading {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.tf-proof-product-asset {
  color: var(--tf-gold);
  font-size: 0.64rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.tf-proof-product-title {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 400;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.tf-proof-product-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin: 0;
  color: var(--tf-text-soft);
  font-size: 0.66rem;
  line-height: 1.45;
}

.tf-proof-product-badges {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tf-proof-product-cover {
  position: relative;
  display: block;
  padding: 0;
  border: 0;
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
}

.tf-proof-product-cover img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid rgba(208, 168, 79, 0.14);
  border-radius: 16px;
  transition:
    transform var(--tf-transition),
    border-color var(--tf-transition),
    box-shadow var(--tf-transition);
}

.tf-proof-product-cover:hover img,
.tf-proof-product-cover:focus img {
  transform: translateY(-1px);
  border-color: rgba(208, 168, 79, 0.42);
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.18);
}

.tf-proof-product-cover-badge {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 7px 10px;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.58);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.tf-proof-product-gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.tf-proof-product-thumb {
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.tf-proof-product-thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid rgba(208, 168, 79, 0.12);
  transition:
    transform var(--tf-transition),
    border-color var(--tf-transition);
}

.tf-proof-product-thumb:hover img,
.tf-proof-product-thumb:focus img {
  transform: translateY(-1px);
  border-color: rgba(208, 168, 79, 0.4);
}

.tf-proof-product-footer {
  display: grid;
  gap: 4px;
}

.tf-proof-product-footer strong {
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.tf-proof-product-footer em {
  color: var(--tf-text-soft);
  font-style: normal;
  font-size: 0.62rem;
}

.tf-proof-product-empty {
  display: grid;
  gap: 4px;
  padding: 18px 14px;
  border: 1px dashed rgba(208, 168, 79, 0.14);
  border-radius: 14px;
  color: var(--tf-text-soft);
  font-size: 0.68rem;
}

.tf-proof-product-empty strong {
  color: var(--tf-text);
  font-weight: 400;
}

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

@media (max-width: 720px) {
  .tf-proof-product-gallery {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .tf-proof-product-grid {
    grid-template-columns: 1fr;
  }

  .tf-proof-product-gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.tf-trade-manual-close {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  padding: 14px;
  border: 1px solid rgba(208, 168, 79, 0.16);
  border-radius: 16px;
  background: rgba(208, 168, 79, 0.04);
}

.tf-trade-manual-close-head {
  display: grid;
  gap: 4px;
}

.tf-trade-manual-close-head strong {
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.tf-trade-manual-close-modes {
  display: grid;
  gap: 8px;
}

.tf-trade-manual-close-option {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--tf-text);
  font-size: 0.72rem;
}

.tf-trade-manual-close-option input {
  margin: 0;
}

.tf-trade-manual-close-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

@media (max-width: 720px) {
  .tf-trade-manual-close-actions {
    justify-content: stretch;
  }

  .tf-trade-manual-close-actions .tf-button {
    flex: 1 1 0;
  }
}
