/* ===================================
   DROPDOWN MENU STYLES
   =================================== */

/* ===================================
   FOOTER SOCIAL MEDIA
   =================================== */
.footer-social {
  margin: 25px 0;
}

.footer-social-title {
  font-size: 0.85rem;
  color: var(--gold-light);
  margin-bottom: 15px;
  letter-spacing: 0.1em;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 25px;
  font-size: 0.85rem;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 1px solid rgba(201, 164, 92, 0.3);
}

.social-link svg {
  flex-shrink: 0;
}

.social-link.instagram {
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  color: white;
  border: none;
}

.social-link.instagram:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(225, 48, 108, 0.4);
}

.social-link.facebook {
  background: #1877F2;
  color: white;
  border: none;
}

.social-link.facebook:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(24, 119, 242, 0.4);
}

.social-link.emag {
  background: linear-gradient(135deg, #f5a623 0%, #f7931e 100%);
  color: white;
  border: none;
}

.social-link.emag:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(247, 147, 30, 0.4);
}

/* ===================================
   FOOTER LEGAL (ANPC & SOL)
   =================================== */
.footer-legal {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
  margin: 30px auto 15px;
  padding: 25px 30px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  flex-wrap: wrap;
  max-width: 500px;
}

.legal-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  padding: 12px 18px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 8px;
  min-width: 180px;
  min-height: 60px;
}

.legal-link:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.legal-link img {
  height: 45px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
}

.legal-text {
  color: var(--choco-dark, #4a3728);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 10px 20px;
  border: 1px solid var(--gold-light);
  border-radius: 6px;
}

.footer-legal-text {
  font-size: 0.75rem;
  color: rgba(232, 213, 168, 0.7);
  max-width: 600px;
  margin: 0 auto 20px;
  line-height: 1.6;
}

.footer-legal-text a {
  color: var(--gold-light);
  text-decoration: underline;
}

.footer-legal-text a:hover {
  color: var(--gold);
}

/* Responsive Footer Social & Legal */
@media (max-width: 768px) {
  .social-links {
    gap: 12px;
  }

  .social-link {
    padding: 8px 15px;
    font-size: 0.8rem;
  }

  .footer-legal {
    gap: 15px;
    padding: 15px;
  }

  .legal-link img {
    height: 30px;
  }
}

@media (max-width: 480px) {
  .social-link span:not(.social-link svg) {
    display: none;
  }

  .social-link {
    padding: 12px;
    border-radius: 50%;
  }
}

/* ===================================
   CART SIDEBAR & OVERLAY FIX
   =================================== */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(47, 35, 26, 0.6);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  z-index: 10000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  cursor: pointer;
}

.cart-overlay.active {
  opacity: 1;
  visibility: visible;
}

.cart-sidebar {
  position: fixed;
  top: 0;
  right: 0;
  width: 380px;
  max-width: 90vw;
  height: 100%;
  max-height: 100vh;
  max-height: 100dvh;
  background: var(--cream-light, #fffcf7);
  box-shadow: -5px 0 30px rgba(47, 35, 26, 0.2);
  z-index: 10001;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.cart-sidebar.active {
  transform: translateX(0);
}

.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid rgba(201, 164, 92, 0.2);
  background: var(--cream, #faf6ef);
  flex: 0 0 auto;
}

.cart-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--choco-dark, #2f231a);
  margin: 0;
}

.cart-close {
  width: 36px;
  height: 36px;
  border: none;
  background: rgba(201, 164, 92, 0.15);
  color: var(--gold-dark, #9a7b3d);
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-close:hover {
  background: var(--gold, #c9a45c);
  color: white;
  transform: rotate(90deg);
}

.cart-items {
  flex: 1 1 auto;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 15px;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  min-height: 0;
  touch-action: pan-y;
}

.cart-footer {
  flex: 0 0 auto;
  padding: 15px 20px;
  border-top: 1px solid rgba(201, 164, 92, 0.2);
  background: var(--cream, #faf6ef);
  touch-action: manipulation;
}

/* ═══════════════════════════════════════════════════════════
   COȘ MOBIL - FIX COMPLET
═══════════════════════════════════════════════════════════ */
@media (max-width: 600px) {
  .cart-sidebar {
    width: 100%;
    max-width: 100%;
    height: 100%;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    border-radius: 0;
  }
  
  .cart-header {
    padding: 10px 15px;
    flex: 0 0 auto;
  }
  
  .cart-title {
    font-size: 1.1rem;
  }
  
  .cart-close {
    width: 32px;
    height: 32px;
  }
  
  .cart-items {
    flex: 1 1 auto;
    padding: 10px 15px;
    overflow-y: scroll;
    -webkit-overflow-scrolling: touch;
  }
  
  .cart-footer {
    flex: 0 0 auto;
    padding: 10px 15px;
    padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  }
  
  /* Summary într-o singură linie */
  .cart-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
    font-size: 0.8rem;
  }
  
  .cart-summary-row {
    display: none;
  }
  
  .cart-summary-row.total {
    display: flex;
    justify-content: space-between;
    width: 100%;
    font-size: 1.1rem;
    font-weight: 700;
    padding: 0;
    margin: 0;
    border: none;
  }
  
  .cart-summary-row.discount {
    display: flex;
    width: 100%;
    font-size: 0.8rem;
    color: #2e7d32;
  }
  
  /* Ascunde nota de plată pe mobil */
  .payment-note {
    display: none;
  }
  
  /* Buton compact */
  .btn-checkout {
    width: 100%;
    padding: 12px 20px;
    font-size: 0.95rem;
    margin-top: 10px;
  }
  
  /* Compact cart items */
  .cart-item {
    padding: 8px 0;
    gap: 10px;
  }
  
  .cart-item-image {
    width: 40px;
    height: 40px;
  }
  
  .cart-item-name {
    font-size: 0.85rem;
  }
  
  .cart-item-meta {
    font-size: 0.7rem;
  }
  
  .cart-qty-btn {
    width: 24px;
    height: 24px;
    font-size: 0.9rem;
  }
  
  .cart-qty-value {
    min-width: 20px;
    font-size: 0.85rem;
  }
  
  .cart-item-remove {
    font-size: 0.65rem;
    padding: 2px 6px;
  }
  
  .cart-item-price {
    font-size: 0.8rem;
  }
  
  .cart-item-discount-badge {
    font-size: 0.6rem;
    padding: 2px 5px;
  }
  
  .cart-discount-progress {
    padding: 6px 8px;
    font-size: 0.75rem;
    margin-top: 8px;
  }
  
  .cart-discount-progress small {
    display: none;
  }
}

/* Landscape pe telefon */
@media (max-height: 500px) {
  .cart-sidebar {
    width: 60%;
    max-width: 350px;
  }
  
  .cart-header {
    padding: 8px 10px;
  }
  
  .cart-title {
    font-size: 1rem;
  }
  
  .cart-close {
    width: 28px;
    height: 28px;
    font-size: 1rem;
  }
  
  .cart-items {
    padding: 5px 10px;
  }
  
  .cart-footer {
    padding: 8px 10px;
  }
  
  .cart-summary-row.total {
    font-size: 1rem;
  }
  
  .payment-note {
    display: none;
  }
  
  .btn-checkout {
    padding: 10px 15px;
    font-size: 0.85rem;
    margin-top: 8px;
  }
  
  .cart-item {
    padding: 5px 0;
  }
  
  .cart-item-image {
    width: 30px;
    height: 30px;
  }
  
  .cart-item-name {
    font-size: 0.8rem;
  }
  
  .cart-item-meta {
    font-size: 0.65rem;
  }
  
  .cart-item-actions {
    gap: 5px;
  }
  
  .cart-qty-btn {
    width: 22px;
    height: 22px;
  }
  
  .cart-item-remove {
    display: none;
  }
  
  .cart-item-price {
    font-size: 0.75rem;
  }
  
  .cart-discount-progress {
    display: none;
  }
}

/* ===================================
   CART DISCOUNT STYLES
   =================================== */
.cart-item.has-discount {
  background: linear-gradient(135deg, rgba(201, 164, 92, 0.08), rgba(201, 164, 92, 0.03));
  border-left: 3px solid var(--gold);
  margin-left: -15px;
  padding-left: 15px;
}

.cart-item-discount-badge {
  font-size: 0.7rem;
  color: var(--gold-dark);
  background: rgba(201, 164, 92, 0.15);
  padding: 3px 8px;
  border-radius: 10px;
  display: inline-block;
  margin-top: 4px;
  font-weight: 500;
}

.cart-item-price .price-original {
  text-decoration: line-through;
  color: var(--muted);
  font-size: 0.85em;
}

.cart-item-price .price-discounted {
  color: var(--gold-dark);
  font-weight: 600;
}

.cart-discount-progress {
  background: linear-gradient(135deg, rgba(201, 164, 92, 0.1), rgba(201, 164, 92, 0.05));
  border: 1px dashed var(--gold);
  border-radius: 10px;
  padding: 12px 15px;
  margin-top: 15px;
  font-size: 0.85rem;
  text-align: center;
  color: var(--choco);
}

.cart-discount-progress small {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.8em;
}

/* ===================================
   PAGE HERO (pentru paginile de categorii)
   =================================== */
.page-hero {
  text-align: center;
  padding: 80px 40px 60px;
  background: 
    radial-gradient(ellipse at 30% 20%, rgba(255, 200, 150, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 70% 80%, rgba(255, 180, 200, 0.12) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 50%, rgba(201, 164, 92, 0.08) 0%, transparent 60%),
    var(--cream-light);
  position: relative;
}

.page-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 15% 25%, var(--gold-light) 1px, transparent 1px),
    radial-gradient(circle at 85% 75%, var(--gold-light) 1px, transparent 1px);
  background-size: 80px 80px;
  opacity: 0.3;
  pointer-events: none;
}

.page-hero-content {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.page-hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  font-weight: 600;
  color: var(--choco-dark);
  margin-bottom: 20px;
  line-height: 1.2;
}

.page-hero .hero-pretitle {
  font-size: 0.85rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

.page-hero .hero-pretitle::before,
.page-hero .hero-pretitle::after {
  content: "";
  width: 40px;
  height: 1px;
  background: var(--gold);
}

.page-hero .hero-subtitle {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-style: italic;
  color: var(--choco-light);
  margin-bottom: 30px;
  max-width: 550px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

.page-hero .hero-badges {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.page-hero .hero-badge {
  background: var(--white);
  border: 1px solid var(--gold);
  padding: 10px 20px;
  border-radius: 25px;
  font-size: 0.8rem;
  color: var(--choco);
  letter-spacing: 0.05em;
  box-shadow: 0 2px 10px rgba(201, 164, 92, 0.15);
  transition: all 0.3s ease;
}

.page-hero .hero-badge:hover {
  background: var(--gold);
  color: var(--white);
  transform: translateY(-2px);
}

/* ===================================
   CATEGORY BUTTONS
   =================================== */
.category-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
  margin-top: 30px;
}

/* Responsive Page Hero */
@media (max-width: 768px) {
  .page-hero {
    padding: 50px 20px 40px;
  }

  .page-hero h1 {
    font-size: 2rem;
  }

  .page-hero .hero-subtitle {
    font-size: 1rem;
  }

  .page-hero .hero-badges {
    gap: 8px;
  }

  .page-hero .hero-badge {
    padding: 8px 15px;
    font-size: 0.75rem;
  }
}

/* Dropdown Container */
.nav-links .dropdown {
  position: relative;
}

/* Dropdown Toggle */
.dropdown-toggle {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* Dropdown Menu */
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  min-width: 200px;
  background: linear-gradient(135deg, #fffdf8 0%, #faf6ef 100%);
  border: 1px solid var(--gold);
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(74, 55, 40, 0.2);
  padding: 10px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%) translateY(10px);
  transition: all 0.3s ease;
  z-index: 1000;
  list-style: none;
}

/* Show dropdown on hover */
.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* Dropdown Items */
.dropdown-menu li {
  margin: 0;
}

.dropdown-menu li a {
  display: block;
  padding: 12px 20px;
  color: var(--choco);
  text-decoration: none;
  font-family: 'Josefin Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 400;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.dropdown-menu li a:hover {
  background: linear-gradient(90deg, rgba(201, 164, 92, 0.15) 0%, transparent 100%);
  color: var(--gold-dark);
  padding-left: 25px;
}

/* Dropdown Divider */
.dropdown-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--gold) 50%, transparent 100%);
  margin: 8px 15px;
}

/* Arrow indicator */
.dropdown-toggle::after {
  content: '';
  display: inline-block;
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  margin-left: 5px;
  transition: transform 0.3s ease;
}

.dropdown:hover .dropdown-toggle::after {
  transform: rotate(180deg);
}

/* Decorative top border */
.dropdown-menu::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20px;
  right: 20px;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, var(--gold) 50%, transparent 100%);
}

/* Collection link styles for clickable cards */
.collection-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.collection-link:hover .collection-card {
  transform: translateY(-5px);
}

/* ===================================
   MOBILE DROPDOWN STYLES
   =================================== */

@media (max-width: 768px) {
  .dropdown-menu {
    position: static;
    transform: none;
    opacity: 1;
    visibility: visible;
    box-shadow: none;
    border: none;
    background: rgba(201, 164, 92, 0.1);
    border-radius: 8px;
    margin: 10px 0;
    padding: 5px 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .dropdown.active .dropdown-menu {
    max-height: 300px;
  }

  .dropdown-menu li a {
    padding: 10px 15px;
    font-size: 0.9rem;
  }

  .dropdown-menu li a:hover {
    padding-left: 20px;
  }

  .dropdown-toggle::after {
    border-top: 4px solid currentColor;
  }

  .dropdown-menu::before {
    display: none;
  }
}

/* ===================================
   ACTIVE STATE FOR CURRENT PAGE
   =================================== */

.dropdown-menu li a.active {
  background: linear-gradient(90deg, rgba(201, 164, 92, 0.25) 0%, transparent 100%);
  color: var(--gold-dark);
  font-weight: 500;
}

.dropdown-menu li a.active::before {
  content: '→ ';
}

/* ===================================
   MENIU MOBIL - RESPONSIVE
   =================================== */

@media (max-width: 768px) {
  /* Navigare mobilă */
  .nav-links {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, #fffcf7 0%, #faf6ef 100%);
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    gap: 0;
    z-index: 9999;
    padding: 80px 20px 40px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav-links.mobile-open {
    display: flex;
  }

  /* Buton meniu - ascunde când meniul e deschis */
  .mobile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: 2px solid var(--gold);
    border-radius: 10px;
    font-size: 1.4rem;
    color: var(--choco);
    cursor: pointer;
    z-index: 10000;
    position: relative;
    transition: all 0.3s ease;
  }

  .mobile-menu-btn:hover {
    background: var(--gold);
    color: white;
  }

  /* Când meniul e deschis, butonul devine fix în colț */
  body.mobile-menu-open .mobile-menu-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    background: var(--gold);
    color: white;
    border-color: var(--gold);
  }

  .nav-links li {
    width: 100%;
    text-align: center;
    border-bottom: 1px solid rgba(201, 164, 92, 0.2);
    list-style: none;
  }

  .nav-links li:last-child {
    border-bottom: none;
  }

  .nav-links > li > a {
    display: block;
    padding: 18px 20px;
    font-size: 1.1rem;
    color: var(--choco);
    letter-spacing: 0.1em;
  }

  .nav-links > li > a:hover,
  .nav-links > li > a.active {
    background: rgba(201, 164, 92, 0.15);
    color: var(--gold-dark);
  }

  /* Dropdown în mobil - ascuns default */
  .nav-links .dropdown {
    position: relative;
  }

  .nav-links .dropdown-toggle {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
  }

  .nav-links .dropdown-menu {
    position: static !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    transform: none !important;
    opacity: 0;
    visibility: hidden;
    max-height: 0;
    overflow: hidden;
    box-shadow: none !important;
    border: none !important;
    background: rgba(201, 164, 92, 0.1) !important;
    padding: 0;
    min-width: 100% !important;
    width: 100% !important;
    border-radius: 0 !important;
    transition: all 0.3s ease;
    display: block !important;
  }

  /* Dropdown deschis pe mobil */
  .nav-links .dropdown.dropdown-open .dropdown-menu {
    opacity: 1 !important;
    visibility: visible !important;
    max-height: 500px !important;
    padding: 10px 0 !important;
  }

  .nav-links .dropdown-menu li {
    border-bottom: 1px dashed rgba(201, 164, 92, 0.15);
  }

  .nav-links .dropdown-menu li:last-child {
    border-bottom: none;
  }

  .nav-links .dropdown-menu a {
    padding: 14px 30px;
    font-size: 0.95rem;
    display: block;
  }

  .nav-links .dropdown-divider {
    height: 1px;
    background: rgba(201, 164, 92, 0.3);
    margin: 5px 20px;
  }

  /* Dezactivează hover pe dropdown pentru mobil */
  .nav-links .dropdown:hover .dropdown-menu {
    opacity: 0;
    visibility: hidden;
    max-height: 0;
  }

  .nav-links .dropdown.dropdown-open:hover .dropdown-menu,
  .nav-links .dropdown.dropdown-open .dropdown-menu {
    opacity: 1;
    visibility: visible;
    max-height: 500px;
  }
}

/* Desktop - ascunde butonul mobil */
@media (min-width: 769px) {
  .mobile-menu-btn {
    display: none;
  }

  .nav-links {
    display: flex;
  }
}

/* ===================================
   FIX FORȚAT DROPDOWN MOBIL
   =================================== */
@media screen and (max-width: 768px) {
  .dropdown-menu,
  .nav-links .dropdown-menu,
  .dropdown .dropdown-menu,
  ul.dropdown-menu {
    position: static !important;
    left: 0 !important;
    right: 0 !important;
    top: auto !important;
    transform: none !important;
    margin: 0 !important;
    float: none !important;
    width: 100% !important;
    min-width: 100% !important;
    max-width: 100% !important;
  }
  
  .dropdown:hover > .dropdown-menu {
    transform: none !important;
  }
}

/* ===================================
   TOUCH DEVICES (telefoane, tablete)
   Dezactivează hover, folosește click
   =================================== */

/* Când e touch device, dropdown-ul NU se deschide la hover */
.touch-device .dropdown:hover .dropdown-menu {
  opacity: 0;
  visibility: hidden;
}

/* Se deschide doar cu clasa dropdown-open (adăugată prin JS) */
.touch-device .dropdown.dropdown-open .dropdown-menu {
  opacity: 1 !important;
  visibility: visible !important;
}

/* Pe touch device în landscape - dropdown sub link */
.touch-device .dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
}

.touch-device .dropdown.dropdown-open .dropdown-menu {
  transform: translateX(-50%) translateY(0);
}

/* Indicator vizual că e clickable */
.touch-device .dropdown-toggle {
  cursor: pointer;
}