body {
  margin: 0;
  font-family: Arial, sans-serif;
  background-color: #111;
  color: #eee;
  padding-bottom: 200px;
}

header {
  background: linear-gradient(135deg, #000000 75%, #00afaf 75%);
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.menu-row {
  margin: 0px;
  display: flex;
  gap: 5px;
}

.header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.top-row {
  padding: 5px;
  border-radius: 5px;
}

.bottom-row {
  background-color: #00585b;
  border-bottom: solid #00afaf 4px;
  padding: 5px;
}

#logo-placeholder {
  height: 40px;
  color: #47e0ee;
  font-size: 30px;
  border-radius: 5px;
  padding-left: 5px;
  padding-right: 10px;
}

.satisfy-regular {
  font-family: "Satisfy", cursive;
  font-weight: bold;
  font-style: normal;
}

.channel {
  margin: 0;
  font-size: 14px;
  color: #eee;
  font-weight: bold;
  padding: 5px;
}

.search-container {
  display: flex;
  align-items: center;
  background-color: white;
  border-radius: 5px;
  border: white 1px solid;
}

#search {
  height: 25px;
  font-size: 16px;
  margin: 0px;
  padding: 5px;
  border-radius: 5px;
  border: none;
  min-width: 160px;
}

#home-button {
  background: #000000;
  border: rgb(255, 255, 255) solid 2px;
  height: 60px;
  width: 60px;
  color: #eee;
  padding: 10px;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.2s ease;
}

#home-button:hover {
  transform: scale(1.05);
  box-shadow: 0 0 8px #00ffff, 0 0 15px #ff00ff;
}

#menu-button {
  background: #000000;
  border: rgb(255, 255, 255) solid 2px;
  height: 60px;
  width: 60px;
  color: #eee;
  padding: 10px;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.2s ease;
}

#menu-button:hover {
  transform: scale(1.05);
  box-shadow: 0 0 8px #00ffff, 0 0 15px #ff00ff;
}

#player-button {
  background: #000000;
  border: rgb(255, 255, 255) solid 2px;
  height: 60px;
  width: 60px;
  color: #eee;
  padding: 10px;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.2s ease;
}

#player-button:hover {
  transform: scale(1.05);
  box-shadow: 0 0 8px #00ffff, 0 0 15px #ff00ff;
}

#filter-button {
  background: #000000;
  border: rgb(255, 255, 255) solid 2px;
  height: 60px;
  width: 60px;
  color: #eee;
  padding: 10px;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.2s ease;
}

#filter-button:hover {
  transform: scale(1.05);
  box-shadow: 0 0 8px #00ffff, 0 0 15px #ff00ff;
}

#filter-options {
  display: none;  
}

#filter-options.show {
  display: block;
  display: flex;
  gap: 5px;
}

#filter-options button {
  display: block;
  width: 100%;
  padding: 5px;
  background-color: #444444;
  color: #eee;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  text-align: left;
  transition: background 0.2s;
  font-size: 8px;
}

#filter-options button:hover {
  background-color: #888;
}

.hidden {
  display: none;
}

/* -------------------------- */

#home-page {
  display: none;
}

#menu-page {
  display: none;
}

/* -------------------------- */

#video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
  gap: 5px;
  padding: 10px;
  padding-top: 20px;
}

.video-card {
  background: linear-gradient(135deg, #272727 15%, #1d1d1d 15%, #181818 90%, #272727 90%);
  background-blend-mode: overlay;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s;
  display: flex;
  flex-direction: column;
  align-items: start;
  padding: 8px;
}

.video-card:hover {
  transform: scale(1.03);
}

.video-card img {
  width: 100%;
  height: auto;
  max-height: 70px;
  object-fit: cover;
  border-radius: 5px;
}

.video-card h3 {
  font-size: 0.75rem;
  margin: 0px 0 0 0;
  display: -webkit-box;
  -webkit-line-clamp: 2; /* 📌 Limit to 2 lines */
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 2.3em;
}

.video-meta {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.video-channel {
  font-size: 0.7rem;
  color: #aaa;
  margin-top: 5px;
}


/* Greenish color */
.current-video {
  background: linear-gradient(135deg, #848809 15%, #476500 15%, #656200 90%, #848809 90%);
  background-blend-mode: overlay;
}

/* Purplish color */
.error-video {
  background: linear-gradient(135deg, #6c0081 15%, #33003d 15%, #210059 90%, #6c0081 90%);
  background-blend-mode: overlay;
}

/* Greenish color */
.played-video {
  background: linear-gradient(135deg, #15827a 15%, #00534c 15%, #004b53 90%, #15827a 90%);
  background-blend-mode: overlay;
}

/* Orangeish color */
.loop-video {
  background: linear-gradient(135deg, #e95d00 15%, #b14700 15%, #b13800 90%, #e95d00 90%);
  background-blend-mode: overlay;
}

/* !!!!!!!!!!!!!!!!!!!!!!!!!! */
/* !!!!!!!!!!!!!!!!!!!!!!!!!! */
/* !!!!!!!!!!!!!!!!!!!!!!!!!! */

@media (max-width: 450px) {
  #video-grid {
    display: flex;
    flex-direction: column;
    padding: 10px;
    padding-top: 20px;
    gap: 5px;
  }

  .video-card {
    flex-direction: row;
    padding: 7px;
    background: linear-gradient(135deg, #272727 14%, #1d1d1d 14%, #181818 95%, #272727 95%);
    background-blend-mode: overlay;
    border-radius: 8px;
  }

  .video-card img {
    width: 40px;
    height: 40px;
    object-fit: cover;
    margin-right: 5px;
    border-radius: 5px;
  }

  .video-card h3 {
    font-size: 0.8rem;
    text-align: left;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* 📌 Limit to 2 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 2.3em;
  }

  .video-channel {
    font-size: 0.7rem;
    color: #aaa;
    margin-top: 0px;
  }

    #search {
      padding: 5px;
      font-size: 1rem;
      border-radius: 5px;
      border: none;
      max-width: 160px;
    }

  /* Red color */
  .error-video {
    background: linear-gradient(135deg, #6c0081 14%, #33003d 14%, #210059 95%, #6c0081 95%);
    background-blend-mode: overlay;
  }

  /* Yellowish color */
  .current-video {
    background: linear-gradient(135deg, #848809 14%, #476500 14%, #656200 95%, #848809 95%);
    background-blend-mode: overlay;
  }

  /* Greenish color */
  .played-video {
    background: linear-gradient(135deg, #15827a 14%, #00534c 14%, #004b53 95%, #15827a 95%);
    background-blend-mode: overlay;
  }

  /* Orangeish color */
  .loop-video {
    background: linear-gradient(135deg, #e95d00 14%, #b14700 14%, #b13800 95%, #e95d00 95%);
    background-blend-mode: overlay;
  }

}

/* !!!!!!!!!!!!!!!!!!!!!!!!!! */
/* !!!!!!!!!!!!!!!!!!!!!!!!!! */
/* !!!!!!!!!!!!!!!!!!!!!!!!!! */

#player-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  background: #000000;
  padding-top: 10px;
  padding-bottom: 10px;
  display: flex;
  flex-direction: column;
  /* align-items: center; */
  gap: 10px;
  z-index: 1000;
}

#player-bar-column-1 {
  background-color: none;
  padding-bottom: 5px;
}

#player-bar-column-2 {
  background-color: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0px;
}

/* -------------------------- */

#progress-line {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 10px;
}

#time-start, #time-end {
  font-size: 0.9rem;
  color: #ccc;
  width: 40px;
  text-align: center;
}

#progress-container {
  flex-grow: 1;
  height: 12px;
  background: #444;
  position: relative;
  border-radius: 5px;
  cursor: pointer;
}

#progress-bar {
  height: 100%;
  width: 0%;
  border-radius: 5px;
  background: linear-gradient(90deg, #6c0081, #07bcb0);
}

#progress-thumb {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  background: #ffffff;
  border-radius: 3px;
  margin-left: -7px;
  pointer-events: none;
}

/* ========================== */

#player-controls-row {
  display: flex;
  align-items: center;
  padding: 0px;
  padding-bottom: 10px;
  padding-left: 10px;
  min-width: 250px;
}

/* -------------------------- */

#loading-spinner {
  font-size: 1rem;
  color: #00ffff;
  animation: pulse 1s infinite;
  width: 80px;
  height: 40px;
  text-align: center;
  display: flex;
  justify-content: center;
  flex-direction: column;
  padding-left: 5px;
}

@keyframes pulse {
  0% { opacity: 0.2; }
  50% { opacity: 1; }
  100% { opacity: 0.2; }
}

#spinner-text {
  font-size: 1rem;
}

/* -------------------------- */

#waveform-container {
  display: none;
  width: 80px;
  height: 40px;
  background: transparent;
  gap: 2px;
  overflow: hidden;
  padding-left: 5px;
  flex-direction: row;
  justify-content: center;
  align-items: center;
}

.waveform-bar {
  width: 7px;
  height: 30px;
  background-color: #00ffee;
  animation: bounce 1s infinite ease-in-out;
  border-radius: 2px;
}

.waveform-bar:nth-child(1) { animation-delay: 0s; }
.waveform-bar:nth-child(2) { animation-delay: 0.1s; }
.waveform-bar:nth-child(3) { animation-delay: 0.2s; }
.waveform-bar:nth-child(4) { animation-delay: 0.3s; }
.waveform-bar:nth-child(5) { animation-delay: 0.4s; }
.waveform-bar:nth-child(6) { animation-delay: 0.5s; }
.waveform-bar:nth-child(7) { animation-delay: 0.6s; }
.waveform-bar:nth-child(8) { animation-delay: 0.7s; }

@keyframes bounce {
  0%, 100% {
    transform: scaleY(0.5);
  }
  50% {
    transform: scaleY(1);
  }
}

/* -------------------------- */

#controls-buttons {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 5px;
}

#controls-buttons button {
  border: none;
  padding: 8px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: background 0.2s ease;
}

/* Play Button */
.play-button {
  background: #00948a;
  color: #eee;
  height: 75px;
  width: 75px;
}
.play-button:hover {
  background: #00b7a0;
}

/* Prev Button */
.prev-button {
  background: #555;
  color: #eee;
  height: 40px;
  width: 40px;
}
.prev-button:hover {
  background: #777;
}

/* Next Button */
.next-button {
  background: #555;
  color: #eee;
  height: 40px;
  width: 40px;
}
.next-button:hover {
  background: #777;
}

/* Base loop button style */
.loop-button {
  background: #555;
  color: #eee;
  height: 60px;
  width: 60px;
  transition: background 0.2s ease;
}

/* Hover when NOT active */
.loop-button:hover {
  background: #ff7c1a;
}

/* Active loop style */
.loop-button.active-loop {
  background: #e95d00; /* Bright orange when looping */
}

/* Hover when ACTIVE */
.loop-button.active-loop:hover {
  background: #ff7c1a; /* Lighter orange hover */
}


.shuffle-button {
  background: #555;
  color: #eee;
  height: 50px;
  width: 50px;
  border: none;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: background 0.2s ease;
}

.shuffle-button:hover {
  background: #00a9cb;
}

.shuffle-button.active-shuffle {
  background: #014f5e;
}

.shuffle-button.active-shuffle:hover {
  background: #00a9cb;
}


/* ========================== */

#player-info-row {
  padding: 0px;
  padding-bottom: 10px;
  padding-left: 10px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 10px;
  /* background-color: purple; */
}

/* -------------------------- */

#player-thumbnail {
  width: 40px;
  height: 40px;
  object-fit: cover;
  border-radius: 5px;
  border: solid 1px black;
  display: flex;
  justify-content: center;
  align-items: center;
  background: #222; /* fallback background */
  overflow: hidden;
  font-size: 0.7rem;
  color: #ccc;
  text-align: center;
}
#player-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 5px;
}

/* -------------------------- */

#channel-name, #player-title {
  font-size: 1rem;
  color: #ccc;
  text-align: left;
  margin: 0px;
  padding: 0px;
}


/* !!!!!!!!!!!!!!!!!!!!!!!!!! */
/* ========================== */
/* -------------------------- */


.home-section, .menu-section {
  background: #1a1a1a;
  border: 1px solid #333;
  padding: 10px;
}

.placeholder-list {
  list-style: none;
  padding-left: 0;
  margin: 0px;
}

.placeholder-list li {
  padding: 10px 5px 10px 5px;
  border-bottom: 1px solid #333;
  color: #ddd;
  font-size: 18px;
}

.placeholder-list li:last-child {
  border-bottom: none;
}

.channel-button {
  width: 100%;
  padding: 10px;
  background-color: #333;
  color: #eee;
  border: 1px solid #555;
  border-radius: 5px;
  text-align: left;
  cursor: pointer;
  transition: background 0.2s ease;
  font-size: 1rem;
}

.channel-button:hover {
  background-color: #444;
}

/* ========================== */

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  margin-top: 10px;
  margin-bottom: 10px;
}

.feature-card {
  background: linear-gradient(135deg, #1d1d1d, #111);
  border: 1px solid #333;
  border-radius: 8px;
  color: #eee;
  aspect-ratio: 1 / 1; /* 🟩 SQUARE */
  padding: 10px;
  font-size: .9rem;
  font-weight: bold;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.1);
  transition: transform 0.2s, box-shadow 0.2s;
  cursor: pointer;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.feature-card:hover {
  transform: scale(1.05);
  background: linear-gradient(135deg, #a90000, #d12a00, #ff5500, #ff4e02, #eb3507, #b90000);
  background-size: 300% 300%;
  animation: flame-gradient 2s linear infinite, flame-border 0.4s ease-in-out infinite;
  border: 2px solid transparent;
  box-shadow:
    0 0 10px rgba(255, 80, 0, 0.6),
    0 0 20px rgba(255, 40, 0, 0.5),
    0 0 30px rgba(255, 0, 0, 0.4),
    inset 0 0 10px rgba(255, 100, 0, 0.5);
}

@keyframes flame-gradient {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes flame-border {
  0%, 100% { border-width: 2px; }
  50% { border-width: 3px; }
}

.feature-card:hover {
  animation: flame-gradient 2s linear infinite, flame-border 0.4s ease-in-out infinite;
}

.feature-card::after {
  content: '🔥';
  position: absolute;
  top: 8px;
  left: 12px;
  font-size: 1.2rem;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.feature-card:hover::after {
  opacity: 1;
}

.feature-card-title {
  font-size: .9rem;
  font-weight: bold;
  color: #fff;
  text-align: center;
  margin-bottom: 5px;
}

.feature-card-subtitle {
  font-size: 0.7rem;
  color: #b4f7ff;
  text-align: center;
}




/* !!!!!!!!!!!!!!!!!!!!!!!!!! */
/* ========================== */
/* -------------------------- */