:root {
  --color-primary: #1C1C1C;
  /* Charcoal */
  --color-accent: #8C857A;
  /* Warm Gray */
  --color-bg: #F4EEDF;
  /* Cream Beige */
  --color-bg-alt: #E6D8C3;
  /* Warm Sand */
  --color-text: #1C1C1C;
  --color-text-light: #FAFAF7;
  /* Off-white */
  --color-overlay: rgba(28, 28, 28, 0.4);

  --font-heading: 'Playfair Display', serif;
  --font-body: 'Outfit', sans-serif;

  --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-soft: 0 10px 40px rgba(0, 0, 0, 0.08);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  overflow-x: hidden;
  width: 100%;
  position: relative;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

/* Layout Utilities */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  padding: 5rem 0;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  color: var(--color-primary);
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background-color: var(--color-accent);
  margin: 1rem auto 0;
}

.bg-light {
  background-color: var(--color-bg-light);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 1rem 2.5rem;
  border: none;
  cursor: pointer;
  font-family: var(--font-body);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: var(--transition);
}

.btn-primary {
  background-color: var(--color-accent);
  color: #fff;
}

.btn-primary:hover {
  background-color: #b08d45;
  transform: translateY(-2px);
}

/* Header */
#main-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
  padding: 1.2rem 0;
  transition: padding 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.4s ease,
    box-shadow 0.4s ease;
}

#main-header.shrunk {
  padding: 0.6rem 0;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 4px 25px rgba(0, 0, 0, 0.1);
}

#main-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-primary);
  transition: font-size 0.4s ease, transform 0.4s ease;
}

#main-header.shrunk .logo {
  font-size: 1.4rem;
}

.logo .dot {
  color: var(--color-accent);
}

nav ul {
  display: flex;
  gap: 2rem;
}

nav a {
  font-weight: 500;
  color: var(--color-primary);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

nav a:hover {
  color: var(--color-accent);
}

.icon-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-primary);
  transition: var(--transition);
}

.icon-btn:hover {
  color: var(--color-accent);
}


/* Hero Section */
.hero {
  height: 100vh;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-align: center;

}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 0.9 ease-in-out;
  will-change: opacity;
}

.hero-bg.active {
  opacity: 1;
}

/* 4 imágenes */
.bg-1 {
  background-image: url("/images/Hero_background.png");
}

.bg-2 {
  background-image: url("/images/Hero_background_OT.png");
}

.bg-3 {
  background-image: url("/images/Hero_background_NI.png");
}

.bg-4 {
  background-image: url("/images/Hero_background_AS.png");
}


.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(10, 25, 47, 0.3), rgba(10, 25, 47, 0.6));
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  padding: 2rem;
}

.hero h1 {
  font-family: var(--font-heading);
  font-size: 4.5rem;
  margin-bottom: 1rem;
  line-height: 1.1;
}



/* Brands Scroller */
.brands-section {
  padding: 4rem 0;
  background-color: var(--color-bg);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.brand-list {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
  align-items: center;
}

.brand-item {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--color-accent);
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 2px;
  opacity: 0.6;
  transition: var(--transition);
  position: relative;
}

.brand-item:hover,
.brand-item.active {
  opacity: 1;
  color: var(--color-primary);
  transform: translateY(-2px);
}

.brand-item.active::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 100%;
  height: 1px;
  background: var(--color-primary);
}

/* Product Gallery */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 4rem 2rem;
}

.product-card {
  background: transparent;
  transition: var(--transition);
  cursor: pointer;
}

.product-card:hover .product-image img {
  transform: scale(1.05);
}

.product-image {
  height: 400px;
  background-color: #ECECEC;
  /* Light gray placeholder */
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.product-info {
  text-align: center;
}

.product-info h4 {
  font-family: var(--font-body);
  font-size: 1rem;
  margin-bottom: 0.2rem;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.product-info .price {
  color: var(--color-accent);
  font-weight: 500;
  font-size: 0.95rem;
}

/* Footer */
footer {
  background-color: var(--color-primary);
  color: #fff;
  padding: 5rem 0 2rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 4rem;
  margin-bottom: 4rem;
}

.footer-brand h3 {
  font-family: var(--font-heading);
  font-size: 2rem;
  margin-bottom: 1rem;
}

.footer-brand p {
  color: rgba(255, 255, 255, 0.7);
}

.footer-links h4,
.footer-social h4 {
  font-family: var(--font-body);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-links ul li {
  margin-bottom: 0.8rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
}

.footer-links a:hover {
  color: var(--color-accent);
}

.footer-social a {
  color: #fff;
  margin-right: 1.5rem;
  font-weight: 600;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.9rem;
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.8s forwards;
}

.delay-1 {
  animation-delay: 0.2s;
}

.delay-2 {
  animation-delay: 0.4s;
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 3rem;
  }

  #main-header .container {
    flex-direction: column;
    gap: 1rem;
  }

  nav ul {
    gap: 1rem;
  }
}

/* Appended Cart & Functional Styles */
/* Cart Count Badge */
.cart-count {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: var(--color-accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: bold;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  pointer-events: none;
}

/* Cart Overlay */
/* Cart Overlay with Blur */
.cart-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
  /* Lighter for glass effect */
  z-index: 1100;
  /* Higher than Navbar (1000) */
  opacity: 0;
  visibility: hidden;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: blur(8px);
  /* Stronger blur */
}

.cart-overlay.open {
  opacity: 1;
  visibility: visible;
}

/* Cart Sidebar with Dynamic Slide */
.cart-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  max-width: 450px;
  /* Slightly wider */
  height: 100vh;
  background-color: #fff;
  z-index: 1101;
  /* Higher than Overlay */
  transform: translateX(100%) scale(0.95);
  /* Slight scale effect */
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  /* Custom ease */
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
}

.cart-sidebar.open {
  transform: translateX(0) scale(1);
}

.cart-header {
  padding: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.cart-header h3 {
  font-family: var(--font-heading);
  margin: 0;
  color: var(--color-primary);
}

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

.cart-item {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.cart-item img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 4px;
  margin-right: 15px;
  background-color: #f0f0f0;
}

.cart-item-details {
  flex: 1;
}

.cart-item h4 {
  margin: 0 0 5px 0;
  font-size: 0.95rem;
  font-weight: 500;
}

.cart-item-price {
  font-size: 0.9rem;
  color: var(--color-text);
  opacity: 0.8;
}

.cart-item-remove {
  background: none;
  border: none;
  color: #e74c3c;
  cursor: pointer;
  font-size: 0.85rem;
  padding: 0;
  margin-top: 5px;
  text-decoration: underline;
}

.cart-item-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: 10px;
}

.qty-btn {
  width: 24px;
  height: 24px;
  border: 1px solid var(--color-primary);
  background: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  color: var(--color-primary);
  transition: all 0.2s;
}

.qty-btn:hover {
  background: var(--color-primary);
  color: #fff;
}

.cart-footer {
  padding: 20px;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  background-color: #fff;
}

.cart-total {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
  font-weight: bold;
  font-size: 1.2rem;
  font-family: var(--font-heading);
  color: var(--color-primary);
}

.btn-block {
  width: 100%;
  text-align: center;
}

.empty-cart-msg {
  text-align: center;
  margin-top: 50px;
  color: #888;
}

/* Toast Notification */
.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  background: var(--color-primary);
  color: #fff;
  padding: 12px 24px;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  animation: slideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
}

.toast.success {
  border-left: 4px solid var(--color-accent);
}

@keyframes slideIn {
  from {
    transform: translateY(100%);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Utility for JS category active state */
/* Gender Tabs */
.gender-tabs {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin: 30px auto;
  border-bottom: 1px solid #ddd;
  max-width: 600px;
  padding-bottom: 0;
}

.gender-tab {
  background: none;
  border: none;
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: #999;
  padding-bottom: 15px;
  cursor: pointer;
  position: relative;
  transition: all 0.3s;
  letter-spacing: 1px;
}

.gender-tab:hover {
  color: var(--color-primary);
}

.gender-tab.active {
  color: var(--color-primary);
  font-weight: 600;
}

.gender-tab.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--color-primary);
}


/* Checkout Modal (Enhanced) */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 2000;
  display: none;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(8px);
}

.modal-content {
  background: #fff;
  width: 90%;
  max-width: 1000px;
  /* Wider */
  border-radius: 4px;
  /* Sharper, more elegant */
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
  overflow: hidden;
  animation: modalUp 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  display: flex !important;
  flex-direction: row !important;
  /* Forces layout to be side-by-side */
  height: 600px;
  /* Fixed height for consistency */
  max-height: 90vh;
}

@keyframes modalUp {
  from {
    transform: translateY(50px);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Product Detail Specifics */
.modal-image {
  flex: 1.2;
  background: #f4f4f4;
  position: relative;
  height: 100%;
  /* Fill the container height */
  min-height: 0;
  /* Remove min-height constraint */
}

.modal-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Cover usually looks better for luxury, ensures no whitespace */
  display: block;
}

.modal-info {
  flex: 1;
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.modal-info h2 {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  margin-bottom: 10px;
  color: var(--color-text);
}

.price-tag {
  font-size: 1.5rem;
  color: var(--color-primary);
  font-weight: 600;
  margin-bottom: 20px;
}

.modal-section-title {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 10px;
  font-weight: 600;
  color: #888;
}

/* Size Buttons */
.size-selector {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 25px;
}

.size-btn {
  width: 45px;
  height: 45px;
  border: 1px solid #ddd;
  background: #fff;
  color: #333;
  cursor: pointer;
  border-radius: 8px;
  /* Softer corners */
  transition: all 0.2s ease;
  font-family: var(--font-body);
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
}

.size-btn:hover {
  border-color: var(--color-primary);
  transform: translateY(-2px);
}

.size-btn.selected {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
  box-shadow: 0 4px 10px rgba(184, 134, 11, 0.3);
}

/* Color Swatches */
.color-selector {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
}

.color-swatch {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid #ddd;
  /* Visibility helper */
  position: relative;
  transition: all 0.2s;
  background-size: cover;
  background-position: center;
}

.color-swatch:hover {
  transform: scale(1.1);
  border-color: #aaa;
}

.color-swatch.selected {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--color-primary);
}

/* Modal Actions */
/* Mobile Responsiveness */
/* Mobile Responsiveness */
@media (max-width: 850px) {
  .modal-content {
    flex-direction: column !important;
    /* Force Stack */
    width: 95%;
    height: 90vh;
    /* Use most of screen */
    border-radius: 8px;
    overflow-y: auto;
    /* Allow scroll */
  }

  .modal-image {
    width: 100%;
    height: 350px !important;
    /* Fixed height for image area */
    flex: none;
    min-height: 0;
  }

  .modal-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .modal-info {
    padding: 20px;
    flex: 1;
    /* Take remaining space */
    width: 100%;
    overflow-y: visible;
  }

  .modal-info h2 {
    font-size: 1.5rem;
  }
}

/* Why Us Section */
.info-section {
  padding: 6rem 0;
  background-color: #fff;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  text-align: center;
}

.info-item h4 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--color-primary);
}

.info-item p {
  color: #666;
  font-size: 0.95rem;
}

/* Reviews Section */
.reviews-section {
  padding: 6rem 0;
  background-color: var(--color-bg-alt);
}

.review-card {
  background: #fff;
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow-soft);
  max-width: 600px;
  margin: 0 auto;
}

.review-text {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-style: italic;
  margin-bottom: 1.5rem;
  color: var(--color-primary);
}

.review-author {
  font-size: 0.9rem;
  text-transform: uppercase;
  color: var(--color-accent);
  letter-spacing: 1px;
}

/* Header Search */
.header-actions {
  display: flex;
  gap: 1.5rem;
}

.header-search {
  flex: 1;
  max-width: 500px;
  margin: 0 2rem;
}

.header-search input {
  width: 100%;
  padding: 12px 20px;
  border-radius: 30px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  background: #fdfdfd;
  font-family: var(--font-body);
  transition: all 0.3s;
}

.header-search input:focus {
  outline: none;
  background: #fff;
  box-shadow: 0 0 0 2px var(--color-primary);
}

@media (max-width: 768px) {
  #main-header .container {
    flex-wrap: wrap;
    padding: 1rem;
  }

  .header-search {
    order: 3;
    /* Move search below logo and cart */
    width: 100%;
    max-width: 100%;
    margin: 10px 0 0 0;
  }

  .header-search input {
    font-size: 14px;
    padding: 10px 15px;
  }
}

/* Parallax Sections */
.parallax-section {
  height: 70vh;
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin: 0;
  width: 100%;
}

@media (max-width: 768px) {
  .parallax-section {
    background-attachment: scroll;
    /* Disable fixed bg on mobile for better stability/performance */
    height: 50vh;
  }
}

.parallax-1 {
  background-image: url('images/Parallax22.jpeg');
}


.parallax-2 {
  background-image: url('images/IAParallax.png');
}

.parallax-overlay {
  background: rgba(0, 0, 0, 0.15);
  width: 100%;
  height: 100%;
  position: absolute;
}

/* Clean Social Section */
.social-clean {
  text-align: center;
  padding: 6rem 1rem;
  background: #fff;
}

.social-clean h3 {
  font-family: var(--font-heading);
  font-size: 2rem;
  margin-bottom: 2.5rem;
  color: var(--color-primary);
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 3rem;
  flex-wrap: wrap;
}

.social-link {
  font-size: 1rem;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  position: relative;
  padding-bottom: 5px;
  font-weight: 500;
}

.social-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 1px;
  background: var(--color-primary);
  transition: width 0.3s;
}

.social-link:hover::after {
  width: 100%;
}

/* Brands Section - Logos */
.brand-list {
  display: flex;
  justify-content: center;
  gap: 3rem;
  overflow-x: auto;
  padding: 2rem 0;
  align-items: center;
}

.brand-item {
  cursor: pointer;
  transition: transform 0.3s, opacity 0.3s;
  opacity: 0.6;
  /* Default inactive */
  filter: grayscale(100%);
  /* B&W default */
}

.brand-item:hover,
.brand-item.active {
  transform: scale(1.1);
  opacity: 1;
  filter: grayscale(0%);
  /* Color on hover/active */
}

.brand-item img {
  height: 48px;
  width: auto;
  display: block;
  /* Removed brightness(0) to prevent black boxes on non-transparent images */
  /* filter: brightness(0); */
  transition: all 0.3s;
}

.brand-item:hover img,
.brand-item.active img {
  filter: none;
  /* Show original color (or black if simpleicon is black) */
  transform: scale(1.1);
}



/* Clean Modal Overlay (Single Definition) */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(28, 28, 28, 0.8);
  /* Darker luxe overlay */
  z-index: 2000;
  display: none;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(5px);
}

/* Modal UX Improvements */
.modal-content {
  background: var(--color-bg);
  width: 95%;
  max-width: 1000px;
  border-radius: 4px;
  /* Minimalist */
  display: flex;
  overflow: hidden;
  position: relative;
  max-height: 90vh;
  /* Viewport constraint */
  overflow-y: auto;
  /* Scrollable if needed */
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.close-modal-btn {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  font-size: 2.5rem;
  /* Larger */
  cursor: pointer;
  color: #333;
  z-index: 100;
  line-height: 1;
  padding: 10px;
  transition: color 0.3s;
}

.close-modal-btn:hover {
  color: var(--color-accent);
}

@keyframes modalUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .modal-content {
    flex-direction: column;
    height: 90vh;
    overflow-y: auto;
  }

  .insta-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Why Us Section Centering */
.info-section {
  text-align: center;
}

/* --- ANIMATIONS FOR WHY US --- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes popIn {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }

  70% {
    transform: scale(1.05);
  }

  100% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes expandLine {
  to {
    transform: scaleX(1);
  }
}

/* Scroll Trigger Classes */
.animate-on-scroll {
  opacity: 0;
  will-change: opacity, transform;
}

.animate-on-scroll.is-visible {
  animation: fadeInUp 0.8s ease-out forwards;
}

/* Why Us Title Styling */
.info-section h2 {
  position: relative;
  display: inline-block;
  color: var(--color-charcoal);
}

.info-section h2::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--color-primary);
  margin: 10px auto 0;
  transform: scaleX(0);
  transition: transform 0.8s ease;
}

.info-section h2.is-visible::after {
  animation: expandLine 0.8s 0.2s ease forwards;
}

/* Grid Items Animation */
.info-item {
  opacity: 0;
  transform: scale(0.9);
  transition: transform 0.3s, box-shadow 0.3s;
}

.info-item.is-visible {
  animation: popIn 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.info-item:nth-child(1) {
  animation-delay: 0.2s;
}

.info-item:nth-child(2) {
  animation-delay: 0.4s;
}

.info-item:nth-child(3) {
  animation-delay: 0.6s;
}

.info-item:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Size Guide Link */
.size-guide-link {
  color: var(--color-primary);
  text-decoration: underline;
  font-size: 0.9rem;
  cursor: pointer;
  margin-top: 10px;
  display: inline-block;
}

.size-guide-link:hover {
  color: var(--color-accent);
}

/* Enhanced Close Button */
#close-cart {
  font-size: 2rem;
  padding: 10px;
  cursor: pointer;
  transition: transform 0.3s, color 0.3s;
  line-height: 1;
}

#close-cart:hover {
  color: var(--color-accent);
  transform: rotate(90deg);
}

/* Cart Item Animation */
.cart-item {
  opacity: 0;
  transform: translateX(20px);
  animation: slideInRight 0.4s ease forwards;
}

@keyframes slideInRight {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Mobile Cart Adjustments */
@media (max-width: 768px) {
  .cart-sidebar {
    width: 100%;
    max-width: 100%;
  }

  .cart-header {
    padding: 15px 20px;
    background-color: #fff;
    position: sticky;
    top: 0;
    z-index: 10;
  }

  #close-cart {
    font-size: 2.5rem;
    /* Larger touch target */
    padding: 10px;
    display: block;
    color: #333;
  }
}

/* Stagger Item Delays */
.cart-item:nth-child(1) {
  animation-delay: 0.1s;
}

.cart-item:nth-child(2) {
  animation-delay: 0.2s;
}

.cart-item:nth-child(3) {
  animation-delay: 0.3s;
}

.cart-item:nth-child(4) {
  animation-delay: 0.4s;
}

/* Floating WhatsApp Button */
.floating-whatsapp {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #25D366, #128C7E);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
  z-index: 1000;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
  animation: pulse 2s infinite;
  cursor: pointer;
}

.floating-whatsapp svg {
  width: 32px;
  height: 32px;
}

.floating-whatsapp:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
  animation: none;
  /* Stop pulse on hover */
}

@keyframes pulse {

  0%,
  100% {
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
  }

  50% {
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.7), 0 0 0 10px rgba(37, 211, 102, 0.1);
  }
}

/* Footer Social Icon Hover Effects */
.footer-social a svg,
.footer-col a svg {
  transition: transform 0.3s ease;
}

.footer-social a:hover svg,
.footer-col a:hover svg {
  transform: scale(1.15) rotate(5deg);
}

/* Responsive Floating Button */
@media (max-width: 768px) {
  .floating-whatsapp {
    width: 50px;
    height: 50px;
    bottom: 15px;
    right: 15px;
  }

  .floating-whatsapp svg {
    width: 26px;
    height: 26px;
  }
}

/* Skeleton Loaders */
.skeleton-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  padding: 2rem 0;
  width: 100%;
}

.skeleton-card {
  background: transparent;
  animation: fadeIn 0.3s ease;
}

.skeleton {
  background: linear-gradient(90deg,
      #f0f0f0 0%,
      #e0e0e0 50%,
      #f0f0f0 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 4px;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

.skeleton-img {
  width: 100%;
  height: 400px;
  margin-bottom: 1.5rem;
}

.skeleton-text {
  height: 16px;
  margin-bottom: 10px;
}

.skeleton-text.title {
  width: 70%;
  height: 18px;
  margin: 0 auto 10px;
}

.skeleton-text.price {
  width: 40%;
  height: 20px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .skeleton-container {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem 1rem;
  }

  .skeleton-img {
    height: 300px;
  }
}

/* Heartbeat/Latency Animation for CTA */
.heartbeat-btn {
  opacity: 0;
  /* Hidden initially */
  animation: fadeInBtn 0.8s ease-out forwards 0.8s, heartbeat 2s infinite ease-in-out 1.6s;
  box-shadow: 0 0 0 0 rgba(140, 133, 122, 0.7);
  /* Using Accent Color */
}

@keyframes fadeInBtn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes heartbeat {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(140, 133, 122, 0.7);
  }

  50% {
    transform: scale(1.05);
    box-shadow: 0 0 0 15px rgba(140, 133, 122, 0);
  }

  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(140, 133, 122, 0);
  }
}

/* Responsive Overrides */
@media (max-width: 768px) {
  #main-header {
    height: auto !important;
    padding: 0.5rem 0;
  }

  #main-header .container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 0 1rem;
    gap: 0.5rem;
  }

  .logo {
    order: 1;
    font-size: 1.4rem !important;
    margin: 0 !important;
    flex: 1;
    /* Allow logo to take space on left */
    text-align: left;
  }

  .header-actions {
    order: 2;
    margin: 0 !important;
    display: flex;
    align-items: center;
    justify-content: flex-end;
  }

  .header-search {
    order: 3;
    width: 100% !important;
    margin: 0.5rem 0 0.2rem 0 !important;
    display: block !important;
    transition: transform 0.4s ease, opacity 0.4s ease;
  }

  #main-header.shrunk .header-search {
    transform: translateY(-2px) scale(0.98);
    opacity: 0.95;
  }

  .header-search input {
    width: 100%;
    padding: 10px 15px;
    font-size: 0.9rem;
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.1);
  }

  /* Compact body offset */
  body {
    padding-top: 130px !important;
  }

  /* Optimize Catalog Spacing */
  .page-header {
    padding: 20px 15px !important;
  }

  .page-header h1 {
    font-size: 2.2rem !important;
  }
}

/* Specific offsets for section titles */
.catalog-hero,
.hero {
  padding-top: 1rem !important;
  margin-top: 0 !important;
}

.section-title,
.catalog-hero h1 {
  margin-top: 0 !important;
}

/* Infinite Scroll Loader */
.load-more-indicator {
  grid-column: 1 / -1;
  text-align: center;
  padding: 2rem 0;
}

/* --- Reviews System (Carousel) --- */
.reviews-carousel-wrapper {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  overflow: hidden;
  padding: 1rem;
}

.reviews-slider {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.review-slide {
  min-width: 100%;
  padding: 10px;
  box-sizing: border-box;
  opacity: 0.3;
  transition: opacity 0.6s ease;
}

.review-slide.active {
  opacity: 1;
}

.review-card {
  background: #fff;
  padding: 3rem 2rem;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  text-align: center;
  border: 1px solid rgba(0, 0, 0, 0.03);
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 250px;
}

.review-stars {
  color: #ffd700;
  margin-bottom: 1rem;
  font-size: 1.2rem;
}

.review-text {
  font-style: italic;
  font-size: 1.2rem;
  line-height: 1.6;
  color: #333;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.review-author {
  font-weight: 700;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-size: 0.9rem;
}

.review-date {
  font-size: 0.8rem;
  color: #aaa;
  margin-top: 8px;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 2rem;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ddd;
  cursor: pointer;
  transition: all 0.3s ease;
}

.dot.active {
  background: var(--color-primary);
  width: 30px;
  border-radius: 5px;
}

/* Star Rating Input */
.star-rating {
  display: flex;
  flex-direction: row-reverse;
  justify-content: flex-end;
  gap: 5px;
  font-size: 1.5rem;
}

.star-rating span {
  cursor: pointer;
  color: #ddd;
  transition: color 0.2s;
}

.star-rating span:hover,
.star-rating span:hover~span,
.star-rating span.active,
.star-rating span.active~span {
  color: #ffd700;
}