/* CCBI — Header prayer times widget (left column) */

/* Masthead layout is always physical LTR — language changes text only, not structure. */
.masthead,
.masthead .mh-inner,
.masthead .header-mobile-info,
.masthead .masthead-info-grid,
.masthead .mh-left,
.masthead .mh-right-col,
.masthead .mh-prayer-times,
.masthead .mh-visit-hours,
.masthead .visit-hours {
  direction: ltr;
}

.masthead .mh-prayer-times {
  text-align: left;
  min-width: 8.5rem;
  max-width: 11.5rem;
}

.mh-prayer-times__title {
  display: block;
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--charcoal, #1c1a17);
  margin-bottom: 0.35rem;
}

.mh-prayer-times__hijri,
.prayer-hijri-date,
.header-hijri-date {
  font-family: 'Source Sans 3', sans-serif;
  font-size: 13px;
  line-height: 1.4;
  color: #c9a24a;
  margin: 10px 0 0;
  text-align: left;
  white-space: nowrap;
}

.mh-prayer-times__gregorian,
.prayer-gregorian-date,
.header-gregorian-date {
  font-family: 'Source Sans 3', sans-serif;
  font-size: 13px;
  line-height: 1.4;
  color: #c9a24a;
  margin: 10px 0 0;
  text-align: left;
  white-space: normal;
}

.mh-prayer-times__dates,
.header-dates {
  display: block;
  margin-top: 8px;
  text-align: left;
  width: 100%;
  max-width: 190px;
  margin-inline: 0;
  margin-inline-end: auto;
}

.mh-prayer-times__dates .header-hijri-date,
.mh-prayer-times__dates .header-gregorian-date,
.mh-prayer-times__dates .mh-prayer-times__hijri,
.mh-prayer-times__dates .mh-prayer-times__gregorian {
  margin-top: 0;
}

.mh-prayer-times__dates .header-gregorian-date,
.mh-prayer-times__dates .mh-prayer-times__gregorian {
  margin-top: 3px;
}

.header-hijri-date,
.header-gregorian-date {
  display: block;
  width: 100%;
  line-height: 1.45;
  white-space: normal;
}

.header-gregorian-date {
  margin-top: 3px;
}

.masthead .mh-prayer-times .prayer-hijri-date,
.masthead .mh-prayer-times .header-hijri-date,
.masthead .mh-prayer-times .prayer-gregorian-date,
.masthead .mh-prayer-times .header-gregorian-date {
  text-align: left;
}

.mh-prayer-times__list {
  list-style: none;
  margin: 0;
  padding: 0;
  width: fit-content;
  max-width: 190px;
  margin-inline: 0;
  margin-inline-end: auto;
}

.mh-prayer-times__list--rows {
  display: block;
  width: 100%;
}

.mh-prayer-times__row,
.prayer-row {
  display: grid;
  grid-template-columns: minmax(70px, auto) auto;
  column-gap: 12px;
  direction: ltr;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  padding: 4px 0;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 0.68rem;
  line-height: 1.35;
  color: rgba(28, 26, 23, 0.72);
  box-sizing: border-box;
}

.mh-prayer-times__row + .mh-prayer-times__row,
.prayer-row + .prayer-row {
  margin-top: 0;
}

.mh-prayer-times__name,
.prayer-name {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  white-space: nowrap;
  font-weight: 600;
  text-align: left;
  direction: auto;
  justify-self: start;
}

.mh-prayer-times__time,
.prayer-time {
  font-variant-numeric: tabular-nums;
  color: rgba(28, 26, 23, 0.82);
  font-weight: 700;
  text-align: right;
  direction: ltr;
  white-space: nowrap;
  justify-self: end;
}

.mh-prayer-times__row.is-current,
.prayer-row.current-prayer {
  color: var(--maroon, #1b3a2d);
  font-weight: 700;
}

.mh-prayer-times__row.is-current .mh-prayer-times__name,
.prayer-row.current-prayer .prayer-name {
  color: inherit;
  font-weight: 700;
}

.mh-prayer-times__row.is-current .mh-prayer-times__time,
.prayer-row.current-prayer .prayer-time {
  color: var(--gold, #b8902a);
  font-weight: 700;
}

.mh-prayer-times__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold, #b8902a);
  box-shadow: 0 0 0 2px rgba(201, 168, 76, 0.25);
  flex-shrink: 0;
}

.mh-prayer-times--unavailable .mh-prayer-times__title {
  margin-bottom: 0;
}

.mh-prayer-times__unavailable {
  margin: 0.2rem 0 0;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 0.68rem;
  color: rgba(28, 26, 23, 0.62);
}

@media (min-width: 992px) {
  .masthead .mh-prayer-times__title,
  .masthead .mh-visit-hours__title {
    display: block;
    margin-top: 0;
    margin-bottom: 0.35rem;
    padding-top: 0;
    font-family: 'Cinzel', serif;
    font-size: 0.72rem !important;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--charcoal, #1c1a17) !important;
    line-height: 1.2;
  }

  .masthead .mh-prayer-times__list,
  .masthead .prayer-times-list,
  .masthead .mh-prayer-times__dates,
  .masthead .header-dates {
    margin-inline: 0;
    margin-inline-end: auto;
    text-align: left;
  }

  .masthead .mh-prayer-times__hijri,
  .masthead .mh-prayer-times__gregorian,
  .masthead .prayer-hijri-date,
  .masthead .prayer-gregorian-date,
  .masthead .header-hijri-date,
  .masthead .header-gregorian-date {
    text-align: left !important;
  }

  .masthead .mh-prayer-times__row,
  .masthead .prayer-row {
    grid-template-columns: minmax(70px, auto) auto;
    column-gap: 12px;
    width: fit-content;
    max-width: 100%;
  }

  .masthead .mh-visit-hours,
  .masthead .visit-hours {
    margin-top: 0 !important;
    padding-top: 0 !important;
    align-self: flex-end;
  }
}

/* CCBI — Header visiting hours widget (right column) */
.masthead .mh-visit-hours {
  text-align: right;
  min-width: 8.5rem;
  max-width: 12.5rem;
  font-family: 'Source Sans 3', sans-serif;
  font-size: 0.68rem;
  line-height: 2.45;
  color: rgba(28, 26, 23, 0.72);
}

.mh-visit-hours__title {
  display: block;
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--charcoal, #1c1a17);
  margin-bottom: 0.35rem;
}

.mh-visit-hours__body {
  color: rgba(28, 26, 23, 0.72);
}

/* Reservar Ingresso — gold/green site identity; overrides global maroon .btn-ticket */
.masthead .mh-visit-hours .btn-ticket,
.masthead .ticket-button .btn-ticket {
  --visit-cta-gold: #c9a84c;
  --visit-cta-gold-hover: var(--gold-lt, #d4af5a);
  --visit-cta-bg: var(--gold, #b8902a);
  --visit-cta-bg-active: #a67f24;
  --visit-cta-text: var(--charcoal, #1c1a17);
  --visit-cta-focus-ring: var(--gold-pale, #f0e0a0);
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin-top: 0.45rem;
  padding: 0.45rem 0.85rem !important;
  font-family: 'Cinzel', serif !important;
  font-size: 0.58rem !important;
  font-weight: 600;
  letter-spacing: 0.12em !important;
  text-transform: uppercase;
  text-decoration: none !important;
  line-height: 1.2;
  box-sizing: border-box;
  border: 2px solid var(--visit-cta-gold) !important;
  border-radius: 0.3rem;
  background: var(--visit-cta-bg) !important;
  color: var(--visit-cta-text) !important;
  box-shadow:
    0 2px 0 rgba(0, 0, 0, 0.18),
    0 3px 10px rgba(184, 144, 42, 0.28);
  transition:
    background 0.22s ease,
    border-color 0.22s ease,
    color 0.22s ease,
    box-shadow 0.22s ease,
    transform 0.15s ease;
}

.masthead .mh-visit-hours .btn-ticket i,
.masthead .ticket-button .btn-ticket i {
  color: inherit !important;
  font-size: 0.95em;
}

.masthead .mh-visit-hours .btn-ticket:hover,
.masthead .mh-visit-hours .btn-ticket:focus-visible,
.masthead .ticket-button .btn-ticket:hover,
.masthead .ticket-button .btn-ticket:focus-visible {
  background: var(--visit-cta-gold-hover) !important;
  border-color: var(--visit-cta-gold-hover) !important;
  color: var(--visit-cta-text) !important;
  box-shadow:
    0 3px 0 rgba(0, 0, 0, 0.14),
    0 5px 14px rgba(212, 175, 90, 0.38);
  transform: translateY(-1px);
}

.masthead .mh-visit-hours .btn-ticket:active,
.masthead .ticket-button .btn-ticket:active {
  background: var(--visit-cta-bg-active) !important;
  border-color: var(--visit-cta-gold) !important;
  color: var(--visit-cta-text) !important;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.22);
  transform: translateY(0);
}

.masthead .mh-visit-hours .btn-ticket:focus,
.masthead .ticket-button .btn-ticket:focus {
  outline: none;
}

.masthead .mh-visit-hours .btn-ticket:focus-visible,
.masthead .ticket-button .btn-ticket:focus-visible {
  outline: 3px solid var(--visit-cta-focus-ring);
  outline-offset: 2px;
}

@media (max-width: 767.98px) {
  .masthead .header-hijri-date,
  .masthead .header-gregorian-date,
  .masthead .mh-prayer-times__hijri,
  .masthead .mh-prayer-times__gregorian {
    text-align: left !important;
  }
}

@media (max-width: 991.98px) {
  .masthead .mh-prayer-times {
    text-align: left;
    min-width: 0;
    max-width: 100%;
  }

  .masthead .mh-visit-hours,
  .masthead .visit-hours {
    text-align: right;
    min-width: 0;
    max-width: 100%;
  }

  .masthead .mh-prayer-times__list,
  .masthead .prayer-times-list,
  .masthead .mh-prayer-times__dates,
  .masthead .header-dates {
    width: 100%;
    max-width: 100%;
    margin-inline: 0;
    margin-inline-end: auto;
  }

  .masthead .mh-prayer-times__dates,
  .masthead .header-dates {
    display: block !important;
    margin-top: 8px;
    text-align: left;
  }

  .masthead .mh-prayer-times .prayer-hijri-date,
  .masthead .mh-prayer-times .header-hijri-date,
  .masthead .mh-prayer-times__hijri,
  .masthead .mh-prayer-times__gregorian,
  .masthead .mh-prayer-times .prayer-gregorian-date,
  .masthead .mh-prayer-times .header-gregorian-date,
  .header-hijri-date,
  .header-gregorian-date {
    display: block !important;
    width: 100%;
    text-align: left !important;
    font-size: 12px;
    line-height: 1.45;
    white-space: normal;
  }

  .masthead .mh-prayer-times__dates .header-hijri-date,
  .masthead .mh-prayer-times__dates .mh-prayer-times__hijri {
    margin-top: 0;
  }

  .masthead .mh-prayer-times__dates .header-gregorian-date,
  .masthead .mh-prayer-times__dates .mh-prayer-times__gregorian {
    margin-top: 3px;
  }

  .masthead .mh-visit-hours,
  .masthead .visit-hours {
    margin-top: 0 !important;
    padding-top: 0 !important;
    align-self: start;
    line-height: 1.45;
  }

  .masthead .mh-visit-hours__title {
    margin-top: 0;
    padding-top: 0;
  }

  .masthead .mh-prayer-times__row,
  .masthead .prayer-row {
    display: grid;
    grid-template-columns: minmax(70px, auto) auto;
    column-gap: 12px;
    direction: ltr;
    width: fit-content;
    max-width: 100%;
    font-size: 0.72rem;
    align-items: center;
  }

  .masthead .mh-prayer-times__name,
  .masthead .prayer-name {
    min-width: 0;
    white-space: nowrap;
    justify-self: start;
    text-align: left;
    direction: auto;
    overflow: visible;
    text-overflow: unset;
  }

  .masthead .mh-prayer-times__time,
  .masthead .prayer-time {
    min-width: 0;
    text-align: right;
    direction: ltr;
    white-space: nowrap;
    justify-self: end;
  }

  .masthead .mh-visit-hours__body {
    line-height: 2.4;
  }

  .masthead .mh-visit-hours .ticket-button,
  .masthead .mh-visit-hours .reservation-button {
    width: 100%;
    max-width: 220px;
    margin: 14px auto 0;
  }

  .masthead .mh-visit-hours .ticket-button .btn-ticket,
  .masthead .mh-visit-hours .reservation-button .btn-ticket {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    min-height: 2.75rem;
    margin-top: 0 !important;
    padding: 0.65rem 1rem !important;
    font-size: 0.62rem !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .masthead .mh-visit-hours .btn-ticket,
  .masthead .ticket-button .btn-ticket {
    transition: background 0.01s, border-color 0.01s, color 0.01s;
  }

  .masthead .mh-visit-hours .btn-ticket:hover,
  .masthead .mh-visit-hours .btn-ticket:active,
  .masthead .ticket-button .btn-ticket:hover,
  .masthead .ticket-button .btn-ticket:active {
    transform: none;
  }
}

@media (max-width: 374px) {
  .masthead .mh-prayer-times__row,
  .masthead .prayer-row {
    font-size: 0.66rem;
    column-gap: 12px;
  }
}
