/* Modern Dark Theme untuk DOODS CERIA 2025 */

/* Base Styles */
:root {
  --dark-primary: #121212;
  --dark-secondary: #1e1e1e;
  --dark-tertiary: #2d2d2d;
  --accent-blue: #4f46e5;
  --accent-blue-hover: #4338ca;
  --text-white: #f8fafc;
  --text-light: #e2e8f0;
  --text-muted: #94a3b8;
  --border-dark: #333333;
  --card-bg: #1e1e1e;
  --green: #22c55e;
  --red: #ef4444;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: linear-gradient(to right, #000000, #0f2b52);
  color: var(--text-light);
  line-height: 1.6;
}


a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--accent-blue-hover);
}

img {
  max-width: 100%;
}

/* Layout */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 20px;
}

.main-wrapper {
  min-height: calc(100vh - 140px);
}

/* Header */
.site-header {
  background-color: rgba(30, 30, 30, 0.95);
  border-bottom: 1px solid var(--border-dark);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
}

.site-logo {
  display: flex;
  align-items: center;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-white);
}

.site-logo svg {
  width: 32px;
  height: 32px;
  margin-right: 10px;
  color: var(--accent-blue);
}

.admin-link {
  background-color: transparent;
  border: 1px solid var(--border-dark);
  color: var(--text-light);
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 0.875rem;
  transition: all 0.2s ease;
}

.admin-link:hover {
  background-color: var(--dark-tertiary);
  color: var(--text-white);
}

/* Main Content */
.main-content {
  padding: 40px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 40px;
}

.section-title h1 {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--text-white);
  margin-bottom: 12px;
}

.section-title p {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto;
}

/* Video Grid */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.video-card {
  background-color: var(--card-bg);
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border-dark);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  text-decoration: none;
  color: inherit;
}

.video-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.thumbnail-container {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.thumbnail-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.video-card:hover .thumbnail-container img {
  transform: scale(1.05);
}

.thumbnail-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}

.video-views {
  position: absolute;
  bottom: 10px;
  left: 10px;
  background-color: rgba(0, 0, 0, 0.7);
  color: var(--text-white);
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.video-duration {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background-color: rgba(0, 0, 0, 0.7);
  color: var(--text-white);
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.video-duration svg {
  width: 12px;
  height: 12px;
}

.video-info {
  padding: 16px;
}

.video-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-white);
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 48px;
}

.video-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.video-likes {
  display: flex;
  align-items: center;
  gap: 4px;
}

.video-date {
  color: var(--text-muted);
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  margin-top: 40px;
}

.pagination-list {
  display: flex;
  list-style: none;
  gap: 4px;
}

.page-link {
  display: inline-block;
  padding: 8px 14px;
  background-color: var(--dark-secondary);
  border: 1px solid var(--border-dark);
  border-radius: 6px;
  color: var(--text-light);
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.page-link:hover {
  background-color: var(--dark-tertiary);
  color: var(--text-white);
}

.page-link.active {
  background-color: var(--accent-blue);
  border-color: var(--accent-blue);
  color: white;
}

/* Single Video Page */
.video-container {
  background-color: var(--card-bg);
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-dark);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.3);
  margin-bottom: 20px;
}

.player-container {
  padding: 20px;
}

.responsive-iframe {
  position: relative;
  overflow: hidden;
  width: 100%;
}

.responsive-iframe iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  border: none;
}

.video-details {
  padding: 20px;
  border-top: 1px solid var(--border-dark);
}

.video-title-large {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-white);
  margin-bottom: 16px;
}

.video-stats {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border-dark);
}

.video-views-count {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.875rem;
}

.video-actions {
  display: flex;
  gap: 12px;
}

.action-button {
  display: flex;
  align-items: center;
  gap: 8px;
  background-color: var(--dark-tertiary);
  border: 1px solid var(--border-dark);
  border-radius: 20px;
  padding: 8px 16px;
  color: var(--text-light);
  font-size: 0.875rem;
  transition: all 0.2s ease;
  cursor: pointer;
}

.action-button:hover {
  background-color: rgba(51, 65, 85, 0.8);
}

.like-button svg {
  color: var(--green);
}

.dislike-button svg {
  color: var(--red);
}

.video-description {
  color: var(--text-light);
  background-color: rgba(51, 65, 85, 0.3);
  padding: 16px;
  border-radius: 8px;
  white-space: pre-line;
  margin-top: 20px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  margin-top: 24px;
  color: var(--accent-blue);
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
}

.back-link svg {
  margin-right: 6px;
}

/* Footer */
.site-footer {
  background-color: var(--dark-secondary);
  border-top: 1px solid var(--border-dark);
  padding: 40px 0;
  margin-top: 60px;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

@media (min-width: 768px) {
  .footer-content {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }
}

.footer-logo {
  display: flex;
  align-items: center;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-white);
  margin-bottom: 20px;
}

@media (min-width: 768px) {
  .footer-logo {
    margin-bottom: 0;
  }
}

.footer-logo svg {
  width: 24px;
  height: 24px;
  margin-right: 8px;
  color: var(--accent-blue);
}

.copyright {
  color: var(--text-muted);
  font-size: 0.875rem;
}

/* Active states for buttons */
.active-like {
  background-color: rgba(34, 197, 94, 0.2) !important;
  border-color: var(--green) !important;
}

.active-dislike {
  background-color: rgba(239, 68, 68, 0.2) !important;
  border-color: var(--red) !important;
}

/* Animation for share button */
@keyframes popIn {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

.share-button:active {
  animation: popIn 0.3s ease;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .video-grid {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
  }
  
  .section-title h1 {
    font-size: 1.75rem;
  }
  
  .video-stats {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  
  .video-actions {
    width: 100%;
    justify-content: space-between;
  }
}


.banner-container {
  padding: 20px;
  background: rgba(0,0,0,0.1);
  border-radius: 10px;
  margin: 20px 0;
}

.banner-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.banner-link {
  display: block;
  transition: transform 0.3s ease;
}

.banner-link:hover {
  transform: scale(1.02);
}

.banner-image {
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.banner-image.glow {
  filter: drop-shadow(0px 0px 10px #ffffff);
}


input[type="text"]:focus, textarea:focus {
    outline: none;
    border-color: var(--accent-blue) !important;
    box-shadow: 0 0 5px rgba(79, 70, 229, 0.3);
}

input[type="text"]::placeholder, textarea::placeholder {
    color: var(--text-muted);
}

button[name="add_comment"]:hover {
    background: var(--accent-blue-hover) !important;
    transform: translateY(-1px);
}

/* Mobile responsive */
@media (max-width: 768px) {
    .video-stats-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .video-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .action-button {
        width: 100%;
        justify-content: center;
    }
}

/* Additional CSS for comment features */
.video-comments {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

/* Mobile responsive for comments section */
@media (max-width: 768px) {
    .latest-comments-section {
        padding: 15px;
        margin: 0 -15px 20px;
        border-radius: 0;
    }
    
    .latest-comments-section h3 {
        font-size: 18px;
    }
    
    .comment-item {
        padding: 12px;
    }
    
    .comment-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .video-comments {
        font-size: 10px;
        padding: 3px 6px;
    }
}

/* Hover effects */
.latest-comments-section .comment-item:hover {
    background: rgba(0,0,0,0.3) !important;
    transform: translateX(5px);
    transition: all 0.3s ease;
}

.latest-comments-section a:hover {
    color: rgba(0, 0, 0, 0.7) !important;
    text-decoration: underline !important;
}