/* =========================
   Base Styles (Jain Theme)
========================= */
body {
  margin: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  background: #fffdf8;
  color: #3a2d0c;
  line-height: 1.6;
  position: relative;
}

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

a {
  transition: color 0.3s, transform 0.2s;
}

/* =========================
   Top Mantra Banner
========================= */
.mantra-banner {
  text-align: center;
  font-weight: 600;
  font-size: 0.9rem;
  /* desktop */
  padding: 4px 10px;
  /* spacing inside banner */
  margin: 0;
  /* flush with top */
  background: linear-gradient(135deg, #fff6e0, #f7e3aa);
  /* same as header */
  color: #7c4500;
  font-family: "Noto Sans Devanagari", "Segoe UI", Arial, sans-serif;
  text-shadow: 0 0 3px #f1d179;
  word-wrap: break-word;
}

/* =========================
   Header
========================= */
header {
  background: linear-gradient(135deg, #fff6e0, #f7e3aa);
  color: #5a2e00;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  padding: 12px 1rem 20px;
  /* space between mantra and header content */
}

.header-content {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
  text-align: center;
}

/* Logo styling */
.header-content .logo {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #c19700;
  flex-shrink: 0;
  margin-top: 5px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: width 0.3s, height 0.3s;
}

.header-text h1 {
  margin: 0;
  font-size: 2.3rem;
  color: #7c4500;
  text-shadow: 1px 1px #f1d179;
}

.header-text .tagline {
  margin-top: 0.4rem;
  font-style: italic;
  font-size: 1.05rem;
  color: #5f3900;
}

/* =========================
   Responsive
========================= */
@media (max-width: 768px) {
  .mantra-banner {
    font-size: 0.85rem;
    padding: 3px 8px;
  }

  .header-content .logo {
    width: 70px;
    height: 70px;
  }

  header h1 {
    font-size: 1.9rem;
  }
}

@media (max-width: 480px) {
  .mantra-banner {
    font-size: 0.8rem;
    padding: 2px 6px;
    line-height: 1.3;
  }

  .header-content .logo {
    width: 60px;
    height: 60px;
  }

  header h1 {
    font-size: 1.6rem;
  }
}

/* =========================
   Navigation
========================= */
nav.main-nav {
  background: #a53f2b;
  display: flex;
  justify-content: center;
  gap: 2rem;
  padding: 0.8rem;
  flex-wrap: wrap;
}

nav a {
  text-decoration: none;
  color: #fffdf8;
  font-weight: bold;
  font-size: 1rem;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
}

nav a:hover,
nav a:focus {
  background: #c94d35;
  color: #fff;
  transform: translateY(-2px);
}

nav a[aria-current="page"] {
  background: #7a291c;
  color: #fff;
}

/* =========================
   Sections & Cards
========================= */
section {
  max-width: 1000px;
  margin: 2rem auto;
  padding: 1rem;
}

/* Intro card styling with watermark */
.intro-card {
  background: #fffdf3;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
  border-left: 6px solid #a53f2b;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.06);
  position: relative;
  overflow: hidden;
}

.intro-card::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 200px;
  height: 200px;
  background-image: url('images/watermark.png');
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  opacity: 0.3;
  /* darker watermark */
  transform: translate(-50%, -50%);
  pointer-events: none;
}


/* Member card styling */
.member-card {
  background: #fffdf3;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
  border-left: 6px solid #a53f2b;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.06);
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 10px 20px;
}

.member-card p {
  margin: 5px 0;
  display: contents;
}

.member-card p strong {
  grid-column: 1;
  color: #7a291c;
  white-space: nowrap;
}

.member-card p span {
  grid-column: 2;
  word-wrap: break-word;
}

/* =========================
   Headings
========================= */
h2 {
  color: #a53f2b;
  border-bottom: 2px solid #f1d179;
  padding-bottom: 0.3rem;
  margin-bottom: 1rem;
  font-size: 1.6rem;
}

ul {
  list-style: none;
  padding: 0;
}

ul li {
  position: relative;
  padding-left: 1.4em;
  margin-bottom: 0.6rem;
}

ul li::before {
  content: "🪷";
  position: absolute;
  left: 0;
  top: 0;
  font-size: 1.1rem;
  color: #c19700;
}

.center {
  text-align: center;
}

/* =========================
   Table Styling
========================= */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
}

th,
td {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: left;
}

th {
  background-color: #f6e7b4;
  color: #5a2e00;
}

tr:nth-child(even) {
  background: #faf7ef;
}

.member-link {
  color: #007bff;
  text-decoration: none;
}

.member-link:hover,
.member-link:focus {
  text-decoration: underline;
  color: #0056b3;
}

/* =========================
   Footer
========================= */
footer {
  background: linear-gradient(135deg, #f7e3aa, #fff6e0);
  text-align: center;
  padding: 1.8rem 1rem;
  font-size: 0.9rem;
  color: #5a3c00;
  border-top: 3px solid #a53f2b;
}

footer span strong {
  color: #7a291c;
}

footer .social-icons {
  margin-top: 12px;
  display: flex;
  justify-content: center;
  gap: 14px;
}

footer .social-icons a img {
  width: 28px;
  height: 28px;
  transition: transform 0.3s, filter 0.3s;
}

footer .social-icons a img:hover,
footer .social-icons a img:focus {
  transform: scale(1.25);
  filter: brightness(1.2);
}

/* Highlight */
mark {
  background-color: #f9ed69;
  padding: 0 4px;
  border-radius: 3px;
}

/* =========================
   Responsive
========================= */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    align-items: center;
    /* center logo and text */
    gap: 10px;
  }

  .header-text {
    text-align: center;
  }

  header h1 {
    font-size: 1.9rem;
  }

  nav.main-nav {
    flex-direction: column;
    gap: 0.8rem;
  }

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

  .member-card p strong,
  .member-card p span {
    grid-column: 1;
  }
}

@media (max-width: 480px) {
  footer {
    font-size: 0.85rem;
    padding: 1rem 0.5rem;
  }

  footer .social-icons {
    flex-wrap: wrap;
    gap: 15px;
  }

  footer .social-icons a img {
    width: 28px;
    height: 28px;
  }
}

/* =========================
   Events List Styling
========================= */
.events-list li {
  position: relative;
  padding-left: 2em;
  /* more space for the icon */
  margin-bottom: 0.8rem;
  font-weight: 500;
}

.events-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 1.5em;
  /* size of the icon */
  height: 1.5em;
  background: url('images/icons/calendar.svg') no-repeat center;
  background-size: contain;
}


/* =========================
   Features List Styling
========================= */
.features-list li::before {
  content: "📚";
  position: absolute;
  left: 0;
  top: 0;
  font-size: 1.2rem;
  color: #a53f2b;
}

/* =========================
   Pathshala Schedule Table
========================= */
.schedule-table {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
  background: #fffdf3;
}

.schedule-table th {
  background: #f1d179;
  color: #5a2e00;
  font-weight: 600;
  text-align: left;
}

.schedule-table td {
  background: #fffdf3;
}

/* =========================
   Responsive Member Table (Mobile Fix)
   — Added enhancement (non-destructive)
========================= */

@media (max-width: 768px) {

  /* Make table elements behave as stacked cards */
  table,
  thead,
  tbody,
  th,
  td,
  tr {
    display: block;
  }

  thead {
    display: none;
    /* Hide header row */
  }

  tr {
    margin-bottom: 1rem;
    background: #fffdf3;
    border: 1px solid #f1d179;
    border-radius: 10px;
    padding: 0.6rem 0.8rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
  }

  td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.4rem 0;
    border: none;
    border-bottom: 1px solid #f9efc4;
    font-size: 0.95rem;
  }

  td:last-child {
    border-bottom: none;
  }

  td::before {
    content: attr(data-label);
    font-weight: 600;
    color: #7a291c;
    text-transform: capitalize;
    margin-right: 0.6rem;
  }

  /* Make mark highlight look natural */
  mark {
    background: #f9ed69;
    border-radius: 3px;
    padding: 0 3px;
  }

  /* Adjust font size for small screens */
  @media (max-width: 480px) {
    td {
      font-size: 0.9rem;
      flex-direction: column;
      align-items: flex-start;
    }

    td::before {
      margin-bottom: 0.2rem;
    }
  }
}