/* css/styles.css */

/* THEME CONFIGURATION */
:root {
  --color-primary: #F7D35B;
  --color-accent: #E5C76B;
  --color-bg: #FBF7EF;
  --color-bg-alt: #fff9f0;
  --color-surface: #ffffff;
  --color-border: #f1e2c5;
  --color-text: #4A4A4A;
  --color-text-muted: #767676;
  --color-shadow-soft: rgba(0, 0, 0, 0.06);

  --font-heading: "Montserrat", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Noto Sans", "Noto Naskh Arabic", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;

  --spacing-section: 4rem;
  --max-width: 1240px;

  --transition-fast: 0.2s ease;
}

/* Global resets */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover,
a:focus-visible {
  text-decoration: underline;
}

button {
  font-family: inherit;
}

/* Accessibility helpers */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -40px;
  left: 16px;
  padding: 0.5rem 1rem;
  background: var(--color-primary);
  color: #000;
  border-radius: var(--radius-sm);
  z-index: 1000;
}

.skip-link:focus {
  top: 16px;
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

/* Layout utilities */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.section {
  padding: var(--spacing-section) 0;
}

.section-intro {
  max-width: 640px;
  color: var(--color-text-muted);
}

/* Subtle geometric patterned background */
.patterned-bg {
  position: relative;
  background:
    radial-gradient(circle at 0 0, rgba(247, 211, 91, 0.12), transparent 55%),
    radial-gradient(circle at 100% 100%, rgba(229, 199, 107, 0.12), transparent 55%),
    var(--color-bg-alt);
}

/* Header and navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 999;
  background-color: rgba(251, 247, 239, 0.96);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
}

.logo-img {
  height: 52px;
  width: auto;
  max-width: 190px;
  object-fit: contain;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.18));
}

.site-nav {
  display: flex;
}

/* simplified, pill-style nav */
.nav-list {
  list-style: none;
  display: flex;
  gap: 0.75rem;
  margin: 0;
  padding: 0.35rem 0.75rem;
  font-size: 0.9rem;
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 999px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
}

.nav-list a {
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  font-weight: 500;
  position: relative;
}

.nav-list a::after {
  display: none;
}

.nav-list a:hover,
.nav-list a:focus-visible {
  background-color: rgba(247, 211, 91, 0.18);
  text-decoration: none;
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.4rem;
  cursor: pointer;
  border-radius: 999px;
}

.nav-toggle-bar {
  display: block;
  width: 22px;
  height: 2px;
  background-color: var(--color-text);
  margin: 3px 0;
  border-radius: 999px;
}

/* Hero section */
.hero-section {
  padding: 4rem 0 3.25rem;
  background: linear-gradient(to bottom, #fbf7ef 0%, #fff9f0 70%);
}

.hero-visual {
  max-width: 1180px;
  margin: 0 auto 2rem;
  position: relative;
  border-radius: 28px;
  overflow: hidden;
}

.hero-visual-image {
  height: 540px;
  background-image: url("../assets/al-abrar-scene.jpeg");
  background-size: cover;
  background-position: center 40%;
  background-repeat: no-repeat;
}

/* Dark overlay for legibility */
.hero-visual-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.65) 0%,
    rgba(0, 0, 0, 0.42) 40%,
    rgba(0, 0, 0, 0.18) 72%,
    rgba(0, 0, 0, 0.06) 100%
  );
  pointer-events: none;
}

/* Layout inside hero */
.hero-heading-row {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(340px, 0.9fr);
  column-gap: 1.75rem;
  align-items: center;
  padding: 0 3.25rem;
}

.hero-heading-block {
  color: #fff;
  max-width: 720px;
}

.hero-heading-block h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.9rem, 5vw, 3.7rem);
  margin: 0 0 0.45rem;
}

.hero-subtitle {
  font-size: 1.06rem;
  color: rgba(255, 255, 255, 0.86);
  margin: 0;
}

/* Below-hero text */
.hero-below {
  display: block;
}

.hero-text-column {
  max-width: 900px;
  margin: 1.7rem auto 0;
}

.hero-text-column .hero-intro {
  font-size: 1.02rem;
  line-height: 1.8;
  color: var(--color-text-muted);
  margin: 0;
  padding: 0;
  background: none;
  border: none;
  box-shadow: none;
}

/* Prayer widget – desktop card */
.hero-heading-row .prayer-widget {
  width: 100%;
}

.prayer-widget {
  background: rgba(255, 249, 241, 0.97);
  backdrop-filter: blur(10px);
  border-radius: 18px;
  border: 1px solid rgba(243, 228, 207, 0.9);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.16);
  padding: 1.15rem 1.35rem 1.3rem;
}

.prayer-widget h2 {
  font-family: var(--font-heading);
  font-size: 1.22rem;
  letter-spacing: 0.03em;
  margin: 0;
}

.prayer-widget-note {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-top: 0.32rem;
}

/* Header */
.prayer-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.25rem;
  margin: 0.9rem 0 1rem;
}

.prayer-header-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #948367;
  margin: 0 0 0.1rem;
}

.prayer-header-time {
  font-family: var(--font-heading);
  font-size: 1.48rem;
  font-variant-numeric: tabular-nums;
  margin: 0;
  color: #3b3122;
}

.prayer-header-next {
  padding: 0.55rem 0.95rem;
  border-radius: 14px;
  background-color: #ffffff;
  border: 1px solid #ece1d2;
  min-width: 150px;
  display: flex;
  flex-direction: column;
}

.prayer-header-main {
  margin: 0;
  font-weight: 600;
  font-size: 0.94rem;
}

.prayer-header-countdown {
  margin: 0.08rem 0 0;
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
  color: #7b6b52;
}

/* Grid of prayer cards */
.prayer-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.prayer-card {
  padding: 0.55rem 1.1rem;
  border-radius: 12px;
  background-color: #fffdf8;
  border: 1px solid #f2e4d1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  column-gap: 0.6rem;
  font-size: 0.86rem;
  color: #4c4130;
}

.prayer-card-name {
  font-weight: 500;
  margin-right: 0.4rem;
  white-space: nowrap;
}

.prayer-card-time {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  white-space: nowrap;
}

@media (max-width: 720px) {
  .prayer-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* “Next” pill */
.prayer-card-next {
  border-color: #f3dba6;
  background: #fffaf1;
  box-shadow: 0 0 0 1px rgba(243, 219, 166, 0.55);
}

/* Active state */
.prayer-chip--active,
.prayer-row.is-active,
.prayer-card.is-active {
  background: #f7ecd2;
  border-color: #f0d59b;
  box-shadow: 0 0 0 1px rgba(240, 207, 145, 0.55);
}

.prayer-chip--active .prayer-name,
.prayer-row.is-active .prayer-time,
.prayer-card.is-active .prayer-card-time {
  color: #3f311c;
}

/* Extra text */
.prayer-widget-small {
  margin-top: 0.85rem;
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

/* Legacy rows, if used elsewhere */
.prayer-row {
  background-color: #fffdf8;
  border: 1px solid #f2e4d1;
  color: #4c4130;
}

.prayer-row-label {
  color: #8f7d63;
}

/* Desktop hover */
@media (hover: hover) {
  .prayer-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  }
}

/* Headings */
h2 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin-bottom: 0.75rem;
}

/* Chairman card – two-column layout */
.chairman-message {
  max-width: 1500px;
  margin: 0 auto;
}

.chairman-card {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 2.4fr);
  gap: 1.75rem;
  align-items: flex-start;
  padding: 1.75rem 1.9rem;
  border-radius: 22px;
  background-color: #fffdf8;
  border: 1px solid var(--color-border);
  box-shadow: 0 18px 40px var(--color-shadow-soft);
}

/* left column */
.chairman-card-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.chairman-photo {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #f3df9b;
  box-shadow: 0 10px 24px var(--color-shadow-soft);
  margin-bottom: 0.75rem;
}

.chairman-profile-text {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.chairman-name {
  font-weight: 700;
  margin: 0;
}

.chairman-role {
  margin: 0;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

/* right column */
.chairman-card-right {
  font-size: 0.98rem;
  line-height: 1.9;
  color: #3e3426;
  max-width: 70ch;
}

.chairman-card-right p {
  margin: 0 0 1.05rem;
}

.chairman-card-right p:last-child {
  margin-bottom: 0;
}

.chairman-greeting {
  font-weight: 600;
}

/* Team section */
.team-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.team-card {
  background-color: var(--color-surface);
  padding: 1.25rem;
  border-radius: var(--radius-md);
  text-align: center;
  border: 1px solid var(--color-border);
  box-shadow: 0 12px 25px var(--color-shadow-soft);
}

.team-photo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 0.75rem;
  border: 3px solid rgba(247, 211, 91, 0.6);
}

.team-role {
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

.team-name {
  font-weight: 600;
  margin-bottom: 0.4rem;
}

.team-bio {
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

/* Team Carousel Styles */
.team-carousel-wrapper {
  position: relative;
  margin: 3rem 0 0;
}

.team-carousel {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 1rem 0;
  scrollbar-width: thin;
}

.team-carousel::-webkit-scrollbar {
  height: 8px;
}

.team-carousel::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 4px;
}

.team-carousel::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 4px;
}

.team-card-carousel {
  flex: 0 0 280px;
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.team-card-carousel:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.team-photo-carousel {
  width: 100%;
  height: 320px;
  object-fit: cover;
  display: block;
}

.team-card-body {
  padding: 1.5rem;
  text-align: center;
}

.team-name-carousel {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
  color: #1a1a1a;
}

.team-role-carousel {
  font-size: 0.95rem;
  color: #666;
  margin: 0;
  font-weight: 500;
}

/* Team carousel controls – only positioning, visuals from .carousel-control */
.team-carousel-wrapper .carousel-control.prev {
  left: -6px;
}

.team-carousel-wrapper .carousel-control.next {
  right: -6px;
}

@media (max-width: 768px) {
  .team-card-carousel {
    flex: 0 0 240px;
  }

  .team-photo-carousel {
    height: 280px;
  }
}

/* Events carousel */
.events-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
}

.events-tagline {
  margin: 0.15rem 0 0;
  font-size: 0.95rem;
  color: var(--color-text-muted);
}

.events-view-all {
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background-color: var(--color-surface);
  box-shadow: 0 6px 16px var(--color-shadow-soft);
  text-decoration: none;
}

.events-view-all:hover,
.events-view-all:focus-visible {
  background-color: rgba(247, 211, 91, 0.12);
}

/* Wrapper keeps arrows aligned over the scroll area */
.events-carousel-wrapper {
  position: relative;
  margin-top: 1.75rem;
}

/* Horizontal scrolling row with scroll snap */
.events-carousel {
  display: flex;
  gap: 1.25rem;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding-bottom: 0.5rem;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.events-carousel::-webkit-scrollbar {
  height: 6px;
}

.events-carousel::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.04);
}

.events-carousel::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.18);
  border-radius: 999px;
}

/* === CLEAN EVENT CARDS === */
.event-card {
  scroll-snap-align: start;
  flex: 0 0 min(320px, 80vw);
  background-color: var(--color-surface);
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--color-border);
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.event-card:hover,
.event-card:focus-within {
  transform: translateY(-4px);
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.14);
}

.event-image {
  width: 100%;
  max-height: 180px;
  object-fit: cover;
}

.event-body {
  padding: 1.5rem 1.75rem 1.75rem;
}

.event-chip {
  display: inline-block;
  padding: 0.15rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}

.event-chip-regular {
  background: #fff4d5;
  color: #7b5b09;
}

.event-chip-grand {
  background: #ebe3ff;
  color: #43338c;
}

.event-title {
  margin-top: 0.75rem;
  margin-bottom: 0.25rem;
  font-size: 1.15rem;
}

.event-date {
  margin: 0 0 0.85rem;
  font-size: 0.9rem;
  color: #6b7280;
}

.event-list {
  margin: 0;
  padding-left: 1.1rem;
  font-size: 0.96rem;
  line-height: 1.55;
}

.event-list li + li {
  margin-top: 0.18rem;
}

/* Events list cards (below Upcoming Events) */
.events-list-grid {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
}

.events-list-card {
  background: #fffdf8;
  border-radius: 18px;
  border: 1px solid var(--color-border);
  padding: 1.5rem 1.6rem 1.7rem;
  box-shadow: 0 14px 34px var(--color-shadow-soft);
}

/* coloured category labels */
.events-list-chip {
  display: inline-block;
  padding: 0.15rem 0.75rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* Weekly = green, Monthly = gold, Annual = purple */
.events-list-chip-weekly {
  background: #dcfce7;
  color: #166534;
}

.events-list-chip-monthly {
  background: #fef3c7;
  color: #92400e;
}

.events-list-chip-annual {
  background: #ede9fe;
  color: #4338ca;
}

.events-list-title {
  margin: 0.75rem 0 0.25rem;
  font-size: 1.12rem;
}

.events-list-meta {
  margin: 0 0 0.8rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.events-list-items {
  margin: 0;
  padding-left: 1.1rem;
  font-size: 0.95rem;
  line-height: 1.55;
}

.events-list-items li + li {
  margin-top: 0.2rem;
}

/* Carousel controls */
.carousel-control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background-color: #fff;
  color: #000;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.2);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
  z-index: 5;
}

.carousel-control:hover,
.carousel-control:focus-visible {
  transform: translateY(-50%) translateY(-1px);
  background-color: var(--color-primary);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.25);
}

.carousel-control.prev {
  left: -6px;
}

.carousel-control.next {
  right: -6px;
}

.events-news-highlight {
  margin-top: 2.25rem;
}

.events-news-highlight h3 {
  margin: 0 0 0.9rem;
  font-family: var(--font-heading);
  font-size: 1.2rem;
}

.events-news-card {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.8fr);
  gap: 1.25rem;
  align-items: center;
  padding: 1.2rem 1.4rem;
  border-radius: 18px;
  background: #fffdf8;
  border: 1px solid var(--color-border);
  box-shadow: 0 14px 32px var(--color-shadow-soft);
}

.events-news-image {
  width: 100%;
  border-radius: 14px;
  object-fit: cover;
}

.events-news-text p {
  margin: 0 0 0.45rem;
  font-size: 0.95rem;
}

.events-news-title {
  font-weight: 600;
}

.events-news-meta {
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

/* Gallery */
.gallery-grid {
  margin-top: 1.75rem;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.gallery-item {
  border: none;
  padding: 0;
  background: none;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 10px 24px var(--color-shadow-soft);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-fast);
}

.gallery-item:hover img,
.gallery-item:focus-visible img {
  transform: scale(1.04);
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.lightbox.visible {
  display: flex;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.65);
}

.lightbox-content {
  position: relative;
  z-index: 1;
  max-width: 860px;
  width: 90%;
  background-color: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.lightbox-content img {
  width: 100%;
  height: auto;
  display: block;
}

.lightbox-caption {
  margin: 0;
  padding: 0.75rem 1rem;
  color: #eee;
  font-size: 0.9rem;
}

.lightbox-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background-color: rgba(0, 0, 0, 0.65);
  color: #fff;
  cursor: pointer;
}

/* Resources */
.resource-list {
  margin-top: 1rem;
  padding-left: 1.1rem;
}

.resource-downloads {
  margin-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* History section layout */
.history-layout {
  display: grid;
  grid-template-columns: minmax(0, 2.2fr) minmax(260px, 0.9fr);
  gap: 2rem;
  align-items: flex-start;
  margin-top: 1.25rem;
}

.history-copy {
  background: #fffdf8;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  padding: 1.5rem 1.75rem 1.75rem;
  box-shadow: 0 14px 32px var(--color-shadow-soft);
  position: relative;
}

/* subtle left accent bar */
.history-copy::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.4rem;
  bottom: 1.4rem;
  width: 4px;
  border-radius: 999px;
  background: linear-gradient(
    to bottom,
    rgba(247, 211, 91, 0.9),
    rgba(229, 199, 107, 0.7)
  );
}

.history-copy p {
  margin: 0 0 1rem;
}

.history-copy h3 {
  margin-top: 1.6rem;
  margin-bottom: 0.6rem;
}

/* Side facts card */
.history-facts {
  background: radial-gradient(circle at top left, rgba(247, 211, 91, 0.16), transparent 55%), #ffffff;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  padding: 1.25rem 1.4rem;
  box-shadow: 0 14px 30px var(--color-shadow-soft);
}

.history-facts h3 {
  margin: 0 0 0.75rem;
  font-family: var(--font-heading);
  font-size: 1.1rem;
}

.history-facts ul {
  list-style: none;
  margin: 0;
  padding-left: 0;
  font-size: 0.92rem;
}

.history-facts li + li {
  margin-top: 0.4rem;
}

.history-facts strong {
  font-weight: 600;
}

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.2rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-weight: 600;
  letter-spacing: 0.02em;
  font-size: 0.95rem;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
}

.button.primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  color: #000;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.16);
}

.button.primary:hover,
.button.primary:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.2);
}

.button.secondary {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text);
}

.button.secondary:hover,
.button.secondary:focus-visible {
  background-color: rgba(247, 211, 91, 0.12);
}

/* Contact section */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 2.25rem;
  align-items: flex-start;
}

.contact-info > p {
  margin: 0 0 0.25rem;
  color: var(--color-text-muted);
}

.contact-info > p a {
  text-decoration: underline;
}

/* Form card */
.contact-form {
  margin-top: 1.25rem;
  background: radial-gradient(circle at top left, rgba(247, 211, 91, 0.18), transparent 55%), #ffffff;
  padding: 1.4rem 1.6rem 1.6rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  box-shadow: 0 18px 40px var(--color-shadow-soft);
}

.form-field {
  display: flex;
  flex-direction: column;
  margin-bottom: 0.95rem;
}

.form-field label {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.form-field input,
.form-field textarea {
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  padding: 0.55rem 0.65rem;
  font: inherit;
  background-color: #fff;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-field input:focus-visible,
.form-field textarea:focus-visible {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(247, 211, 91, 0.35);
}

/* Map card */
.contact-map h3 {
  margin-top: 0;
  margin-bottom: 0.35rem;
}

.contact-map {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.map-embed-wrapper {
  margin-top: 0.9rem;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.04);
  box-shadow: 0 18px 40px var(--color-shadow-soft);
}

.map-embed-wrapper iframe {
  border: 0;
  width: 100%;
  height: 340px;
}

/* Volunteer section */
.volunteer-section {
  background: linear-gradient(135deg, rgba(247, 211, 91, 0.1), rgba(229, 199, 107, 0.18));
}

.volunteer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

/* Donation section and modal */
.donation-methods {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
  margin-top: 1rem;
}

.donation-method h4 {
  margin: 0 0 0.4rem;
  font-family: var(--font-heading);
  font-size: 1rem;
}

.donation-method-note {
  margin: 0 0 0.6rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

.donation-details {
  list-style: none;
  padding-left: 0;
  margin: 0;
  font-size: 0.9rem;
}

.donation-details li + li {
  margin-top: 0.15rem;
}

.paynow-layout {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.7rem;
  align-items: center;
}

.paynow-qr-placeholder {
  width: 110px;
  height: 110px;
  border-radius: 10px;
  border: 1px dashed var(--color-border);
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  text-align: center;
  color: var(--color-text-muted);
}

.paynow-details p {
  margin: 0 0 0.25rem;
  font-size: 0.9rem;
}

.donation-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.donation-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.donation-modal[aria-hidden="false"],
.donation-modal.visible {
  display: flex;
}

.donation-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.donation-content {
  position: relative;
  z-index: 1;
  max-width: 640px;
  width: min(640px, 100% - 2rem);
  background: #ffffff;
  border-radius: 18px;
  padding: 1.5rem 1.75rem 1.6rem;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

.donation-content h3 {
  margin-top: 0;
  margin-bottom: 0.4rem;
}

.donation-content > p {
  margin: 0 0 0.9rem;
  color: var(--color-text-muted);
}

.donation-close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: none;
  background: #f5f2ea;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.donation-amounts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.75rem 0 1.1rem;
}

.donation-amount {
  min-width: 72px;
}

.donation-custom {
  display: inline-flex;
  flex-direction: column;
  font-size: 0.85rem;
  gap: 0.25rem;
}

.donation-custom input {
  padding: 0.4rem 0.5rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  font: inherit;
}

.donation-note {
  margin-top: 0.75rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

/* Mobile tweaks for donation modal */
@media (max-width: 768px) {
  .donation-content {
    max-width: 100%;
    width: 100%;
    margin: 1rem;
    padding: 1.25rem 1.25rem 1.4rem;
  }

  .donation-methods {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
  }

  .paynow-layout {
    grid-template-columns: auto 1fr;
  }
}

@media (max-width: 520px) {
  .paynow-layout {
    grid-template-columns: 1fr;
    justify-items: flex-start;
  }

  .paynow-qr-placeholder {
    width: 140px;
    height: 140px;
  }
}

/* Footer */
.site-footer {
  margin-top: 1.5rem;
  background-color: #111;
  color: #f7f7f7;
  padding-top: 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1fr;
  gap: 2rem;
}

.footer-section h3 {
  font-family: var(--font-heading);
  margin-top: 0;
  margin-bottom: 0.5rem;
}

.footer-section p,
.footer-section ul {
  font-size: 0.9rem;
  color: #e0e0e0;
  margin: 0.15rem 0;
}

.footer-prayers ul {
  list-style: none;
  padding-left: 0;
}

.social-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  gap: 0.5rem;
}

.social-list a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background-color: #222;
  font-size: 0.75rem;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
  padding: 0.75rem 1.25rem 1rem;
  margin-top: 1.5rem;
  font-size: 0.8rem;
  color: #bbb;
}

/* DEFAULT visibility: mobile widget hidden (overridden on mobile) */
.mobile-prayer-section,
.prayer-widget-mobile {
  display: none;
}

/* Responsive design */
/* Tablet-ish */
@media (max-width: 960px) {
  .hero-visual {
    max-width: 100%;
    padding: 0 1rem;
  }

  .hero-visual-image {
    height: 380px;
    background-position: 50% 35%;
  }

  .hero-heading-row {
    grid-template-columns: 1fr;
    row-gap: 1.25rem;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
    align-items: flex-start;
  }

  .events-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .events-view-all {
    align-self: flex-end;
  }

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

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

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

/* Mobile layout */
@media (max-width: 768px) {
  .header-inner {
    padding-inline: 1rem;
  }

  .site-nav {
    position: absolute;
    inset-inline: 0;
    top: 100%;
    z-index: 20;
    background-color: rgba(251, 247, 239, 0.98);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-fast);
  }

  .site-nav.open {
    max-height: 320px;
  }

  .nav-list {
    flex-direction: column;
    padding: 0.75rem 1.25rem 1rem;
    background: none;
    box-shadow: none;
  }

  .nav-toggle {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border: none;
    background: transparent;
    position: relative;
  }

  .nav-toggle-bar {
    width: 22px;
    height: 2px;
    margin: 3px 0;
    border-radius: 999px;
    background-color: #222222;
    transition:
      transform 0.25s ease,
      opacity 0.25s ease,
      top 0.25s ease;
  }

  .nav-toggle:hover .nav-toggle-bar,
  .nav-toggle:focus-visible .nav-toggle-bar {
    background-color: #000000;
  }

  /* X state */
  .nav-toggle[aria-expanded="true"] .nav-toggle-bar {
    position: absolute;
    left: 50%;
    transform-origin: center;
    margin: 0;
    translate: -50% 0;
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
    top: 50%;
    transform: rotate(45deg);
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
    opacity: 0;
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) {
    top: 50%;
    transform: rotate(-45deg);
  }

  /* HERO */
  .hero-section {
    padding-top: 3.25rem;
    padding-bottom: 0;
  }

  .hero-visual {
    max-width: none;
    margin: 0;
    padding: 0;
    border-radius: 0;
  }

  .hero-visual-image {
    height: 520px;
    background-position: 50% 40%;
  }

  .hero-visual-overlay {
    background: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0.65) 0%,
      rgba(0, 0, 0, 0.48) 35%,
      rgba(0, 0, 0, 0.2) 75%,
      rgba(0, 0, 0, 0.0) 100%
    );
  }

  .hero-heading-row {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: flex-start;
    padding: 1.8rem 1.4rem 1.4rem;
    row-gap: 0.8rem;
  }

  .hero-heading-block {
    max-width: 90%;
  }

  .hero-heading-block h1 {
    font-size: clamp(2.3rem, 7vw, 2.8rem);
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero-heading-row .prayer-widget {
    display: block;
    width: 100%;
    max-width: 100%;
    background: rgba(255, 249, 241, 0.96);
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
    border-radius: 18px;
    padding: 0.8rem 0.9rem 1rem;
    transform: translateY(8px);
  }

  .mobile-prayer-section,
  .prayer-widget-mobile {
    display: none;
  }

  .prayer-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin: 0.6rem 0 0.8rem;
  }

  .prayer-header-time {
    font-size: 1.3rem;
  }

  .prayer-header-next {
    width: 100%;
  }

  .prayer-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.45rem;
  }

  .prayer-card {
    padding: 0.35rem 0.7rem;
    font-size: 0.78rem;
  }

  .chairman-card {
    grid-template-columns: 1fr;
    padding: 1.4rem 1.35rem 1.5rem;
  }

  .chairman-card-left {
    flex-direction: row;
    align-items: center;
    text-align: left;
    gap: 0.9rem;
  }

  .chairman-photo {
    width: 96px;
    height: 96px;
    margin-bottom: 0;
  }

  .chairman-card-right {
    font-size: 0.95rem;
  }

  .history-layout {
    grid-template-columns: 1fr;
  }

  .history-copy::before {
    left: 0.75rem;
  }

  .events-carousel-wrapper {
    margin-top: 1.5rem;
  }

  .team-grid {
    grid-template-columns: 1fr;
  }

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

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .volunteer-inner,
  .donation-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .carousel-control.prev {
    left: 4px;
  }

  .carousel-control.next {
    right: 4px;
  }

  .events-news-card {
    grid-template-columns: 1fr;
  }

  .events-list-grid {
    grid-template-columns: 1fr;
  }
}

/* Small phones */
@media (max-width: 520px) {
  .hero-visual-image {
    height: 620px;
  }

  .hero-heading-row {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }

  .prayer-list {
    grid-template-columns: 1fr;
  }

  .event-card {
    flex: 0 0 82vw;
  }

  .events-view-all {
    width: 100%;
    text-align: center;
    justify-content: center;
  }
}

/* Floating WhatsApp */
.whatsapp-float-button {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background-color: #25d366;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  z-index: 999;
}

.whatsapp-float-icon {
  width: 34px;
  height: 34px;
  display: block;
}

.whatsapp-float-button:hover {
  background-color: #1ebe57;
}
