/* Base styles: reset, typography, layout, components. Minimal/intentionally undesigned. */

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

html {
  font-size: 16px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
  color: #1a1a1a;
  background-color: #ffffff;
}

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

a {
  color: #1d4ed8;
  text-decoration: underline;
}

a:hover {
  text-decoration: none;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid #1d4ed8;
  outline-offset: 2px;
}

h1, h2, h3, h4 {
  line-height: 1.25;
  margin-bottom: 0.5em;
}

h1 { font-size: 2rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.15rem; }

p { margin-bottom: 1em; }

ul, ol {
  margin-bottom: 1em;
  padding-left: 1.25em;
}

.plain-list {
  list-style: none;
  padding-left: 0;
}

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Header / nav */

.site-header {
  border-bottom: 1px solid #e2e2e2;
  background-color: #ffffff;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
}

.logo {
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
}

.primary-nav ul {
  display: flex;
  list-style: none;
  padding-left: 0;
  margin-bottom: 0;
  gap: 1.25rem;
}

.primary-nav a {
  text-decoration: none;
  color: #1a1a1a;
  font-weight: 500;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
}

.primary-nav a:hover,
.primary-nav a.is-active {
  border-bottom-color: #1d4ed8;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  background: none;
  border: 1px solid #d1d1d1;
  border-radius: 4px;
  padding: 0.4rem;
  cursor: pointer;
}

.nav-toggle-bar {
  width: 22px;
  height: 2px;
  background-color: #1a1a1a;
  display: block;
}

/* Footer */

.site-footer {
  border-top: 1px solid #e2e2e2;
  margin-top: 2rem;
  padding: 1.5rem 0;
  font-size: 0.9rem;
  color: #444;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: flex-start;
}

.footer-church-name {
  font-weight: 600;
  color: #1a1a1a;
}

.footer-copyright {
  width: 100%;
  margin-top: 1rem;
  font-size: 0.8rem;
  color: #777;
}

/* Layout sections */

.section {
  padding: 2rem 1rem;
  max-width: 1100px;
  margin: 0 auto;
}

.hero-meta {
  font-size: 1.05rem;
  margin-bottom: 0.4em;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.button {
  display: inline-block;
  padding: 0.6rem 1.1rem;
  border-radius: 4px;
  background-color: #1d4ed8;
  color: #fff;
  text-decoration: none;
  font-weight: 600;
}

.button:hover {
  background-color: #1e40af;
}

.button-secondary {
  background-color: #fff;
  color: #1d4ed8;
  border: 1px solid #1d4ed8;
}

.button-secondary:hover {
  background-color: #eff4ff;
}

/* Cards */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
  margin-bottom: 1rem;
}

.card {
  border: 1px solid #e2e2e2;
  border-radius: 6px;
  overflow: hidden;
  background-color: #fff;
  display: flex;
  flex-direction: column;
}

.card-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background-color: #f0f0f0;
}

.card-body {
  padding: 1rem;
}

.card-meta {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 0.5em;
}

.read-more {
  font-weight: 600;
  font-size: 0.9rem;
}

.detail-image {
  width: 100%;
  max-height: 360px;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 1rem;
}

/* Gallery */

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.filter-button {
  border: 1px solid #d1d1d1;
  background-color: #fff;
  border-radius: 999px;
  padding: 0.35rem 0.9rem;
  cursor: pointer;
  font-size: 0.9rem;
}

.filter-button.is-active {
  background-color: #1d4ed8;
  color: #fff;
  border-color: #1d4ed8;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.gallery-item {
  border: 1px solid #e2e2e2;
  border-radius: 6px;
  overflow: hidden;
  background-color: #fff;
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background-color: #f0f0f0;
}

.gallery-item figcaption {
  padding: 0.5rem 0.75rem;
  font-size: 0.85rem;
  color: #444;
}

.gallery-preview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.75rem;
}

.gallery-preview img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 6px;
  background-color: #f0f0f0;
}

/* States */

.empty-state,
.error-state {
  padding: 1rem;
  border-radius: 6px;
  background-color: #f7f7f7;
  color: #555;
}

.error-state {
  background-color: #fdecec;
  color: #991b1b;
}
