/* ───────────────────────────────────────────────────────────────────────
   TG MARKETPLACE — Estilos Completos (Adaptación Next.js -> PHP)
   ─────────────────────────────────────────────────────────────────────── */

/* ✅ RESET & BASE */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Telegram Palette Oficial */
  --tg-blue: #2AABEE;
  --tg-blue-dark: #1C8DCE;
  --tg-navy: #070E1A;
  --tg-surface: #17212B;
  --tg-surface-2: #1E2C3A;
  --tg-border: rgba(255, 255, 255, 0.08);
  
  /* Accent Colors */
  --accent-purple: #8B5CF6;
  --accent-green: #10B981;
  --accent-gold: #F59E0B;
  --accent-red: #EF4444;
  
  /* Text */
  --text-primary: #E9F2F9;
  --text-muted: #94A3B8;
}

html, body {
  font-family: -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background-color: var(--tg-navy);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* ───────────────────────────────────────────────────────────────────────
   BACKGROUND EFFECTS (Orbes Flotantes & Grid)
   ─────────────────────────────────────────────────────────────────────── */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  background:
    radial-gradient(ellipse 60% 40% at 0% 0%, rgba(42, 171, 238, 0.12) 0%, transparent 70%),
    radial-gradient(ellipse 50% 60% at 100% 100%, rgba(139, 92, 246, 0.12) 0%, transparent 70%),
    radial-gradient(ellipse 40% 30% at 50% 60%, rgba(42, 171, 238, 0.06) 0%, transparent 60%),
    linear-gradient(180deg, var(--tg-navy) 0%, #0A1628 100%);
}

body::after {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  opacity: 0.025;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(42, 171, 238, 1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42, 171, 238, 1) 1px, transparent 1px);
  background-size: 80px 80px;
}

::selection {
  background: rgba(42, 171, 238, 0.3);
  color: white;
}

/* ───────────────────────────────────────────────────────────────────────
   ANIMACIONES KEYFRAMES
   ─────────────────────────────────────────────────────────────────────── */
@keyframes float {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  33% { transform: translateY(-18px) rotate(3deg); }
  66% { transform: translateY(-6px) rotate(-2deg); }
}

@keyframes scan-line {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100vh); }
}

@keyframes text-shimmer {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.animate-float {
  animation: float 8s ease-in-out infinite;
}

.shimmer-white {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.04), transparent);
  background-size: 200% 100%;
  animation: shimmer 2.5s linear infinite;
}

/* ───────────────────────────────────────────────────────────────────────
   BOTONES PREMIUM (Del diseño original)
   ─────────────────────────────────────────────────────────────────────── */
.btn-premium {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 900;
  letter-spacing: 0.02em;
  border-radius: 16px;
  padding: 16px 40px;
  cursor: pointer;
  transition: all 0.3s ease;
  background: linear-gradient(135deg, var(--tg-blue) 0%, var(--tg-blue-dark) 100%);
  color: white;
  box-shadow: 0 8px 32px rgba(42, 171, 238, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn-premium::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.btn-premium:hover::before { left: 100%; }
.btn-premium:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 32px rgba(42, 171, 238, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.btn-outline-neon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 900;
  letter-spacing: 0.02em;
  border-radius: 16px;
  padding: 16px 40px;
  cursor: pointer;
  transition: all 0.3s ease;
  background: rgba(42, 171, 238, 0.06);
  color: var(--tg-blue);
  border: 1px solid rgba(42, 171, 238, 0.3);
  backdrop-filter: blur(12px);
  text-decoration: none;
}

.btn-outline-neon:hover {
  background: rgba(42, 171, 238, 0.12);
  border-color: rgba(42, 171, 238, 0.5);
  box-shadow: 0 0 20px rgba(42, 171, 238, 0.2);
  transform: translateY(-1px);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: 14px;
  border: none;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.25s ease;
}
.btn-primary {
  background: linear-gradient(135deg, var(--tg-blue) 0%, var(--tg-blue-dark) 100%);
  color: white;
  box-shadow: 0 8px 32px rgba(42, 171, 238, 0.25);
}
.btn-primary:hover { transform: translateY(-1px); }
.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ───────────────────────────────────────────────────────────────────────
   HEADER (Sticky & Glassmorphism)
   ─────────────────────────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 80px;
  padding: 0 24px;
  border-bottom: 1px solid rgba(42, 171, 238, 0.08);
  background: rgba(7, 14, 26, 0.85);
  backdrop-filter: blur(24px);
  display: flex;
  align-items: center;
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.site-logo-icon {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--tg-blue) 0%, var(--tg-blue-dark) 100%);
  box-shadow: 0 0 16px rgba(42, 171, 238, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: transform 0.3s ease;
}
.site-logo:hover .site-logo-icon { transform: scale(1.1); }

.site-logo-text {
  display: flex;
  align-items: baseline;
  gap: 2px;
}
.site-logo-name {
  font-size: 18px;
  font-weight: 900;
  color: white;
  text-transform: uppercase;
  letter-spacing: -0.02em;
}
.site-logo-domain {
  font-size: 18px;
  font-weight: 900;
  color: var(--tg-blue);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.site-nav-link {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  text-decoration: none;
  transition: color 0.2s ease;
}
.site-nav-link:hover { color: white; }

.site-nav-divider {
  height: 20px;
  width: 1px;
  background: rgba(255, 255, 255, 0.1);
}

/* ───────────────────────────────────────────────────────────────────────
   LANDING PAGE SECTIONS
   ─────────────────────────────────────────────────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* HERO SECTION */
.hero-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 24px 100px;
  overflow: hidden;
}

.hero-scan-line {
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 2px;
  opacity: 0.1;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, var(--tg-blue), transparent);
  animation: scan-line 8s linear infinite;
}

.hero-floating-tg {
  position: absolute;
  top: 12%; right: 8%;
  opacity: 0.3;
  display: none; /* Hidden mobile */
}
.hero-floating-tg .tg-orb {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: rgba(42, 171, 238, 0.6);
  filter: blur(32px);
}
.hero-floating-tg .tg-icon { position: relative; z-index: 1; }

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 1050px;
}

.hero-title {
  font-size: clamp(2.5rem, 7vw, 5.5rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 0.9;
  margin-bottom: 16px;
}
.hero-title span {
  background: linear-gradient(135deg, var(--tg-blue) 0%, #64C8FF 35%, #A78BFA 70%, var(--tg-blue) 100%);
  background-size: 300% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: text-shimmer 5s linear infinite;
}

.hero-subtitle {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.5);
  max-width: 650px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 24px;
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  margin-top: 8px;
}
.hero-trust-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.4);
}

/* Hero Preview Card */
.hero-preview {
  margin-top: 80px;
  max-width: 1000px;
  width: 100%;
}
.hero-preview-border {
  border-radius: 24px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(42, 171, 238, 0.3) 0%, rgba(139, 92, 246, 0.2) 50%, rgba(42, 171, 238, 0.1) 100%);
}
.hero-preview-card {
  border-radius: 24px;
  padding: 28px;
  background: rgba(14, 22, 33, 0.92);
  backdrop-filter: blur(32px);
}
.hero-preview-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}
.hero-preview-dot { width: 12px; height: 12px; border-radius: 999px; }
.hero-preview-url {
  flex: 1;
  height: 32px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  display: flex;
  align-items: center;
  padding: 0 12px;
  color: rgba(255, 255, 255, 0.3);
  font-size: 11px;
  font-family: monospace;
}

.hero-preview-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.preview-card {
  border-radius: 16px;
  padding: 18px;
  background: rgba(23, 33, 43, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.3s ease;
}
.preview-card:hover { border-color: rgba(42, 171, 238, 0.3); transform: translateY(-4px); }

/* STATS BELT */
.stats-section {
  position: relative;
  padding: 64px 24px;
  overflow: hidden;
}
.stats-bg {
  position: absolute;
  inset: 0;
  border-top: 1px solid rgba(42, 171, 238, 0.08);
  border-bottom: 1px solid rgba(42, 171, 238, 0.08);
  background: linear-gradient(90deg, transparent, rgba(42, 171, 238, 0.04) 50%, transparent);
}
.stats-grid {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}
@media (min-width: 768px) {
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
}
.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.stat-icon {
  width: 44px; height: 44px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 12px;
}
.stat-value { font-size: 32px; font-weight: 900; letter-spacing: -0.04em; margin-bottom: 4px; }
.stat-label {
  font-size: 10px; font-weight: 800; letter-spacing: 0.2em;
  text-transform: uppercase; color: rgba(255, 255, 255, 0.4);
}

/* FEATURES SECTION */
.section {
  padding: 120px 24px;
}
.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 64px;
}
.section-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  border: 1px solid rgba(42, 171, 238, 0.2);
  background: rgba(42, 171, 238, 0.08);
  color: var(--tg-blue);
  margin-bottom: 16px;
}
.section-title {
  font-size: clamp(2rem, 5vw, 4rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.1;
}
.section-title span {
  background: linear-gradient(135deg, var(--tg-blue) 0%, #64C8FF 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.section-desc {
  margin-top: 16px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 18px;
  line-height: 1.8;
}

.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
}
@media (min-width: 768px) {
  .features-grid { grid-template-columns: repeat(3, 1fr); }
}
.feature-card-border {
  padding: 1px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(42, 171, 238, 0.1) 0%, transparent 60%);
  transition: transform 0.5s ease;
}
.feature-card-border:hover { transform: scale(1.02); }
.feature-card {
  border-radius: 24px;
  padding: 32px;
  background: rgba(14, 22, 33, 0.85);
  backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}
.feature-card:hover .feature-glow { opacity: 0.3; }
.feature-card:hover .shimmer-white { opacity: 1; }
.feature-top { display: flex; gap: 20px; align-items: flex-start; margin-bottom: 24px; }
.feature-icon {
  width: 56px; height: 56px; border-radius: 20px;
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.feature-title { font-size: 20px; font-weight: 900; margin-top: 4px; }
.feature-tag { font-size: 9px; font-weight: 900; letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.6; }
.feature-text { color: rgba(255, 255, 255, 0.5); line-height: 1.8; font-size: 15px; }

/* HOW IT WORKS */
.steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  max-width: 1000px;
  margin: 0 auto;
  position: relative;
}
@media (min-width: 768px) {
  .steps-grid { grid-template-columns: repeat(3, 1fr); }
}
.step-card {
  text-align: center;
  padding: 32px;
  border-radius: 24px;
  background: rgba(14, 22, 33, 0.7);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(42, 171, 238, 0.1);
  position: relative;
}
.step-icon {
  width: 64px; height: 64px; border-radius: 20px;
  background: linear-gradient(135deg, rgba(42,171, 238, 0.2) 0%, rgba(42, 171, 238, 0.05) 100%);
  border: 1px solid rgba(42,171, 238, 0.3);
  box-shadow: 0 0 20px rgba(42,171, 238, 0.15);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
  position: relative;
}
.step-number {
  position: absolute;
  top: -8px; right: -8px;
  width: 24px; height: 24px;
  border-radius: 999px;
  background: var(--tg-blue);
  color: var(--tg-navy);
  font-size: 9px;
  font-weight: 900;
  display: flex; align-items: center; justify-content: center;
}
.step-card h3 { font-size: 18px; font-weight: 900; margin-bottom: 8px; }
.step-card p { font-size: 14px; color: rgba(255,255,255,0.45); line-height: 1.7; }

/* ───────────────────────────────────────────────────────────────────────
   FOOTER (Original Design con Redes Sociales)
   ─────────────────────────────────────────────────────────────────────── */
.site-footer {
  width: 100%;
  padding: 80px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(23, 33, 43, 0.2);
  backdrop-filter: blur(12px);
  margin-top: 80px;
}
.footer-container { max-width: 1200px; margin: 0 auto; }
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr; gap: 64px; }
}

.footer-brand {
  text-align: center;
}
@media (min-width: 768px) {
  .footer-brand { text-align: left; }
}
.footer-brand-logo {
  display: flex; align-items: center; gap: 12px;
  justify-content: center; text-decoration: none;
  margin-bottom: 24px;
}
@media (min-width: 768px) {
  .footer-brand-logo { justify-content: flex-start; }
}
.footer-brand-text {
  font-size: 20px; font-weight: 900; text-transform: uppercase; letter-spacing: -0.02em;
}
.footer-brand-text span { color: var(--tg-blue); text-transform: lowercase; }
.footer-brand-desc {
  color: rgba(255, 255, 255, 0.45);
  font-size: 16px; line-height: 1.7;
  max-width: 360px;
  margin: 0 auto;
}

.footer-col h4 {
  font-size: 10px; font-weight: 900; letter-spacing: 0.3em;
  text-transform: uppercase; color: white; margin-bottom: 24px;
  text-align: center;
}
@media (min-width: 768px) {
  .footer-col h4 { text-align: left; }
}
.footer-nav {
  display: flex; flex-direction: column; gap: 16px; text-align: center;
}
@media (min-width: 768px) {
  .footer-nav { text-align: left; }
}
.footer-nav a {
  font-size: 14px; font-weight: 800; color: rgba(255,255,255,0.45);
  text-decoration: none; transition: color 0.2s ease;
}
.footer-nav a:hover { color: var(--tg-blue); }

.footer-bottom {
  max-width: 1200px; margin: 64px auto 0;
  padding-top: 32px; border-top: 1px solid rgba(255, 255, 255, 0.05);
  display: flex; flex-direction: column; gap: 32px; align-items: center;
}
@media (min-width: 768px) {
  .footer-bottom { flex-direction: row; justify-content: space-between; }
}
.footer-copyright {
  font-size: 10px; font-weight: 900; letter-spacing: 0.2em;
  text-transform: uppercase; color: rgba(255, 255, 255, 0.3);
  text-align: center;
}
.footer-social {
  display: flex; gap: 16px; flex-wrap: wrap; justify-content: center;
}
.social-link {
  width: 40px; height: 40px; border-radius: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.45);
  text-decoration: none; transition: all 0.3s ease;
}
.social-link:hover {
  color: var(--tg-blue);
  border-color: rgba(42, 171, 238, 0.5);
  transform: translateY(-2px);
}

/* ───────────────────────────────────────────────────────────────────────
   LOGIN & REGISTER (Auth Pages)
   ─────────────────────────────────────────────────────────────────────── */
.auth-container {
  min-height: 100vh;
  display: flex; flex-direction: column;
}
.auth-wrapper {
  display: flex; flex: 1; width: 100%;
}
.auth-form-side {
  width: 100%;
  padding: 48px 32px;
  display: flex; flex-direction: column; justify-content: center;
  position: relative; z-index: 10;
}
.auth-content { max-width: 420px; margin: 0 auto; width: 100%; }
.auth-back {
  display: inline-flex; align-items: center; gap: 8px;
  color: rgba(255,255,255,0.4); text-decoration: none;
  font-size: 11px; font-weight: 900; letter-spacing: 0.2em; text-transform: uppercase;
  margin-bottom: 36px; width: fit-content;
}
.auth-back:hover { color: white; }
.auth-logo-box {
  width: 56px; height: 56px; border-radius: 20px;
  background: linear-gradient(135deg, var(--tg-blue) 0%, #8B5CF6 100%);
  box-shadow: 0 8px 24px rgba(42,171,238,0.35);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 32px;
}
.auth-title {
  font-size: 40px; font-weight: 900; letter-spacing: -0.04em; margin-bottom: 8px; line-height: 1;
}
.auth-subtitle {
  font-size: 15px; color: rgba(255, 255, 255, 0.45); margin-bottom: 40px; font-weight: 500;
}

.auth-form-group { margin-bottom: 20px; }
.auth-form-group label {
  display: block; margin-bottom: 8px;
  color: rgba(255,255,255,0.45);
  font-weight: 900; font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase;
}
.auth-input-wrapper { position: relative; }
.auth-input-icon {
  position: absolute; left: 22px; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; color: rgba(255,255,255,0.25); transition: color 0.2s ease;
}
.auth-input-wrapper:focus-within .auth-input-icon { color: var(--tg-blue); }
.auth-input {
  width: 100%; padding: 16px 22px 16px 54px;
  border: 1px solid rgba(255,255,255,0.1); border-radius: 16px;
  background: rgba(255,255,255,0.03); color: var(--text-primary); font-size: 15px; font-weight: 500;
  outline: none; transition: all 0.2s ease;
}
.auth-input:focus { border-color: rgba(42,171,238,0.4); box-shadow: 0 0 0 3px rgba(42,171,238,0.12); }
.auth-input::placeholder { color: rgba(255,255,255,0.2); }

.password-checks {
  display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-top: 12px;
}
.password-check-item { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 600; color: rgba(255,255,255,0.3); }

.auth-btn {
  width: 100%; padding: 16px 40px; border-radius: 16px; border: none;
  background: linear-gradient(135deg, var(--tg-blue) 0%, var(--tg-blue-dark) 100%);
  color: white; font-size: 15px; font-weight: 900;
  cursor: pointer; margin-top: 8px;
  box-shadow: 0 8px 32px rgba(42,171,238,0.25);
  transition: all 0.25s ease;
}
.auth-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 32px rgba(42,171,238,0.45), inset 0 1px 0 rgba(255,255,255,0.25); }
.auth-btn:disabled { opacity: 0.5; cursor: not-allowed; }

.auth-footer {
  margin-top: 48px; padding-top: 32px; border-top: 1px solid rgba(255,255,255,0.05); text-align: center;
}
.auth-footer-text { font-size: 14px; color: rgba(255,255,255,0.45); font-weight: 500; }
.auth-footer-link { color: var(--tg-blue); font-weight: 900; text-decoration: none; transition: color 0.2s ease; }
.auth-footer-link:hover { color: #64C8FF; }

.auth-image-side { display: none; position: relative; background: var(--tg-navy); }
.auth-bg-overlay {
  position: absolute; inset: 0; z-index: 20; pointer-events: none;
  background: linear-gradient(to right, var(--tg-navy) 0%, rgba(7,14,26,0.6) 50%, transparent 100%);
}
.auth-bg-image {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 10;
}
.auth-quote {
  position: absolute; bottom: 64px; left: 64px; right: 64px; z-index: 30;
  font-size: 24px; color: rgba(255,255,255,0.85); line-height: 1.5; font-style: italic; font-weight: 500;
}

@media (min-width: 1024px) {
  .auth-form-side { width: 50%; padding: 48px 80px; }
  .auth-image-side { width: 50%; display: block; }
  .hero-floating-tg { display: block; }
}

/* ───────────────────────────────────────────────────────────────────────
   SCROLLBAR & MISC
   ─────────────────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: rgba(42,171,238,0.2);
  border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover { background: rgba(42,171,238,0.4); }

.alert { padding: 16px 20px; border-radius: 16px; margin-bottom: 24px; display: flex; align-items: center; gap: 10px; font-weight: 600; }
.alert-success { background: rgba(16,185,129,0.08); border: 1px solid rgba(16,185,129,0.25); color: #6EE7B7; }
.alert-error { background: rgba(239,68,68,0.08); border: 1px solid rgba(239,68,68,0.25); color: #FCA5A5; }

/* ───────────────────────────────────────────────────────────────────────
   UTILITY CLASSES
   ─────────────────────────────────────────────────────────────────────── */
.text-white { color: white !important; }
.neon-glow { box-shadow: 0 0 20px rgba(42,171,238,0.4), 0 0 60px rgba(42,171,238,0.15); }
.glass-card { background: rgba(23,33,43,0.8); border: 1px solid rgba(255,255,255,0.08); border-radius: 20px; backdrop-filter: blur(20px); }

/* =========================================================
   Marketplace listings grid & cards
   ========================================================= */
.listings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}

.listing-card {
    display: block;
    text-decoration: none;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 20px;
    padding: 14px;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.listing-card:hover {
    transform: translateY(-4px);
    border-color: rgba(42,171,238,0.3);
    background: rgba(255,255,255,0.05);
}

.listing-type {
    color: rgba(255,255,255,0.4);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    margin-bottom: 6px;
}

.listing-title {
    color: #fff;
    font-size: 17px;
    font-weight: 900;
    letter-spacing: -0.02em;
    margin: 0 0 12px 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.listing-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.listing-seller {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255,255,255,0.6);
    font-size: 13px;
    font-weight: 700;
    min-width: 0;
}

.listing-seller img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.listing-seller span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.listing-stat {
    display: flex;
    align-items: center;
    gap: 4px;
    color: rgba(255,255,255,0.4);
    font-size: 12px;
    font-weight: 800;
    flex-shrink: 0;
}

.listing-stat svg {
    width: 14px;
    height: 14px;
}

.listing-price {
    color: #fff;
    font-size: 22px;
    font-weight: 900;
    letter-spacing: -0.02em;
    padding-top: 12px;
    border-top: 1px solid rgba(255,255,255,0.06);
}

/* Tabs (marketplace filters) */
.tab-btn {
    display: inline-flex;
    align-items: center;
    padding: 12px 22px;
    border-radius: 14px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.6);
    font-weight: 800;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    background: rgba(255,255,255,0.06);
    color: #fff;
}

.tab-btn.active {
    background: linear-gradient(135deg, var(--tg-blue) 0%, var(--tg-blue-dark) 100%);
    border-color: transparent;
    color: #fff;
}

/* =========================================================
   App header: hide redundant search-icon button on desktop
   ========================================================= */
.app-header-search-btn {
    display: none;
}

@media (max-width: 968px) {
    .app-header-search-btn {
        display: flex;
    }
}

/* =========================================================
   Profile (bio-style) page
   ========================================================= */
.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 28px;
    border-radius: 24px;
    background: rgba(14,22,33,0.85);
    border: 1px solid rgba(255,255,255,0.06);
    backdrop-filter: blur(20px);
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.profile-avatar-lg {
    width: 84px;
    height: 84px;
    border-radius: 22px;
    background: linear-gradient(135deg,#8B5CF6,#2AABEE);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 34px;
    color: #fff;
    flex-shrink: 0;
}

.profile-info h1 {
    font-size: 26px;
    font-weight: 900;
    color: #fff;
    letter-spacing: -0.03em;
    margin: 0 0 4px 0;
}

.profile-info p {
    color: rgba(255,255,255,0.45);
    font-size: 14px;
    margin: 0;
    font-weight: 700;
}

.profile-stats {
    display: flex;
    gap: 24px;
    margin-left: auto;
    flex-wrap: wrap;
}

.profile-stat {
    text-align: center;
}

.profile-stat strong {
    display: block;
    font-size: 22px;
    font-weight: 900;
    color: var(--tg-blue);
    font-family: monospace;
}

.profile-stat span {
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.35);
}

.profile-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    padding-bottom: 0;
}

.profile-tab {
    padding: 12px 20px;
    border-radius: 12px 12px 0 0;
    color: rgba(255,255,255,0.5);
    font-weight: 800;
    font-size: 14px;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: all 0.2s ease;
}

.profile-tab:hover {
    color: #fff;
}

.profile-tab.active {
    color: var(--tg-blue);
    border-bottom-color: var(--tg-blue);
}

.profile-item-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px;
    border-radius: 16px;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.05);
    margin-bottom: 10px;
    text-decoration: none;
    transition: all 0.2s ease;
    flex-wrap: wrap;
}

.profile-item-card:hover {
    background: rgba(255,255,255,0.04);
    border-color: rgba(42,171,238,0.2);
}

.profile-item-title {
    color: #fff;
    font-weight: 800;
    font-size: 15px;
    margin: 0 0 4px 0;
}

.profile-item-sub {
    color: rgba(255,255,255,0.4);
    font-size: 13px;
    margin: 0;
}

.profile-empty {
    text-align: center;
    padding: 48px 16px;
    color: rgba(255,255,255,0.4);
}

.status-badge {
    display: inline-flex;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.status-active   { background: rgba(16,185,129,0.15); color: #10B981; }
.status-sold     { background: rgba(139,92,246,0.15); color: #8B5CF6; }
.status-draft    { background: rgba(255,255,255,0.08); color: rgba(255,255,255,0.5); }
.status-suspended,
.status-expired  { background: rgba(239,68,68,0.15); color: #EF4444; }
.status-pending  { background: rgba(245,158,11,0.15); color: #F59E0B; }
.status-in_escrow{ background: rgba(42,171,238,0.15); color: #2AABEE; }
.status-completed{ background: rgba(16,185,129,0.15); color: #10B981; }
.status-delivered{ background: rgba(42,171,238,0.15); color: #2AABEE; }
.status-cancelled,
.status-refunded,
.status-rejected,
.status-disputed { background: rgba(239,68,68,0.15); color: #EF4444; }

/* =========================================================
   Mobile collapsible sidebar groups (Configuración / Soporte)
   ========================================================= */
.sidebar-group-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    cursor: pointer;
    user-select: none;
}

.sidebar-group-toggle .chevron {
    width: 16px;
    height: 16px;
    transition: transform 0.2s ease;
    opacity: 0.4;
    display: none;
}

.sidebar-group-toggle.open .chevron {
    transform: rotate(180deg);
}

.sidebar-group-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

@media (max-width: 968px) {
    .sidebar-group-content {
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.25s ease;
    }
    .sidebar-group-content.open {
        max-height: 400px;
    }
}

/* =========================================================
   Settings page
   ========================================================= */
.settings-card {
    border-radius: 24px;
    padding: 28px;
    background: rgba(14,22,33,0.85);
    border: 1px solid rgba(255,255,255,0.06);
    backdrop-filter: blur(20px);
    margin-bottom: 24px;
}

.settings-card h2 {
    font-size: 18px;
    font-weight: 900;
    color: #fff;
    margin: 0 0 4px 0;
}

.settings-card .settings-desc {
    color: rgba(255,255,255,0.4);
    font-size: 13px;
    margin: 0 0 20px 0;
}

.settings-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

@media (max-width: 640px) {
    .settings-row {
        grid-template-columns: 1fr;
    }
    .profile-stats {
        margin-left: 0;
        width: 100%;
        justify-content: space-between;
    }
}

.settings-label {
    display: block;
    color: rgba(255,255,255,0.4);
    font-weight: 900;
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 8px;
}

/* ==========================================================
   UI/UX PRO MAX — Design Refinements
   Dark Fintech/Crypto Marketplace · Glassmorphism
   Transitions: 150-300ms · Transform/opacity only
   ========================================================== */

/* — Page entry animation — */
@keyframes fadeSlideUp {
  from { opacity:0; transform:translateY(16px); }
  to   { opacity:1; transform:translateY(0); }
}
@keyframes fadeIn {
  from { opacity:0; } to { opacity:1; }
}
@keyframes shimmer {
  0%   { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}
@keyframes pulseGlow {
  0%,100% { box-shadow: 0 0 0 0 rgba(42,171,238,0); }
  50%      { box-shadow: 0 0 20px 4px rgba(42,171,238,0.25); }
}
@keyframes scaleIn {
  from { opacity:0; transform:scale(0.94); }
  to   { opacity:1; transform:scale(1); }
}

@media (prefers-reduced-motion: no-preference) {
  .app-content { animation: fadeIn 0.25s ease; }
  .listing-card { animation: fadeSlideUp 0.3s ease both; }
  .listing-card:nth-child(1) { animation-delay: 0ms; }
  .listing-card:nth-child(2) { animation-delay: 40ms; }
  .listing-card:nth-child(3) { animation-delay: 80ms; }
  .listing-card:nth-child(4) { animation-delay: 120ms; }
  .listing-card:nth-child(5) { animation-delay: 160ms; }
  .listing-card:nth-child(6) { animation-delay: 200ms; }
  .settings-card  { animation: fadeSlideUp 0.3s ease both; }
  .profile-header { animation: fadeSlideUp 0.25s ease both; }
}

/* — Refined listing card — */
.listing-card {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  background: rgba(18, 28, 40, 0.92);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 22px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  padding: 0;
}
.listing-card:hover {
  transform: translateY(-5px);
  border-color: rgba(42,171,238,0.35);
  box-shadow: 0 20px 48px rgba(0,0,0,0.4), 0 0 0 1px rgba(42,171,238,0.1);
}
.listing-card-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}
.listing-card-img-placeholder {
  width: 100%;
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(42,171,238,0.12), rgba(139,92,246,0.08));
  position: relative;
  overflow: hidden;
}
.listing-card-img-placeholder::after {
  content:'';
  position:absolute;
  inset:0;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.03) 50%, transparent 100%);
  background-size: 400px 100%;
  animation: shimmer 2s infinite;
}
.listing-card-body {
  padding: 16px 18px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 8px;
}
.listing-card-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 2px;
}
.listing-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.listing-badge-type {
  background: rgba(255,255,255,0.07);
  color: rgba(255,255,255,0.5);
}
.listing-badge-sale {
  background: rgba(42,171,238,0.15);
  color: #2AABEE;
}
.listing-badge-auction {
  background: rgba(245,158,11,0.15);
  color: #F59E0B;
}
.listing-badge-featured {
  background: rgba(139,92,246,0.2);
  color: #A78BFA;
}
.listing-card-title {
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.listing-card-seller {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,0.45);
  font-size: 12px;
  font-weight: 700;
}
.listing-card-seller-avatar {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg,#8B5CF6,#2AABEE);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 900;
  color: #fff;
  flex-shrink: 0;
}
.listing-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.06);
  margin-top: auto;
}
.listing-card-price {
  font-size: 20px;
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.03em;
  font-family: 'Inter', monospace;
}
.listing-card-stat {
  display: flex;
  align-items: center;
  gap: 4px;
  color: rgba(255,255,255,0.35);
  font-size: 12px;
  font-weight: 700;
}

/* — Comments system — */
.comments-section {
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,0.07);
}
.comments-section h3 {
  font-size: 18px;
  font-weight: 900;
  color: #fff;
  margin: 0 0 20px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}
.comments-section h3 span.count {
  font-size: 13px;
  font-weight: 800;
  color: rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.06);
  padding: 2px 10px;
  border-radius: 999px;
}

.comment-form {
  display: flex;
  gap: 12px;
  margin-bottom: 28px;
  align-items: flex-start;
}
.comment-avatar {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: linear-gradient(135deg,#8B5CF6,#2AABEE);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 900;
  color: #fff;
  flex-shrink: 0;
}
.comment-input-wrap {
  flex: 1;
  position: relative;
}
.comment-textarea {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 14px 18px;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  resize: none;
  min-height: 52px;
  line-height: 1.5;
  transition: border-color 0.2s ease, background 0.2s ease, min-height 0.2s ease;
  box-sizing: border-box;
}
.comment-textarea:focus {
  outline: none;
  border-color: rgba(42,171,238,0.4);
  background: rgba(255,255,255,0.06);
  min-height: 88px;
}
.comment-textarea::placeholder {
  color: rgba(255,255,255,0.3);
}
.comment-submit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  padding: 9px 20px;
  background: var(--tg-blue);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: opacity 0.15s ease, transform 0.15s ease;
}
.comment-submit:hover { opacity: 0.88; transform: translateY(-1px); }
.comment-submit:active { transform: translateY(0); }

.comments-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.comment-item {
  display: flex;
  gap: 12px;
  padding: 16px;
  border-radius: 16px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.04);
  transition: background 0.15s ease;
  animation: fadeSlideUp 0.2s ease both;
}
.comment-item:hover { background: rgba(255,255,255,0.04); }
.comment-item.reply {
  margin-left: 50px;
  background: rgba(42,171,238,0.03);
  border-color: rgba(42,171,238,0.08);
}
.comment-body { flex: 1; min-width: 0; }
.comment-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}
.comment-author {
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}
.comment-time {
  color: rgba(255,255,255,0.3);
  font-size: 11px;
  font-weight: 700;
}
.comment-text {
  color: rgba(255,255,255,0.7);
  font-size: 14px;
  line-height: 1.6;
  margin: 0;
  word-break: break-word;
}
.comment-reply-btn {
  background: none;
  border: none;
  color: rgba(255,255,255,0.35);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: color 0.15s ease, background 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.comment-reply-btn:hover {
  color: #2AABEE;
  background: rgba(42,171,238,0.08);
}
.reply-form {
  display: none;
  margin-top: 12px;
}
.reply-form.open { display: flex; gap: 10px; align-items: flex-start; }
.reply-form .comment-textarea { font-size: 13px; }

/* — Settings page refinement — */
.settings-card {
  border-radius: 24px;
  padding: 28px 32px;
  background: rgba(18, 28, 40, 0.92);
  border: 1px solid rgba(255,255,255,0.07);
  backdrop-filter: blur(20px);
  margin-bottom: 20px;
  transition: border-color 0.2s ease;
}
.settings-card:hover { border-color: rgba(255,255,255,0.1); }
.settings-card h2 {
  font-size: 17px;
  font-weight: 900;
  color: #fff;
  margin: 0 0 4px 0;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 10px;
}
.settings-card h2::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 18px;
  border-radius: 2px;
  background: var(--tg-blue);
  flex-shrink: 0;
}
.settings-card .settings-desc {
  color: rgba(255,255,255,0.4);
  font-size: 13px;
  margin: 0 0 24px 0;
  line-height: 1.6;
  padding-left: 14px;
}
.settings-label {
  display: block;
  color: rgba(255,255,255,0.5);
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.auth-input {
  width: 100%;
  background: rgba(255,255,255,0.04) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  border-radius: 14px !important;
  color: #fff !important;
  font-size: 15px !important;
  transition: border-color 0.2s ease, background 0.2s ease !important;
  box-sizing: border-box;
}
.auth-input:focus {
  outline: none;
  border-color: rgba(42,171,238,0.45) !important;
  background: rgba(255,255,255,0.06) !important;
}

/* — Support page cards — */
.support-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 20px;
  border-radius: 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  margin-bottom: 10px;
}
.support-item:hover {
  background: rgba(255,255,255,0.06);
  border-color: rgba(42,171,238,0.25);
  transform: translateX(4px);
}
.support-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.support-item-info h4 {
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  margin: 0 0 2px 0;
}
.support-item-info p {
  color: rgba(255,255,255,0.4);
  font-size: 13px;
  margin: 0;
}

/* — Sidebar: remove admin section visual noise — */
.sidebar-admin-hidden { display: none !important; }

/* — Marketplace filter bar refinement — */
.filter-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 28px;
  padding: 6px;
  background: rgba(255,255,255,0.03);
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,0.06);
  width: fit-content;
}
.filter-btn {
  padding: 10px 20px;
  border-radius: 12px;
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.55);
  font-weight: 800;
  font-size: 13px;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
  white-space: nowrap;
}
.filter-btn:hover { background: rgba(255,255,255,0.06); color: #fff; }
.filter-btn.active {
  background: rgba(42,171,238,0.18);
  color: #fff;
  box-shadow: inset 0 0 0 1px rgba(42,171,238,0.3);
}

/* — Stat cards on listing detail — */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px,1fr));
  gap: 10px;
}
.stat-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 16px;
  padding: 14px 16px;
}
.stat-label {
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  margin-bottom: 4px;
}
.stat-value {
  font-size: 16px;
  font-weight: 900;
  color: #fff;
}

/* — Buy/bid panel on listing — */
.purchase-panel {
  border-radius: 24px;
  padding: 24px;
  background: rgba(14,22,33,0.92);
  border: 1px solid rgba(255,255,255,0.08);
  backdrop-filter: blur(24px);
  position: sticky;
  top: 90px;
}

/* — Alert messages — */
.alert {
  padding: 14px 20px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 20px;
  line-height: 1.5;
}
.alert-error   { background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.25); color: #ef4444; }
.alert-success { background: rgba(16,185,129,0.1); border: 1px solid rgba(16,185,129,0.25); color: #10B981; }

/* — Quick access card hover animation — */
.quick-link-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border-radius: 18px;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid transparent;
}
.quick-link-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

/* — Sidebar app link hover — */
.app-sidebar-link {
  transition: background 0.15s ease, color 0.15s ease;
  cursor: pointer;
}

/* — Profile header animation — */
.profile-header { transition: border-color 0.2s ease; }
.profile-stat strong {
  font-variant-numeric: tabular-nums;
}

/* — Mobile responsive fixes — */
@media (max-width: 768px) {
  .listings-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .settings-card { padding: 20px; }
  .settings-row { grid-template-columns: 1fr; }
  .comment-item.reply { margin-left: 24px; }
  .filter-bar { width: 100%; }
}
@media (max-width: 480px) {
  .listings-grid { grid-template-columns: 1fr; }
  .listing-card-img, .listing-card-img-placeholder { height: 160px; }
}

/* ==========================================================
   RESPONSIVE LAYOUT UTILITIES  
   Mobile-first, consistent across all pages
   Breakpoints: 480 · 640 · 768 · 968 · 1200
   ========================================================== */

/* --- Page wrapper --- */
.page-wrap { padding-bottom: 88px; }

/* --- Section headings --- */
.page-title {
  font-size: clamp(22px, 5vw, 30px);
  font-weight: 900;
  color: #fff;
  letter-spacing: -0.04em;
  margin: 0 0 4px 0;
  line-height: 1.2;
}
.page-subtitle {
  color: rgba(255,255,255,0.4);
  font-size: clamp(13px, 2.5vw, 15px);
  margin: 0 0 24px 0;
  line-height: 1.5;
}

/* --- Two-column layout (listing detail, dashboard, etc.) --- */
.two-col {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 24px;
  align-items: start;
}
.two-col-wide {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 28px;
  align-items: start;
}
@media (max-width: 968px) {
  .two-col, .two-col-wide {
    grid-template-columns: 1fr;
  }
  .two-col .sticky-col,
  .two-col-wide .sticky-col {
    position: static !important;
  }
}

/* --- Three stats row --- */
.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}
@media (max-width: 640px) {
  .stats-row { grid-template-columns: 1fr; gap: 10px; }
}

/* --- Form two-col --- */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}
@media (max-width: 640px) {
  .form-row { grid-template-columns: 1fr; }
}

/* --- Card base (reusable) --- */
.card {
  border-radius: 22px;
  padding: 22px 24px;
  background: rgba(18, 28, 40, 0.95);
  border: 1px solid rgba(255,255,255,0.07);
  backdrop-filter: blur(12px);
}
.card-sm {
  border-radius: 16px;
  padding: 16px 18px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
}
.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  gap: 12px;
  flex-wrap: wrap;
}
.card-title {
  font-size: 16px;
  font-weight: 900;
  color: #fff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.dot-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
}
.dot-blue   { background:#2AABEE; box-shadow: 0 0 8px rgba(42,171,238,0.5); }
.dot-green  { background:#10B981; box-shadow: 0 0 8px rgba(16,185,129,0.5); }
.dot-purple { background:#8B5CF6; box-shadow: 0 0 8px rgba(139,92,246,0.5); }
.dot-amber  { background:#F59E0B; box-shadow: 0 0 8px rgba(245,158,11,0.5); }

/* --- Sticky sidebar panel --- */
.sticky-col {
  position: sticky;
  top: 90px;
}

/* --- Wallet page --- */
.wallet-balance-hero {
  border-radius: 28px;
  padding: 32px;
  background: linear-gradient(135deg, rgba(42,171,238,0.2), rgba(42,171,238,0.05));
  border: 1px solid rgba(42,171,238,0.25);
  text-align: center;
  margin-bottom: 20px;
  position: relative;
  overflow: hidden;
}
.wallet-balance-hero::before {
  content: '';
  position: absolute;
  top: -40%;
  left: 50%;
  transform: translateX(-50%);
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(42,171,238,0.15) 0%, transparent 70%);
  pointer-events: none;
}
.wallet-balance-amount {
  font-size: clamp(36px, 8vw, 52px);
  font-weight: 900;
  color: #fff;
  font-family: monospace;
  letter-spacing: -0.04em;
  margin: 0 0 4px 0;
  position: relative;
}
.wallet-balance-label {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
}
.wallet-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 20px;
}
@media (max-width: 480px) {
  .wallet-actions { grid-template-columns: 1fr; }
}

/* --- Transaction row --- */
.tx-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.05);
  transition: background 0.15s ease;
  text-decoration: none;
}
.tx-row:hover { background: rgba(255,255,255,0.04); }
.tx-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.tx-info { flex: 1; min-width: 0; }
.tx-title { font-size: 14px; font-weight: 800; color: #fff; margin: 0 0 2px 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tx-sub   { font-size: 12px; color: rgba(255,255,255,0.4); margin: 0; }
.tx-amount { font-size: 15px; font-weight: 900; font-family: monospace; flex-shrink: 0; }
.tx-amount.positive { color: #10B981; }
.tx-amount.negative { color: #EF4444; }

/* --- Messages page --- */
.msg-list { display: flex; flex-direction: column; gap: 6px; }
.msg-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.05);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.msg-row:hover   { background: rgba(255,255,255,0.05); border-color: rgba(42,171,238,0.2); }
.msg-row.unread  { background: rgba(42,171,238,0.04); border-color: rgba(42,171,238,0.12); }
.msg-avatar {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, #8B5CF6, #2AABEE);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 18px;
  color: #fff;
  flex-shrink: 0;
}
.msg-body    { flex: 1; min-width: 0; }
.msg-name    { font-size: 14px; font-weight: 800; color: #fff; margin: 0 0 2px 0; }
.msg-preview { font-size: 12px; color: rgba(255,255,255,0.4); margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.msg-meta    { text-align: right; flex-shrink: 0; }
.msg-time    { font-size: 11px; color: rgba(255,255,255,0.3); font-weight: 700; }
.msg-badge   { display: inline-flex; width: 18px; height: 18px; border-radius: 999px; background: #2AABEE; color: #fff; font-size: 10px; font-weight: 900; align-items: center; justify-content: center; margin-top: 4px; }

/* --- Create listing form --- */
.create-listing-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  align-items: start;
}
@media (max-width: 968px) {
  .create-listing-grid { grid-template-columns: 1fr; }
}

/* --- Form input group --- */
.form-group { margin-bottom: 18px; }
.form-group label {
  display: block;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  margin-bottom: 8px;
}
.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  color: #fff;
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.2s ease, background 0.2s ease;
  box-sizing: border-box;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none;
  border-color: rgba(42,171,238,0.45);
  background: rgba(255,255,255,0.06);
}
.form-select { cursor: pointer; }
.form-textarea { resize: vertical; min-height: 100px; line-height: 1.6; }

/* --- Upload zone --- */
.upload-zone {
  border: 2px dashed rgba(255,255,255,0.12);
  border-radius: 18px;
  padding: 40px 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.upload-zone:hover {
  border-color: rgba(42,171,238,0.4);
  background: rgba(42,171,238,0.04);
}

/* --- Notifications --- */
.notif-row {
  display: flex;
  gap: 14px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.05);
  background: rgba(255,255,255,0.02);
  transition: background 0.15s ease;
  text-decoration: none;
}
.notif-row.unread { background: rgba(42,171,238,0.05); border-color: rgba(42,171,238,0.1); }
.notif-row:hover  { background: rgba(255,255,255,0.04); }
.notif-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.notif-body { flex: 1; min-width: 0; }
.notif-title { font-size: 14px; font-weight: 800; color: #fff; margin: 0 0 3px 0; }
.notif-desc  { font-size: 13px; color: rgba(255,255,255,0.45); margin: 0; line-height: 1.5; }
.notif-time  { font-size: 11px; color: rgba(255,255,255,0.3); font-weight: 700; margin-top: 6px; display: block; }

/* --- Boost listing --- */
.boost-option {
  border-radius: 18px;
  padding: 20px;
  border: 2px solid rgba(255,255,255,0.08);
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
  position: relative;
}
.boost-option:hover { border-color: rgba(245,158,11,0.4); background: rgba(245,158,11,0.05); transform: translateY(-2px); }
.boost-option.selected { border-color: rgba(245,158,11,0.6); background: rgba(245,158,11,0.08); }
.boost-popular-badge {
  position: absolute;
  top: -10px;
  right: 16px;
  background: linear-gradient(135deg, #F59E0B, #EF4444);
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.1em;
  padding: 3px 10px;
  border-radius: 999px;
}

/* --- Chat / Messages detail --- */
.chat-wrap {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 140px);
  border-radius: 22px;
  overflow: hidden;
  background: rgba(18,28,40,0.95);
  border: 1px solid rgba(255,255,255,0.07);
}
@media (max-width: 968px) {
  .chat-wrap { height: calc(100dvh - 120px); border-radius: 16px; }
}
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.1) transparent;
}
.chat-bubble {
  max-width: min(70%, 480px);
  padding: 12px 16px;
  border-radius: 18px;
  font-size: 14px;
  line-height: 1.55;
  word-break: break-word;
}
.chat-bubble.mine {
  background: linear-gradient(135deg, #2AABEE, #1C8DCE);
  color: #fff;
  margin-left: auto;
  border-bottom-right-radius: 4px;
}
.chat-bubble.theirs {
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.85);
  border-bottom-left-radius: 4px;
}
.chat-input-bar {
  padding: 14px 16px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  gap: 10px;
  align-items: center;
}
.chat-input {
  flex: 1;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  padding: 12px 16px;
  color: #fff;
  font-size: 14px;
  font-family: inherit;
  resize: none;
  max-height: 120px;
}
.chat-input:focus { outline: none; border-color: rgba(42,171,238,0.4); }
.chat-send-btn {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--tg-blue);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: opacity 0.15s ease;
}
.chat-send-btn:hover { opacity: 0.85; }

/* --- Index / Landing responsive polish --- */
@media (max-width: 640px) {
  .hero-headline { font-size: clamp(28px, 8vw, 44px) !important; }
  .hero-sub      { font-size: 15px !important; }
}

/* --- Global responsive overrides for inline styles on pages --- */
@media (max-width: 968px) {
  /* Dashboard two-col */
  [style*="grid-template-columns:1fr 360px"],
  [style*="grid-template-columns:1fr 380px"],
  [style*="grid-template-columns:1fr 400px"],
  [style*="grid-template-columns: 1fr 360px"],
  [style*="grid-template-columns: 1fr 380px"],
  [style*="grid-template-columns: 1fr 400px"] {
    grid-template-columns: 1fr !important;
  }
  /* Stats row */
  [style*="grid-template-columns:repeat(3,1fr)"],
  [style*="grid-template-columns: repeat(3, 1fr)"] {
    grid-template-columns: 1fr 1fr !important;
  }
  /* Content padding */
  .app-content { padding: 14px 14px 80px !important; }
}
@media (max-width: 640px) {
  [style*="grid-template-columns:repeat(3,1fr)"],
  [style*="grid-template-columns: repeat(3, 1fr)"] {
    grid-template-columns: 1fr !important;
  }
  [style*="grid-template-columns:1fr 1fr"],
  [style*="grid-template-columns: 1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }
  /* Smaller font on mobile for mono prices */
  [style*="font-size:34px"],
  [style*="font-size: 34px"] { font-size: 26px !important; }
  .card, .settings-card { padding: 16px !important; border-radius: 18px !important; }
  .wallet-balance-hero { padding: 22px !important; }
}
@media (max-width: 480px) {
  .page-title { font-size: 22px; }
  .profile-header { flex-direction: column; align-items: flex-start; gap: 14px; }
  .profile-stats { margin-left: 0; width: 100%; justify-content: flex-start; gap: 20px; }
  .filter-bar { flex-wrap: nowrap; overflow-x: auto; padding: 4px; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .filter-bar::-webkit-scrollbar { display: none; }
  .filter-btn { flex-shrink: 0; }
  .listings-grid { grid-template-columns: 1fr; gap: 12px; }
  .listing-card-img, .listing-card-img-placeholder { height: 140px; }
  .profile-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; scrollbar-width: none; }
  .profile-tab { flex-shrink: 0; }
  /* Settings grids on mobile */
  [style*="display:grid;grid-template-columns:1fr 1fr"],
  [style*="display: grid; grid-template-columns: 1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }
  .comment-item.reply { margin-left: 12px; }
}

/* --- Safe area insets (iPhone notch / home bar) --- */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
  .app-mobile-nav {
    padding-bottom: calc(10px + env(safe-area-inset-bottom));
  }
  .page-wrap { padding-bottom: calc(88px + env(safe-area-inset-bottom)); }
}

/* --- Smooth scroll & selection --- */
html { scroll-behavior: smooth; }
::selection { background: rgba(42,171,238,0.3); }

/* --- Tablet-specific (768-968px) tweaks --- */
@media (min-width: 640px) and (max-width: 968px) {
  .listings-grid { grid-template-columns: repeat(2, 1fr) !important; }
  .stats-row     { grid-template-columns: repeat(3, 1fr); }
}

