@import url('https://fonts.googleapis.com/css2?family=Fredoka+One&family=Nunito:wght@400;600;700;800&display=swap');

:root {
  --bg: #0d0a2e;
  --bg2: #13103d;
  --teal: #00e5d4;
  --cyan: #22d3ee;
  --pink: #f472b6;
  --purple: #a78bfa;
  --gold: #fbbf24;
  --card-bg: #1a1650;
  --card-border: #2d2870;
  --radius: 20px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  padding-top: 56px;
  font-family: 'Nunito', sans-serif;
  background: var(--bg);
  color: #fff;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* ── Starry background ──────────────────────────────── */
.stars-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.star {
  position: absolute;
  border-radius: 50%;
  background: #fff;
  animation: twinkle var(--d, 3s) ease-in-out infinite var(--delay, 0s);
  opacity: 0;
}

@keyframes twinkle {
  0%, 100% { opacity: 0; transform: scale(0.8); }
  50%       { opacity: 1; transform: scale(1.2); }
}

/* Floating sparkle particles */
.particle {
  position: fixed;
  pointer-events: none;
  font-size: 18px;
  animation: float-up var(--dur, 8s) linear infinite var(--delay2, 0s);
  opacity: 0;
  z-index: 0;
}

@keyframes float-up {
  0%   { transform: translateY(100vh) rotate(0deg);   opacity: 0; }
  10%  { opacity: 0.8; }
  90%  { opacity: 0.6; }
  100% { transform: translateY(-10vh) rotate(360deg); opacity: 0; }
}

/* ── Main layout ───────────────────────────────────── */
.app {
  position: relative;
  z-index: 1;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

/* ── Header ────────────────────────────────────────── */
header {
  text-align: center;
  padding: 48px 20px 32px;
}

.logo {
  display: block;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  border: 3px solid rgba(0,229,212,0.5);
  box-shadow: 0 0 30px rgba(0,229,212,0.4);
  animation: bounce-logo 2.5s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes bounce-logo {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50%       { transform: translateY(-16px) rotate(3deg); }
}

.title {
  font-family: 'Fredoka One', cursive;
  font-size: clamp(2.2rem, 6vw, 4.5rem);
  background: linear-gradient(90deg, var(--teal), var(--cyan), var(--pink), var(--purple), var(--gold), var(--teal));
  background-size: 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: rainbow-shift 4s linear infinite;
  line-height: 1.1;
}

@keyframes rainbow-shift {
  0%   { background-position: 0%; }
  100% { background-position: 300%; }
}

.subtitle {
  color: var(--purple);
  font-size: 1.1rem;
  font-weight: 700;
  margin-top: 8px;
  letter-spacing: 0.05em;
}

/* ── Category tabs ─────────────────────────────────── */
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin: 0 0 40px;
  padding: 0 10px;
}

.tab {
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  padding: 10px 22px;
  border: 2px solid var(--card-border);
  background: var(--card-bg);
  color: #9ca3af;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  user-select: none;
  letter-spacing: 0.03em;
}

.tab:hover {
  border-color: var(--teal);
  color: var(--teal);
  transform: scale(1.06) translateY(-2px);
}

.tab.active {
  background: linear-gradient(135deg, var(--teal), var(--purple));
  border-color: transparent;
  color: #fff;
  box-shadow: 0 0 20px rgba(0, 229, 212, 0.45), 0 0 40px rgba(167, 139, 250, 0.2);
  transform: scale(1.08) translateY(-2px);
}

/* ── Card grid ─────────────────────────────────────── */
.grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

@media (max-width: 1100px) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px)  { .grid { grid-template-columns: repeat(2, 1fr); gap: 16px; } }
@media (max-width: 480px)  { .grid { grid-template-columns: 1fr; } }

/* ── Video card ────────────────────────────────────── */
.card {
  background: var(--card-bg);
  border: 2px solid var(--card-border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease, border-color 0.3s ease;
  animation: card-in 0.5s ease both;
}

@keyframes card-in {
  from { opacity: 0; transform: translateY(24px) scale(0.95); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.card:hover {
  transform: scale(1.08) translateY(-6px);
  box-shadow: 0 0 30px rgba(0, 229, 212, 0.4), 0 16px 40px rgba(0, 0, 0, 0.5);
  border-color: var(--teal);
}

.card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  background: #0a0830;
  overflow: hidden;
}

.card-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-thumb .play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.25);
  transition: opacity 0.25s;
}

.card:hover .play-overlay {
  opacity: 0;
}

.play-btn-icon {
  width: 52px;
  height: 52px;
  background: rgba(0, 229, 212, 0.85);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 0 20px rgba(0,229,212,0.6);
  transition: transform 0.2s;
}

.card:hover .play-btn-icon {
  transform: scale(1.15);
}

.card-info {
  padding: 14px 16px 16px;
}

.card-emoji {
  font-size: 1.6rem;
  display: block;
  margin-bottom: 4px;
}

.card-title {
  font-family: 'Fredoka One', cursive;
  font-size: 1.05rem;
  color: #e2e8f0;
  line-height: 1.3;
  margin-bottom: 8px;
}

.card-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 3px 10px;
  border-radius: 20px;
  background: rgba(0, 229, 212, 0.12);
  color: var(--teal);
  border: 1px solid rgba(0,229,212,0.3);
}

.badge-dancando  { background: rgba(244,114,182,0.12); color: var(--pink); border-color: rgba(244,114,182,0.3); }
.badge-falando   { background: rgba(167,139,250,0.12); color: var(--purple); border-color: rgba(167,139,250,0.3); }
.badge-celebrando{ background: rgba(251,191,36,0.12); color: var(--gold); border-color: rgba(251,191,36,0.3); }
.badge-eua       { background: rgba(34,211,238,0.12); color: var(--cyan); border-color: rgba(34,211,238,0.3); }
.badge-aventuras { background: rgba(52,211,153,0.12); color: #34d399; border-color: rgba(52,211,153,0.3); }
.badge-fofinhos  { background: rgba(255,182,193,0.15); color: #ff9eb5; border-color: rgba(255,182,193,0.4); }

/* ── Empty state ───────────────────────────────────── */
.empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--purple);
  font-size: 1.2rem;
}

/* ── Modal ─────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 4, 20, 0.92);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(6px);
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal-box {
  position: relative;
  width: 100%;
  max-width: 900px;
  background: var(--card-bg);
  border: 2px solid var(--teal);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 0 60px rgba(0, 229, 212, 0.3), 0 0 120px rgba(167, 139, 250, 0.15);
  transform: scale(0.85) translateY(30px);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.open .modal-box {
  transform: scale(1) translateY(0);
}

.modal-header {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 10px 14px 6px;
  background: var(--card-bg);
}

.modal-video-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  background: #000;
}

.modal-video-wrap video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.modal-footer {
  padding: 16px 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-title {
  font-family: 'Fredoka One', cursive;
  font-size: 1.4rem;
  color: #fff;
  flex: 1;
}

.modal-close {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.12);
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.2s;
}

.modal-close:hover {
  background: var(--pink);
  transform: rotate(90deg) scale(1.1);
}

/* ── Confetti ──────────────────────────────────────── */
.confetti-piece {
  position: fixed;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  pointer-events: none;
  z-index: 2000;
  animation: confetti-fall var(--cf-d, 1.5s) ease-in var(--cf-delay, 0s) forwards;
}

@keyframes confetti-fall {
  0%   { transform: translateY(0) rotate(0deg) scale(1); opacity: 1; }
  100% { transform: translateY(600px) rotate(720deg) scale(0.3); opacity: 0; }
}

/* ── Footer ────────────────────────────────────────── */
footer {
  text-align: center;
  padding: 40px 20px 20px;
  color: #4b5563;
  font-size: 0.95rem;
  font-weight: 600;
  position: relative;
  z-index: 1;
}

footer span {
  color: var(--pink);
}

/* ── Fade animation for grid transitions ───────────── */
.grid.fading {
  opacity: 0;
  transform: scale(0.97);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.grid.visible {
  opacity: 1;
  transform: scale(1);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

/* ── Like button ───────────────────────────────────── */
.like-btn {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid rgba(244, 114, 182, 0.4);
  background: rgba(244, 114, 182, 0.1);
  font-size: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.15s, border-color 0.2s;
  position: relative;
}

.like-btn:hover {
  background: rgba(244, 114, 182, 0.25);
  border-color: rgba(244, 114, 182, 0.8);
  transform: scale(1.1);
}

.like-btn.liked {
  background: rgba(244, 114, 182, 0.3);
  border-color: var(--pink);
  animation: like-pop 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes like-pop {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.4); }
  100% { transform: scale(1); }
}

/* ── Owl burst animation ───────────────────────────── */
.owl-burst {
  position: fixed;
  font-size: 28px;
  pointer-events: none;
  z-index: 3000;
  animation: owl-float var(--owl-dur, 1.2s) ease-out var(--owl-delay, 0s) forwards;
  user-select: none;
}

@keyframes owl-float {
  0%   { transform: translateY(0) scale(1) rotate(var(--owl-rot, 0deg)); opacity: 1; }
  100% { transform: translateY(-110vh) scale(0.8) rotate(var(--owl-rot2, 20deg)); opacity: 1; }
}

/* ── Share button ──────────────────────────────────── */
.share-btn {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 18px;
  height: 48px;
  border-radius: 24px;
  border: 2px solid rgba(167, 139, 250, 0.35);
  background: rgba(167, 139, 250, 0.1);
  color: #c4b5fd;
  font-family: 'Nunito', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  position: relative;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.share-btn:hover {
  background: rgba(167, 139, 250, 0.22);
  border-color: rgba(167, 139, 250, 0.7);
  transform: scale(1.05);
}

.share-btn svg {
  flex-shrink: 0;
}

.share-toast {
  position: absolute;
  bottom: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(6px);
  background: #a78bfa;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
  padding: 5px 12px;
  border-radius: 20px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
}

.share-btn.copied .share-toast {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── Card creator credit ───────────────────────────── */
.card-creator {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.07);
}

.creator-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #a78bfa, #22d3ee);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}

.creator-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: #94a3b8;
}

/* ── FAB upload button ─────────────────────────────── */
.fab-upload {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  width: 88px;
  height: 88px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #00e5d4, #a78bfa);
  box-shadow: 0 4px 24px rgba(0, 229, 212, 0.45), 0 2px 8px rgba(0,0,0,0.3);
  cursor: pointer;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s cubic-bezier(0.34,1.56,0.64,1), box-shadow 0.2s;
}

.fab-upload:hover {
  transform: translateX(-50%) scale(1.12);
  box-shadow: 0 6px 32px rgba(0, 229, 212, 0.6), 0 2px 8px rgba(0,0,0,0.3);
}

.fab-upload:active {
  transform: translateX(-50%) scale(0.95);
}

.fab-plus {
  color: #fff;
  font-size: 52px;
  line-height: 1;
  font-weight: 300;
  margin-top: -3px;
}

/* ── Upload panel ──────────────────────────────────── */
.upload-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5, 4, 20, 0.88);
  z-index: 1100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0 16px 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(6px);
}

.upload-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.upload-panel {
  width: 100%;
  max-width: 520px;
  background: #13103a;
  border: 2px solid rgba(0, 229, 212, 0.3);
  border-bottom: none;
  border-radius: 28px 28px 0 0;
  padding: 32px 28px 48px;
  text-align: center;
  position: relative;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.upload-overlay.open .upload-panel {
  transform: translateY(0);
}

.upload-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.1);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.upload-close:hover { background: var(--pink); }

.upload-icon {
  font-size: 3rem;
  margin-bottom: 12px;
}

.upload-title {
  font-family: 'Fredoka One', cursive;
  font-size: 1.8rem;
  color: #fff;
  margin-bottom: 10px;
}

.upload-desc {
  font-size: 0.95rem;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 24px;
}

.upload-file-btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 30px;
  background: linear-gradient(135deg, #00e5d4, #a78bfa);
  color: #fff;
  font-family: 'Fredoka One', cursive;
  font-size: 1.1rem;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
  box-shadow: 0 4px 16px rgba(0,229,212,0.3);
  margin-bottom: 16px;
}

.upload-file-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 24px rgba(0,229,212,0.45);
}

.upload-hint {
  font-size: 0.78rem;
  color: #4b5563;
}

/* ── Upload actions row ────────────────────────────── */
.upload-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.upload-cam-btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 30px;
  background: rgba(244, 114, 182, 0.15);
  border: 2px solid rgba(244, 114, 182, 0.5);
  color: #f472b6;
  font-family: 'Fredoka One', cursive;
  font-size: 1.1rem;
  cursor: pointer;
  transition: transform 0.15s, background 0.2s, box-shadow 0.15s;
}

.upload-cam-btn:hover {
  background: rgba(244, 114, 182, 0.28);
  transform: scale(1.05);
  box-shadow: 0 4px 16px rgba(244,114,182,0.3);
}

/* ── Camera recorder ───────────────────────────────── */
.cam-recorder {
  margin-top: 20px;
  border-radius: 16px;
  overflow: hidden;
  border: 2px solid rgba(0, 229, 212, 0.3);
}

.cam-preview {
  width: 100%;
  aspect-ratio: 4/3;
  background: #000;
  display: block;
}

.cam-controls {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  padding: 12px;
  background: rgba(0,0,0,0.4);
}

.cam-record-btn, .cam-stop-btn, .cam-close-btn {
  padding: 9px 18px;
  border-radius: 20px;
  border: none;
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  font-size: 0.85rem;
  cursor: pointer;
  transition: opacity 0.2s, transform 0.15s;
}

.cam-record-btn {
  background: #ef4444;
  color: #fff;
}

.cam-stop-btn {
  background: #374151;
  color: #fff;
}

.cam-stop-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.cam-close-btn {
  background: rgba(255,255,255,0.1);
  color: #fff;
}

.cam-record-btn:not(:disabled):hover,
.cam-close-btn:hover { transform: scale(1.07); }

.cam-status {
  text-align: center;
  font-size: 0.8rem;
  color: #94a3b8;
  padding: 6px 12px 10px;
  background: rgba(0,0,0,0.3);
  margin: 0;
}

/* ── Splash screen ─────────────────────────────────── */
.splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: radial-gradient(ellipse at center, #1a1246 0%, #0d0a2e 70%);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}

.splash.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.splash-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.splash-owl {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  object-fit: cover;
  animation: splash-bounce 0.7s cubic-bezier(0.34,1.56,0.64,1) 0.2s both;
  display: block;
  box-shadow: 0 0 50px rgba(0,229,212,0.55), 0 0 100px rgba(167,139,250,0.2);
  border: 3px solid rgba(0,229,212,0.4);
}

.splash-wave {
  font-size: 3.5rem;
  animation: splash-wave-hand 0.6s ease-in-out 0.9s both;
  display: block;
  transform-origin: bottom center;
  margin-top: -10px;
}

.splash-title {
  font-family: 'Fredoka One', cursive;
  font-size: 5rem;
  color: #fff;
  margin: 0;
  animation: splash-pop 0.5s cubic-bezier(0.34,1.56,0.64,1) 1.1s both;
  text-shadow: 0 0 40px rgba(0,229,212,0.6);
}

.splash-sub {
  font-family: 'Fredoka One', cursive;
  font-size: 2.8rem;
  color: #a78bfa;
  margin: 0;
  animation: splash-fade-in 0.5s ease 1.5s both;
  text-shadow: 0 0 30px rgba(167,139,250,0.5);
}

.splash-sub strong {
  background: linear-gradient(90deg, #f472b6, #a78bfa, #22d3ee, #fbbf24, #f472b6);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: splash-rainbow 3s linear infinite, splash-fade-in 0.5s ease 1.5s both;
}

@keyframes splash-rainbow {
  0%   { background-position: 0% center; }
  100% { background-position: 200% center; }
}

@keyframes splash-bounce {
  0%   { transform: translateY(80px) scale(0.3); opacity: 0; }
  100% { transform: translateY(0) scale(1); opacity: 1; }
}

@keyframes splash-wave-hand {
  0%   { transform: rotate(-20deg) scale(0); opacity: 0; }
  60%  { transform: rotate(25deg) scale(1.1); opacity: 1; }
  80%  { transform: rotate(-10deg) scale(1); }
  100% { transform: rotate(10deg) scale(1); opacity: 1; }
}

@keyframes splash-pop {
  0%   { transform: scale(0); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes splash-fade-in {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.splash-owl::-webkit-media-controls { display: none !important; }
.splash-owl::-webkit-media-controls-enclosure { display: none !important; }

/* ── YouTube Layout ─────────────────────────────────── */

body { background: #0f0f0f; }

.yt-header {
  position: fixed; top: 0; left: 0; right: 0; height: 56px;
  background: #0f0f0f; display: flex; align-items: center;
  justify-content: space-between; padding: 0 16px;
  z-index: 100; border-bottom: 1px solid #272727;
}
.yt-header-left { display: flex; align-items: center; gap: 12px; }
.yt-hamburger { background: none; border: none; color: #f1f1f1; font-size: 20px; cursor: pointer; padding: 8px; border-radius: 50%; }
.yt-hamburger:hover { background: #272727; }
.yt-logo-img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.yt-logo-name { font-family: 'Fredoka One', cursive; font-size: 1.2rem; color: #f1f1f1; white-space: nowrap; }
.yt-logo-accent { color: #00e5d4; }

.yt-header-center { flex: 1; max-width: 560px; margin: 0 32px; }
.yt-search { display: flex; border: 1px solid #303030; border-radius: 40px; overflow: hidden; }
.yt-search-input { flex: 1; background: #121212; border: none; padding: 8px 16px; color: #f1f1f1; font-size: 0.95rem; outline: none; }
.yt-search-btn { background: #272727; border: none; padding: 8px 16px; color: #f1f1f1; cursor: pointer; font-size: 16px; }

.yt-header-right { display: flex; align-items: center; gap: 12px; }
.yt-upload-trigger { display: flex; align-items: center; gap: 8px; background: #272727; border: none; color: #f1f1f1; font-size: 16px; cursor: pointer; padding: 10px 18px; border-radius: 20px; font-family: 'Nunito', sans-serif; font-weight: 800; white-space: nowrap; transition: background 0.2s; }
.yt-upload-trigger:hover { background: #3f3f3f; }
.yt-avatar { width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, #a78bfa, #22d3ee); display: flex; align-items: center; justify-content: center; font-size: 0.7rem; font-weight: 800; color: #fff; cursor: pointer; }

/* Channel banner */
.yt-channel-banner {
  margin-top: 56px; margin-left: 240px;
  background: linear-gradient(135deg, #0d0a2e 0%, #1a1246 100%);
  border-bottom: 1px solid #272727; padding: 24px 32px;
  position: relative; z-index: 1;
}
.yt-channel-info { display: flex; align-items: center; gap: 20px; }
.yt-channel-avatar { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; border: 3px solid #00e5d4; }
.yt-channel-name { font-family: 'Fredoka One', cursive; font-size: 1.8rem; color: #f1f1f1; margin: 0 0 4px; }
.yt-channel-sub { font-size: 0.85rem; color: #aaaaaa; margin: 0; }

/* Sidebar */
.yt-sidebar {
  position: fixed; left: 0; top: 56px; bottom: 0;
  width: 240px; background: #0f0f0f; overflow-y: auto;
  padding: 12px 0; z-index: 90; transition: width 0.2s;
}
.yt-sidebar.collapsed { width: 72px; }
.yt-sidebar.collapsed .yt-nav-label { display: none; }
.yt-sidebar.collapsed .yt-nav-item { justify-content: center; padding: 14px 0; }

.yt-nav-item {
  display: flex; align-items: center; gap: 16px;
  padding: 10px 24px; cursor: pointer; border-radius: 10px;
  margin: 2px 8px; color: #f1f1f1; font-size: 0.92rem;
  font-family: 'Nunito', sans-serif; font-weight: 600;
  text-decoration: none; transition: background 0.15s;
}
.yt-nav-item:hover { background: #272727; }
.yt-nav-item.active { background: #272727; font-weight: 800; }
.yt-nav-item.active .yt-nav-icon { filter: drop-shadow(0 0 6px rgba(0,229,212,0.8)); }
.yt-nav-icon { font-size: 1.2rem; flex-shrink: 0; }

/* Main content area */
.yt-main {
  margin-left: 240px; margin-top: 0; padding: 24px 24px 80px;
  transition: margin-left 0.2s; min-height: 100vh;
  position: relative; z-index: 1;
}
.yt-main.expanded { margin-left: 72px; }

/* Video grid — YouTube style */
.yt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px 16px;
}

/* Card — YouTube style */
.card {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  cursor: pointer;
}
.card:hover {
  transform: none !important;
  box-shadow: none !important;
  border-color: transparent !important;
}
.card-thumb {
  border-radius: 12px !important;
  aspect-ratio: 16/9 !important;
  overflow: hidden;
  position: relative;
}
.card-info {
  padding: 10px 0 0 !important;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.card-side-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, #a78bfa, #22d3ee);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem; font-weight: 800; color: #fff;
  flex-shrink: 0; margin-top: 2px;
}
.card-text-col { flex: 1; min-width: 0; }
.card-title {
  font-size: 0.95rem !important;
  color: #f1f1f1 !important;
  font-family: 'Roboto', sans-serif !important;
  font-weight: 600 !important;
  line-height: 1.3 !important;
  margin-bottom: 4px !important;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-meta { font-size: 0.8rem; color: #aaaaaa; }
.card-emoji { display: none !important; }
.card-creator { display: none !important; }
.card-badge { display: none !important; }

/* ── App title bar ─────────────────────────────────── */
.app-title-bar {
  text-align: center;
  padding: 24px 24px 20px;
  border-bottom: 1px solid #272727;
  margin-bottom: 24px;
}
.app-main-title {
  font-family: 'Fredoka One', cursive;
  font-size: 2.2rem;
  line-height: 1.3;
  display: block;
  padding: 6px 0 4px;
  background: linear-gradient(90deg, #f472b6, #a78bfa, #22d3ee);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0 0 6px;
}
.app-main-sub {
  color: #aaaaaa;
  font-size: 0.95rem;
  margin: 0;
}

/* ── Sidebar overlay (mobile) ──────────────────────── */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 150;
}

.sidebar-overlay.open {
  display: block;
}

/* ── Mobile responsiveness ─────────────────────────── */
@media (max-width: 768px) {
  .yt-sidebar {
    transform: translateX(-240px);
    width: 240px !important;
    z-index: 200;
    transition: transform 0.2s ease, width 0.2s;
  }

  .yt-sidebar.open {
    transform: translateX(0);
  }

  .yt-sidebar.collapsed {
    width: 240px !important;
    transform: translateX(-240px);
  }

  .yt-sidebar.collapsed.open {
    transform: translateX(0);
  }

  .yt-main,
  .yt-main.expanded {
    margin-left: 0 !important;
  }

  .yt-channel-banner {
    margin-left: 0;
  }

  .yt-grid {
    grid-template-columns: 1fr;
  }

  .yt-header-center {
    display: none;
  }

  .app-main-title {
    font-size: 1.3rem;
  }
}
