@font-face {
  font-family: 'noorehira';
  src: url('./fonts/noorehira.woff2') format('woff2'),
      url('./fonts/noorehira.woff') format('woff');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}
.quran-text-arabic {
  font-family: 'noorehira', 'KFGQPC Uthman Taha Naskh', serif;
  font-size: clamp(28px, 4vw, 36px);
  line-height: 1.9;
  white-space: pre-line;
  overflow-wrap: anywhere;
}
.quran-text-arabic--large {
  font-size: 25px;
  line-height: 65px;
}
.quran-surah-ayah--meta{
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
}

.quran-surah-ayah-play{
  margin-top: 0;
  cursor: pointer;
  width: 28px;
  height: 28px;
  opacity: 1;
  transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid #e6e7ea;
  border-radius: 50%;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.quran-surah-ayah-play:hover{
  background: rgba(10,125,56,0.06);
  border-color: #dfe3e8;
}

.quran-surah-ayah-play svg {
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}

/* Bookmark button styling */
.quran-surah-ayah-bookmark {
  cursor: pointer;
  width: 28px;
  height: 28px;
  color: #888;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid #e6e7ea;
  border-radius: 50%;
  background: #fff;
}
.quran-surah-ayah-bookmark:hover {
  color: #ffbf00;
  background: rgba(255,191,0,0.08);
  border-color: #e6cf8a;
}
.quran-surah-ayah-bookmark.active {
  color: #ffbf00;
  background: rgba(255,191,0,0.12);
  border-color: #e6cf8a;
}

/* Circular icon buttons feel */
.quran-surah-ayah-play,
.quran-surah-ayah-bookmark{
  border-radius: 50%;
}

.quran-surah-ayah-play:focus-visible,
.quran-surah-ayah-bookmark:focus-visible{
  outline: 2px solid #0a7d38;
  outline-offset: 2px;
}

.quran-surah-ayah-play:hover,
.quran-surah-ayah-bookmark:hover{
  background: rgba(10,125,56,0.08);
}

/* Ensure icons don't shrink */
.quran-surah-ayah--meta svg {
  width: 100%;
  height: 100%;
}

.ayah-svg{
  background-image: url('../images/bullet.svg');
  display: inline-block;
  width: 25px;
  height: 25px;
  background-size: cover;
  margin-left: 10px;
  vertical-align: top;
  margin-top: 30px;
}

.quran-audio-player{
  opacity: 0;
}
.quran-surah-name--wrapper{
  display: flex;
}
h2.quran-surah-name--arabic{
width: auto;
}
.dwl-surah-toggle {
  margin-right: auto;
  cursor: pointer;
  background: transparent;
  color: #000;
  border: none;
  font-size: 20px;
  outline: none;
  padding: 0;
  font-weight: bold;
}
.dwl-surah-toggle:hover,.dwl-surah-toggle:focus {
  outline: none;
  background: none;
  color: #000;
  opacity: 0.9;
}
.dwl-surah-toggle .quran-surah-name--english {
  margin-right: 5px;
}
.dwl-surah-toggle *{
  pointer-events: none;
}

.offacnvas-area {
  position: fixed;
  top: 0;
  left: -101%;
  background: rgba(0,0,0, 0.4);
  width: 100%;
  height: 100%;
  z-index: 99999;
  transition: all 0.1s ease;
}

.offacnvas-area.active-offcanvas{
  left: 0;
}

button.dwl-surah-offcanvas-close {
  border: 0 none;
  width: 25px;
  display: block;
  padding: 0;
  background: transparent;
  height: 24px;
  z-index: 99999;
  cursor: pointer;
  margin-right: auto;
  margin-bottom: 50px;
}

.dwl-surah-offcanvas-close *{
  pointer-events: none;
}

button.dwl-surah-offcanvas-close span {
  width: 100%;
  height: 2px;
  background: #000;
  transform: rotate(40deg);
  display: block;
  transform-origin: top;
}

button.dwl-surah-offcanvas-close span:last-child {
  transform: rotate(-42deg) translate(0px, -2px);
}

.dwl-quran-area .offcanvas-content-wrap {
  background: #fff;
  width: 320px;
  margin-right: auto;
  padding: 50px 20px;
  height: 100%;
  overflow: auto;
}


ul.dwl-surah-list {
  list-style: none;
  height: 100%;
  overflow-x: auto;
  margin: 0;
  padding: 0;
}

ul.dwl-surah-list button {
  padding: 14px 18px;
  background: transparent;
  border-radius: 12px;
  transition: background-color 0.2s ease, transform 0.2s ease;
  border: none;
  font-weight: 500;
  color: #000;
  margin: 0;
  cursor: pointer;
  display: flex;
  width: 100%;
  text-align: left;
  flex-direction: column;
  gap: 8px;
}
.dwl-surah-list .dwl-surah-name-btn.active,
.dwl-surah-list .dwl-surah-name-btn:hover {
  background-color: #f3f3f3;
}
.dwl-surah-list .dwl-surah-name-btn:focus {
  outline: 2px solid #0a7d38;
  outline-offset: 3px;
}
.dwl-surah-list .dwl-surah-name-btn *{
  pointer-events: none;
}
.dwl-surah-list .dwl-surah--number {
  font-family: 'noorehira', 'KFGQPC Uthman Taha Naskh', serif;
  font-size: 15px;
  font-weight: 600;
  background: #fff;
  color: #333;
  border-radius: 50%;
  border: 1px solid #ddd;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.dwl-surah--english-name {
  font-size: 18px;
  font-weight: 700;
  color: #111;
  margin: 0;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dwl-surah--translation {
  font-size: 12px;
  color: #666;
  text-transform: uppercase;
  margin: 0;
  line-height: 1.2;
}
.dwl-surah--arabic-name.quran-text-arabic {
  font-size: 21px;
  font-weight: 600;
  color: #0a7d38;
  line-height: 1.5;
  text-align: right;
  direction: rtl;
}

/* Surah listing */
.quran-surah-ayah--text {
    margin-top: 20px;
}
.dwl-quran-surah{
  display: none;
}
.dwl-quran-surah.active{
  display: block;
}
.quran-surah-ayah--number {
  font-family: 'noorehira', 'KFGQPC Uthman Taha Naskh', serif;
  font-size: 18px;
  font-weight: 600;
  line-height: 1;
  padding: 4px 10px;
  background: #f2f3f5;
  color: #333;
  border-radius: 999px;
  border: 1px solid #e6e7ea;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0 8px;
}
.quran-surah-ayah--wrapper {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 12px;
  padding: 18px 22px;
  margin-bottom: 16px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
  transition: box-shadow .2s ease, transform .2s ease;
}
.quran-surah-ayah--wrapper:hover{
  box-shadow: 0 6px 16px rgba(0,0,0,0.08);
  transform: translateY(-1px);
}
#quran-audio-player{
  opacity: 0;
}
.dwl-quran-single-surah-wrapper .dwl-surah-toggle span:last-child{

  display: none;

}

/* Single Ayah*/

.dwl-quran-ayah-wrapper .quran-surah-ayah--meta{
  justify-content: normal;
}
.dwl-quran-ayah-wrapper .quran-surah-ayah--meta .quran-surah-name--english,
.dwl-quran-ayah-wrapper .quran-surah-ayah--meta .quran-surah-ayah--number{
width: 50%;
}
.dwl-quran-ayah-wrapper .quran-surah-name--english{
  font-weight: bold;
}
.dwl-quran-ayah-wrapper .quran-surah-ayah--wrapper {
  padding: 15px 20px;
}

/* Translation line (non‑Arabic) */
.quran-surah-ayah--text:not(.quran-text-arabic) .quran-single-ayah{
  font-size: 16px;
  color: #444;
  line-height: 1.8;
}

/* Footer player bar polish */
#qita-player-bar{
  backdrop-filter: saturate(140%) blur(6px);
  border-top: 1px solid rgba(255,255,255,0.08);
}
#qita-player-bar button{
  border-radius: 6px;
}
#qita-player-bar #qita-seek{
  height: 4px;
}

@media (max-width: 600px) {
  .quran-surah-ayah--wrapper { padding: 14px 16px; }
  .quran-surah-ayah-play, .quran-surah-ayah-bookmark { width: 24px; height: 24px; }
  .quran-surah-ayah--number { font-size: 16px; padding: 3px 8px; }
  .quran-text-arabic { font-size: clamp(24px, 6vw, 34px); line-height: 1.8; }
}

/* Improved Surah list layout and alignment for Surah names */
.dwl-surah-row {
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 16px;
  width: 100%;
}

.dwl-surah--meta {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  gap: 4px;
  min-width: 0;
}