/* ====== Reset & Base ====== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: 'Arial', sans-serif;
  background-color: #fbe8d3;
  color: #333;
  line-height: 1.6;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
body.page-loaded {
  opacity: 1;
  transform: translateY(0);
}
a {
  text-decoration: none;
  color: inherit;
}
img {
  display: block;
  border-radius: 8px;
  width: 100%;
  height: auto;
}

/* ====== Layout ====== */
.container {
  display: flex;
  min-height: 100vh;
}
.sidebar {
  width: 220px;
  background-color: #ffe7b3;
  padding: 2rem 1rem;
  border-right: 4px solid #f4d06f;
  transition: left 0.3s ease;
}
.logo {
  font-size: 1.5rem;
  color: #d94040;
  margin-bottom: 2rem;
  text-align: center;
}
.sidebar nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.sidebar nav ul li {
  margin-bottom: 1rem;
}
.sidebar nav ul li.section-title {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #ccc;
}
.sidebar nav a {
  display: block;
  padding: 0.5rem;
  border-radius: 4px;
  transition: all 0.2s ease;
}
.sidebar nav a:hover {
  background-color: #f4d06f;
  color: #d94040;
  transform: translateX(4px);
}
.main-content {
  flex: 1;
  padding: 2rem;
}

/* ====== Hero Section ====== */
.hero {
  position: relative;
  margin-bottom: 3rem;
}
.hero-image {
  max-height: 400px;
  object-fit: cover;
  width: 100%;
}
.hero-text {
  position: absolute;
  bottom: 20px;
  left: 30px;
  background-color: rgba(255, 231, 179, 0.95);
  padding: 1rem 2rem;
  border-radius: 8px;
  animation: fadeInUp 1s ease forwards;
}
.hero-text h2 {
  font-size: 2rem;
  color: #d94040;
}
.hero-text p {
  font-size: 1rem;
}

/* ====== Portfolio Grid ====== */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}
.grid-item figcaption {
  margin-top: 0.5rem;
  text-align: center;
  color: #555;
}

/* ====== Contact Section ====== */
.contact-section {
  margin-top: 4rem;
}
.contact-section h2 {
  font-size: 1.8rem;
  color: #d94040;
  margin-bottom: 1rem;
}
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 400px;
}
.contact-form input,
.contact-form textarea {
  padding: 0.8rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
}
.contact-form button {
  padding: 0.8rem;
  background-color: #d94040;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.contact-form button:hover {
  background-color: #a02e2e;
}

/* ====== Scroll to Top Button ====== */
.scroll-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #d94040;
  color: white;
  border: none;
  font-size: 1.5rem;
  padding: 0.6rem 1rem;
  border-radius: 50%;
  cursor: pointer;
  display: none;
  z-index: 999;
  transition: background 0.3s ease;
}
.scroll-top:hover {
  background-color: #a02e2e;
}

/* ====== Mobile Header ====== */
.mobile-header {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: #ffe7b3;
  padding: 1rem;
  z-index: 1000;
  justify-content: space-between;
  align-items: center;
}
.menu-toggle {
  font-size: 2rem;
  background: none;
  border: none;
  cursor: pointer;
}

/* ====== Responsive Sidebar ====== */
@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    left: -100%;
    top: 0;
    height: 100%;
    z-index: 999;
    background: #ffe7b3;
  }
  .sidebar.active {
    left: 0;
  }
  .mobile-header {
    display: flex;
  }
  .main-content {
    padding-top: 5rem;
  }
  .desktop-only {
    display: none;
  }
}

/* ====== Modal Lightbox ====== */
.image-modal {
  display: none;
  position: fixed;
  z-index: 1001;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0,0,0,0.85);
  justify-content: center;
  align-items: center;
  overflow: auto;
  padding: 2rem;
  box-sizing: border-box;
}
.image-modal.active {
  display: flex;
}
.modal-content {
  position: relative;
  width: auto;
  max-width: 90vw;
  max-height: 90vh;
  text-align: center;
  color: #fff;
}
.modal-content img {
  width: auto;
  height: auto;
  max-width: 90vw;
  max-height: 90vh;
  display: block;
  margin: 0 auto;
  border-radius: 8px;
  box-shadow: 0 0 20px #000;
}

.modal-caption {
  margin-top: 1rem;
  font-size: 1.4rem;
  color: #fff;
  cursor: pointer;
}
.modal-caption:hover {
  text-decoration: underline;
}
.modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 2rem;
  color: white;
  background: transparent;
  border: none;
  cursor: pointer;
}
.modal-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.5rem;
  color: #fff;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0 1rem;
}
.modal-nav.prev {
  left: 10px;
}
.modal-nav.next {
  right: 10px;
}


/* ====== Animations ====== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Footer social links */
.site-footer {
  text-align: center;
  padding: 2rem 1rem;
  background-color: #ffe7b3;
  color: #3d3d3d;
}
.footer‑social a {
  margin: 0 0.5rem;
  font-size: 1.4rem;
  color: #3d3d3d;
  transition: color 0.2s ease;
}
.footer‑social a:hover {
  color: #d94040;
}

/* Prominent social links on contact page */
.social‑links‑prominent {
  margin: 2rem 0;
  text-align: center;
}
.social‑links‑prominent .social‑icon {
  margin: 0 1rem;
  font-size: 2.5rem;
  color: #d94040;
  transition: color 0.2s ease, transform 0.2s ease;
}
.social‑links‑prominent .social‑icon:hover {
  color: #a02e2e;
  transform: scale(1.1);
}

/* Fade‑in up animation for grid items */
.grid-item {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease forwards;
}
.grid-item:nth-child(1) { animation-delay: 0.2s; }
.grid-item:nth-child(2) { animation-delay: 0.4s; }
.grid-item:nth-child(3) { animation-delay: 0.6s; }
.grid-item:nth-child(4) { animation-delay: 0.8s; }
.grid-item:nth-child(5) { animation-delay: 1s; }
.grid-item:nth-child(6) { animation-delay: 1.2s; }

/* Contact page: Animate form & social links in */
.contact-section iframe,
.contact-section .social-links‑prominent {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.8s ease forwards;
}
.contact-section iframe {
  animation-delay: 0.3s;
}
.contact-section .social-links‑prominent {
  animation-delay: 0.6s;
}

/* Existing keyframes */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.grid-item img:hover {
  transform: scale(1.05);
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

:root {
  --bg-color: #fbe8d3;
  --text-color: #333;
  --accent-color: #d94040;
  --sidebar-bg: #ffe7b3;
  --sidebar-border: #f4d06f;
}
[data-theme="dark"] {
  --bg-color: #1e1e1e;
  --text-color: #ddd;
  --accent-color: #ff6b6b;
  --sidebar-bg: #2b2b2b;
  --sidebar-border: #444;
}
body {
  background-color: var(--bg-color);
  color: var(--text-color);
}
.sidebar {
  background-color: var(--sidebar-bg);
  border-right-color: var(--sidebar-border);
}
a:hover {
  color: var(--accent-color);
}

.page-transition-enter {
  opacity: 0;
  transform: translateY(20px);
}
.page-transition-enter-active {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.page-transition-exit {
  opacity: 1;
}
.page-transition-exit-active {
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hero {
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 150%;
  background-image: url('assets/hero.jpg');
  background-attachment: fixed;
  background-position: center;
  background-size: cover;
  transform: translateY(-25%);
  z-index: -1;
}
body {
  cursor: url('assets/cursor.svg') 16 16, auto;
}
@media(max-width:768px) {
  .main-content {
    padding-top: 70px; /* adjust to match mobile-header height */
  }
}

.hero-carousel {
  position: relative;
  width: 100%;
  height: auto;
  overflow: hidden;
}
.hero-carousel .carousel-slide {
  position: absolute;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}
.hero-carousel .carousel-slide img {
  width: 100%;
  height: auto;
  display: block;
}
.hero-carousel .carousel-slide.active {
  opacity: 1;
}

