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

/* Google Font Poppins: sudah include di layouts.app */
html,
body {
  font-family: "Poppins", sans-serif;
  background-color: #110027;
  color: hsl(210deg 20% 98% / 80%);
}

/* Container */
.container {
  width: 100%;
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Header */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background-color: #1a0037;
}
header .logo {
  font-size: 1.5rem;
  color: #fff;
  text-decoration: none;
}
header .logo:hover {
  color: #7d00ff;
}
#nav a {
  margin: 0 8px;
  font-size: 1rem;
  color: #e2e8f0;
  text-decoration: none;
}
#nav a:hover {
  color: #7d00ff;
}

.search-bar {
  display: flex;
  width: 100%;
  background-color: #10032a;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  overflow: hidden;
  margin: 1.5rem 0;
  align-items: center;
}

.search-bar .input-wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  padding: 0 12px;
}

.search-bar .icon {
  color: rgba(255, 255, 255, 0.5);
  margin-right: 8px;
  display: flex;
  align-items: center;
}

.search-bar .search-input {
  flex: 1;
  background: transparent;
  border: none;
  color: #e2e8f0;
  font-size: 1rem;
  padding: 14px 0;
  outline: none;
}

.search-bar .search-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.search-bar .search-button {
  background-color: #1f293700;
  border: none;
  color: #e2e8f0;
  padding: 0 24px;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  height: 100%;
}

/* Responsive tweak (tidak diubah ke column biar tetap horizontal di mobile) */
@media (max-width: 640px) {
  .search-bar {
    flex-direction: row;
  }

  .search-bar .search-button {
    padding: 0 16px;
    font-size: 0.9rem;
  }
}

/* Tablet */
@media (max-width: 1024px) {
  .container {
    max-width: 900px;
    padding: 0 0.75rem;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .container {
    max-width: 100%;
    padding: 0 0.5rem; /* lebih sempit agar muat di layar kecil */
  }
}

/* Video Grid */
.video-grid {
  display: grid;
  /* Desktop: 4 kolom */
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 16px;
  margin-bottom: 30px;
}

/* Tablet */
@media (max-width: 1024px) {
  .video-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Mobile (portrait + landscape) */
@media (max-width: 768px) {
  .video-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

/* Container Card */
.video-card {
  display: flex;
  flex-direction: column;
  //  border-radius: 8px;
  border-color: #d70000;
  overflow: hidden;
  text-decoration: none;
  color: #fff;
  transition: transform 0.2s ease;
}

.video-card:hover {
  transform: translateY(-4px);
}

/* Thumbnail */
.video-card .thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background-color: #111;
  background-image: var(--thumb); /* fallback jika inline style gagal */
  background-repeat: repeat; /* tile jika gambar kecil */
  background-size: contain; /* tampilkan penuh tanpa crop */
  background-position: center;
  transition: background 0.2s ease;
}

/* Gambar Utama */
.video-card .thumb img.main-thumb {
  width: 100%;
  height: 100%;
  object-fit: contain; /* agar tidak pecah/ngezoom */
  display: block;
  background-color: transparent; /* biar tidak tumpang tindih dengan bg .thumb */
}

/* Ikon Bolt */
.video-card .thumb .icon-bolt {
  position: absolute;
  bottom: 8px;
  left: 8px;
  width: 24px;
  height: 24px;
  background-color: rgba(0, 0, 0, 0.6);
  padding: 4px;
  color: #fff; /* ← ini supaya bolt putih */
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px; /* sesuaikan agar ikon proporsional */
  line-height: 1;
  z-index: 1;
}

/* Judul Video */
.video-card .title {
  margin: 0.5rem;
  font-size: 0.9rem;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
  color: hsl(210deg 20% 98% / 80%);
}

/* Title */
.video-card .title {
  margin: 0.5rem;
  font-size: 1rem;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
  color: hsl(210deg 20% 98% / 80%);
}

/* Pagination Container */
.pagination-container {
  margin: 2rem auto;
  max-width: 900px;
  padding: 0 1rem;
}
.pagination-container nav {
  display: flex;
  justify-content: center;
}
.pagination-container ul.pagination {
  display: flex;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
  flex-wrap: wrap;
}
.pagination-container li .page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  border-radius: 6px;
  background: #26004d;
  color: #fff;
  text-decoration: none;
  font-size: 0.875rem;
  transition: background 0.2s;
}
.pagination-container li a.page-link:hover {
  background: rgba(29, 0, 71, 0.6);
}
.pagination-container li.active .page-link {
  background: transparent;
  border: 2px solid #7d00ff;
}
.pagination-container li.disabled .page-link {
  background: transparent;
  color: rgba(255, 255, 255, 0.6);
  cursor: default;
}

/* Footer */
.site-footer {
  background-color: #1a0037;
  color: #e2e8f0;
  padding: 3rem 0;
  font-size: 0.9rem;
}
.site-footer .container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1rem;
}
.footer-desc {
  line-height: 1.6;
  margin-bottom: 1.5rem;
}
.footer-links {
  list-style: disc inside;
  margin-bottom: 1.5rem;
  padding-left: 1rem;
}
.footer-links li {
  margin-bottom: 0.5rem;
}
.footer-copy {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1rem;
  font-size: 0.8rem;
  color: rgba(226, 232, 240, 0.7);
  text-align: center;
}

/* Hamburger Menu */
.hamburger {
  font-size: 24px;
  color: white;
  cursor: pointer;
  display: none;
}
@media (max-width: 768px) {
  .hamburger {
    display: block;
  }
  #nav {
    display: none;
    flex-direction: column;
    gap: 10px;
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    background-color: #1a0037;
    padding: 1rem;
  }
  #nav.active {
    display: flex;
  }
}
#ageVerification {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

#ageVerification .popup {
  background-color: #111;
  color: #fff;
  padding: 30px;
  max-width: 500px;
  text-align: center;
  border: 1px solid #333;
  box-shadow: 0 0 20px #000;
}

.popup .logo {
  font-size: 24px;
  margin-bottom: 10px;
}

.popup .logo span {
  background: #fff;
  color: #f90;
  padding: 2px 5px;
  font-weight: bold;
  border-radius: 3px;
}

.popup h1 {
  font-size: 20px;
  margin-bottom: 20px;
}

.popup p {
  font-size: 14px;
  margin-bottom: 20px;
}

.popup .btns {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-bottom: 20px;
}

.popup .btns button {
  padding: 10px 15px;
  font-size: 14px;
  font-weight: bold;
  border: none;
  cursor: pointer;
}

.popup .enter {
  background-color: #f90;
  color: #000;
}

.popup .exit {
  background-color: #333;
  color: #fff;
}

.popup .controls {
  font-size: 12px;
  color: #aaa;
}

.popup .controls a {
  color: #f90;
  text-decoration: none;
}

.popSc {
  position: fixed;
  z-index: 99981;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background-color: rgba(0, 0, 0, 0.5);
  /* set transparan gelap */
  display: flex;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(4px);
  /* efek blur di belakang popup */
}

.popSc.hidden {
  display: none;
}

.popBo {
  position: relative;
  background: #fff;
  max-width: 400px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  padding: 30px;
  border-radius: 30px;
}

.popBo svg {
  display: block;
  width: 50px;
  height: 50px;
  fill: none !important;
  stroke: #08102b;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.popBo h2 {
  margin: 10px 0 15px;
  font-size: 1.2rem;
  font-weight: 800;
  color: #08102b;
}

.popBo p {
  margin: 0;
  line-height: 1.7em;
  font-size: 0.9rem;
  color: #08102b;
}

.darkMode .popSc,
.darkMode .popBo .popBtn {
  background: #1f1f1f;
}

.darkMode .popBo {
  background: #2c2d31;
}

.darkMode .popBo svg {
  stroke: #fefefe;
}

.darkMode .popBo p,
.darkMode .popBo h2 {
  color: #fefefe;
}
