@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;700&family=Playfair+Display:ital,wght@0,400;0,700;1,400&display=swap');

:root {
  /* Color Palette */
  --primary-color: #0f172a; /* Deep Navy */
  --primary-light: #1e293b;
  --accent-color: #d97706; /* Soft Gold/Amber */
  --accent-hover: #b45309;
  --bg-color: #f8fafc; /* Very light slate/off-white */
  --surface-color: #ffffff;
  --text-main: #334155;
  --text-muted: #64748b;
  --text-light: #f8fafc;
  
  /* Typography */
  --font-sans: 'Outfit', sans-serif;
  --font-serif: 'Playfair Display', serif;
  
  /* Spacing & Layout */
  --section-padding: 6rem 2rem;
  --container-max: 1200px;
  --border-radius: 12px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  color: var(--primary-color);
  line-height: 1.2;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 700;
  margin-bottom: 1rem;
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1.5rem;
  text-align: center;
}

.subtitle {
  font-size: 1.25rem;
  font-weight: 300;
  color: var(--text-light);
  margin-bottom: 2rem;
  font-family: var(--font-sans);
}

/* Layout Utilities */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: var(--section-padding);
}

.text-center {
  text-align: center;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 50px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  font-family: var(--font-sans);
}

.btn-primary {
  background-color: var(--accent-color);
  color: var(--text-light);
  box-shadow: 0 4px 14px rgba(217, 119, 6, 0.4);
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(217, 119, 6, 0.6);
  color: var(--text-light);
}

.btn-outline {
  background-color: transparent;
  border: 2px solid var(--text-light);
  color: var(--text-light);
}

.btn-outline:hover {
  background-color: var(--text-light);
  color: var(--primary-color);
  transform: translateY(-2px);
}

/* Header & Nav */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  transition: var(--transition);
  padding: 1.5rem 0;
}

header.scrolled {
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 1rem 0;
  box-shadow: var(--shadow-sm);
}

/* Page Header (Shared for inner pages) */
.page-header {
  background-color: var(--primary-color);
  padding: 8rem 2rem 4rem;
  text-align: center;
  color: var(--text-light);
}

.page-header h1 {
  color: var(--text-light);
  margin-bottom: 1rem;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 2rem;
}

.logo {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-light);
  letter-spacing: 1px;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-links a {
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--accent-color);
  transition: var(--transition);
}

.nav-links a:hover, .nav-links a.active {
  color: var(--text-light);
}

.nav-links a:hover::after, .nav-links a.active::after {
  width: 100%;
}

.hamburger {
  display: none;
  cursor: pointer;
  background: none;
  border: none;
  color: var(--text-light);
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background-color: var(--primary-color);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(15, 23, 42, 0.7), rgba(15, 23, 42, 0.8)), url('../images/MainVisual.jpg') center/cover no-repeat;
  z-index: 1;
  transform: scale(1.05); /* For load animation */
}

.hero-content {
  position: relative;
  z-index: 2;
  color: var(--text-light);
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  padding-top: 5rem;
}

.hero h1 {
  color: var(--text-light);
  text-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

/* Split Section (About / Info) */
.split-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.split-section.reverse {
  direction: rtl;
}

.split-section.reverse > * {
  direction: ltr;
}

.split-image {
  position: relative;
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/3;
}

.split-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.split-image:hover img {
  transform: scale(1.05);
}

.split-content h3 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.split-content p {
  margin-bottom: 1.5rem;
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* Feature Grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.feature-card {
  background: var(--surface-color);
  padding: 2.5rem 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  text-align: center;
  border: 1px solid rgba(0,0,0,0.05);
}

.feature-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-md);
  border-color: rgba(217, 119, 6, 0.3);
}

.feature-icon {
  font-size: 2.5rem;
  color: var(--accent-color);
  margin-bottom: 1.5rem;
}

.feature-card h4 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

/* Gallery Section */
.gallery-section {
  background-color: var(--primary-color);
  color: var(--text-light);
}

.gallery-section h2 {
  color: var(--text-light);
}

.gallery-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 3rem;
}

.gallery-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  aspect-ratio: 1;
  cursor: pointer;
  width: 100%;
  max-width: 350px;
  flex: 0 0 auto;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gallery-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: var(--transition);
}

.gallery-overlay h4 {
  color: #ffffff;
  font-size: 1.8rem;
  text-shadow: 0 3px 6px rgba(0,0,0,0.8);
  padding: 0 1rem;
  text-align: center;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-item:hover .gallery-overlay {
  background: rgba(15, 23, 42, 0.6);
}

/* Contact/Donate Section */
.contact-section {
  background-color: var(--surface-color);
}

.contact-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  background: var(--surface-color);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  margin-top: -5rem; /* Pull up into previous section slightly */
  position: relative;
  z-index: 10;
}

.contact-info {
  background: var(--primary-color);
  color: var(--text-light);
  padding: 4rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact-info h3 {
  color: var(--text-light);
  font-size: 2rem;
  margin-bottom: 1.5rem;
}

.contact-info p {
  color: rgba(255,255,255,0.8);
  margin-bottom: 2rem;
}

.contact-form-wrapper {
  padding: 4rem;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-control {
  width: 100%;
  padding: 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-family: var(--font-sans);
  font-size: 1rem;
  background: var(--bg-color);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px rgba(217, 119, 6, 0.1);
  background: var(--surface-color);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

/* Footer */
footer {
  background-color: var(--primary-light);
  color: var(--text-light);
  padding: 4rem 0 2rem;
  text-align: center;
}

.footer-content {
  margin-bottom: 2rem;
}

.footer-logo {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  color: var(--text-light);
  margin-bottom: 1rem;
  display: block;
}

.copyright {
  color: var(--text-muted);
  font-size: 0.9rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 2rem;
}

/* Animations Data Attributes */
[data-aos] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-aos].aos-animate {
  opacity: 1;
  transform: translateY(0);
}

/* Mobile Responsiveness */
@media (max-width: 992px) {
  .split-section, .contact-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .contact-container {
    margin-top: 0;
  }
  
  .contact-info, .contact-form-wrapper {
    padding: 2.5rem;
  }

  .nav-links {
    display: none; /* Hide on mobile initially */
  }

  .hamburger {
    display: block;
  }
}

@media (max-width: 768px) {
  :root {
    --section-padding: 4rem 1.5rem;
  }
  
  h1 {
    font-size: 2.5rem;
  }
  
  .hero-content {
    padding-top: 0;
  }
}

/* -----------------------------------------
   Newsletters Feature Styles
----------------------------------------- */
.admin-toggle-container {
  margin-top: -6rem; /* Pull up to overlap header slightly */
  margin-bottom: 2rem;
  position: relative;
  z-index: 10;
}

.admin-section {
  padding: 2rem 0;
  transition: var(--transition);
}

.dropzone {
  border: 2px dashed var(--text-muted);
  border-radius: var(--border-radius);
  padding: 4rem 2rem;
  text-align: center;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: var(--transition);
  max-width: 600px;
  margin: 0 auto;
}

.dropzone:hover, .dropzone.dragover {
  border-color: var(--accent-color);
  background: var(--surface-color);
  box-shadow: var(--shadow-md);
}

/* MacOS Stacked Paper Aesthetic */
.latest-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: 3rem;
  perspective: 1000px;
}

.paper-stack {
  position: relative;
  width: 100%;
  max-width: 450px; /* Base size of the paper */
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.paper-stack:hover {
  transform: translateY(-10px) scale(1.02);
}

.paper-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: white;
  border-radius: 4px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1), 0 1px 3px rgba(0,0,0,0.08);
  border: 1px solid #f1f5f9;
  transition: var(--transition);
}

/* Base element holding the image */
.paper-main {
  position: relative;
  z-index: 3;
  width: 100%;
  background-color: white;
  border-radius: 4px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.15), 0 5px 10px rgba(0,0,0,0.05);
  overflow: hidden;
  border: 1px solid #e2e8f0;
}

.paper-main img {
  width: 100%;
  height: auto;
  display: block;
}

/* The visual stack layers behind the main paper */
.paper-stack .layer-1 {
  z-index: 2;
  transform: rotate(3deg) translate(8px, 8px);
}

.paper-stack .layer-2 {
  z-index: 1;
  transform: rotate(-2deg) translate(-5px, 12px);
}

.paper-stack:hover .layer-1 {
  transform: rotate(5deg) translate(15px, 15px);
}

.paper-stack:hover .layer-2 {
  transform: rotate(-4deg) translate(-10px, 20px);
}

.empty-state {
  color: var(--text-muted);
  font-style: italic;
  padding: 3rem;
  background: var(--surface-color);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-sm);
}

/* Archive Grid */
.archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 2rem;
}

.archive-item {
  background: white;
  padding: 1rem;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid #e2e8f0;
  text-align: center;
}

.archive-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent-color);
}

.archive-thumb {
  width: 100%;
  aspect-ratio: 1/1.4; /* Standard paper aspect ratio approx */
  object-fit: cover;
  border: 1px solid #f1f5f9;
  margin-bottom: 1rem;
}

.archive-date {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Modal for viewing PDFs directly on screen */
.pdf-modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(15, 23, 42, 0.85); /* Deep navy tint */
  backdrop-filter: blur(5px);
}

.pdf-modal.show {
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  position: relative;
  width: 90%;
  max-width: 900px;
  height: 90vh;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  animation: modalFadeIn 0.3s ease-out forwards;
}

@keyframes modalFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.close-modal {
  position: absolute;
  top: 5px;
  right: 15px;
  color: #333;
  font-size: 35px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s;
  z-index: 10;
}

.close-modal:hover {
  color: var(--accent-color);
}

/* Admin Newsletter Delete Button */
.delete-btn {
  position: absolute;
  top: -12px;
  right: -12px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: #ef4444; /* Bright Red */
  color: white;
  border: none;
  font-size: 22px;
  line-height: 30px;
  text-align: center;
  cursor: pointer;
  z-index: 20;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  transition: all 0.2s;
  padding: 0;
}

.delete-btn:hover {
  background-color: #b91c1c;
  transform: scale(1.1);
}
