.ytt-root {
  --yt-red: #f00;

  max-width: 1400px;
  margin: 0 auto;
}

.premium-card {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 32px;
  padding: 2rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
  .premium-card {
  padding: 1rem;
  border-radius: 20px;
}
}

.theme-dark .ytt-root .premium-card {
  background: rgba(15, 23, 42, 0.7);
  border-color: rgba(255, 255, 255, 0.05);
}

.main-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 2rem;
  align-items: start;
}

@media (max-width: 1100px) { .main-layout { grid-template-columns: 1fr; } }

@media (max-width: 768px) { .main-layout { gap: 1rem; } }

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: sticky;
  top: 2rem;
}

@media (max-width: 1100px) { .sidebar { position: static; } }

@media (max-width: 768px) { .sidebar { gap: 1rem; } }

.upload-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

@media (max-width: 768px) { .upload-group {
  grid-template-columns: 1fr;
  gap: 0.5rem;
} }

.drop-zone {
  width: 100%;
  height: 100px;
  border: 2px dashed rgba(239, 68, 68, 0.15);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  cursor: pointer;
  background: rgba(239, 68, 68, 0.02);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-align: center;
  padding: 0.5rem;
  color: inherit;
}

@media (max-width: 768px) { .drop-zone {
  height: 80px;
  border-radius: 16px;
} }

.drop-zone:hover,
.drop-zone.hover {
  border-color: var(--yt-red);
  background: rgba(239, 68, 68, 0.06);
  transform: translateY(-2px);
}

.drop-icon {
  font-size: 1.6rem;
  color: var(--yt-red);
}

.drop-text h3 {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 800;
}
.drop-text p {
  margin: 0;
  font-size: 0.6rem;
  color: #94a3b8;
}

@media (max-width: 768px) {
  .drop-text h3 { font-size: 0.7rem; }
  .drop-text p { font-size: 0.55rem; }
  .drop-icon { font-size: 1.2rem; }
}

.gallery-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px;
  background: rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: 16px;
  min-height: 50px;
}

@media (max-width: 768px) { .gallery-preview {
  gap: 6px;
  padding: 8px;
  border-radius: 12px;
} }

.theme-dark .ytt-root .gallery-preview {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.06);
}

.custom-settings {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.25rem;
  background: rgba(0, 0, 0, 0.03);
  border-radius: 20px;
  border: 1px solid rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) { .custom-settings {
  padding: 1rem;
  gap: 0.75rem;
  border-radius: 16px;
} }

.theme-dark .ytt-root .custom-settings {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.06);
}

.settings-group label {
  display: block;
  font-size: 0.7rem;
  font-weight: 800;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.3rem;
}

.settings-group input {
  width: 100%;
  padding: 0.8rem;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  font-size: 0.9rem;
  background: white;
  color: #1e293b;
  outline: none;
  transition: all 0.2s;
  box-sizing: border-box;
}

@media (max-width: 768px) {
  .settings-group label { font-size: 0.65rem; }
  .settings-group input {
  padding: 0.7rem;
  font-size: 0.85rem;
  border-radius: 10px;
}
}

.theme-dark .ytt-root .settings-group input {
  background: rgba(15, 23, 42, 0.5);
  border-color: rgba(255, 255, 255, 0.1);
  color: #f1f5f9;
}

.settings-group input:focus {
  border-color: var(--yt-red);
  box-shadow: 0 0 0 4px rgba(255, 0, 0, 0.05);
}

.tester-controls {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

@media (max-width: 768px) { .tester-controls {
  grid-template-columns: 1fr;
  gap: 0.5rem;
} }

.control-btn {
  border: none;
  background: rgba(0, 0, 0, 0.05);
  padding: 1rem;
  border-radius: 14px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: #64748b;
  transition: all 0.2s;
}

@media (max-width: 768px) { .control-btn {
  padding: 0.8rem;
  font-size: 0.75rem;
  border-radius: 12px;
} }

.control-btn:hover {
  background: rgba(0, 0, 0, 0.08);
  color: #1e293b;
}

.theme-dark .ytt-root .control-btn {
  background: rgba(255, 255, 255, 0.05);
  color: #94a3b8;
}

.theme-dark .ytt-root .control-btn:hover { color: #f1f5f9; }

.control-btn.active {
  background: var(--yt-red);
  color: white;
  box-shadow: 0 8px 20px rgba(255, 0, 0, 0.15);
}

.control-btn--reset {
  grid-column: span 2;
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.2);
}

@media (max-width: 768px) { .control-btn--reset { grid-column: span 1; } }

.preview-area { min-width: 0; }

.comparison-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  background: #e2e8f0;
  border-radius: 32px;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
}

.theme-dark .comparison-container {
  background: rgba(255, 255, 255, 0.05);
}

@media (max-width: 768px) {
  .comparison-container {
  grid-template-columns: 1fr;
  border-radius: 20px;
  gap: 8px;
}
}

.comparison-side {
  position: relative;
  padding: 3rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 600px;
  transition: background 0.3s ease;
}

@media (max-width: 768px) {
  .comparison-side {
  padding: 2rem 1rem;
  min-height: auto;
}
}

.comparison-label {
  position: absolute;
  top: 1.25rem;
  left: 1.25rem;
  background: rgba(0, 0, 0, 0.6);
  color: white;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 900;
  z-index: 20;
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

@media (max-width: 768px) {
  .comparison-label {
  font-size: 10px;
  padding: 4px 8px;
  top: 0.75rem;
  left: 0.75rem;
}
}

.mockup-grid {
  display: grid;
  gap: 3rem;
  width: 100%;
}

.mockup-desktop .mockup-grid { max-width: 520px; }
.mockup-mobile .mockup-grid { max-width: 320px; }

@media (max-width: 768px) {
  .mockup-grid { gap: 2rem; }
  .mockup-desktop .mockup-grid,
  .mockup-mobile .mockup-grid { max-width: 100%; }
}

.yt-card {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  animation: ytt-slide-up 0.4s ease-out backwards;
}

@media (max-width: 768px) {
  .yt-card { gap: 0.75rem; }
}

@keyframes ytt-slide-up {
  from {
  opacity: 0;
  transform: translateY(20px);
}
  to {
  opacity: 1;
  transform: translateY(0);
}
}

.yt-thumbnail-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 16px;
  overflow: hidden;
  background: #e2e8f0;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.yt-thumbnail-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.yt-duration {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(0, 0, 0, 0.9);
  color: white;
  padding: 3px 6px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 600;
}

@media (max-width: 768px) {
  .yt-duration {
  font-size: 10px;
  padding: 2px 4px;
  bottom: 6px;
  right: 6px;
}
}

.yt-info-row {
  display: flex;
  gap: 14px;
}

@media (max-width: 768px) {
  .yt-info-row { gap: 10px; }
}

.yt-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  overflow: hidden;
  background: #e5e7eb;
  border: 1px solid rgba(0, 0, 0, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
}

.mockup-mobile .yt-avatar {
  width: 36px;
  height: 36px;
}

.yt-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.yt-avatar svg {
  width: 60%;
  height: 60%;
}

.yt-text-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.yt-title {
  font-weight: 700;
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: inherit;
}

.mockup-desktop .yt-title { font-size: 1.1rem; }
.mockup-mobile .yt-title { font-size: 0.9rem; }

.yt-channel,
.yt-views {
  font-size: 0.85rem;
  margin: 0;
  font-weight: 500;
}

.mockup-mobile .yt-channel,
.mockup-mobile .yt-views { font-size: 0.75rem; }

@media (max-width: 768px) {
  .yt-channel, .yt-views { font-size: 0.75rem; }
  .mockup-mobile .yt-channel, .mockup-mobile .yt-views { font-size: 0.65rem; }
}

.light .yt-channel, .light .yt-views { color: #606060; }
.dark .yt-channel, .dark .yt-views { color: #aaa; }

.yt-mockup.light {
  background: #f9f9f9;
  color: #030303;
}
.yt-mockup.dark {
  background: #0f0f0f;
  color: #f1f1f1;
}

.gallery-item {
  width: 60px;
  aspect-ratio: 16/9;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.btn-remove-thumb {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #ef4444;
  color: white;
  border: none;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 0.2s;
}

.gallery-item:hover .btn-remove-thumb { opacity: 1; }
