/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Outfit:wght@400;600;700&display=swap');

:root {
  /* Colors - Derived from local header image */
  --color-primary: #1B4D3E;
  /* Deep Jungle Green */
  --color-primary-dark: #0F2A22;
  --color-secondary: #E8F1F2;
  /* Light Blue-Grey/Mist */
  --color-accent: #D4AF37;
  /* Metallic Gold */
  --color-accent-hover: #B8962D;
  --color-sky-blue: #5DADE2;
  /* Vibrant Sky Blue */

  --color-text: #2C3E50;
  /* Deep Slate */
  --color-text-light: #F9F9F9;
  --color-background: #FFFFFF;
  /* Pure White */
  --color-white: #FFFFFF;
  --color-overlay: rgba(0, 0, 0, 0.3);

  /* Typography */
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 4rem;
  --spacing-xl: 8rem;

  /* Transitions */
  --transition-fast: 0.3s ease;
  --transition-smooth: 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
}

/* Reset & Base */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-background);
  line-height: 1.6;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  line-height: 1.2;
  color: var(--color-primary);
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

/* Utilities */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

.section {
  padding: var(--spacing-xl) 0;
}

.btn {
  display: inline-block;
  padding: 0.8rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.9rem;
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-white);
}

.btn-primary:hover {
  background-color: var(--color-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(45, 79, 60, 0.2);
}

.btn-accent {
  background-color: var(--color-accent);
  color: var(--color-white);
}

.btn-accent:hover {
  background-color: var(--color-accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(212, 163, 115, 0.3);
}

/* Animations */
.fade-in-up {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
  padding: 1rem 0;
  transition: var(--transition-fast);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
}

.logo-img {
  height: 50px;
  /* Adjust based on navbar height */
  width: auto;
  transition: var(--transition-fast);
}

.logo:hover .logo-img {
  transform: scale(1.05);
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-left: 0.8rem;
  /* Ensure text is visible and layout is correct */
}

@media (max-width: 480px) {

  /* Optionally hide text on very small screens if needed, or adjust size */
  .logo-text {
    font-size: 1.2rem;
  }
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  font-weight: 500;
  color: var(--color-text);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-accent);
  transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.menu-toggle {
  display: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--color-primary);
}

/* Header Banner */
.header-banner {
  width: 100%;
  height: 85vh;
  /* Restore height since we're using bg image */
  margin-top: 60px;

  /* Fixed Background Image Strategy */
  background-image: linear-gradient(to bottom, rgba(255, 255, 255, 0) 80%, #FFFFFF 100%), url('images/header-bg.webp');
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;

  /* Default to scroll for mobile (performance/support) */
  background-attachment: scroll;
}

/* Desktop/Tablet: Fixed "Parallax" Effect */
@media (min-width: 768px) {
  .header-banner {
    background-attachment: fixed;
  }
}

/* Intro Section */
.intro {
  padding: var(--spacing-lg) 0;
  text-align: center;
  background-color: var(--color-white);
}

.intro-content h1 {
  font-size: 4rem;
  color: var(--color-primary);
  margin-bottom: 1rem;
  /* Removed text-shadow since background is now white */
}

.intro-content p {
  font-size: 1.5rem;
  /* Slightly larger for emphasis */
  color: var(--color-text);
  max-width: 700px;
  margin: 0 auto 2rem;
  line-height: 1.6;
}

/* Responsive adjustments for intro */
@media (max-width: 768px) {
  .header-banner {
    margin-top: 70px;
  }

  .intro-content h1 {
    font-size: 2.5rem;
  }

  .intro-content p {
    font-size: 1.1rem;
  }
}

/* About Section */
.about {
  background-color: var(--color-white);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-text h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.about-text p {
  margin-bottom: 1rem;
  color: #555;
}

.about-image img {
  border-radius: var(--radius-md);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Accommodation Section */
.accommodation {
  background-color: var(--color-secondary);
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title h2 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.section-title p {
  color: #666;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.card {
  background: var(--color-white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: var(--transition-fast);
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.card-img {
  height: 250px;
  object-fit: cover;
  width: 100%;
}

.card-content {
  padding: 1.5rem;
}

.card-content h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

/* Activities Section */
.activities {
  background-color: var(--color-white);
}

.activity-item {
  display: flex;
  align-items: center;
  gap: 4rem;
  margin-bottom: 4rem;
}

.activity-item:nth-child(even) {
  flex-direction: row-reverse;
}

.activity-text {
  flex: 1;
}

.activity-img {
  flex: 1;
}

.activity-img img {
  border-radius: var(--radius-md);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Coastline Section */
.coastline {
  background: linear-gradient(rgba(45, 79, 60, 0.9), rgba(45, 79, 60, 0.9)), url('https://images.unsplash.com/photo-1507525428034-b723cf961d3e?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
  background-size: cover;
  background-attachment: fixed;
  color: var(--color-white);
  text-align: center;
}

.coastline h2 {
  color: var(--color-white);
  font-size: 3rem;
  margin-bottom: 1.5rem;
}

.coastline p {
  max-width: 700px;
  margin: 0 auto 2rem;
  font-size: 1.1rem;
  opacity: 0.9;
}

/* Contact / Footer */
.footer {
  background-color: var(--color-primary-dark);
  color: var(--color-white);
  padding: 4rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-col h3 {
  color: var(--color-accent);
  margin-bottom: 1.5rem;
  font-size: 1.25rem;
}

.contact-links a {
  display: block;
  margin-bottom: 0.8rem;
  opacity: 0.8;
}

.contact-links a:hover {
  opacity: 1;
  color: var(--color-accent);
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.copyright {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.9rem;
  opacity: 0.6;
}

/* Responsive */
@media (max-width: 768px) {
  :root {
    --spacing-xl: 4rem;
  }

  .nav-links {
    position: fixed;
    top: 70px;
    right: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background-color: var(--color-white);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: 0.4s ease;
  }

  .nav-links.active {
    right: 0;
  }

  .menu-toggle {
    display: block;
  }

  .hero-content h1 {
    font-size: 2.5rem;
  }

  .about-grid,
  .activity-item {
    grid-template-columns: 1fr;
    flex-direction: column;
    text-align: center;
    gap: 2rem;
  }

}


/* Wave Separator */
.wave-divider {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  overflow: hidden;
  line-height: 0;
  transform: rotate(180deg);
}

.wave-divider svg {
  position: relative;
  display: block;
  width: calc(150% + 1.3px);
  height: 60px;
}

.wave-divider .shape-fill {
  fill: var(--color-white);
}

.section-alt {
  background-color: var(--color-background);
  position: relative;
}

/* Programs Section */
.programs {
  background-color: var(--color-secondary);
  position: relative;
  padding-bottom: var(--spacing-xl);
}

.program-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 3rem;
  margin-top: 3rem;
}

.program-card {
  background: var(--color-white);
  padding: 2rem;
  border-radius: var(--radius-md);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  border-top: 4px solid var(--color-primary);
  transition: var(--transition-fast);
}

.program-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.program-card h3 {
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.program-card ul {
  list-style-type: disc;
  padding-left: 1.5rem;
  color: #555;
}

.program-card li {
  margin-bottom: 0.5rem;
}

/* Past Projects List */
.projects-list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
}

.project-tag {
  background-color: #e8f5e9;
  color: var(--color-primary-dark);
  padding: 0.5rem 1rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
}

/* Around Borneo Section */
.borneo-destinations {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.destination-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-md);
  height: 300px;
}

.destination-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.destination-item:hover img {
  transform: scale(1.1);
}

.destination-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 1.5rem;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
  color: var(--color-white);
}

.destination-overlay h3 {
  color: var(--color-white);
  margin-bottom: 0.5rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  :root {
    --spacing-xl: 4rem;
  }

  /* ... existing mobile styles ... */
  .destination-item {
    height: 250px;
  }
}

/* Social Feed Section */
.social-feed {
  background-color: var(--color-background);
}

.feed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.feed-item {
  background: var(--color-white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
}

.feed-item:hover {
  transform: translateY(-5px);
}

.feed-img {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.feed-content {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.feed-meta {
  display: flex;
  justify-content: space-between;
  color: #888;
  font-size: 0.9rem;
  margin-bottom: 0.8rem;
  font-weight: 500;
}

.feed-text {
  margin-bottom: 1.5rem;
  color: var(--color-text);
  line-height: 1.6;
  flex-grow: 1;
}

.social-btn {
  display: inline-block;
  color: var(--color-primary);
  font-weight: 600;
  text-decoration: none;
  align-self: flex-start;
}

.social-btn:hover {
  text-decoration: underline;
}

/* Booking Modal Styles */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
}

.modal-content {
  background-color: var(--color-white);
  margin: 5% auto;
  padding: 2rem;
  border: 1px solid #888;
  width: 90%;
  max-width: 500px;
  border-radius: var(--radius-md);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  position: relative;
  animation: modalDescend 0.3s ease-out;
}

@keyframes modalDescend {
  from {
    transform: translateY(-50px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.close-modal {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.2s;
}

.close-modal:hover,
.close-modal:focus {
  color: var(--color-primary);
  text-decoration: none;
  cursor: pointer;
}

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--color-text);
}

.form-group input,
.form-group select {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid #ccc;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 1rem;
}

.form-group input:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(45, 79, 60, 0.1);
}