/* =====================================================================
   Sivani Living — Homepage styles (index.php only)
   Shared base for the homepage: variables, reset, old header base,
   gallery popup, footer, booking button, animations.
   The page sections themselves are styled in assets/css/home.css.
   Breakpoints: 1024px (tablet) · 768px (phone) · 600px · 480px (small phone)
   ===================================================================== */


/* ---------------------------------------------------------------------
   1. Variables
   --------------------------------------------------------------------- */
:root {
  --primary: #0a6fb1;
  --primary-dark: #085a89;
  --accent: #ffb300;
  --accent-dark: #ff9500;
  --text-dark: #0d1b2a;
  --text-medium: #415a77;
  --text-light: #6b889e;
  --bg-light: #f7fbff;
  --bg-white: #ffffff;
  --border-light: #eef6fb;
  --shadow-sm: 0 2px 8px rgba(13, 27, 42, 0.04);
  --shadow-md: 0 8px 24px rgba(13, 27, 42, 0.08);
  --shadow-lg: 0 16px 48px rgba(13, 27, 42, 0.12);
  --shadow-xl: 0 24px 64px rgba(13, 27, 42, 0.16);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 999px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}


/* ---------------------------------------------------------------------
   2. Reset & base
   --------------------------------------------------------------------- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-white);
  color: var(--text-dark);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
}


/* ---------------------------------------------------------------------
   3. Header (markup in includes/header.php)
   --------------------------------------------------------------------- */
header {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1200;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  border-radius: var(--radius-full);
  padding: 12px 24px;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(10, 111, 177, 0.08);
  max-width: min(95%, 1100px);
  width: 100%;
  transition: var(--transition);
}

header.scrolled {
  padding: 10px 20px;
  box-shadow: var(--shadow-xl);
}

.nav-container {
  display: flex;
  align-items: center;
  gap: 30px;
  justify-content: space-between;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  transition: var(--transition);
}

.brand:hover {
  transform: translateY(-2px);
}

.brand.logo-only {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.brand-logo {
  height: 42px;
  width: auto;
  object-fit: contain;
  display: block;
}


nav {
  display: flex;
  gap: 32px;
  align-items: center;
}

nav a {
  color: var(--text-medium);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: var(--transition);
  position: relative;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width 0.3s ease;
}

nav a:hover {
  color: var(--primary);
}

nav a:hover::after {
  width: 100%;
}

.book-btn {
  padding: 10px 24px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border: none;
  border-radius: var(--radius-full);
  color: white;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-md);
}

.book-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  color: var(--text-dark);
  cursor: pointer;
}

@media (max-width: 768px) {
  header {
    top: 38px;
    padding: 10px 16px;
  }

  nav {
    display: none;
  }

  .mobile-menu-btn {
    display: block;
  }
}

@media (max-width: 480px) {
  .brand-logo {
    height: 34px;
  }
}


/* ---------------------------------------------------------------------
   11. Gallery lightbox (popup photo viewer)
   --------------------------------------------------------------------- */
.gallery-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-modal.active {
  display: flex;
  opacity: 1;
}

.modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(13, 27, 42, 0.95);
  backdrop-filter: blur(5px);
  z-index: 1;
}

.modal-content {
  position: relative;
  z-index: 2;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  animation: modalFadeIn 0.3s ease-out;
}

.modal-image-container {
  max-width: 100%;
  max-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
}

#modalImage {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  display: block;
}

.modal-close {
  position: absolute;
  top: -50px;
  right: 0;
  background: var(--bg-white);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-dark);
  font-size: 1.2rem;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  z-index: 3;
}

.modal-close:hover {
  background: var(--accent);
  color: var(--bg-white);
  transform: scale(1.1);
}

.modal-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--bg-white);
  border: none;
  width: 50px;
  height: 50px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-dark);
  font-size: 1.2rem;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  z-index: 3;
}

.modal-prev {
  left: -70px;
}

.modal-next {
  right: -70px;
}

.modal-nav:hover {
  background: var(--primary);
  color: var(--bg-white);
  transform: translateY(-50%) scale(1.1);
}

.modal-info {
  margin-top: 20px;
  color: var(--bg-white);
  text-align: center;
}

.image-counter {
  font-size: 0.9rem;
  opacity: 0.8;
}

@media (max-width: 768px) {
  .modal-nav {
    width: 44px;
    height: 44px;
  }

  .modal-prev {
    left: 10px;
  }

  .modal-next {
    right: 10px;
  }

  .modal-close {
    top: 10px;
    right: 10px;
  }

  .modal-image-container {
    max-height: 70vh;
  }

  #modalImage {
    max-height: 70vh;
  }
}

@media (max-width: 480px) {
  .modal-nav {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }

  .modal-prev {
    left: 5px;
  }

  .modal-next {
    right: 5px;
  }
}


/* ---------------------------------------------------------------------
   13. Footer (markup in includes/footer.php)
   --------------------------------------------------------------------- */
footer {
  background: var(--text-dark);
  color: white;
  padding: 80px 24px 40px;
  margin-top: 80px;
}


/* ---------------------------------------------------------------------
   14. Booking form button (form in includes/booking_form.php)
   --------------------------------------------------------------------- */
.submit-btn {
  width: 100%;
  padding: 14px 24px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: var(--transition);
  margin-top: 8px;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}


/* ---------------------------------------------------------------------
   15. Animations (gallery popup)
   --------------------------------------------------------------------- */
@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}
