/* ==========================================================================
   Base Layout CSS - Core Layout and Navigation Styles
   ========================================================================== */

/* CSS Variables */
:root {
  --primary-rose: #F4E4E6;
  --accent-blush: #E8B4B8;
  --soft-lavender: #E6E0F8;
  --warm-cream: #FAF7F2;
  --elegant-charcoal: #2C2C2C;
  --gold-accent: #D4AF37;
  --navbar-height: 80px;
  --shop-nav-height: 55px;
  --filter-bar-height: 55px;
}

/* Global Reset and Base Styles */
html {
  overflow-x: auto;
}

body {
  background-color: #fff;
  display: flex;
  flex-direction: column;
  position: relative;
  min-height: 100vh;
  width: 100%;
  margin: 0;
  padding: 0;
  font-family: "Dosis", sans-serif;
  font-display: swap; 
}

a {
  text-decoration: none;
}

/* ==========================================================================
   Main Navbar - Fixed at Top
   ========================================================================== */

.navbar {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 4px 20px rgba(0,0,0,0.08);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--navbar-height);
  z-index: 1030;
  padding: 0 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-sizing: border-box;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

.navbar.navbar-hidden {
  transform: translateY(-100%);
}

.navbar.navbar-transparent {
  background: transparent !important;
  backdrop-filter: none !important;
  border-bottom: none !important;
  box-shadow: none !important;
}

.navbar.navbar-transparent .nav-link,
.navbar.navbar-transparent .navbar-brand {
  color: white !important;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.navbar.navbar-transparent .nav-link:hover {
  background-color: rgba(255,255,255,0.1) !important;
  color: white !important;
}

.navbar.navbar-transparent .hamburger i {
  color: white !important;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.nav-left, .nav-right {
  display: flex;
  align-items: center;
  flex: 1;
  gap: 32px;
}

.nav-left {
  justify-content: flex-start;
}

.nav-right {
  justify-content: flex-end;
}

.navbar-brand {
  font-family: 'Cinzel', serif;
  font-size: 2rem;
  font-weight: 500;
  letter-spacing: 3px;
  color: #1a1a1a;
  text-decoration: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.navbar-brand:hover {
  color: #000;
  transform: translateX(-50%) scale(1.02);
}

.nav-link, .cart-button {
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 8px 16px;
  border-radius: 6px;
}

.nav-link {
  color: #2c2c2c;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  cursor: pointer;
  text-transform: uppercase;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #1a1a1a, #4a4a4a);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateX(-50%);
  border-radius: 1px;
}

.nav-link:hover::after {
  width: 70%;
}

.nav-link:hover {
  color: #000;
  background-color: rgba(0,0,0,0.04);
  transform: translateY(-1px);
}

/* ==========================================================================
   Base Container Layout
   ========================================================================== */

.container-fluid {
  position: relative;
  display: block;
  width: 100%;
  margin: 0; 
  min-height: 100vh;
  max-width: 100vw;
  overflow-x: hidden;
}

/* Special case for index page with hero banner */
body:has(.hero-banner) .container-fluid,
.container-fluid:has(.hero-banner) {
  padding-top: 0 !important;
  margin-top: 0 !important;
}

.hero-banner {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

.container-fluid.center.g-0 {
  padding-top: 0 !important;
  margin-top: 0 !important;
}

/* ==========================================================================
   Shop Navigation and Filter Bar - Sticky Elements
   ========================================================================== */

.items-nav-wrapper {
  position: sticky;
  top: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: white;
  border-bottom: 1px solid #f0f0f0;
  z-index: 1025;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.shop-nav {
  width: 600px;
  height: var(--shop-nav-height);
  position: relative;
  background-color: white;
  padding: 20px 40px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #f0f0f0;
}

.shop-nav-item {
  color: #333;
  text-decoration: none;
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  padding: 8px 16px;
  transition: all 0.3s ease;
  position: relative;
  display: inline-block;
}

.shop-nav-item:hover {
  color: #000;
  text-decoration: none;
}

.shop-nav-item::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #333, #666);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.shop-nav-item:hover::before {
  width: 80%;
}

.shop-nav-item.active {
  color: #000;
  font-weight: 600;
}

.shop-nav-item.active::before {
  width: 80%;
}

.item-filter-bar {
  position: relative;
  background-color: white;
  width: 100%;
  height: var(--filter-bar-height);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 15px 0;
  border-bottom: 1px solid #f0f0f0;
}

.filter-bar-box {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  margin: 0; 
  position: relative;
}

.shop-title {
  font-size: 18px;
  font-weight: 600;
  color: #333;
  letter-spacing: 1px; 
}

#filterBtn {
  background: white;
  border: 1px solid #333;
  color: #333;
  padding: 10px 20px;
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  padding-right: 3vw;
}

#filterBtn:hover {
  background: #333;
  color: white;
  text-decoration: none;
}

/* ==========================================================================
   Mobile Responsiveness
   ========================================================================== */

/* ==========================================================================
   Hamburger Menu & Mobile Navigation
   ========================================================================== */

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  padding: 8px;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.hamburger:hover {
  background-color: rgba(0,0,0,0.05);
}

.hamburger i {
  font-size: 1.2rem;
  color: #2c2c2c;
  transition: color 0.3s ease;
}

.mobile-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  backdrop-filter: blur(10px);
  border-top: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  flex-direction: column;
  padding: 20px 0;
  z-index: 1029;
}

.mobile-nav a {
  color: #2c2c2c;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 12px 40px;
  transition: all 0.3s ease;
  border-left: 3px solid transparent;
}

.mobile-nav a:hover {
  background-color: rgba(0,0,0,0.04);
  border-left-color: #1a1a1a;
  color: #000;
}

 /* ==========================================================================
    Search Form Styles
   ========================================================================== */

.search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 80px;
  animation: overlayFadeIn 0.4s ease-out;
}

.search-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.9));
  backdrop-filter: blur(10px);
  cursor: pointer;
}

.search-container {
  position: relative;
  z-index: 10000;
  background: #ffffff;
  border-radius: 8px;
  padding: 2rem;
  border: 1px solid #e0e0e0;
  max-width: 600px;
  width: 90%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}



.search-form {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 1.5rem;
}

.search-close {
  width: 32px;
  height: 32px;
  border-radius: 4px;
  background: #f8f8f8;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: pointer;
  color: #666;
  transition: all 0.2s ease;
  border: 1px solid #e0e0e0;
  z-index: 10001;
  margin-bottom: 1rem;
}

.search-close:hover {
  background: #333;
  color: white;
}

.search-form .form-input {
  flex: 1;
  max-width: 500px;
  width: calc(100% - 32px);
  padding: 12px 16px;
  border: 1px solid #d0d0d0;
  border-radius: 4px;
  font-size: 16px;
  font-family: "Dosis", sans-serif;
  outline: none;
  background: #ffffff;
  transition: border-color 0.2s ease;
}

.search-form .form-input:focus {
  border-color: #333;
}

.search-form .btn-search {
  padding: 12px 24px;
  background: #333;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-family: "Dosis", sans-serif;
  font-size: 16px;
  font-weight: 500;
  color: white;
  transition: background-color 0.2s ease;
  min-width: 100px;
  white-space: nowrap;
}



.search-form .btn-search:hover {
  background: #000;
}





.search-form .btn-search.loading {
  background: #666;
  cursor: not-allowed;
  opacity: 0.7;
}



.search-form .btn-search.loading:hover {
  background: #666;
}



.search-form .form-input.error {
  border-color: #e74c3c;
}



.search-error-message {
  color: #e74c3c;
  font-size: 14px;
  margin-top: 8px;
  text-align: center;
  display: none;
}

.search-error-message.show {
  display: block;
}

/* Search Suggestions */
.search-input-wrapper {
  position: relative;
  flex: 1;
}

.search-suggestions-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  display: none;
  max-height: 280px;
  overflow: hidden;
}

.search-suggestions-dropdown.show {
  display: block;
}

.suggestions-header {
  padding: 12px 16px 8px;
  font-size: 12px;
  font-weight: 600;
  color: #666;
  background: #f8f8f8;
  border-bottom: 1px solid #e0e0e0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0;
}

.suggestion-item {
  padding: 12px 16px;
  cursor: pointer;
  transition: background-color 0.2s ease;
  border-bottom: 1px solid #f0f0f0;
  font-weight: 400;
  color: #333;
}



.suggestion-item:hover {
  background: #f8f8f8;
  color: #000;
}



.suggestion-item:last-child {
  border-bottom: none;
}







/* Disable body scroll when search is open */
body.search-open {
  overflow: hidden;
}

/* ==========================================================================
   Mobile Responsiveness
   ========================================================================== */

@media (max-width: 768px) {
  .navbar {
    padding: 12px 24px;
  }
  
  .nav-left, .nav-right {
    display: none;
  }
  
  .hamburger {
    display: flex;
  }
  
  .navbar-brand {
    font-size: 1.6rem;
    letter-spacing: 2px;
    position: static;
    transform: none;
  }
  
  .mobile-nav.active {
    display: flex;
  }
  
  .shop-nav {
    width: 100%;
    padding: 15px 20px;
    flex-wrap: wrap;
    height: auto;
    min-height: var(--shop-nav-height);
  }
  
  .shop-nav-item {
    font-size: 12px;
    padding: 8px 16px;
    min-height: 44px;
    line-height: 28px;
  }
  
  .shop-title {
    font-size: 16px;
    padding-left: 20px;
  }
  
  #filterBtn {
    font-size: 11px;
    padding: 8px 16px;
    padding-right: 20px; 
}

@media (max-width: 480px) {
  .navbar {
    padding: 10px 20px;
  }
  
  .navbar-brand {
    font-size: 1.4rem;
    letter-spacing: 1.5px;
  }
  
  .mobile-nav {
    padding: 16px 0;
  }
  
  .mobile-nav a {
    padding: 10px 20px;
    font-size: 0.9rem;
  }
  
  .nav-left, .nav-right {
    gap: 10px;
  }
  
  .shop-nav {
    padding: 12px 15px;
    flex-wrap: wrap;
  }
  
  .shop-nav-item {
    font-size: 11px;
    padding: 6px 12px;
  }
  
  .shop-title {
    font-size: 14px;
    padding-left: 15px;
  }
  
  #filterBtn {
    font-size: 10px;
    padding: 6px 12px;
    padding-right: 15px;
  }
}

@media (max-width: 360px) {
  .shop-nav {
    padding: 10px 12px;
    flex-wrap: wrap;
  }
  
  .shop-nav-item {
    font-size: 10px;
    padding: 5px 10px;
    letter-spacing: 0.5px;
  }
  
  .shop-title {
    font-size: 13px;
    padding-left: 12px;
  }
  
  #filterBtn {
     font-size: 9px;
     padding: 5px 10px;
     padding-right: 12px;
   }
 }

}