/* ================================================
   DUSOOUSA - LUXURY PERFUMES FROM DUBAI
   Premium CSS with Animations & Optimizations
   ================================================ */

/* ===== CSS VARIABLES ===== */
:root {
  /* Brand Colors */
  --primary: #8B7355;
  --secondary: #1a1a1a;
  --accent: #D4AF37;
  --background: #F5F5F0;
  --text: #2c2c2c;
  --text-light: #6b6b6b;
  --white: #ffffff;

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 4rem;
  --spacing-xl: 6rem;

  /* Typography */
  --font-serif: 'Cormorant Garamond', serif;
  --font-sans: 'Montserrat', sans-serif;

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.16);
  --shadow-gold: 0 4px 20px rgba(212, 175, 55, 0.3);
}

/* ===== RESET & BASE STYLES ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  color: var(--text);
  background-color: var(--background);
  line-height: 1.7;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  line-height: 1.2;
  font-weight: 600;
  margin-bottom: 1rem;
}

h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2.5rem); }
h4 { font-size: clamp(1.25rem, 2.5vw, 1.75rem); }

p {
  margin-bottom: 1rem;
  line-height: 1.8;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-base);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  cursor: pointer;
  border: none;
  font-family: var(--font-sans);
}

/* ===== PRELOADER ===== */
.preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.hidden {
  opacity: 0;
  visibility: hidden;
}

.preloader-logo {
  font-family: var(--font-serif);
  font-size: 3rem;
  color: var(--accent);
  animation: pulse 2s ease-in-out infinite;
}

/* ===== HEADER & NAVIGATION ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: transparent;
  z-index: 1000;
  transition: var(--transition-base);
  padding: 1.5rem 0;
}

.header.scrolled {
  background: rgba(26, 26, 26, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-md);
  padding: 1rem 0;
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: 2px;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2.5rem;
  align-items: center;
}

.nav-link {
  color: var(--white);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.5px;
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition-base);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.lang-switcher {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.lang-btn {
  background: transparent;
  color: var(--white);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-size: 0.85rem;
  font-weight: 500;
  transition: var(--transition-base);
  opacity: 0.7;
}

.lang-btn:hover,
.lang-btn.active {
  background: var(--accent);
  opacity: 1;
}

.mobile-menu-toggle {
  display: none;
  background: transparent;
  color: var(--white);
  font-size: 1.5rem;
  padding: 0.5rem;
}

/* ===== HERO SECTION ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(135deg, var(--secondary) 0%, #2d2416 100%);
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.3;
  transform: scale(1.1);
}

.hero-parallax {
  will-change: transform;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(26, 26, 26, 0.5), rgba(26, 26, 26, 0.8));
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  text-align: center;
  color: var(--white);
}

.hero-subtitle {
  font-size: 1.1rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
  opacity: 0;
  animation: fadeInUp 1s ease forwards 0.2s;
}

.hero-title {
  font-size: clamp(3rem, 7vw, 5.5rem);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeInUp 1s ease forwards 0.4s;
}

.hero-description {
  font-size: 1.25rem;
  max-width: 700px;
  margin: 0 auto 2.5rem;
  line-height: 1.8;
  opacity: 0;
  animation: fadeInUp 1s ease forwards 0.6s;
}

.hero-cta {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeInUp 1s ease forwards 0.8s;
}

/* ===== BUTTONS ===== */
.btn {
  padding: 1rem 2.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 4px;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  letter-spacing: 0.5px;
}

.btn-primary {
  background: var(--accent);
  color: var(--secondary);
}

.btn-primary:hover {
  background: #e5c04a;
  transform: translateY(-2px);
  box-shadow: var(--shadow-gold);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border: 2px solid var(--white);
}

.btn-outline:hover {
  background: var(--white);
  color: var(--secondary);
  transform: translateY(-2px);
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn:active::before {
  width: 300px;
  height: 300px;
}

/* ===== SECTIONS ===== */
.section {
  padding: var(--spacing-xl) 0;
  position: relative;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-lg);
}

.section-subtitle {
  font-size: 1rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.section-title {
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  color: var(--secondary);
  margin-bottom: 1rem;
}

.section-description {
  font-size: 1.1rem;
  color: var(--text-light);
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.8;
}

/* ===== FADE-IN ANIMATIONS ===== */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-left {
  opacity: 0;
  transform: translateX(-50px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.fade-in-right {
  opacity: 0;
  transform: translateX(50px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* ===== PRODUCT CARDS ===== */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2.5rem;
  margin-top: 3rem;
}

.product-card {
  background: var(--white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
  cursor: pointer;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.product-image-wrapper {
  position: relative;
  width: 100%;
  padding-top: 120%;
  overflow: hidden;
  background: linear-gradient(135deg, #f5f5f0 0%, #e8e8e0 100%);
}

.product-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.product-card:hover .product-image {
  transform: scale(1.1);
}

.product-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--accent);
  color: var(--secondary);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.product-content {
  padding: 2rem;
}

.product-brand {
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.product-title {
  font-size: 1.75rem;
  margin-bottom: 1rem;
  color: var(--secondary);
}

.product-description {
  font-size: 0.95rem;
  color: var(--text-light);
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.product-notes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.note-tag {
  background: var(--background);
  color: var(--text);
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  font-size: 0.8rem;
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.5rem;
  border-top: 1px solid #e8e8e0;
}

.product-price {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-serif);
}

.product-cta {
  background: var(--secondary);
  color: var(--white);
  padding: 0.8rem 1.5rem;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: 600;
  transition: var(--transition-base);
}

.product-cta:hover {
  background: var(--accent);
  color: var(--secondary);
}

/* ===== FEATURED PRODUCT SECTION ===== */
.featured-product {
  background: linear-gradient(135deg, var(--secondary) 0%, #2d2416 100%);
  color: var(--white);
  padding: var(--spacing-xl) 0;
}

.featured-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.featured-image-wrapper {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.featured-image {
  width: 100%;
  height: auto;
  display: block;
}

.featured-content h2 {
  color: var(--white);
  margin-bottom: 1rem;
}

.featured-content .section-subtitle {
  color: var(--accent);
}

.pyramid {
  margin: 2rem 0;
}

.pyramid-level {
  background: rgba(255, 255, 255, 0.05);
  border-left: 4px solid var(--accent);
  padding: 1.5rem;
  margin-bottom: 1rem;
  border-radius: 4px;
  transition: var(--transition-base);
}

.pyramid-level:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateX(8px);
}

.pyramid-label {
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.pyramid-notes {
  font-size: 1.1rem;
  line-height: 1.6;
}

/* ===== TESTIMONIALS ===== */
.testimonials {
  background: var(--white);
  padding: var(--spacing-xl) 0;
}

.testimonials-slider {
  position: relative;
  max-width: 900px;
  margin: 3rem auto 0;
  overflow: hidden;
}

.testimonial-card {
  background: var(--background);
  padding: 3rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.testimonial-text {
  font-size: 1.25rem;
  font-style: italic;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 2rem;
}

.testimonial-author {
  font-weight: 600;
  color: var(--secondary);
  margin-bottom: 0.25rem;
}

.testimonial-location {
  font-size: 0.9rem;
  color: var(--text-light);
}

.slider-dots {
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  margin-top: 2rem;
}

.slider-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d0d0d0;
  transition: var(--transition-base);
  cursor: pointer;
}

.slider-dot.active {
  background: var(--accent);
  width: 30px;
  border-radius: 5px;
}

/* ===== FAQ ACCORDION ===== */
.faq {
  background: var(--background);
}

.faq-container {
  max-width: 900px;
  margin: 0 auto;
}

.faq-item {
  background: var(--white);
  margin-bottom: 1rem;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.faq-question {
  width: 100%;
  text-align: left;
  padding: 1.5rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--secondary);
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: var(--transition-base);
}

.faq-question:hover {
  background: var(--background);
}

.faq-icon {
  font-size: 1.5rem;
  transition: transform var(--transition-base);
  color: var(--accent);
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.active .faq-answer {
  max-height: 500px;
  padding: 0 2rem 1.5rem 2rem;
}

.faq-answer p {
  color: var(--text-light);
  line-height: 1.8;
}

/* ===== NEWSLETTER ===== */
.newsletter {
  background: linear-gradient(135deg, var(--primary) 0%, #6b5739 100%);
  color: var(--white);
  text-align: center;
  padding: var(--spacing-lg) 0;
}

.newsletter-form {
  max-width: 600px;
  margin: 2rem auto 0;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

.newsletter-input {
  flex: 1;
  min-width: 250px;
  padding: 1rem 1.5rem;
  border: none;
  border-radius: 4px;
  font-size: 1rem;
}

.newsletter-btn {
  padding: 1rem 2.5rem;
  background: var(--secondary);
  color: var(--white);
  font-weight: 600;
  border-radius: 4px;
  transition: var(--transition-base);
}

.newsletter-btn:hover {
  background: var(--accent);
  color: var(--secondary);
  transform: translateY(-2px);
}

/* ===== FOOTER ===== */
.footer {
  background: var(--secondary);
  color: var(--white);
  padding: var(--spacing-lg) 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-section h3 {
  color: var(--accent);
  margin-bottom: 1.5rem;
  font-size: 1.25rem;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.8rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  transition: var(--transition-base);
}

.footer-links a:hover {
  color: var(--accent);
  padding-left: 5px;
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1rem;
}

.social-link {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-base);
}

.social-link:hover {
  background: var(--accent);
  transform: translateY(-3px);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.6);
}

/* ===== WHATSAPP BUTTON ===== */
.whatsapp-float {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 60px;
  height: 60px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
  z-index: 1000;
  cursor: pointer;
  transition: var(--transition-base);
  animation: pulse 2s infinite;
}

.whatsapp-float:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(37, 211, 102, 0.6);
}

.whatsapp-float svg {
  width: 30px;
  height: 30px;
  fill: white;
}

/* ===== BACK TO TOP ===== */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  left: 2rem;
  width: 50px;
  height: 50px;
  background: var(--accent);
  color: var(--secondary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-base);
  z-index: 999;
  cursor: pointer;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

/* ===== COOKIE CONSENT ===== */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--secondary);
  color: var(--white);
  padding: 1.5rem;
  z-index: 1001;
  transform: translateY(100%);
  transition: transform var(--transition-base);
}

.cookie-consent.visible {
  transform: translateY(0);
}

.cookie-content {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.cookie-text {
  flex: 1;
  min-width: 300px;
}

.cookie-buttons {
  display: flex;
  gap: 1rem;
}

.cookie-btn {
  padding: 0.8rem 1.5rem;
  border-radius: 4px;
  font-weight: 600;
  transition: var(--transition-base);
}

.cookie-accept {
  background: var(--accent);
  color: var(--secondary);
}

.cookie-decline {
  background: transparent;
  color: var(--white);
  border: 1px solid var(--white);
}

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

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1024px) {
  .featured-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 400px;
    height: 100vh;
    background: var(--secondary);
    flex-direction: column;
    padding: 6rem 2rem 2rem;
    gap: 2rem;
    transition: right var(--transition-base);
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.3);
  }

  .nav-menu.active {
    right: 0;
  }

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

  .products-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-cta {
    flex-direction: column;
  }

  .newsletter-form {
    flex-direction: column;
  }

  .cookie-content {
    flex-direction: column;
    text-align: center;
  }

  .whatsapp-float {
    bottom: 1.5rem;
    right: 1.5rem;
    width: 55px;
    height: 55px;
  }

  .back-to-top {
    bottom: 1.5rem;
    left: 1.5rem;
    width: 45px;
    height: 45px;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 14px;
  }

  .container {
    padding: 0 1rem;
  }

  .section {
    padding: var(--spacing-lg) 0;
  }

  .product-content {
    padding: 1.5rem;
  }
}

/* ===== LAZY LOADING PLACEHOLDER ===== */
.lazy-loading {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* ===== PRINT STYLES ===== */
@media print {
  .header,
  .whatsapp-float,
  .back-to-top,
  .cookie-consent,
  .newsletter {
    display: none;
  }
}
