/*
 Theme Name: Quran The Right Way
 Description: Custom styles and advanced functionality for the Quran The Right Way architecture.
 Template: generatepress
 Version: 1.0.0
*/

:root {
  --quran-emerald: #175946;
  --quran-emerald-light: #f0f9f6;
  --quran-gold: #be9b30;
  --cream-bg: #fffcf5;
}

/* Custom Utilities for those who prefer CSS over Tailwind classes in editor */
.bg-cream-50 {
  background-color: var(--cream-bg) !important;
}
.text-quran-emerald-900 {
  color: #0d362a !important;
}
.text-quran-emerald-800 {
  color: #124738 !important;
}
.text-quran-gold {
  color: var(--quran-gold) !important;
}
.bg-quran-emerald-100 {
  background-color: #e1edea !important;
}

/* Premium Card Styles */
.quran-card {
  transition: all 0.3s ease;
}
.quran-card:hover {
  transform: translateY(-5px);
  box-shadow:
    0 20px 25px -5px rgba(0, 0, 0, 0.1),
    0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Material Symbols alignment */
.material-symbols-outlined {
  vertical-align: middle;
  line-height: 1;
}

/* Responsive Buttons */
.wp-element-button {
  transition: all 0.2s ease-in-out;
}
.wp-element-button:hover {
  opacity: 0.9;
  transform: scale(1.02);
}

/* ==========================================================
   CONTACT FORM 7 (CF7) PREMIUM STYLING ENGINE OVERRIDE
========================================================== */

/* Structure & Typography */
.wpcf7-form {
  background-color: transparent;
  max-width: 100%;
}
.wpcf7-form p {
  margin-bottom: 1.5rem;
  color: #4b5563; /* text-gray-600 */
  font-weight: 700;
}

/* Base Form Inputs (Texts, Emails, Numbers, Textareas, Selects) */
.wpcf7-form-control.wpcf7-text,
.wpcf7-form-control.wpcf7-number,
.wpcf7-form-control.wpcf7-select,
.wpcf7-form-control.wpcf7-textarea {
  width: 100%;
  background-color: #ffffff;
  color: #08211a;
  padding: 1rem 1.5rem;
  border-radius: 1.2rem;
  border: 2px solid #e1edea; /* quran-emerald-100 */
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: inset 0 2px 4px 0 rgba(0, 0, 0, 0.02);
  font-weight: 600;
  font-size: 1rem;
}

.wpcf7-form-control::placeholder {
  color: #9ca3af;
  font-weight: 500;
}

/* Golden Focus States */
.wpcf7-form-control:focus {
  outline: none !important;
  border-color: var(--quran-gold);
  box-shadow: 0 0 0 5px rgba(190, 155, 48, 0.15);
}

/* Custom Select Dropdown Chevron */
.wpcf7-form-control.wpcf7-select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 1.5rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-right: 3.5rem;
  cursor: pointer;
}

/* Interactive Radio Buttons */
.wpcf7-list-item {
  display: inline-flex;
  align-items: center;
  margin-right: 2rem;
}
.wpcf7-list-item input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  width: 1.7rem;
  height: 1.7rem;
  border: 2px solid #d1d5db;
  background-color: white;
  border-radius: 50%;
  margin-right: 0.75rem;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  vertical-align: middle;
}
.wpcf7-list-item input[type="radio"]:checked {
  border-width: 7px;
  border-color: var(--quran-gold);
  box-shadow: 0 0 0 4px rgba(190, 155, 48, 0.15);
}

/* Master Submission CTA Button */
.wpcf7-form-control.wpcf7-submit {
  width: 100%;
  background-color: var(--quran-gold) !important;
  color: #08211a !important;
  font-weight: 900 !important;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  padding: 1.5rem 2rem !important;
  border-radius: 1.2rem !important;
  border: none !important;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  box-shadow: 0 10px 30px -10px rgba(190, 155, 48, 0.5) !important;
  margin-top: 1rem;
}

.wpcf7-form-control.wpcf7-submit:hover {
  background-color: #e1bc40 !important;
  transform: translateY(-3px) scale(1.02) !important;
  box-shadow: 0 15px 40px -5px rgba(190, 155, 48, 0.6) !important;
}

/* Form Validation Architecture */
.wpcf7-not-valid-tip {
  color: #ef4444 !important;
  font-size: 0.85rem;
  margin-top: 0.5rem;
  font-weight: 800;
}
.wpcf7-response-output {
  border-radius: 1.2rem !important;
  padding: 1.25rem 2rem !important;
  border-width: 2px !important;
  font-weight: 700 !important;
  margin-top: 2rem !important;
}

.page-id-31 .wpcf7-form label {
  color: var(--cream-bg) !important;
}

.home .wpcf7 form.sent .wpcf7-response-output {
  color: #fff !important;
}

/* ==========================================================
   MOBILE COMPACT MODE: SPACING & TYPOGRAPHY OPTIMIZATION
   Aggressively reduces padding, margins, and gaps on mobile
   to create a more space-efficient and reachable UI.
========================================================== */
@media (max-width: 768px) {
  /* Global Section Padding Compression */
  .py-32,
  .py-28 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
  .py-24,
  .py-20 {
    padding-top: 2.25rem !important;
    padding-bottom: 2.25rem !important;
  }
  .py-16,
  .py-12 {
    padding-top: 1.75rem !important;
    padding-bottom: 1.75rem !important;
  }

  /* Container & Column Padding Compression */
  .p-16,
  .p-12,
  .p-10 {
    padding: 1.25rem !important;
  }
  .px-16,
  .px-12,
  .px-10 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  .rounded-\[3rem\],
  .rounded-\[4rem\] {
    border-radius: 1.5rem !important;
  }

  /* Gaps & Item Spacing */
  .gap-16,
  .gap-12 {
    gap: 1.5rem !important;
  }
  .gap-10,
  .gap-8 {
    gap: 1rem !important;
  }
  .space-y-12,
  .space-y-10 {
    margin-top: 1.5rem !important;
  }
  .space-y-8,
  .space-y-6 {
    margin-top: 1rem !important;
  }

  /* Typography Compactness */
  h1 {
    font-size: 2.1rem !important;
    line-height: 1.2 !important;
    margin-bottom: 1rem !important;
  }
  h2 {
    font-size: 1.6rem !important;
    line-height: 1.2 !important;
    margin-bottom: 0.75rem !important;
  }
  h3 {
    font-size: 1.3rem !important;
    line-height: 1.3 !important;
  }
  p {
    font-size: 0.95rem !important;
    line-height: 1.5 !important;
    margin-bottom: 1rem !important;
  }

  /* Header & Navigation Compression */
  #masthead nav {
    padding-top: 0.6rem !important;
    padding-bottom: 0.6rem !important;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  #masthead img {
    height: 2.4rem !important;
  }
  .bg-gray-950.py-3 {
    padding-top: 0.4rem !important;
    padding-bottom: 0.4rem !important;
  }

  /* Promotional Banner Compression */
  .bg-gradient-to-r.py-4,
  .bg-gradient-to-r.py-8 {
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
  }
  #quran-countdown {
    transform: scale(0.85);
    margin-top: 0.25rem;
  }

  /* Button Compression */
  .wp-element-button,
  .quran-btn,
  a.bg-primary,
  a.bg-secondary {
    padding: 0.6rem 1.2rem !important;
    font-size: 0.8rem !important;
    border-radius: 0.7rem !important;
  }

  /* Footer Compression */
  footer {
    padding-top: 2.5rem !important;
    padding-bottom: 1.5rem !important;
  }
  footer .grid {
    gap: 1.75rem !important;
  }
  footer h3 {
    margin-bottom: 1.25rem !important;
  }
  footer .space-y-6 > * {
    margin-bottom: 0.5rem !important;
  }
  #colophon {
    margin-top: 0 !important;
  }
  section.mt-12.-mb-20 {
    margin-top: 1.5rem !important;
    margin-bottom: -12rem !important;
  }

  /* Go to Top Button Compression */
  #go-to-top {
    width: 3.2rem !important;
    height: 3.2rem !important;
    bottom: 5.5rem !important; /* Positioned above WhatsApp button */
    right: 1.25rem !important;
    border-radius: 1rem !important;
  }
  #go-to-top .material-symbols-outlined {
    font-size: 2.2rem !important;
  }
}

/* 
   ==========================================================================
   ISLAMIC BRANDING - DYNAMIC BACKGROUNDS
   ========================================================================== 
*/

.islamic-pattern {
  position: relative !important;
  overflow: hidden !important;
}

.islamic-pattern::after {
  content: "" !important;
  position: absolute !important;
  inset: 0 !important;
  background-image: url("https://learnqurantherightway.com/wp-content/uploads/2026/04/isalmic.jpg") !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-position: center !important;
  opacity: 0.12 !important;
  pointer-events: none !important;
  z-index: 1 !important;
  display: block !important;
}

.islamic-pattern > * {
  position: relative !important;
  z-index: 10 !important;
}
