/*This font is used on the body of the webpage*/
.merriweather {
  font-family: "Merriweather", serif;
  font-optical-sizing: auto;
  font-weight: 200, 400, 600, 800;
  font-style: normal;
  font-variation-settings:
    "wdth" 100;
}

/*This font is used on the headers of the webpage*/
.atkinson-hyperlegible-regular {
  font-family: "Atkinson Hyperlegible", sans-serif;
  font-weight: 400;
  font-style: normal;
}

.atkinson-hyperlegible-bold {
  font-family: "Atkinson Hyperlegible", sans-serif;
  font-weight: 700;
  font-style: normal;
}

.atkinson-hyperlegible-regular-italic {
  font-family: "Atkinson Hyperlegible", sans-serif;
  font-weight: 400;
  font-style: italic;
}

.atkinson-hyperlegible-bold-italic {
  font-family: "Atkinson Hyperlegible", sans-serif;
  font-weight: 700;
  font-style: italic;
}

/*Root to the webpage*/
:root {
  /* Primary & Accent Palette */
  --color-primary: #1e293b;        /* Deep Slate Navy — high contrast, authoritative yet warm */
  --color-primary-hover: #0f172a;  /* Slightly darker blue for active states */
  --color-accent: #c27803;         /* Warm Amber/Gold — inviting, high-contrast accent */
  --color-accent-hover: #a16207;   /* Darker Gold for hover states */

  /* Surface & Background Colors */
  --bg-page: #fafaf9;              /* Warm Off-White — soft on elderly eyes, avoids harsh screen glare */
  --bg-card: #ffffff;              /* Pure White for card container contrast */
  --bg-subtle: #f1f5f9;            /* Cool Light Grey for controls & secondary elements */
  --bg-subtle-hover: #e2e8f0;      /* Slightly darker grey for player hover states */

  /* Text & Typography (Ensures 7:1+ contrast ratios for readability) */
  --text-main: #0f172a;            /* Almost Black — clear readability for vision impairments */
  --text-muted: #475569;           /* Dark Slate — soft secondary text that stays legible */
  --text-inverse: #ffffff;         /* Light text for dark backgrounds */

  /* Borders & Shadows */
  --border-card: #e2e8f0;          /* Soft border to define boundaries clearly */
  --shadow-card: 0 4px 12px rgba(15, 23, 42, 0.06); /* Soft elevation */

  /* clamp(MIN, PREFERRED, MAX) */
  --fs-h1: clamp(2rem, 4vw + 1rem, 3.5rem);
  --fs-h2: clamp(1.75rem, 3vw + 1rem, 2.75rem);
  --fs-h3: clamp(1.5rem, 2vw + 0.8rem, 2.25rem);
  --fs-h4: clamp(1.25rem, 1vw + 0.8rem, 1.75rem);
  
  --p-important: 1.2em;
  --p-text: 1.15em;
  --p-prayer: 0.95em;
  --p-bible: 1em;
}

/* Applying the custom properties to headings */
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
h4 { font-size: var(--fs-h4); }

h1, h2, h3, h4{
  text-align: center;
}

h1, h2{
  font-family: Atkinson Hyperlegible;
  font-weight: 700;
}

h3, h4{
  font-weight: 300;
}

/*CSS Basics*/
*{
 margin: 0; 
 padding: 0;
 box-sizing: border-box;
}

html{
  scroll-behavior: smooth;
}

body{
  background: var(--bg-page);
  font-family: Merriweather;
}

section{
  border-bottom: 1px solid black;
  padding: 15px 5px;
}

p{
  padding: 10px 0;
}

ul.social-icons{
  display: flex;
  justify-content: center; /* Horizontally centers the icons */
  align-items: center;     /* Vertically centers the icons */
  gap: 10px;               /* Adds space between the icons */
  list-style: none;
  margin-bottom: 10px;
}

ol{
  padding: 0 45px;
}

ol li{
  padding: 5px 0;
  line-height: 25px;
}

/*ID naming and behavoir*/
#center-me{
  text-align: center;
}

#small-letters{
  font-size: .6em;
}

#red{
  color: red;
}

/*Different Headers to Webpage*/
h1.header{
  color: var(--color-primary);
  font-size: clamp(2.5em, 4vw, 1.5em);
}

h2.sub-header{
  color: var(--color-primary-hover);
  font-size: clamp(1.5em, 2vw, 1em);
}

.parent-container {
  display: flex;
  justify-content: center; /* Centers horizontally */
  align-items: center;     /* Centers vertically (if parent has height) */
}

/*Navigation Bar Section*/
.nav-toggle-btn {
  display: inline-flex;
  align-items: center;     /* Centers vertically (if parent has height) */
  gap: 0.5rem;
  padding: 0.6em 1.2em;
  font-size: 1em;
  font-weight: 900;
  color: var(--text-inverse);
  background-color: var(--color-accent);
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.nav-toggle-btn:hover {
  background-color: var(--color-accent-hover);
}

/* Overlay Background */
.nav-overlay {
  position: fixed;
  inset: 0;
  background-color: inherit;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 10;
}

.nav-overlay.is-active {
  opacity: 1;
  visibility: visible;
}

/* Sliding Navigation Drawer */
.side-nav {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: 100%; /* Default width for Mobile */
  max-width: 100%;
  background-color: var(--bg-card);
  color: var(--text-color);
  transform: translateX(-100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 10;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.side-nav.is-open {
  transform: translateX(0);
}

/* Nav Header & Close Button */
.nav-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1em;
}

.nav-logo {
  font-size: 2em;
  font-weight: 700;
}

.close-btn {
  background: none;
  border: none;
  color: var(--text-main);
  font-size: 2em;
  line-height: 1;
  cursor: pointer;
  padding: 0.2em 0.5em;
}

.close-btn:hover {
  color: var(--color-accent-hover);
}

/* Navigation List */
.nav-list {
  list-style: none;
  padding: 1em 0;
  text-align: center;
}

.nav-link {
  display: inline-block;
  padding: 0.85em 1.5em;
  color: var(--color-primary);
  text-decoration: none;
  font-size: 1em;
  transition: background-color 0.2s, color 0.2s;
}

.nav-link:hover {
  background-color: var(--bg-subtle);
  color: var(--color-accent);
  box-shadow: --shadow-card;
  width: 100%;
}

/*Index.html css code*/
header a{
  text-decoration: none;
}

h2.main-header{
  color: var(--color-accent);
  font-size: var(--fs-h3);
  margin-bottom: 15px;
}

p.main-text{
  padding: 20px;
  color: red;
}

p.main-sub-header{
  padding: 15px;
  font-size: var(--p-prayer);
}

p.main-about{
  padding: 30px 15px;
  color: var(--color-accent);
  line-height: 2.5;
}

.act-article{
  text-align: center;
}

.act-buttons{
  display: flex;
  flex-direction: column;
  gap: 10px;
}


button{
  padding: 12px 16px;
  background: var(--color-accent);
  color: var(--text-inverse);
  border: none;
  border-radius: 5px;
  font-weight: 900;
}

a button:hover{
  background: var(--color-accent-hover);
  color: var(--text-inverse);
  box-shadow: --shadow-card;
}

.uitreike-sub p{
  padding-left: 50px;
  padding-right: 50px;
}

.colins-house, .abraham-kriel-bermuda{
  margin: 0 30px;
}

.kriel-grid, .colins-grid, .vroue-bybelstudies-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
}

#laerskool-grid{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 10px;
}

.download-card{
  background: var(--bg-card);
  border-radius: 5px;
  height: 100px;
  align-content: center;
  display: flex;
  justify-content: center; /* Centers horizontally */
  align-items: center;     /* Centers vertically (if container has height)
  */
  flex-direction: column;
}

.card-title{
  font-size: 1em;
}

.download-card a{
  padding: 10px;
  font-size: 1.5em;
}

/*Images of the webpage section*/
.logo-image, .bank-details img{
    width: 300px;
    display: block;
    margin: 0 auto;
}

.genesis img{
  width: 300px;
  border-radius: 25px;
  padding: 10px 0;
  display: inline-block;
  margin: 0 auto;
}

.uitreike-images, .aktiwiteite-image{
  width: 300px;
  border-radius: 25px;
  display: block;
  margin: 0 auto;
  padding: 10px 0;
}

/*Flexbox Card with Images and description*/
/* Container to hold cards next to each other */
.card-container {
  display: flex;
  gap: 10px; /* Space between cards */
  flex-wrap: wrap; /* Allows cards to stack on smaller screens */
  justify-content: center;
}

/* Individual card styling */
.card {
  flex: 1 1 300px; /* Flex-grow, flex-shrink, and base width */
  max-width: 350px;
  border: 1px solid var(--bg-card);
  border-radius: 5px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  background-color: var(--bg-subtle);
}

/* Image formatting */
.card-image {
  width: 100%;
  height: 200px;
  object-fit: cover; /* Keeps image proportions intact */
  display: block;
}

/* Description area underneath the image */
.card-content {
  padding: 16px;
}

.card-content h3 {
  margin-top: 0;
  margin-bottom: 5px;
  font-size: 1.25em;
  color: var(--text-main);
}

.card-content p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.4;
}


/*Tabel content and layout structure for tables*/
/* Container for responsive scrolling on small screens */
.table-container {
  width: 100%;
  overflow-x: auto;
  margin: 1.5rem 0;
}

/* Base table layout */
.custom-table {
  width: 100%;
  border-collapse: collapse;
  font-family: inherit;
  font-size: 1rem;
  text-align: left;
  background-color: #ffffff;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  overflow: hidden;
}

/* Header styling */
.custom-table thead tr {
  background-color: #1e293b;
  color: #ffffff;
  font-weight: 600;
}

.custom-table th,
.custom-table td {
  padding: 12px 16px;
  border-bottom: 1px solid #e2e8f0;
}

/* Alternating row colors for readability */
.custom-table tbody tr:nth-of-type(even) {
  background-color: #f8fafc;
}

/* Hover effect on rows */
.custom-table tbody tr:hover {
  background-color: #f1f5f9;
  transition: background-color 0.2s ease;
  box-shadow: --shadow-card;
}

.custom-table td:first-child{
  font-weight: 700;
}

/*Psalm Section*/
.psalm-book p{
  padding: 5px 0;
}

/*Audio Files and Player*/
.preke-audio{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 10px;
}

/* Card Container */
.sermon-card {
  max-width: 350px;
  background-color: var(--bg-card);
  border-radius: 12px;
  padding: 24px; /* Generous touch target & spacing */
  margin: 0 10px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-card);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.sermon-card:hover {
  transform: translateY(-2px);
  box-shadow: --shadow-card;
}

/* Header Layout */
.sermon-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.sermon-date {
  font-size: 0.8125rem; /* ~13px minimum for readability */
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-accent); /* Amber accent tag */
}

.sermon-title {
  margin: 0;
  font-size: 1.25rem; /* ~20px for high visibility */
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.35;
}

.sermon-speaker {
  margin: 0;
  font-size: 0.9375rem; /* ~15px */
  color: var(--text-muted);
}

/* Audio Player & Download Row */
.sermon-player-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

a.player-link{
  text-align: center;
  font-weight: 700;
  color: var(--text-inverse);
  text-decoration: none;
}

/*Preke Pages and sections
/* Container Layout */
.preke-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin: 0 auto;
  padding: 10px;
}

preke-audio

/* Base Card Structure */
.preke-card {
  position: relative;
  background-color: var(--bg-page);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Image Header */
.preke-image-wrapper {
  width: 100%;
  height: 200px;
  overflow: hidden;
}

.preke-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Content Box overlapping the image bottom */
.preke-content {
  position: relative;
  margin-top: -30px;
  margin-left: 24px;
  margin-right: 24px;
  margin-bottom: 24px;
  background-color: var(--bg-card);
  padding: 20px;
  border-radius: 4px;
  box-sizing: border-box;
}

/* Typography & Button */
.preke-title {
  margin: 0 0 10px 0;
  font-size: 1.25em;
  font-weight: 700;
  color: var(--text-main);
}

.preke-description {
  margin: 0 0 20px 0;
  font-size: 0.95em;
  line-height: 1.4;
  color: var(--text-muted);
}

.preke-button {
  display: inline-block;
  background-color: var(--color-accent);
  color: var(--text-inverse);
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-size: 0.9em;
  font-weight: 600;
  transition: background-color 0.2s ease;
}

.preke-button:hover {
  background-color: var(--color-accent-hover);
  box-shadow: --shadow-card;
}

.image-gallery img{
  width: 200px;
}

main.voorskool{
  text-align: center;
}

p.voorskool-para{
  padding: 10px 30px;
}

h3.voorskool-sub{
  padding-top: 20px;
}

/* Responsive Grid Layout */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: .5rem;
  max-width: 1200px;
  margin: 0 auto;
}

.gallery-item {
  overflow: hidden;
  border-radius: 8px;
  cursor: pointer;
  background-color: var(--bg-subtle-hover);
}

.gallery-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.gallery-item:hover img {
  transform: scale(1.05);
  opacity: 0.9;
  box-shadow: --shadow-card;
}

/* Lightbox Styles */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 1000;
  padding: 2rem;
}

.lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Close Button */
.close-btn {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 2.5rem;
  color: #ffffff;
  background: none;
  border: none;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s ease, transform 0.2s ease;
}

.close-btn:hover {
  color: var(--color-accent);
  transform: scale(1.1);
}

.openbaring{
  text-align: center;
}

.openbaring .download-card, .audio-player-card{
  max-width: 100%;
  font-size: var(--fs-h4);
}

.openbaring b{
  font-size: 30px;
  display: inline-block;
  padding: 40px 0  20px 0;
}

/*Video Player*/
video{
  width: 100%;
  height: 480px;
}

/* Card Container */
.audio-player-card {
  width: 100%;
  background: var(--bg-card);
  border-radius: 5px;
  padding: 12px;
  box-shadow: var(--shadow-card);
  box-sizing: border-box;
}

/* Header / Title Section */
.player-header {
  margin-bottom: 20px;
  text-align: center;
}

.track-title {
  margin: 0 0 4px 0;
  font-size: 1.25rem;
  color: var(--color-primary);
  font-weight: 700;
  line-height: 1.3;
}

/* Audio Player Section */
.player-body audio {
  width: 100%;
  height: 50px;
  border-radius: 8px;
  outline: none;
}

/*Footer Style*/
/* Footer Styles */
.site-footer {
  background-color: var(--text-main);
  color: #e2e8f0;
  padding: 2em 1.5em 1.5em;
  font-family: Atkinson Hyperlegible;
  line-height: 1.1;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1.5em;
}

/* Brand Section */
.footer-logo {
  color: var(--bg-card);
  font-size: 1.2em;
  font-weight: 700;
  margin: 0 0 0.25em 0;
}

.footer-subtitle {
  color: var(--bg-subtle);
  font-size: 0.9rem;
  margin: 0 0 1rem 0;
}

.footer-motto {
  font-size: 0.8em;
  color: var(--bg-subtle-hover);
  margin-bottom: 1em;
}

.service-time {
  font-size: 0.9rem;
  color: var(--bg-card);
}

/* Headings */
.footer-heading {
  color: var(--bg-card);
  font-size: 1em;
  font-weight: 600;
  margin: 0 0 1em 0;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* Links List */
.footer-links,
.footer-contact {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.6em;
}

.footer-links a {
  color: var(--bg-subtle);
  text-decoration: none;
  transition: color 0.2s ease-in-out, padding-top 0.2s ease-in-out;
}

.footer-links a:hover,
.footer-links a:focus {
  color: var(--color-accent);
  padding-top: 4px;
}

/* Contact Info */
.footer-contact li {
  margin-bottom: 0.7em;
  font-size: 0.95rem;
  color: var(--bg-subtle);
}

.footer-contact a {
  color: var(--bg-subtle-hover);
  text-decoration: none;
  transition: color 0.2s ease-in-out;
}

.footer-contact a:hover {
  text-decoration: underline;
  color: var(--color-accent-hover);
}

/* Social Icons */
.social-links {
  display: flex;
  gap: 0.7em;
}

/* Bottom Bar */
.footer-bottom {
  max-width: 1200px;
  margin: 3rem auto 0;
  padding-top: 1.5rem;
  border-top: 1px solid var(--bg-subtle-hover);
  text-align: center;
  font-size: 0.8em;
  color: whitesmoke;
}

/*Media Qeuries*/
@media (min-width: 300px) {
  .sermon-card {
    max-width: 100%;
  }
  
  .act-buttons{
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
  }
}

/* Responsive Desktop/Tablet Rule */
@media (min-width: 600px) {
  .side-nav {
    width: 350px; /* 350px width on Desktop/Tablet */
  }
}

/* Responsive Grid Breakpoints */
@media (min-width: 640px) {
  .footer-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .footer-container {
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
  }
}