/* COLOR PALETTE */
/* Primary: #3d7c4f (Green), Gold: #d4af37, Purple: #8b5a8e */

*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  width: 100%;
  margin: 0;
  min-height: 100%;
  overflow-x: hidden;
}

body {
  background: 
  linear-gradient(135deg, #f8f9f7 0%, #f0f3ef 100%),url('bbody.png');
  background-blend-mode: lighten;
  background-size: cover;
  font-family: 'Open Sans', sans-serif;
  color: #2c3e3f;
  scroll-behavior: smooth;
}

/* NAVBAR */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  background: linear-gradient(135deg, #3d7c4f 0%, #2d5a3d 100%);
  display: flex;
  justify-content: space-between;
  padding: 15px 45px;
  box-shadow: 0 4px 15px rgba(45, 90, 61, 0.3);
  z-index: 1000;
  align-items: center;
}

.nav-links {
  display: flex;
  gap: 30px;
  list-style: none;
  width: 50%;
  justify-content: flex-end;
  padding-right: 20px;
  align-items: center;
  margin: 0;
}

.navbar a {
  text-decoration: none;
  color: #ffffff;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

.navbar a:hover {
  color: #d4af37;
}

.navbar i {
  font-size: 16px;
  transition: transform 0.3s ease;
}

.navbar a:hover i {
  transform: scale(1.2);
}

.nav-toggle {
  display: none;
  border: none;
  background: transparent;
  color: #ffffff;
  font-size: 22px;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle:focus {
  outline: 2px solid #d4af37;
  outline-offset: 2px;
}

.logo {
  font-family: 'Playfair Display', serif;
  padding-left: 10px;
  color: #d4af37;
  font-size: 22px;
  font-weight: 600;
  margin: 0;
}

/* HERO */
.hero {
  height: 100vh;
  background: linear-gradient(135deg, rgba(45, 90, 61, 0.75) 0%, rgba(139, 90, 142, 0.75) 100%), url('last.jpeg')  center;
  
  /* background-position: right; */
  background-size: cover;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 60px;
}

.overlay {
  background: rgba(243, 248, 245, 0.18);
  padding: 30px 40px;
  text-align: center;
  color: white;
  backdrop-filter: blur(1px);
  margin: 0 20px;
  border-radius: 24px;
  max-width: 700px;
}

.overlay-photo {
  width: min(230px, 80vw);
  height: min(230px, 80vw);
  margin: 0 auto 22px;
  background: url('last.jpeg') center/cover no-repeat;
  border-radius: 22px;
  border: 3px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.2);
}

.overlay h1 {
  font-family: 'Dancing Script', cursive;
  font-size: 60px;
  letter-spacing: 3px;
  margin: 0 0 20px 0;
  color: rgb(201, 199, 199);
}

.overlay h3 {
  font-family: 'Playfair Display', serif;
  font-size: 30px;
  margin: 5px 0;
  letter-spacing: 2px;
  color: #d4af37;
}


.overlay p {
  font-size: 18px;
  letter-spacing: 1px;
  margin: 0;
  color: rgb(201, 199, 199);
  
}

/* SECTIONS */
.section {
  width: min(100%, 1200px);
  max-width: 100%;
  padding: 60px 20px;
  margin: auto;
}

#memory {
  padding: 20px;
}

.centered {
  text-align: center;
}

h2 {
  font-family: 'Playfair Display', serif;
  margin-bottom: 30px;
  position: relative;
  color: #2d5a3d;
  font-size: 36px;
  font-weight: 600;
}

h2::after {
  content: "";
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, #3d7c4f 0%, #d4af37 50%, #8b5a8e 100%);
  display: block;
  margin: 15px auto 0;
  border-radius: 2px;
}

.timeline-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-bottom: 30px;
}

.candle {
  position: relative;
  width: 28px;
  height: 60px;
}

.candle .wax {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 42px;
  background: linear-gradient(180deg, #ffe6c8 0%, #f1b964 100%);
  border-radius: 10px 10px 4px 4px;
  box-shadow: inset 0 5px 0 rgba(255,255,255,0.65), 0 6px 12px rgba(0,0,0,0.08);
}

.candle .flame {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 18px;
  height: 28px;
  background: radial-gradient(circle at 50% 20%, #fff4b2 0%, #ffd16c 40%, #f08f1f 70%, transparent 80%);
  border-radius: 50% 50% 50% 50%;
  filter: blur(0.5px);
  animation: flicker 1.4s infinite ease-in-out;
}

.candle .glow {
  position: absolute;
  top: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 36px;
  height: 36px;
  background: radial-gradient(circle, rgba(255, 218, 128, 0.45) 0%, rgba(255, 168, 55, 0.05) 60%, transparent 100%);
  border-radius: 50%;
  filter: blur(2px);
  animation: glowPulse 1.4s infinite ease-in-out;
}

#timeline {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.92) 0%, rgba(244, 246, 244, 0.92) 100%);
  border-radius: 18px;
  box-shadow: 0 16px 40px rgba(45, 90, 61, 0.08);
  padding: 50px 40px;
}

.timeline-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 18px;
}

.timeline-list li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: rgba(255, 255, 255, 0.95);
  border-left: 5px solid #3d7c4f;
  border-radius: 14px;
  padding: 18px 22px;
  box-shadow: 0 10px 24px rgba(45, 90, 61, 0.08);
}

.timeline-list li i {
  color: #3d7c4f;
  font-size: 20px;
  min-width: 34px;
  text-align: center;
  margin-top: 2px;
}

.timeline-list li span {
  color: #2c3e3f;
  font-size: 1rem;
  line-height: 1.6;
}

@media (max-width: 768px) {
  #timeline {
    padding: 35px 20px;
  }

  .timeline-list li {
    padding: 16px 16px;
  }
}

@keyframes flicker {
  0%, 100% { transform: translateX(-50%) scaleY(1) scaleX(1); opacity: 1; }
  20% { transform: translateX(-52%) scaleY(0.95) scaleX(1.05); opacity: 0.95; }
  40% { transform: translateX(-50%) scaleY(1.05) scaleX(0.98); opacity: 0.9; }
  60% { transform: translateX(-48%) scaleY(0.98) scaleX(1.02); opacity: 0.95; }
  80% { transform: translateX(-50%) scaleY(1) scaleX(1); opacity: 1; }
}

@keyframes glowPulse {
  0%, 100% { transform: translateX(-50%) scale(1); opacity: 0.55; }
  50% { transform: translateX(-50%) scale(1.08); opacity: 0.35; }
}




/* MASONRY GALLERY */
.masonry-gallery {
  column-count: 7;
  column-gap: 15px;
  width: 100%;
  margin: 0 auto;
}

.masonry-gallery img {
  width: 100%;
  margin-bottom: 15px;
  break-inside: avoid;
  transition: all 0.3s ease;
  box-shadow: 0 8px 20px rgba(45, 90, 61, 0.15);
  border-radius: 6px;
  overflow: hidden;
}

.masonry-gallery img:hover {
  transform: scale(1.05);
  box-shadow: 0 12px 30px rgba(61, 124, 79, 0.25);
}



.uploaded-media-section {
  margin-bottom: 30px;
}

.uploaded-media-title {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  color: #3d7c4f;
  margin-bottom: 18px;
}

.uploaded-media-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

/* Medium screens (768px and up) */
@media (min-width: 768px) {
  .uploaded-media-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

/* Large screens (1200px and up) */
@media (min-width: 1200px) {
  .uploaded-media-grid {
    grid-template-columns: repeat(7, 1fr);
  }
}

.uploaded-media-card {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(246, 248, 246, 0.95) 100%);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 24px rgba(45, 90, 61, 0.12);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.uploaded-media-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 30px rgba(45, 90, 61, 0.18);
}

.uploaded-media-card img,
.uploaded-media-card video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.uploaded-media-card video {
  aspect-ratio: 16 / 9;
}

.uploaded-media-info {
  padding: 14px 16px;
  font-size: 14px;
  color: #3a473b;
  line-height: 1.5;
  background: rgba(255, 255, 255, 0.95);
}

@media (max-width: 820px) {
  .masonry-gallery {
    column-count: 5;
  }
  .navbar {
    padding: 15px 20px;
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    right: 20px;
    left: 20px;
    background: rgba(45, 90, 61, 0.95);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease;
    border-radius: 10px;
    box-shadow: 0 12px 30px rgba(45, 90, 61, 0.2);
    z-index: 1001;
  }

  .nav-links.open {
    max-height: 360px;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links li + li {
    border-top: 1px solid rgba(255,255,255,0.12);
  }

  .nav-links a {
    width: 100%;
    padding: 14px 18px;
    justify-content: center;
  }
}

@media (max-width: 600px) {
  .hero {
    padding-top: 70px;
  }
  h2 {
    font-size: 32px;
  }

  .overlay {
    padding: 45px 25px;
    margin: 0 15px;
  }

  .overlay h1 {
    font-size: 30px;
  }

  .overlay h2 {
    font-size: 38px;
  }

  .overlay p {
    font-size: 16px;
  }

  .section {
    padding: 50px 15px;
  }

   .masonry-gallery {
    column-count: 4;
  }

  .nav-links {
    left: 10px;
    right: 10px;
  }

}

@media (max-width: 500px) {
  .masonry-gallery {
    column-count: 3;
  }

  .overlay h2 {
    font-size: 32px;
  }

  .overlay h1 {
    font-size: 30px;
  }
  .overlay{
    margin: 0;
    border-radius: 0;
  }
}


/* FORM STYLING */
form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  max-width: 500px;
  margin: auto;
}

input, textarea {
  padding: 14px 16px;
  border: 2px solid #e0e0e0;
  border-radius: 6px;
  font-family: 'Open Sans', sans-serif;
  color: #2c3e3f;
  transition: all 0.3s ease;
  font-size: 14px;
}

input::placeholder, textarea::placeholder {
  color: #999;
}

input:focus, textarea:focus {
  outline: none;
  border-color: #3d7c4f;
  box-shadow: 0 0 0 4px rgba(61, 124, 79, 0.1);
}

input[type="file"] {
  padding: 10px;
  cursor: pointer;
}

input[type="file"]::file-selector-button {
  background: #3d7c4f;
  color: white;
  padding: 8px 16px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.3s ease;
  font-size: 14px;
  font-weight: 500;
}

input[type="file"]::file-selector-button:hover {
  background: #2d5a3d;
}

/* BUTTONS */
button {
  background: linear-gradient(135deg, #3d7c4f 0%, #2d5a3d 100%);
  color: white;
  padding: 14px 30px;
  border: none;
  cursor: pointer;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.3s ease;
  font-size: 14px;
}

button:hover {
  background: linear-gradient(135deg, #4a9a5f 0%, #3d7c4f 100%);
  box-shadow: 0 8px 24px rgba(61, 124, 79, 0.35);
  transform: translateY(-2px);
}

button:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(61, 124, 79, 0.25);
}

.contribute-btn {
  display: inline-block;
  background: linear-gradient(135deg, #8b5a8e 0%, #6b4570 100%);
  color: white;
  padding: 14px 35px;
  border: none;
  cursor: pointer;
  font-size: 15px;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.3s ease;
  margin-top: 20px;
}

.contribute-btn:hover {
  background: linear-gradient(135deg, #a06ba3 0%, #7b5880 100%);
  box-shadow: 0 8px 24px rgba(139, 90, 142, 0.35);
  transform: translateY(-2px);
}

/* MODAL */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  right: 0;
  bottom:0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(3px);
}

.modal-content {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 248, 0.98) 100%);
  margin: 10% auto;
  padding: 40px;
  width: 90%;
  max-width: 500px;
  border-radius: 10px;
  text-align: center;
  animation: fadeIn 0.4s ease;
  box-shadow: 0 10px 40px rgba(45, 90, 61, 0.2);
  border-top: 4px solid #3d7c4f;
}

.modal-content h3 {
  color: #2d5a3d;
  font-family: 'Playfair Display', serif;
  margin-bottom: 25px;
}

.close {
  float: right;
  font-size: 28px;
  cursor: pointer;
  color: #999;
  background: none;
  border: none;
  padding: 0;
  transition: color 0.3s ease;
}

.close:hover {
  color: #3d7c4f;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* MEMORY LIST */
#memoryList {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  max-width: 100%;
  margin: 30px 0;
}

.memory {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(250, 252, 250, 0.9) 100%);
  padding: 25px;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(45, 90, 61, 0.1);
  border-left: 5px solid #d4af37;
  text-align: left;
  transition: all 0.3s ease;
  position: relative;
}

.memory:hover {
  box-shadow: 0 8px 25px rgba(45, 90, 61, 0.15);
  transform: translateY(-2px);
}

.memory h3 {
  margin: 0 0 5px 0;
  font-family: 'Playfair Display', serif;
  color: #3d7c4f;
  font-size: 16px;
}

.memory p {
  font-size: 14px;
  color: #2c3e3f;
  line-height: 1.6;
  margin-top: 10px;
  margin-bottom: 10px;
}

.memory img {
  width: 100%;
  max-width: 300px;
  height: 150px;
  border-radius: 6px;
  box-shadow: 0 4px 12px rgba(45, 90, 61, 0.15);
  object-fit: cover;
}

.memory video {
  width: 100%;
  max-width: 300px;
  height: 150px;
  border-radius: 6px;
  box-shadow: 0 4px 12px rgba(45, 90, 61, 0.15);
  object-fit: cover;
}

.memory small {
  display: block;
  font-size: 12px;
  color: #666;
  font-style: italic;
  margin-bottom: 0;
}

.delete-btn {
  position: absolute;
  top: 15px;
  right: 15px;
  background: rgba(220, 53, 69, 0.1);
  color: #dc3545;
  border: 1px solid rgba(220, 53, 69, 0.3);
  border-radius: 4px;
  width: 30px;
  height: 30px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  opacity: 0;
  transform: scale(0.8);
}

.memory:hover .delete-btn {
  opacity: 1;
  transform: scale(1);
}

.delete-btn:hover {
  background: #dc3545;
  color: white;
  border-color: #dc3545;
  transform: scale(1.05);
}

/* LARGE SCREEN LAYOUT FOR MEMORY POSTS */
@media (min-width: 700px) {
  .memory {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 25px;
  }

  .memory .text-content {
    flex: 1;
    order: 1;
  }

  .memory .media-content {
    width: 200px;
    height: 150px;
    flex-shrink: 0;
    order: 2;
    margin: 0;
    object-fit: cover;
  }

  .memory h3 {
    margin-bottom: 10px;
  }

  .memory p {
    margin-top: 0;
    margin-bottom: 15px;
  }
}

/* FOOTER */
footer {
  text-align: center;
  padding: 40px 20px;
  font-size: 14px;
  color: #666;
  background: linear-gradient(135deg, rgba(61, 124, 79, 0.05) 0%, rgba(139, 90, 142, 0.05) 100%);
  border-top: 1px solid rgba(61, 124, 79, 0.2);
}

/* FADE-IN ANIMATION */
.fade-in {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease;
}

.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

/* UTILITY */
section p {
  line-height: 1.8;
  color: #2c3e3f;
  font-size: 15px;
}

.read-more-btn {
  background: linear-gradient(135deg, #3d7c4f 0%, #2d5a3d 100%);
  color: #ffffff;
  border: none;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 500;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
  margin: 20px 0;
}

.read-more-btn:hover {
  background: linear-gradient(135deg, #2d5a3d 0%, #1e3a2a 100%);
  transform: translateY(-2px);
}
/* SECTION */
.centered {
  text-align: center;
  font-family: 'Playfair Display', serif;
  margin-bottom: 40px;
}



#story p {
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-weight: 400;
  line-height: 1.8;
  letter-spacing: 0.3px;
  font-size: 1.1rem;
  text-align: left;
}



/* RESPONSIVE */

