:root {
  text-align: -webkit-center;
  background-color: #42434b;
}

[data-tooltip] {
  position: relative;
  cursor: pointer;
}

/* Tooltip content */
[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  top: 120%;
  left: 50%;
  transform: translateX(-50%);
  background: #222;
  color: white;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.75em;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 200;
  font-family: "Almarai", sans-serif;
}

/* Show on hover/focus */
[data-tooltip]:hover::after {
  opacity: 1;
  transform: translateX(-50%) translateY(-4px);
}

[data-tooltip-2] {
  position: relative;
  cursor: pointer;
}

/* Tooltip content */
[data-tooltip-2]::after {
  content: attr(data-tooltip-2);
  position: absolute;
  top: -65%;
  left: 50%;
  transform: translateX(-50%);
  background: #222;
  color: white;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.75em;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 200;
  font-family: "Almarai", sans-serif;
}

/* Show on hover/focus */
[data-tooltip-2]:hover::after {
  opacity: 1;
  transform: translateX(-50%) translateY(-4px);
}

.save-btn {
  margin-top: 5px;
  padding: 4px 10px;
  border: none;
  border-radius: 6px;
  background: #eee;
  font-size: 0.8em;
  cursor: pointer;
  color: #333;
  transition: background 0.2s;
}
.save-btn:hover {
  background: #f19b1a;
  color: white;
}

.save-btn:hover .star-icon {
  stroke: white; /* works if the SVG paths use stroke */
}

.verse-box {
  display: flex;
  gap: 10px;
  align-items: center; /* ✅ Align top of lines */
  justify-content: flex-end;
  border-radius: 6px;
  transition: background 0.2s;
  text-align: right;
  direction: rtl;
  padding: 10px;
  margin: 8px 0;
  background: #33343c;
  font-family: "Almarai", sans-serif;
  flex-wrap: nowrap; /* ✅ Prevent wrapping between prefix and text */
}

.verse-prefix {
  font-weight: bold;
  width: 24px;
  text-align: center;
  color: #999;
  flex-shrink: 0; /* ✅ Prevent shrinking on long lines */
}

.verse-box.chorus .verse-prefix {
  color: #f19b1a;
}

.verse-box:hover {
  background: #42434b;
}

.verse-box.selected {
  background: #42434b;
  border: 0px solid #ffcc5b;
}

.verse-content {
  flex: 1;
  line-height: 1.8;
  word-break: break-word; /* ✅ Proper wrap on long text */
  text-align: right;
}

#dropdown li.no-results {
  text-align: center;
  color: #999;
  background-color: #24252b;
  padding: 10px;
  cursor: default;
  pointer-events: none;
}

.tagtab {
  border-radius: 50px;
  background-color: #35363e;
  color: white;
  border: 0px solid #78797f;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: "Almarai", sans-serif;
  cursor: pointer;
}

.inner-tag {
  border-radius: 50px;
  background-color: #35363e;
  color: white;
  border: 0px solid #78797f;
  margin: 6px 0px 0px 6px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  font-family: "Almarai", sans-serif;
  cursor: pointer;
}
.main-container {
  text-align: -webkit-right;
  background-color: #2b2c33;
  padding: 12px;
  border-radius: 25px;
  justify-items: right;
}
#fullscreen {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 2em;
}

.fullscreen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  color: #ffffff;
  font-size: 2em;
  font-family: "Almarai", sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 5000;
}

body {
  max-width: 800px;
  font-family: "Almarai", sans-serif;
  margin: 0;
  padding: 10px;
  text-align: center;
}

#logo {
  z-index: 0;
  margin-bottom: 20px;
  color: #ff4d4f;
  font-size: 2em;
  font-weight: bold;
  height: 30vh;
  max-width: 400px;
  object-fit: contain;
  object-position: center bottom;
  padding-bottom: 20px;
  align-content: center;
}

.hide-logo {
  animation: hideLogo 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.show-logo {
  animation: showLogo 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes hideLogo {
  0% {
    opacity: 1;
    transform: translateY(0px) scale(1);
    height: 30vh;
  }
  100% {
    opacity: 0;
    transform: translateY(-50px) scale(0.5);
    height: 25px;
  }
}

@keyframes showLogo {
  0% {
    opacity: 0;
    transform: translateY(-50px) scale(0.5);
    height: 0px;
  }
  100% {
    opacity: 1;
    transform: translateY(0px) scale(1);
    height: 30vh;
  }
}

.search-container {
  position: relative;
  align-items: center;
  width: 100%;
  background-color: #42434b;
  border: 1px solid #78797f;
  border-radius: 12px;
  margin-bottom: -4px;
}

.search-icon {
  position: absolute;
  right: 5px;
  height: 24px;
  width: 24px;
  padding-right: 10px;
  color: white;
  align-self: anchor-center;
}

#searchBox {
  font-family: "Almarai", sans-serif;
  inline-size: -webkit-fill-available;
  line-height: 1.5;
  padding: 10px 52px 10px 6px;
  font-size: 16px;
  height: 24px;
  border-radius: 12px;
  background-color: #42434b;
  border: 0px solid #78797f;
  color: white;
  text-align: right;
  direction: rtl;
}

#dropdown {
  list-style: none;
  margin: 0;
  padding: 0;
  position: absolute;
  width: 100%;
  max-height: 350px;
  overflow-y: auto;
  z-index: 1000;
  text-align: right;
  background: #24252b;
  border-radius: 20px;
  margin-top: 20px;
  padding: 14px 0px;
}

#dropdown li {
  padding: 8px 10px;
  cursor: pointer;
  transition: background 0.2s;
  background: #33343c;
  margin: 6px 20px;
  border-radius: 10px;
}

#dropdown li.active,
#dropdown li:hover {
  background: #42434b;
}

#dropdown li .title {
  font-weight: bold;
  color: white;
}

#dropdown li .line {
  font-size: 0.9em;
  color: #a0a1a5;
}

#dropdown::-webkit-scrollbar {
  width: 14px;
}

#dropdown::-webkit-scrollbar-thumb {
  background-color: rgb(66, 67, 75);
  border-radius: 10px;
  border-width: 4px;
  border-style: solid;
  border-color: #24252b;
  border-image: initial;
}

#dropdown::-webkit-scrollbar-track {
  margin-top: 10px;
  margin-bottom: 10px;
  background: transparent;
}

mark {
  background: yellow;
}

#songContainer {
  margin-top: 20px;
  display: inline-block;
  inline-size: -webkit-fill-available;
  text-align: right;
  border: 0px solid #ccc;
  background: #2b2c33;
  padding: 0px 1px 15px 15px;
  border-radius: 25px;
  color: white;
  max-height: calc(100vh - 350px);
  
  overflow-y: scroll;
  font-size: 0.9em;
  font-weight: bold;
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  opacity: 1;
  transform: scale(1);
  border-bottom: 10px solid #2b2c33;
  min-width: -moz-available;

}

/* Chrome, Edge, Safari */
#songContainer::-webkit-scrollbar {
  width: 14px;
}

#songContainer::-webkit-scrollbar-track {
  background: transparent;
  margin-top: 30px;
  margin-bottom: 30px;
}

#songContainer::-webkit-scrollbar-thumb {
  background-color: #42434b;
  border-radius: 10px;
  border: 4px solid #2b2c33;
}

.hidden {
  opacity: 0 !important;
  transform: scale(1.1) !important;
  pointer-events: none !important;
}

.full-hidden {
  opacity: 0 !important;
  transform: scale(1.1) !important;
  pointer-events: none !important;
  display: none !important;
}

.song-header {
  flex-direction: row-reverse;
  justify-content: space-between;
  display: flex;
  align-items: center;
  position: sticky;
  top: 0;
  padding-top: 20px;
  padding-bottom: 10px;
  background-color: #2b2c33; /* optional: prevent content underlapping */
  z-index: 20; /* optional: ensure it stays on top */
}

#closeBtn {
  background-color: #2b2c33;
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 1em;
  cursor: pointer;
  width: fit-content;

  margin-left: 5px;
}

#fullscreen-content {
  align-items: center;
  justify-content: center;

  direction: rtl;

  width: 100%;
}

.save-btn {
  background: none;
  padding: 0px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.2s ease;
  height: 40px;
  width: 40px;
  border-radius: 40px;
  background-color: #52535c;
}

.save-btn .star-icon {
  width: 16px;
  height: 16;
  stroke: rgb(160, 161, 165);
  fill: none;
  transition: fill 0.2s ease;
}

.save-btn.active {
  background-color: #f19b1a;
}

.save-btn.active .star-icon {
  fill: white;
  stroke: white;
}

.app-loading {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgb(66, 67, 75);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  color: white;
  font-size: 16px;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.app-loading.fade-out {
  opacity: 0;
  transform: translateY(-20px);
}

.app-loading.hidden {
  display: none;
}

.css-loader {
  width: 60px;
  height: 60px;
  border: 4px solid rgba(255, 255, 255, 0.2);
  border-top: 4px solid #fff;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 20px;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.loading-text {
  margin-top: 10px;
}
#songheader-controls {
  min-width: fit-content;
}
#songPlayer {
  max-width: 450px !important;
  width: 100%;
  max-width: 600px;
  min-width: 300px;
  border-radius: 10px;
  background-color: #d4d3cc;
  color: white;
  padding: 5px;
  box-sizing: border-box;
  filter: invert(1);
}

/* 🎚 شريط التحكم */
#songPlayer::-webkit-media-controls-panel {
  background-color: #bdbcb4;
}

/* ▶️ زرار التشغيل */
#songPlayer::-webkit-media-controls-play-button {
  background-color: #bdbcb4;
  border-radius: 50%;
}

/* 🔊 أيقونة الصوت */
#songPlayer::-webkit-media-controls-mute-button {
  background-color: #b1b0a7;
  border-radius: 50%;
}

/* ⏱ شريط التقدم */
#songPlayer::-webkit-media-controls-timeline {
  background-color: #bdbcb4;
  border-radius: 5px;
}

/* 🔊 شريط الصوت */
#songPlayer::-webkit-media-controls-volume-slider {
  background-color: #b1b0a7;
  border-radius: 5px;
}

/* ⏱ الوقت */
#songPlayer::-webkit-media-controls-current-time-display,
#songPlayer::-webkit-media-controls-time-remaining-display {
  color: white;
  filter: invert(1);
}

.masses-controls {
  display: flex;
  flex-direction: row-reverse;
  gap: 4px; /* مسافة بين كل زرار */
  flex-wrap: wrap; /* لو الشاشة ضيقة يتكسر للسطر التالي */
  align-items: center;
  background-color: rgb(43, 44, 51);
  padding: 8px 0px;
  border-radius: 12px;
}

.masses-controls label {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 6px;
  background-color: #35363e;
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  cursor: pointer;
  font-family: "Almarai", sans-serif;
  user-select: none;
  transition: all 0.3s ease;
}

/* Hover effect */
.masses-controls label:hover {
  background-color: #35363e;
}

.masses-controls input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 18px;
  height: 18px;
  border: 2px solid white;
  border-radius: 4px;
  position: relative;
  cursor: pointer;
  background-color: transparent; /* default empty */
  transition: all 0.2s;
}

/* Checked state */
.masses-controls input[type="checkbox"]:checked {
  background-color: #f19b1a;
  border-color: #f19b1a;
}

/* Optional: add check mark */
.masses-controls input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 6px;
  width: 3px;
  height: 8px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  margin-bottom: 10px;
}

.font-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #42434b;
  border-radius: 50px;
  width: 45px;
  height: 45px;
  min-width: 45px;
  min-height: 45px;
  max-width: 45px;
  max-height: 45px;
  cursor: pointer;
  transition: none;
  border: 2px solid #42434b;
  padding: 10px;
}

.font-btn:hover {
  background-color: #4d4e57;
  border: 2px solid #4d4e57;
}

.font-btn svg {
  pointer-events: none;
}

#left-controls {
  display: flex;
  flex-direction: row;
  width: fit-content;
  min-width: fit-content;
  gap: 5px;
  align-items: center;
}

/* Hide PWA standalone mode title bar icons */
@media (display-mode: standalone) {
  /* Hide the entire title bar area */
  body {
    padding-top: 0 !important;
    margin-top: 0 !important;
  }

  /* If there's a specific container for these icons */
  .pwa-title-bar,
  .standalone-header,
  .app-header {
    display: none !important;
  }
}

.row {
  display: flex;
  gap: 1rem; /* مسافة بين الاتنين */
  margin-bottom: 0.75rem;
}
.row label {
  flex: 1; /* كل label ياخد نص العرض */
  display: flex;
  flex-direction: column;
  font-size: 14px;
  gap: 5px;
  font-weight: normal;
}
.row input,
.row select {
  margin-top: 0.25rem;
}

label.number-drag {
  cursor: default;
  user-select: none;
}

label.number-drag:hover {
  cursor: ew-resize; /* horizontal arrows */
}
#songVerses {
  direction: rtl;
  border-top: 1px solid #42434b;
}



