/*
 * Stylesheet for the traditional church website.
 * Provides layout, typography, navigation styling and the hero section
 * with a blurred background image overlaid by location and meeting time.
 */

/* Reset some default margin/padding for a cleaner layout */
body,
h1, h2, h3, p, ul {
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f7f4ef;
}

/* Navigation styles */
header {
  background: #4a3f36;
  color: #fff;
  padding: 0.5rem 1rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

nav {
  display: flex;
  justify-content: center;
  align-items: center;
}

nav .brand {
  margin-right: auto;   /* sends the brand to the left */
}

nav ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

nav a {
  color: #fff;
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 500;
  transition: color 0.3s ease;
}

nav a:hover,
nav a:focus {
  color: #f2e6d9;
}

/* Active link indicator */
.active {
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* Hero section on the home page */
.hero {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  display: flex;
  justify-content: center;
  color: #fff; text-align: center;
}

/* Image: contain (no crop), centered, 60% of viewport width */
.hero-bg {
  position: absolute;
  top: 40%; left: 50%;
  transform: translate(-50%, -50%);
  width: 60vw;          /* limit to 60% of screen width */
  height: auto;
  max-height: 100%;
  object-fit: contain;
  z-index: 1;
}

/* Content card: fix typos, bring it closer to the image & bottom */
.hero-content {
  position: absolute;
  bottom: 30%;                  /* was 0.em — brings it closer */
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;                      /* above the image */
  padding: .75rem 1rem;            /* a bit tighter */
  background: rgba(0, 0, 0, 0.35);
  border-radius: 8px;              /* was 'px' */
  width:  750px;          /* responsive cap */
}

/* Pull the main card up to reduce the perceived gap after the hero */
.hero + main {
  margin-top: -10rem;            /* small overlap for tighter look */
  position: relative;
  z-index: 3;
}

.hero-content h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.hero-content p {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

main {
  padding: 2rem 1.5rem;
  max-width: 900px;
  margin: 0 auto;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

h2 {
  margin-bottom: 1rem;
  color: #4a3f36;
}

p {
  margin-bottom: 1rem;
}

/* Contact form styling */
form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

label {
  font-weight: bold;
  margin-bottom: 0.25rem;
}

input,
textarea {
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
}

textarea {
  resize: vertical;
  min-height: 120px;
}

button {
  padding: 0.75rem 1.5rem;
  background-color: #4a3f36;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 1rem;
  cursor: pointer;
  align-self: flex-start;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: #6c5848;
}

/* Responsive adjustments */
@media (max-width: 600px) {
  nav ul {
    gap: 1rem;
  }
  .hero-content h1 {
    font-size: 2rem;
  }
  .hero-content p {
    font-size: 1rem;
  }
}