/*
Theme Name: Masjid Ayesha
Theme URI: https://mashrur.co.uk
Author: Mashrur Arafat Chowdhury
Author URI: https://mashrur.co.uk
Description: Cinematic day and night mosque theme with a configurable front page and read-only Daily Prayer Time integration.
Version: 1.0.0
Requires at least: 6.5
Tested up to: 6.9
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: masjid-ayesha
Tags: custom-logo, custom-menu, featured-images, full-width-template, translation-ready, blog
*/

[hidden] {
 display: none !important;
}

.ayesha-daily {
 min-width: 0;
}

.hero-prayer-note {
 max-width: 300px;
 font-size: 11px;
 line-height: 1.6;
 margin: 16px 0 0;
}

.timetable-message {
 font-size: 12px;
 line-height: 1.65;
 color: var(--muted);
 margin: 20px 0 0 !important;
}

.daily-custom-heading {
 font: 400 34px/1.1 var(--serif);
 margin: 0 0 26px;
}

.nav-links .menu {
 display: contents;
 list-style: none;
 margin: 0;
 padding: 0;
}

.nav-links .menu > li {
 display: contents;
}

.navigation .nav-links a {
 display: flex;
 align-items: center;
 position: relative;
 height: 100%;
 color: #173e36;
}

.navigation .nav-links a:after {
 content: "";
 position: absolute;
 bottom: 14px;
 left: 0;
 width: 100%;
 height: 1px;
 background: var(--ayesha-accent);
 transform: scaleX(0);
 transform-origin: left;
 transition: transform .25s;
}

.navigation .nav-links a:hover:after {
 transform: scaleX(1);
}

.navigation .nav-links a {
 font-size: 14px;
}

.footer-menu {
 display: contents;
 list-style: none;
 margin: 0;
 padding: 0;
}

.footer-menu > li {
 display: contents;
}

.eyebrow:before {
 background: var(--ayesha-accent);
}

.text-link {
 border-bottom-color: var(--ayesha-accent);
}

.text-link > span,
.card-link > span,
.since-year,
.programme-card > svg,
.programme-number,
.support-dome {
 color: var(--ayesha-accent);
}

.admin-bar .navigation {
 top: 32px;
}

.inner-header {
 display: flex;
 justify-content: space-between;
 align-items: center;
 padding-block: 24px;
 gap: 24px;
}

.inner-header > a:first-child {
 flex-shrink: 0;
}

.inner-header img {
 display: block;
 width: 65px;
 height: 83px;
 object-fit: contain;
}

.inner-header > p {
 font-size: 10px;
 letter-spacing: .16em;
 text-transform: uppercase;
 color: var(--muted);
 margin: 0 auto 0 24px;
}

.inner-header + .navigation {
 border-top: 1px solid var(--rule);
}

.content-shell {
 padding-block: 78px 110px;
 min-height: 60vh;
}

.page-heading {
 margin-bottom: 46px;
 max-width: 900px;
}

.page-heading h1 {
 font: 400 clamp(42px, 5.5vw, 76px)/1.03 var(--serif);
 letter-spacing: -.04em;
 margin: 0 0 24px;
 color: var(--ink);
}

.page-heading > p:last-child {
 max-width: 600px;
 color: var(--muted);
 font-size: 15px;
 line-height: 1.8;
}

.entry-content {
 font-size: 17px;
 line-height: 1.9;
 max-width: 880px;
 margin-inline: auto;
 color: var(--ink);
 overflow-wrap: break-word;
}

.entry-content > p,
.entry-content > ul,
.entry-content > ol {
 margin-bottom: 1.5em;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
 margin: 1.4em 0 .6em;
 line-height: 1.15;
}

.entry-content h2 {
 font-size: 44px;
}

.entry-content h3 {
 font-size: 32px;
}

.entry-content a {
 color: var(--ink);
 text-decoration: underline;
 text-underline-offset: 4px;
}

.entry-content img {
 max-width: 100%;
 height: auto;
}

.entry-content .alignwide {
 width: min(1180px, calc(100vw - 48px));
 max-width: none;
 position: relative;
 left: 50%;
 transform: translateX(-50%);
}

.entry-content .alignfull {
 width: calc(100vw - 24px);
 max-width: none;
 position: relative;
 left: 50%;
 transform: translateX(-50%);
}

.entry-content blockquote {
 border-left: 1px solid var(--ayesha-accent);
 margin: 36px 0;
 padding: 0 28px;
 font: 400 29px/1.4 var(--serif);
}

blockquote:before {
 display: none;
}



.entry-content table:not(.yearly-prayers) {
 border-collapse: collapse;
 width: 100%;
 font-size: 14px;
}

.entry-content table:not(.yearly-prayers) th,
.entry-content table:not(.yearly-prayers) td {
 padding: 12px;
 border-bottom: 1px solid var(--rule);
 text-align: left;
}

.entry-hero {
 display: block;
 width: 100%;
 max-height: 620px;
 object-fit: cover;
 margin-bottom: 44px;
}

.entry-navigation {
 margin: 70px auto 0;
 max-width: 880px;
 border-top: 1px solid var(--rule);
 padding-top: 26px;
}

.nav-links .nav-previous,
.nav-links .nav-next {
 display: block;
}

.posts-navigation .nav-links,
.post-navigation .nav-links {
 display: flex;
 justify-content: space-between;
 gap: 24px;
}

.archive-grid {
 gap: 30px;
}

.archive-grid .news-copy h2 {
 font-size: 31px;
}

.pagination {
 margin-top: 44px;
 text-align: center;
}

.page-numbers {
 display: inline-block;
 padding: 8px 14px;
 border: 1px solid var(--rule);
 margin: 3px;
}

.page-numbers.current {
 background: var(--ink);
 color: var(--paper);
}

.comments-area {
 margin-top: 70px;
}

.comment-list {
 padding-left: 24px;
}

.comment-body {
 padding-block: 22px;
 border-bottom: 1px solid var(--rule);
}

input,
textarea,
select {
 font: inherit;
 color: var(--ink);
 max-width: 100%;
}

.entry-content input:not([type=checkbox]):not([type=radio]),
.entry-content textarea,
.search-form input[type=search] {
 padding: 12px 15px;
 background: #fff;
 border: 1px solid var(--rule);
 width: 100%;
 border-radius: 0;
}

.search-form {
 display: flex;
 gap: 10px;
 max-width: 600px;
 margin-block: 30px;
}

.entry-content input[type=submit],
.search-form input[type=submit] {
 padding: 12px 22px;
 background: var(--ink);
 color: var(--paper);
 border: 0;
 width: auto;
 cursor: pointer;
}

.screen-reader-text {
 position: absolute;
 width: 1px;
 height: 1px;
 clip: rect(1px, 1px, 1px, 1px);
 overflow: hidden;
 white-space: nowrap;
}

.sticky {
 outline-offset: 4px;
}

.gallery {
 display: grid;
 gap: 14px;
 grid-template-columns: repeat(3, 1fr);
}

.gallery-item {
 margin: 0;
}

.gallery-caption,
.wp-caption-text {
 font-size: 12px;
 color: var(--muted);
}

.wp-caption {
 max-width: 100%;
}

.alignleft {
 float: left;
 margin: 0 24px 20px 0;
}

.alignright {
 float: right;
 margin: 0 0 20px 24px;
}

.aligncenter {
 display: block;
 margin-inline: auto;
}

.bypostauthor {
 border-color: var(--ayesha-accent);
}

.admin-only-note {
 font-size: 12px;
 color: #6e5c35;
 background: #f3eedf;
 padding: 14px 18px;
 margin: 18px 0 !important;
}

.newsletter-form .mc4wp-form-fields > p {
 margin: 0 0 12px;
}

.newsletter-form input[type=email] {
 width: 100%;
 border: 0;
 border-bottom: 1px solid #aab9ac;
 background: none;
 border-radius: 0;
 padding: 14px 0;
 font: inherit;
}

.newsletter-form input[type=submit],
.newsletter-form button {
 background: var(--ink);
 color: var(--paper);
 padding: 12px 22px;
 border: 0;
 cursor: pointer;
}

.newsletter-form label {
 font-size: 12px;
 line-height: 1.8;
}

.newsletter-form .mc4wp-response {
 font-size: 12px;
 margin-top: 12px;
}

.entry-content .ayesha-daily,
.entry-content .ayesha-calendar {
 font-size: 15px;
 line-height: 1.75;
}

.entry-content .prayer-waqt h3 {
 margin: 0;
 font-size: 23px;
}

.entry-content .prayer-schedule {
 margin-block: 30px;
}

.entry-content .ayesha-calendar a {
 text-decoration: none;
}

.waqt-icon,
.eyebrow:before {
 color: var(--ayesha-accent);
}

.is-single-column .prayer-time-labels {
 grid-template-rows: 88px 36px;
}

@media (max-width: 782px) {
 .admin-bar .navigation {
  top: 46px;
 }
}

@media (max-width: 760px) {
 .navigation .nav-links a {
  font-size: 13px;
  min-height: 44px;
 }

 .navigation .nav-links a:after {
  display: none;
 }

 .inner-header {
  padding-block: 18px;
  gap: 15px;
 }

 .inner-header > p {
  display: none;
 }

 .inner-header .text-link {
  font-size: 11px;
 }

 .inner-header img {
  width: 54px;
  height: 69px;
 }

 .content-shell {
  padding-block: 52px 72px;
 }

 .page-heading {
  margin-bottom: 30px;
 }

 .entry-content {
  font-size: 16px;
  line-height: 1.8;
 }

 .entry-content .prayer-waqt h3 {
  font-size: 24px;
 }

 .is-single-column .prayer-time-labels {
  grid-template-rows: auto;
  grid-template-columns: minmax(0, 1fr) 72px;
 }

 .is-single-column .prayer-waqt {
  grid-template-columns: minmax(0, 1fr) 72px;
 }

 .is-single-column .prayer-waqt dl {
  grid-template-columns: 1fr;
 }

 .gallery {
  grid-template-columns: repeat(2, 1fr);
 }
}

@media (max-width: 600px) {
 .admin-bar .navigation {
  top: 0;
 }
}


/* Restore proper menu containers. */
.navigation .nav-links > .menu {
 display: flex;
 align-items: stretch;
 gap: inherit;
 height: 100%;
 margin: 0;
 padding: 0;
 list-style: none;
}

.navigation .nav-links > .menu > li {
 position: relative;
 display: flex;
 align-items: center;
 gap: 4px;
 height: 100%;
}

.navigation,
.navigation-inner,
.navigation .nav-links {
 overflow: visible;
}

/* Keep the dropdown arrow next to its label. */
.navigation .nav-links .ma-submenu-toggle {
 display: grid;
 place-items: center;
 flex: 0 0 28px;
 width: 28px;
 min-height: 44px;
 padding: 0;
 border: 0;
 background: transparent;
 color: #173e36;
}

.navigation .nav-links .ma-submenu-toggle:hover {
 color: var(--ayesha-accent, #b38b48);
}

/* Refined dropdown panel. */
.navigation .nav-links .sub-menu {
 display: none;
 position: absolute;
 top: 100%;
 bottom: auto;
 left: 0;
 right: auto;
 z-index: 100;
 width: 270px;
 max-width: calc(100vw - 32px);
 margin: 0;
 padding: 7px;
 list-style: none;
 background: #faf8f2;
 color: #173e36;
 border: 1px solid #e5dfd2;
 border-top: 2px solid var(--ayesha-accent, #b38b48);
 border-radius: 0 0 10px 10px;
 box-shadow: 0 18px 42px rgb(20 48 38 / 12%);
}

.navigation .nav-links li.is-submenu-open > .sub-menu {
 display: block;
 animation: ma-dropdown-in 160ms ease-out;
}

.navigation .nav-links .sub-menu > li {
 position: relative;
 display: flex;
 align-items: center;
 height: auto;
}

/* Compact, left-aligned dropdown links. */
.navigation .nav-links .sub-menu a {
 flex: 1;
 justify-content: flex-start;
 min-width: 0;
 min-height: 44px;
 height: auto;
 padding: 11px 14px;
 border-radius: 5px;
 font-size: 15px;
 font-weight: 400;
 line-height: 1.5;
 letter-spacing: 0;
 white-space: normal;
 text-align: left;
 color: #173e36;
 transition:
         background-color 150ms ease,
         color 150ms ease;
}

/* Remove the main navigation underline from submenu links. */
.navigation .nav-links .sub-menu a::after {
 content: none;
}

.navigation .nav-links .sub-menu a:hover,
.navigation .nav-links .sub-menu a:focus-visible {
 background: #eeeadf;
 color: #0b3026;
}

/* Further nested levels. */
.navigation .nav-links .sub-menu .sub-menu {
 top: -8px;
 left: 100%;
 border-radius: 10px;
}

/* Preserve the existing screen-edge handling. */
.navigation .nav-links .ma-submenu-flip > .sub-menu {
 left: auto;
 right: 0;
}

.navigation .nav-links .sub-menu .ma-submenu-flip > .sub-menu {
 right: 100%;
}

@keyframes ma-dropdown-in {
 from {
  opacity: 0;
  transform: translateY(5px);
 }

 to {
  opacity: 1;
  transform: translateY(0);
 }
}

/* Mobile: one column with indented expandable submenus. */
@media (max-width: 760px) {
 .navigation .nav-links {
  max-height: 70svh;
  overflow-y: auto;
  padding: 10px;
 }

 .navigation .nav-links.is-open,
 .navigation .nav-links > .menu {
  display: block;
  height: auto;
 }

 .navigation .nav-links > .menu > li,
 .navigation .nav-links .sub-menu > li {
  flex-wrap: wrap;
  gap: 0;
  height: auto;
 }

 .navigation .nav-links > .menu > li > a {
  flex: 1;
  justify-content: flex-start;
  min-height: 48px;
  height: auto;
  padding: 10px 12px;
  font-size: 15px;
 }

 .navigation .nav-links .ma-submenu-toggle {
  flex-basis: 44px;
  width: 44px;
 }

 .navigation .nav-links .sub-menu,
 .navigation .nav-links .sub-menu .sub-menu {
  position: static;
  flex: 0 0 calc(100% - 12px);
  width: auto;
  max-width: none;
  margin: 0 0 8px 12px;
  padding: 2px 0 2px 10px;
  background: transparent;
  border: 0;
  border-left: 1px solid #d9c7a2;
  border-radius: 0;
  box-shadow: none;
  animation: none;
 }
}

@media (prefers-reduced-motion: reduce) {
 .navigation .nav-links li.is-submenu-open > .sub-menu {
  animation: none;
 }
}
