
/* St. Mary's Church, Vakayar — static Firebase Hosting stylesheet */

/* ========================================
   1. CSS Variables and Global Styles
   ======================================== */

:root {
    --primary: #174b3a;
    --primary-dark: #10382c;
    --gold: #c99a3b;
    --ink: #202b27;
    --muted: #66736d;
    --paper: #f7f7f2;
    --white: #fff;
    --border: #e2e7e2;
    --radius: 16px;
    --shadow: 0 8px 28px rgba(25, 45, 35, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    font: 16px/1.65 system-ui, -apple-system, "Segoe UI", sans-serif;
}

img,
iframe {
    max-width: 100%;
}

img {
    display: block;
}

a {
    color: var(--primary);
    text-decoration: none;
}

a:hover {
    color: var(--gold);
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1,
h2,
h3 {
    line-height: 1.2;
}

h2 {
    font-size: clamp(1.7rem, 3vw, 2.4rem);
}

em {
    color: var(--gold);
}

button {
    font: inherit;
    cursor: pointer;
}

:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 3px;
}

/* ========================================
   2. Sections and Buttons
   ======================================== */

.section {
    width: min(1120px, calc(100% - 40px));
    margin: 0 auto;
    padding: 76px 0;
}

.section-narrow {
    width: min(1120px, calc(100% - 40px));
    margin: 30px auto 0;
}

.eyebrow,
.section-kicker {
    color: var(--gold);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.13em;
    margin-bottom: 12px;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border: 0;
    border-radius: 999px;
    background: var(--primary);
    color: var(--white);
    font-weight: 700;
    transition: background 0.2s ease, transform 0.2s ease;
}

.button:hover {
    background: var(--primary-dark);
    color: var(--white);
    transform: translateY(-1px);
}

.button-light {
    background: var(--white);
    color: var(--primary);
}

.button-light:hover {
    background: #f1e7d1;
    color: var(--primary-dark);
}

.text-link {
    font-weight: 700;
}

.text-link span {
    color: var(--gold);
}

/* ========================================
   3. Header and Navigation
   ======================================== */

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px max(20px, calc((100% - 1120px) / 2));
    background: var(--white);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 12px rgba(30, 41, 59, 0.06);
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--primary);
    line-height: 1.25;
}

.brand strong,
.brand small {
    display: block;
}

.brand strong {
    font-size: 1.05rem;
}

.brand small {
    color: var(--muted);
    font-size: 0.78rem;
	min-width: 15rem;
}

.brand-mark {
    flex: 0 0 42px;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #f5eddc;
    color: var(--gold);
    font-size: 1.4rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 22px;
}

.nav-links a {
    color: var(--ink);
    font-size: 0.92rem;
    font-weight: 650;
}

.nav-links a:hover {
    color: var(--gold);
}

.nav-toggle {
    display: none;
    border: 1px solid var(--border);
    border-radius: 9px;
    padding: 7px 11px;
    background: var(--white);
    color: var(--primary);
}

/* ========================================
   4. Hero Section
   Single full-width image with white text
   ======================================== */

.hero {
    position: relative;
    isolation: isolate;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: #102d25;
    color: var(--white);
}

.hero-background {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center 48%;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: linear-gradient(
        90deg,
        rgba(8, 27, 22, 0.91) 0%,
        rgba(8, 27, 22, 0.82) 24%,
        rgba(8, 27, 22, 0.58) 43%,
        rgba(8, 27, 22, 0.20) 68%,
        rgba(8, 27, 22, 0.05) 100%
    );
}

.hero-copy {
    position: relative;
    z-index: 1;
    width: min(100%, 600px);
    color: var(--white);
}

.hero-copy .eyebrow {
    color: #f1d58b;
}

.hero h1 {
    max-width: 620px;
    margin-bottom: 18px;
    color: var(--white);
    font-size: clamp(2.45rem, 5vw, 4.25rem);
    line-height: 1.08;
}

.hero-copy > p:not(.eyebrow) {
    max-width: 560px;
    margin-bottom: 26px;
    color: rgba(255, 255, 255, 0.96);
    font-size: clamp(1rem, 1.5vw, 1.12rem);
    line-height: 1.8;
}

.hero-copy .button {
    background: #f5eddc;
    color: var(--primary-dark);
}

.hero-copy .button:hover {
    background: var(--white);
    color: var(--primary-dark);
}

.art-caption {
    position: absolute;
    z-index: 1;
    right: max(22px, calc((100% - 1120px) / 2));
    bottom: 22px;
    padding: 10px 16px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    background: rgba(16, 56, 44, 0.78);
    color: var(--white);
    font-size: 0.9rem;
    font-weight: 700;
    backdrop-filter: blur(6px);
}

/* ========================================
   5. Announcements
   ======================================== */

.alert-grid,
.mass-grid,
.news-grid,
.priest-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 22px;
}

.alert-grid {
    margin-top: 14px;
}

.alert-card,
.mass-card,
.news-card,
.priest-card,
.location-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.alert-card {
    display: flex;
    gap: 14px;
    padding: 20px;
}

.alert-card h3 {
    margin-bottom: 8px;
    font-size: 1.05rem;
}

.alert-card p {
    margin-bottom: 0;
    color: var(--muted);
}

.alert-icon,
.mass-symbol {
    color: var(--gold);
    font-size: 1.5rem;
}

/* ========================================
   6. About Section
   ======================================== */

.intro {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    align-items: center;
    gap: 54px;
}

.intro-image {
    min-height: 350px;
    display: grid;
    place-items: center;
    position: relative;
    border-radius: var(--radius);
}

.image-cross {
    color: var(--gold);
    font-size: 7rem;
}

.image-label {
    position: absolute;
    bottom: 5px;
    font-weight: 700;
    color: var(--primary);
}

.intro-copy p:not(.eyebrow) {
    color: var(--muted);
}

/* ========================================
   7. Mass Timings, News and Priests
   ======================================== */

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 28px;
    margin-bottom: 28px;
}

.section-heading > p {
    max-width: 440px;
    margin-bottom: 4px;
    color: var(--muted);
}

.mass-card,
.priest-card {
    padding: 24px;
}

.mass-time {
    color: var(--primary);
    font-weight: 800;
}

.mass-card p:last-child {
    margin-bottom: 0;
    color: var(--muted);
}

.news-image {
    display: grid;
    place-items: center;
    background: #e9eee7;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-image-symbol span {
    color: var(--gold);
    font-size: 4rem;
}

.news-content {
    padding: 22px;
}

.news-content h3 {
    margin-bottom: 10px;
}

.news-content > p:not(.eyebrow) {
    color: var(--muted);
}

.priest-card {
    text-align: center;
}

.priest-avatar {
    width: 110px;
    height: 110px;
    margin: 0 auto 18px;
    overflow: hidden;
    border-radius: 50%;
    background: #e9eee7;
    display: grid;
    place-items: center;
    color: var(--gold);
    font-size: 2.5rem;
}

.priest-card p,
.priest-card small {
    color: var(--muted);
}

.priest-card p {
    margin-bottom: 8px;
}

/* ========================================
   8. Visit Call-to-Action
   ======================================== */

.visit-cta {
    padding: 70px 20px;
    text-align: center;
    background: var(--primary);
    color: var(--white);
}

.visit-cta h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    color: var(--white);
}

.visit-cta .eyebrow {
    color: #e9c878;
}

/* ========================================
   9. Location and Map
   ======================================== */

.location-heading {
    text-align: center;
    max-width: 680px;
    margin: 0 auto 28px;
}

.location-heading > p:last-child {
    color: var(--muted);
}

.location-card {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
}

.location-map {
    min-height: 320px;
}

.location-map iframe {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 320px;
    border: 0;
}

.location-details {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 28px;
}

.location-icon {
    color: var(--gold);
    font-size: 2rem;
}

.location-copy {
    flex: 1;
    min-width: 0;
}

.location-copy h3 {
    margin-bottom: 8px;
}

.location-copy p {
    margin-bottom: 6px;
    color: var(--muted);
}

.location-coordinates {
    font-size: 0.85rem;
}

.location-button {
    flex-shrink: 0;
}

/* ========================================
   10. Footer
   ======================================== */

.footer {
    padding: 38px 20px;
    text-align: center;
    background: #102d24;
    color: #eaf0eb;
}

.footer-brand {
    color: var(--white);
    font-weight: 800;
}

.footer-brand:hover {
    color: #e9c878;
}

.footer p {
    margin: 12px 0;
}

/* ========================================
   11. Responsive Layout: Tablets
   ======================================== */

@media (max-width: 1000px) {
    .site-header {
        gap: 16px;
    }

    .nav-links {
        gap: 14px;
    }

    .nav-links a {
        font-size: 0.88rem;
    }

    .location-details {
        flex-wrap: wrap;
    }

    .location-button {
        flex-basis: 100%;
    }
}

/* ========================================
   12. Responsive Layout: Mobile
   ======================================== */

@media (max-width: 800px) {
    html {
        scroll-padding-top: 76px;
    }

    .site-header {
        flex-wrap: wrap;
        padding: 12px 20px;
    }

    .nav-toggle {
        display: block;
    }

    .nav-links {
        display: none;
        flex-basis: 100%;
        align-items: stretch;
        flex-direction: column;
        gap: 0;
        padding-top: 8px;
    }

    .nav-links.open {
        display: flex;
    }

    .nav-links a {
        padding: 11px 4px;
        border-top: 1px solid var(--border);
        font-size: 0.95rem;
    }

    .hero {
    }

    .hero-background {
        object-position: center;
    }

    .hero-overlay {
        background: linear-gradient(
            0deg,
            rgba(8, 27, 22, 0.94) 0%,
            rgba(8, 27, 22, 0.78) 45%,
            rgba(8, 27, 22, 0.35) 78%,
            rgba(8, 27, 22, 0.18) 100%
        );
    }

    .hero-copy {
        max-width: 620px;
    }

    .hero h1 {
        font-size: clamp(2.35rem, 7vw, 3.5rem);
    }

    .intro,
    .location-card {
        grid-template-columns: 1fr;
    }

    .intro-image {
        min-height: 260px;
    }

    .section-heading {
        display: block;
    }

    .section-heading > p {
        margin-top: 12px;
    }

    .location-details {
        flex-wrap: wrap;
    }

    .location-button {
        flex-basis: 100%;
    }
}

/* ========================================
   13. Responsive Layout: Small Phones
   ======================================== */

@media (max-width: 480px) {
    .section,
    .section-narrow {
        width: calc(100% - 28px);
    }

    .section {
        padding: 52px 0;
    }

    .section-narrow {
        margin-top: 24px;
    }

    .site-header {
        padding: 12px 14px;
        gap: 12px;
    }

    .brand {
        gap: 9px;
    }

    .brand-mark {
        flex-basis: 38px;
        width: 38px;
        height: 38px;
    }

    .brand small {
        max-width: 225px;
        font-size: 0.72rem;
    }

    .hero {
    }

    .hero h1 {
        font-size: clamp(2.15rem, 9vw, 2.8rem);
    }

    .hero-copy > p:not(.eyebrow) {
        line-height: 1.7;
    }

    .art-caption {
        right: 14px;
        bottom: 14px;
        font-size: 0.8rem;
    }

    .intro-image {
        min-height: 230px;
    }

    .location-details {
        padding: 22px;
    }

    .location-button {
        width: 100%;
    }
}

/* ========================================
   14. Accessibility: Reduced Motion
   ======================================== */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}

/* ========================================
   15. Desktop and Mobile Banners
   ======================================== */

.banner-desktop {
    display: block;
    width: 100%;
}

.banner-mobile {
    display: none;
    width: 100%;
}

/* On mobile screens 768px wide or less */

@media (max-width: 768px) {
    .banner-desktop {
        display: none;
    }

    .banner-mobile {
        display: block;
    }
}


/* Blog image with flowing text */
.blog-image {
  float: left;
  width: 280px;
  max-width: 45%;
  height: auto;
  margin: 0.4rem 1.25rem 1rem 0;
  border-radius: 8px;
  object-fit: cover;
}

/* Keep the intro content readable */
.intro-copy p {
  line-height: 1.8;
  text-align: justify;
}

/* Mobile layout */
@media (max-width: 600px) {
  .blog-image {
    width: 45%;
    max-width: 180px;
    margin: 0.3rem 1rem 0.6rem 0;
  }
}




/* ========================================
   Memories Carousel — Fade / Crossfade
   ======================================== */

.carousel {
  position: relative;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 12px;
}

.carousel-track {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 7;
  background: #f2f2f2;
  isolation: isolate;
}

/* Slides overlap so the images can crossfade */
.carousel-slide {
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 800ms ease-in-out,
    visibility 0s linear 800ms;
}

/* Active slide fades in */
.carousel-slide.active {
  z-index: 1;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition:
    opacity 800ms ease-in-out,
    visibility 0s linear 0s;
}

/* Keep outgoing and incoming images layered during fading */
.carousel-slide.active,
.carousel-slide:has(+ .carousel-slide.active) {
  /* No additional layout changes required */
}

.carousel-slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Previous and next buttons */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 50%;
  width: 42px;
  height: 42px;
  cursor: pointer;
  color: #fff;
  background: rgb(0 0 0 / 55%);
  transition: background 200ms ease;
}

.carousel-btn:hover {
  background: rgb(0 0 0 / 80%);
}

.carousel-prev {
  left: 12px;
}

.carousel-next {
  right: 12px;
}

/* Navigation dots */
.carousel-dots {
  position: absolute;
  bottom: 12px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 60px;
  z-index: 3;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  background: rgb(255 255 255 / 60%);
  transition:
    background 200ms ease,
    transform 200ms ease;
}

.carousel-dot.active {
  background: #fff;
  transform: scale(1.3);
}

/* Pause / play button */
.carousel-pause {
  top: auto;
  right: 12px;
  bottom: 9px;
  transform: none;
  width: 32px;
  height: 32px;
  font-size: 12px;
}

/* Mobile layout */
@media (max-width: 600px) {
  .carousel-track {
    aspect-ratio: 4 / 3;
  }

  .carousel-btn {
    width: 34px;
    height: 34px;
  }

  .carousel-pause {
    width: 30px;
    height: 30px;
    bottom: 7px;
  }

  .carousel-dots {
    gap: 5px;
    bottom: 8px;
    padding: 0 48px;
  }

  .carousel-dot {
    width: 6px;
    height: 6px;
  }
}

/* Accessibility: respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
  .carousel-slide,
  .carousel-slide.active,
  .carousel-btn,
  .carousel-dot {
    transition: none;
  }
}




/* Holy Qurbana & Mass Timings */
.mass-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2rem;
  align-items: stretch;
  margin-top: 1.5rem;
}

/* Left-side church image */
.mass-image {
  min-width: 0;
  min-height: 100%;
  overflow: hidden;
  border-radius: 14px;
  place-items: center;
}

.mass-image img {
  display: block;
  width: 60%;
  min-height: 400px;
  object-fit: cover;
  border-radius: inherit;
}

/* Right-side vertical cards */
.mass-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-content: stretch;
}

.mass-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  min-width: 0;
  border-radius: 12px;
}

/* Keep the icon and text aligned */
.mass-symbol {
  flex-shrink: 0;
  font-size: 1.8rem;
}

.mass-card-content h3 {
  margin: 0 0 0.4rem;
}

.mass-card-content .mass-time {
  margin: 0;
}

/* Tablet and mobile layout */
@media (max-width: 768px) {
  .mass-layout {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .mass-image img {
    height: auto;
	width: 100%;
    min-height: 33rem;
    max-height: 380px;
    aspect-ratio: 16 / 10;
  }

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

.carousel-pause {
  top: auto;
  right: 12px;
  bottom: 42px;
  transform: none;
  z-index: 4;
  font-size: 16px;
}

.brand-logo {
  display: block;
  width: 32px;
  height: 32px;
  object-fit: contain;
  flex-shrink: 0;
}


.footer-email {
  color: inherit;
  text-decoration: none;
}

.footer-email:hover {
  text-decoration: none;
}


/* Announcement cards: square image left, details right */

.alert-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.alert-card {
  display: flex;
  align-items: stretch;
  gap: 20px;
  padding: 18px;
  border-radius: 12px;
  overflow: hidden;
}

.alert-image {
  width: 160px;
  aspect-ratio: 1 / 1;
  height: 160px;
  flex: 0 0 160px;
  object-fit: cover;
  border-radius: 8px;
}

.alert-content {
  flex: 1;
  min-width: 0;
}

.alert-content h3 {
  margin: 0 0 12px;
}

.alert-content p {
  margin: 0 0 10px;
  line-height: 1.6;
}

.alert-content .alert-date {
  margin-top: 14px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* Mobile screens */
@media (max-width: 520px) {
  .alert-card {
    gap: 12px;
    padding: 12px;
  }

  .alert-image {
    width: 100px;
    height: 100px;
    flex-basis: 100px;
  }

  .alert-content h3 {
    font-size: 1rem;
  }

  .alert-content p {
    font-size: 0.9rem;
  }
}


/* Fixed WhatsApp floating icon */
.whatsapp-float {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 9999;

  width: 36px;
  height: 36px;
  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;

  background-color: #25D366;
  color: #ffffff;
  box-shadow: 0 4px 12px rgb(0 0 0 / 25%);

  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.whatsapp-float svg {
  width: 20px;
  height: 20px;
}

.whatsapp-float:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 16px rgb(0 0 0 / 30%);
}

@media (max-width: 600px) {
  .whatsapp-float {
    right: 16px;
    bottom: 16px;
    width: 36px;
    height: 36px;
  }

  .whatsapp-float svg {
    width: 20px;
    height: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .whatsapp-float {
    transition: none;
  }
}
