:root {
  --bg: #000000;
  --panel: rgba(18, 18, 18, 0.8);
  --panel-light: rgba(28, 28, 30, 0.8);
  --line: rgba(255, 255, 255, 0.08);
  --strong-blue: #007AFF;
  --strong-blue-glow: rgba(0, 122, 255, 0.4);
  --lime: #d9ff4c;
  --white: #ffffff;
  --muted: #8e8e93;
  --red: #ff3b30;
  --green: #34c759;
  --yellow: #ffcc00;
  --font-main: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --sidebar-width: 280px;
  --sidebar-collapsed-width: 88px;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-font-smoothing: antialiased; }

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font-main);
  overflow: hidden;
  height: 100vh;
}

h1, h2, h3 { font-weight: 800; letter-spacing: -0.03em; margin-bottom: 16px; }
h2 { font-size: 2.2rem; text-transform: uppercase; background: linear-gradient(180deg, #fff 0%, #aaa 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

.eyebrow { 
  font-size: 0.75rem; 
  font-weight: 700; 
  text-transform: uppercase; 
  letter-spacing: 0.15em; 
  color: var(--strong-blue);
  margin-bottom: 12px;
  display: block;
}

.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr 320px;
  height: 100vh;
  transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

.sidebar-collapsed { grid-template-columns: var(--sidebar-collapsed-width) 1fr 320px; }
.history-collapsed { grid-template-columns: var(--sidebar-width) 1fr 0px; }
.sidebar-collapsed.history-collapsed { grid-template-columns: var(--sidebar-collapsed-width) 1fr 0px; }

aside.sidebar {
  background: var(--bg);
  border-right: 1px solid var(--line);
  padding: 32px 0;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 100;
  overflow: hidden;
  transition: width 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

.brand-head { 
  padding: 0 24px; 
  margin-bottom: 48px; 
  display: flex; 
  align-items: center; 
  gap: 16px; 
  white-space: nowrap;
}

/* LOGO RESTORATION & BACKGROUND ELIMINATION */
.brand-logo { 
  width: 44px; 
  height: 44px; 
  object-fit: contain;
  filter: invert(1) contrast(1.5) brightness(1.2);
  mix-blend-mode: screen;
  transition: transform 0.3s ease;
}
.brand-logo:hover { transform: scale(1.1) rotate(-5deg); }

.brand-text { 
  font-size: 1.4rem; 
  font-weight: 900; 
  letter-spacing: -0.05em;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.sidebar-collapsed .brand-text, 
.sidebar-collapsed .nav-link span { 
  opacity: 0;
  pointer-events: none;
  position: absolute;
}

.sidebar-collapsed .brand-head, 
.sidebar-collapsed .nav-link { 
  justify-content: center; 
  padding: 12px 0; 
}

.nav-list { flex: 1; padding: 0 16px; }
.nav-link {
  width: 100%;
  padding: 14px 20px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 14px;
  display: flex;
  align-items: center;
  gap: 16px;
  cursor: pointer;
  margin-bottom: 8px;
  transition: all 0.3s cubic-bezier(0.19, 1, 0.22, 1);
  position: relative;
}

.nav-link:hover { 
  background: var(--panel-light); 
  color: var(--white); 
  transform: translateX(4px);
}

.sidebar-collapsed .nav-link:hover { transform: scale(1.1); }

.nav-link.active { 
  background: var(--strong-blue); 
  color: var(--white); 
  box-shadow: 0 8px 24px var(--strong-blue-glow);
}

.icon { 
  font-size: 1.4rem; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  width: 24px; 
  height: 24px; 
  flex-shrink: 0;
}

.stage {
  padding: 60px;
  overflow-y: auto;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
  background: var(--bg);
}

.glass-card {
  background: var(--panel);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 32px;
  margin-bottom: 32px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.4);
  transition: transform 0.3s ease, border-color 0.3s ease;
}
.glass-card:hover { border-color: rgba(255,255,255,0.15); }

.btn-action {
  padding: 16px 28px;
  border-radius: 16px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.19, 1, 0.22, 1);
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.btn-primary { 
  background: var(--strong-blue); 
  color: white; 
  box-shadow: 0 10px 20px var(--strong-blue-glow);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 15px 30px var(--strong-blue-glow); }

.btn-secondary { 
  background: var(--panel-light); 
  color: var(--white); 
  border: 1px solid var(--line); 
}
.btn-secondary:hover { background: rgba(255,255,255,0.1); }

.report-item {
  padding: 20px;
  background: rgba(255,255,255,0.03);
  border-radius: 18px;
  border: 1px solid var(--line);
  margin-bottom: 16px;
  transition: all 0.2s ease;
}
.report-item:hover { background: rgba(255,255,255,0.05); }

input, select, textarea {
  background: rgba(45, 45, 48, 0.9);
  border: 1px solid var(--line);
  padding: 14px 20px;
  border-radius: 14px;
  color: var(--white);
  font-family: var(--font-main);
  font-size: 1rem;
  transition: all 0.2s ease;
}

select option {
  background: #2d2d30;
  color: var(--white);
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--strong-blue);
  background: rgba(255,255,255,0.08);
  box-shadow: 0 0 0 4px var(--strong-blue-glow);
}

.history-content { 
  height: 100%; 
  overflow-y: auto; 
  border-left: 1px solid var(--line); 
  padding: 32px; 
  background: var(--bg); 
  transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

.history-item { border-bottom: 1px solid var(--line); padding: 16px 0; font-size: 0.85rem; }
.history-item .time { color: var(--strong-blue); font-weight: 700; margin-bottom: 6px; font-size: 0.7rem; }

.warmup-ladder { 
  background: rgba(0, 122, 255, 0.08); 
  border: 1px solid rgba(0, 122, 255, 0.2); 
  border-radius: 18px; 
  padding: 20px; 
}

.login-shell {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, #111 0%, #000 100%);
}

.logo-3d {
  width: 120px;
  height: 120px;
  object-fit: contain;
  filter: 
    invert(1) 
    contrast(1.5) 
    brightness(1.2)
    drop-shadow(0 10px 20px rgba(0, 122, 255, 0.4))
    drop-shadow(0 20px 40px rgba(0, 0, 0, 0.6));
  transform: perspective(1000px) rotateX(10deg) translateY(-10px);
  transition: transform 0.5s cubic-bezier(0.19, 1, 0.22, 1);
  margin-bottom: 32px;
}
.logo-3d:hover {
  transform: perspective(1000px) rotateX(0deg) translateY(-15px) scale(1.05);
}
.cat-compound { border-left: 6px solid var(--green) !important; }
.cat-plyometric { border-left: 6px solid var(--yellow) !important; }
.cat-eccentric { border-left: 6px solid var(--red) !important; }
.cat-core { border-left: 6px solid #AF52DE !important; }

/* TOAST NOTIFICATIONS */
.toast-container {
  position: fixed;
  bottom: 40px;
  right: 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 9999;
  pointer-events: none;
}

.toast {
  min-width: 320px;
  padding: 18px 24px;
  background: rgba(20, 20, 20, 0.8);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 4px solid var(--strong-blue);
  border-radius: 16px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  animation: toastIn 0.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
  pointer-events: auto;
}

.toast.success { border-left-color: var(--lime); }
.toast.error { border-left-color: var(--red); }
.toast.info { border-left-color: var(--strong-blue); }

@keyframes toastIn {
  from { opacity: 0; transform: translateX(100%) scale(0.9); }
  to { opacity: 1; transform: translateX(0) scale(1); }
}

.toast.fade-out {
  animation: toastOut 0.5s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

@keyframes toastOut {
  from { opacity: 1; transform: translateX(0) scale(1); }
  to { opacity: 0; transform: translateX(20px) scale(0.95); }
}

.toast-icon {
  font-size: 1.2rem;
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* SUCCESS STATE FOR BUTTONS */
.btn-success-state {
  background: var(--lime) !important;
  color: var(--bg) !important;
  pointer-events: none;
}

.btn-success-state::after {
  content: "✓";
  margin-left: 8px;
}
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }

@keyframes slideInRight { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }
.stage > * { animation: slideInRight 0.6s cubic-bezier(0.19, 1, 0.22, 1) forwards; }

.landing-page { height: 100vh; overflow-y: auto; scroll-behavior: smooth; background: var(--bg); }
.landing-nav { position: fixed; top: 0; left: 0; right: 0; padding: 20px 60px; display: flex; justify-content: space-between; align-items: center; z-index: 1000; background: rgba(5,5,5,0.8); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.brand-logo-box {
  background: var(--panel-light);
  border: 1px solid var(--line);
  padding: 8px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}
.brand-logo-box:hover {
  border-color: var(--strong-blue);
  transform: translateY(-2px);
}

.hero { height: 100vh; display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 80px; padding: 0 120px; background: var(--bg); }
.hero-video-container { 
  position: relative; 
  width: 100%; 
  max-width: 1650px; 
  aspect-ratio: 1650 / 1500; 
  border-radius: 40px; 
  overflow: hidden; 
  box-shadow: 0 30px 60px rgba(0,0,0,0.5);
  background: #000;
  justify-self: center;
}
.hero-video-container video { 
  width: 100%; 
  height: 100%; 
  object-fit: cover; 
  transition: opacity 0.1s ease-in-out;
}

.gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.login-overlay { 
  position: fixed; 
  top: 0; 
  left: 0; 
  right: 0; 
  bottom: 0; 
  background: #000;
  z-index: 1500; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  overflow: hidden;
}

.login-bg-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.3;
  filter: blur(40px) brightness(0.5);
  transform: scale(1.1); /* Prevent blur edges */
}

.login-card {
  width: 100%;
  max-width: 420px;
  padding: 48px;
  background: rgba(20, 20, 20, 0.6);
  backdrop-filter: blur(30px) saturate(150%);
  -webkit-backdrop-filter: blur(30px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 32px;
  position: relative;
  z-index: 10;
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.8);
  animation: loginAppear 0.8s cubic-bezier(0.19, 1, 0.22, 1);
}

@keyframes loginAppear {
  from { opacity: 0; transform: translateY(20px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Biometric Scanning Line */
.login-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--lime), transparent);
  animation: scanLine 4s linear infinite;
  opacity: 0.5;
  pointer-events: none;
}

@keyframes scanLine {
  0% { top: 0; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

.login-header h2 {
  font-size: 1.8rem;
  margin-bottom: 8px;
  letter-spacing: -0.04em;
}

.login-field {
  margin-bottom: 24px;
}

.login-field label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
}

.login-field input {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 16px;
  border-radius: 12px;
  color: #fff;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.login-field input:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--lime);
  box-shadow: 0 0 20px rgba(217, 255, 76, 0.2);
}

@media (max-width: 1024px) {
  .hero { padding: 0 40px; }
  .gallery-grid { grid-template-columns: 1fr 1fr; }
  #location { grid-template-columns: 1fr !important; }
}

/* SMART TEAM DASHBOARD & COMMAND HUB STYLES */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 24px; margin-bottom: 40px; }
.stat-card { background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.01) 100%); border: 1px solid var(--line); border-radius: 20px; padding: 24px; position: relative; overflow: hidden; }
.stat-card .value { font-size: 2rem; font-weight: 900; color: var(--white); line-height: 1; margin-bottom: 4px; }
.stat-card .label { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; color: var(--muted); letter-spacing: 0.05em; }
.stat-card::after { content: ""; position: absolute; top: -50%; right: -50%; width: 100%; height: 100%; background: radial-gradient(circle, var(--strong-blue-glow) 0%, transparent 70%); opacity: 0.3; pointer-events: none; }

.progression-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 20px; margin-bottom: 40px; }
.athlete-progress-card { 
  background: var(--panel); 
  border: 1px solid var(--line); 
  border-radius: 20px; 
  padding: 20px; 
  text-align: center; 
  cursor: pointer; 
  transition: all 0.3s cubic-bezier(0.19, 1, 0.22, 1); 
}
.athlete-progress-card:hover { transform: translateY(-5px); border-color: var(--lime); background: rgba(217, 255, 76, 0.05); }

.progress-ring-container { 
  position: relative; 
  width: 90px; 
  height: 90px; 
  margin: 0 auto 16px; 
  display: flex;
  align-items: center;
  justify-content: center;
}

.progress-ring { 
  transform: rotate(-90deg); 
  width: 90px; 
  height: 90px; 
}

.progress-ring circle { 
  fill: transparent; 
  stroke-width: 6; 
}

.progress-ring .bg { 
  stroke: rgba(255, 255, 255, 0.03); 
}

.progress-ring .active { 
  stroke: var(--lime); 
  stroke-dasharray: 226; 
  stroke-dashoffset: 226; /* Start empty for animation */
  stroke-linecap: round; 
  transition: stroke-dashoffset 1.5s cubic-bezier(0.19, 1, 0.22, 1); 
  filter: drop-shadow(0 0 8px rgba(217, 255, 76, 0.4)); 
}

/* Pulsing effect for incomplete sessions */
.athlete-progress-card.incomplete .progress-ring .active {
  animation: ringPulse 2s infinite ease-in-out;
}

@keyframes ringPulse {
  0% { filter: drop-shadow(0 0 2px rgba(217, 255, 76, 0.2)); }
  50% { filter: drop-shadow(0 0 12px rgba(217, 255, 76, 0.6)); }
  100% { filter: drop-shadow(0 0 2px rgba(217, 255, 76, 0.2)); }
}

.progress-value {
  position: absolute;
  font-family: var(--font-main);
  font-weight: 900;
  font-size: 1.1rem;
  letter-spacing: -0.05em;
  color: var(--white);
}

.debt-wall { display: grid; grid-template-columns: 1fr; gap: 12px; }
.debt-item { 
  padding: 14px 18px; 
  background: rgba(255, 59, 48, 0.05); 
  border: 1px solid rgba(255, 59, 48, 0.15); 
  border-radius: 16px; 
  display: flex; 
  align-items: center; 
  gap: 16px; 
  font-size: 0.85rem;
}
.debt-item:hover { background: rgba(255, 59, 48, 0.08); }
.debt-item .status-dot { width: 8px; height: 8px; background: var(--red); border-radius: 50%; box-shadow: 0 0 10px var(--red); flex-shrink: 0; }

.media-feed { display: flex; gap: 16px; overflow-x: auto; padding: 4px; margin-bottom: 40px; scroll-snap-type: x mandatory; }
.media-thumbnail { 
  width: 220px; 
  height: 140px; 
  background: #111; 
  border-radius: 20px; 
  position: relative; 
  flex-shrink: 0; 
  border: 1px solid var(--line); 
  overflow: hidden; 
  cursor: pointer; 
  scroll-snap-align: start;
  transition: all 0.3s ease;
}
.media-thumbnail:hover { border-color: var(--strong-blue); transform: scale(1.02); }
.media-thumbnail img, .media-thumbnail video { width: 100%; height: 100%; object-fit: cover; opacity: 0.7; transition: opacity 0.3s ease; }
.media-thumbnail:hover img, .media-thumbnail:hover video { opacity: 1; }
.media-thumbnail .tag { position: absolute; bottom: 12px; left: 12px; font-size: 0.65rem; font-weight: 800; background: var(--strong-blue); color: white; padding: 4px 10px; border-radius: 6px; text-transform: uppercase; }

.character-card { display: grid; grid-template-columns: 100px 1fr; gap: 24px; align-items: center; }
.character-avatar { width: 100px; height: 100px; border-radius: 24px; background: var(--panel-light); overflow: hidden; border: 2px solid var(--line); }
.character-avatar img { width: 100%; height: 100%; object-fit: cover; }

.history-timeline { border-left: 2px solid var(--line); margin-left: 20px; padding-left: 32px; display: grid; gap: 24px; position: relative; }
.history-node { position: relative; }
.history-node::before { content: ""; position: absolute; left: -41px; top: 8px; width: 16px; height: 16px; border-radius: 50%; background: var(--bg); border: 3px solid var(--muted); z-index: 2; }
/* ANALYSIS WORKSPACE SPECIFIC STYLES */
.analysis-stage {
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden !important;
  padding: 32px 60px !important;
}

.analysis-header {
  flex-shrink: 0;
  margin-bottom: 24px !important;
}

.analysis-workspace-card {
  flex: 1;
  min-height: 0; /* Critical for inner scrolling/flex behavior */
  margin-bottom: 0 !important;
  display: flex;
  flex-direction: column;
  padding: 24px !important;
}

.analysis-main-layout {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 350px;
  gap: 24px;
  min-height: 0;
}

.video-panel {
  position: relative;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  flex: 1;
}

#analysis-video {
  max-width: 100%;
  max-height: 100%;
  width: auto !important; /* Allow shrink-wrap to aspect ratio */
  height: auto !important;
  display: block;
}

.analysis-canvas {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 5;
}

.analysis-controls {
  overflow-y: auto;
  padding-right: 8px;
}

/* Custom Scrollbar for Controls */
.analysis-controls::-webkit-scrollbar { width: 4px; }

/* HUD STYLES */
.analysis-hud {
  position: absolute;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 24px;
  padding: 12px 32px;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-radius: 100px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  pointer-events: none;
  z-index: 100;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.8);
  transition: all 0.3s ease;
}

.hud-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 90px;
  position: relative;
}

.hud-item:not(:last-child)::after {
  content: "";
  position: absolute;
  right: -12px;
  top: 20%;
  height: 60%;
  width: 1px;
  background: rgba(255, 255, 255, 0.1);
}

.hud-item .value {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-top: 2px;
}

.hud-item .unit {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-top: -2px;
}

/* Ensure icons are bright and visible */
.nav-link .icon {
  filter: brightness(1.5) contrast(1.2);
  opacity: 1 !important;
}

.nav-link.active .icon {
  filter: brightness(2);
}

/* --- INSTAGRAM SNAPSHOT FEED --- */
.insta-feed-container {
  width: 100%;
  overflow: hidden;
  padding: 60px 0;
  background: linear-gradient(to bottom, transparent, rgba(217,255,76,0.03), transparent);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin-top: 40px;
  margin-bottom: 120px;
}

.insta-track {
  display: flex;
  width: fit-content;
  animation: scrollMarquee 60s linear infinite;
  gap: 24px;
}

.insta-track:hover {
  animation-play-state: paused;
}

.insta-card {
  width: 320px;
  height: 420px;
  flex-shrink: 0;
  background: var(--panel);
  border-radius: 24px;
  border: 1px solid var(--line);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
  display: flex;
  flex-direction: column;
  text-decoration: none;
}

.insta-card:hover {
  transform: translateY(-15px) scale(1.02);
  border-color: var(--lime);
  box-shadow: 0 30px 60px rgba(217, 255, 76, 0.15);
}

.insta-img {
  flex: 1;
  background-size: cover;
  background-position: center;
  position: relative;
  background-color: #111;
}

.insta-overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(0,0,0,0.9));
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 24px;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.insta-card:hover .insta-overlay {
  opacity: 1;
}

.insta-badge {
  position: absolute;
  top: 20px;
  right: 20px;
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  z-index: 10;
}

.insta-user {
  display: flex;
  align-items: center; gap: 12px;
  position: absolute;
  top: 20px;
  left: 20px;
  background: rgba(0,0,0,0.6);
  padding: 8px 16px;
  border-radius: 30px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.1);
}

.insta-username {
  font-size: 0.75rem;
  font-weight: 800;
  color: white;
}

@keyframes scrollMarquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(calc(-344px * 10)); } /* Adjusted for 10 items */
}

.insta-footer {
  padding: 20px;
  background: var(--panel-light);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.insta-heart { color: var(--red); margin-right: 6px; }


