/* CENTRAL DESIGN */

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f5f5f5;
  display: flex;
  justify-content: center;
  padding: 20px;
  min-height: 100vh;
}

@font-face {
    font-family: "Noto Sans Arabic";
    src: url("fonts/NotoSansArabic-SemiBold.ttf") format("truetype");
}

.container {
  max-width: 600px;
  width: 100%;
  background: white;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  gap: 30px;
}

/* Title */
h1 {
  text-align: center;
  margin: 0;
  font-size: 2em;
}

/* Big buttons container */
.big-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
}

/* Small buttons container */
.small-buttons {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
  justify-content: start;
}

/* Big buttons */
.big-button {
  flex: 1 1 45%;
  aspect-ratio: 1 / 1; /* Square */
  font-size: 1.6rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #4CAF50;
  color: white;
  border: none;
  border-radius: 16px;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.3s ease;
}

.big-button .emoji {
  font-size: 3.5rem;
}

.big-button .label {
  font-weight: bold;
}

/* Small buttons */
.small-button {
  background: #eee;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  user-select: none;
  padding: 12px 0;
  font-size: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: background-color 0.3s ease;
  position: relative;
}

.top-icons {
  position: absolute;
  top: 4px;
  left: 4px;
  display: flex;
  gap: 2px;
}

.os-icon {
  width: 24px;   /* good default size */
  height: 24px;
  object-fit: contain;
}

/* On small mobile screens */
@media (max-width: 600px) {
  .os-icon {
    width: 16px;
    height: 16px;
  }
}


.small-button:hover .os-icon {
  transform: scale(1.1);
  transition: transform 0.2s;
}

.small-button .emoji {
  font-size: 2rem;
}

.small-button .label {
  font-weight: normal;
  color: #333;
}

.locked {
  background: repeating-linear-gradient(
    45deg,
    #ccc,
    #ccc 10px,
    #bbb 10px,
    #bbb 20px
  );
  color: #777;
  position: relative;
}

.locked::after {
  content: "🔒";
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 1.2rem;
  opacity: 0.8;
}

/* Hover effects */
.big-button:hover {
  background: #45a049;
}

.small-button:hover {
  background: #ddd;
}

/* Responsive for mobile */
@media (max-width: 600px) {
  .big-buttons {
    flex-direction: column;
    gap: 20px;
  }
  .big-button {
    flex: none;
    width: 100%;
  }

  .small-buttons {
    grid-template-columns: 1fr;
    gap: 15px;
  }
}
/* ==================================================== */
/* ALERTS */

.alert-popup {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  min-width: 200px;
  max-width: 80%;
  padding: 15px 25px;
  color: white;
  font-weight: bold;
  border-radius: 12px;
  text-align: center;
  font-size: 1.1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  z-index: 9999;
  box-shadow: 0 0 15px rgba(0,0,0,0.3);
}

.alert-popup.show {
  opacity: 1;
  pointer-events: auto;
}

.alert-popup.success {
  background-color: #4CAF50; /* green */
}

.alert-popup.error {
  background-color: #f44336; /* red */
}

/* ======================================================= */
/* QURAN AND SURAHS */
.surah-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr; /* default 1 column for mobile */
}

@media (min-width: 600px) {
  .surah-grid {
    grid-template-columns: repeat(3, 1fr); /* 3 columns tablets and up */
  }
}

/* Surah card */
.surah-card {
  background: #fff;
  border-radius: 12px;
  padding: 15px 20px;
  box-shadow: 0 0 8px rgba(0,0,0,0.08);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: box-shadow 0.3s, transform 0.2s;
  user-select: none;
}

.surah-card:hover {
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
  transform: scale(1.02);
}

.surah-card.incomplete {
  opacity: 0.6;
  filter: grayscale(50%);
  /* pointer-events: none;  <-- REMOVE or comment out */
  position: relative;
  cursor: pointer; /* Keep the pointer cursor */
}

.surah-card.incomplete::after {
  content: "НЕ ЗАВЕРШАНА";
  position: absolute;
  bottom: -8px;
  right: -8px;
  background: #f44336;
  color: white;
  padding: 3px 8px;
  font-size: 0.75em;
  border-radius: 8px;
  font-weight: bold;
  user-select: none;
  z-index: 5;
  box-shadow: 0 2px 5px rgba(0,0,0,0.3);
}



/* Top row: surah name and number */
.top-row {
  display: flex;
  justify-content: space-between;
  font-weight: bold;
  font-size: 1.1em;
  margin-bottom: 10px;
}

/* Divider */
.divider {
  border-top: 1px solid #ddd;
  margin-bottom: 10px;
}

/* Bottom row: READ and type */
.bottom-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-style: italic;
  color: #444;
  font-size: 0.9em;
}

/* READ badge */
.read-badge {
  background-color: #4CAF50;
  color: white;
  padding: 4px 10px;
  border-radius: 8px;
  font-weight: bold;
  font-size: 0.85em;
  white-space: nowrap;
}

    .home-button {
      margin-bottom: 20px;
      background: #4CAF50;
      color: white;
      border: none;
      padding: 10px 16px;
      font-size: 1.1em;
      border-radius: 12px;
      cursor: pointer;
      user-select: none;
      align-self: flex-start;
    }
    .home-button:hover {
      background: #45a049;
    }
    .home-button:active {
      background: #3e8e41;
    }