:root {
  --primary: #8b5e3c;
  --primary-hover: #6f472b;
  --bg-light: #f9f8f6;
  --dark: #222222;
  --gray: #666666;
  --border: #e6e3dd;
  --white: #ffffff;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Plus Jakarta Sans', sans-serif;
}

/* Previne mărirea automată și distorsionată a textelor pe mobil */
html, body {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-light);
  color: var(--dark);
  line-height: 1.6;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* 1. Bara de sus */
.top-bar {
  background: #1c1c1c;
  color: #bbb;
  font-size: 0.85rem;
  padding: 0.5rem 0;
}

.top-bar-content {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* 2. Meniu Navigare */
.navbar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

/* Suport atât pentru logo text cât și pentru logo.jpg */
.logo, .logo-link {
  font-size: 1.5rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--dark);
  letter-spacing: 1px;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.logo span {
  color: var(--primary);
}

/* Logo Imagine - Mărit și bine proporționat pe calculator */
.logo img, .logo-link img, .logo-img {
  height: 72px;
  max-width: 220px;
  width: auto;
  object-fit: contain;
  display: block;
}

.navbar nav {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.navbar nav a {
  text-decoration: none;
  color: var(--dark);
  font-weight: 500;
  transition: color 0.2s;
}

.navbar nav a:hover {
  color: var(--primary);
}

.nav-categories-btn {
  font-weight: 600;
  color: var(--dark);
  text-decoration: none;
}

/* Buton E-mail */
.nav-email-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: #333333;
  color: #ffffff !important;
  padding: 0.45rem 1rem;
  border-radius: 20px;
  font-weight: 600;
  text-decoration: none;
  font-size: 0.92rem;
  transition: background-color 0.2s, transform 0.2s;
}

.nav-email-btn:hover {
  background-color: var(--primary);
  transform: translateY(-2px);
}

.nav-email-btn .mail-icon {
  fill: #ffffff;
}

/* Buton WhatsApp Rotund & Curat */
.nav-whatsapp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: #25d366;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(37, 211, 102, 0.25);
  transition: background-color 0.2s, transform 0.15s;
}

.nav-whatsapp-btn:hover {
  background-color: #1ebc57;
  transform: scale(1.06);
}

.nav-whatsapp-btn .wa-icon {
  width: 20px;
  height: 20px;
  fill: #ffffff;
}

/* Buton Coș */
.cart-btn {
  background: none;
  border: 1px solid var(--border);
  padding: 0.5rem 1.1rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-shrink: 0;
}

/* Butoane Generale */
.btn {
  display: inline-block;
  padding: 0.8rem 1.6rem;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.2s;
  font-size: 0.95rem;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--white);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
}

.btn-secondary {
  background-color: var(--white);
  color: var(--dark);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background-color: #f0eee9;
}

.btn-block {
  width: 100%;
}

/* 3. Hero (Fundal complet luminos & natural) */
.hero {
  background: url('imagini/fundal.jpg') center/cover no-repeat;
  color: var(--white);
  padding: 6.5rem 0;
  text-align: center;
}

.hero h1 {
  font-size: 2.6rem;
  margin-bottom: 1rem;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5); /* Asigură lizibilitatea pe fundal deschis */
}

.hero p {
  font-size: 1.2rem;
  max-width: 650px;
  margin: 0 auto 2.2rem;
  color: #ffffff;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
}

.hero h1 {
  font-size: 2.6rem;
  margin-bottom: 1rem;
}

.hero p {
  font-size: 1.2rem;
  max-width: 650px;
  margin: 0 auto 2.2rem;
  color: #f1f1f1;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* 4. Catalog Produse */
.catalog-section {
  padding: 4.5rem 0;
}

.section-header {
  text-align: center;
  margin-bottom: 2rem;
}

.section-header h2 {
  font-size: 2.1rem;
  margin-bottom: 0.4rem;
}

.filters {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.filter-btn {
  border: 1px solid var(--border);
  background: var(--white);
  padding: 0.5rem 1.3rem;
  border-radius: 20px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.2s;
}

.filter-btn.active, .filter-btn:hover {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

/* Grid & Carduri Produse */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 2rem;
}

.product-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 22px rgba(0,0,0,0.06);
}

.product-img {
  width: 100%;
  height: 290px;
  object-fit: cover;
  background-color: #eee;
}

.product-info {
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-title {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}

.product-meta {
  color: var(--gray);
  font-size: 0.85rem;
  margin-bottom: 1.2rem;
}

.product-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.product-price {
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--primary);
}

.card-actions {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.btn-details {
  background: #f0eee9;
  color: var(--dark);
  padding: 0.5rem 0.8rem;
  border-radius: 6px;
  font-size: 0.85rem;
  border: none;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s;
}

.btn-details:hover {
  background: #e2ded5;
}

/* 5. Ferestre Pop-up (Modale) */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(3px);
  align-items: center;
  justify-content: center;
  z-index: 300;
  padding: 1rem;
}

.modal.open {
  display: flex !important;
}

.modal-box {
  background: var(--white);
  padding: 2.2rem;
  border-radius: 16px;
  width: 100%;
  max-width: 460px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.close-btn {
  position: absolute;
  right: 1.2rem;
  top: 1rem;
  font-size: 1.8rem;
  line-height: 1;
  color: #888;
  cursor: pointer;
}

.close-btn:hover {
  color: #111;
}

/* Galerie & Detalii Statuetă */
.product-detail-box {
  max-width: 800px !important;
  width: 95% !important;
  padding: 2.2rem !important;
}

.product-modal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

.modal-gallery {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.detail-main-img {
  width: 100%;
  height: 340px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.detail-thumbnails {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 4px;
}

.detail-thumb {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 6px;
  cursor: pointer;
  border: 2px solid transparent;
  opacity: 0.7;
  transition: all 0.2s;
}

.detail-thumb:hover, .detail-thumb.active {
  border-color: var(--primary);
  opacity: 1;
  transform: scale(1.05);
}

.modal-info h2 {
  font-size: 1.6rem;
  margin-bottom: 0.3rem;
}

.modal-meta {
  color: var(--gray);
  font-size: 0.9rem;
  margin-bottom: 0.8rem;
}

.modal-price {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 1.2rem;
}

.detail-description-wrap {
  background: #fbfaf8;
  padding: 1rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  margin-bottom: 1.5rem;
  max-height: 180px;
  overflow-y: auto;
}

.detail-description-wrap h4 {
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
  color: #333;
}

.detail-description-wrap p {
  font-size: 0.9rem;
  color: #555;
  white-space: pre-line;
}

/* Formulare Pop-up */
.custom-modal-box {
  max-width: 520px;
}

.modal-subtitle {
  color: var(--gray);
  font-size: 0.9rem;
  margin-bottom: 1.2rem;
}

.custom-form {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.custom-form label {
  font-weight: 600;
  font-size: 0.85rem;
  color: #444;
}

.custom-form input, .custom-form select, .custom-form textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
}

/* Coș */
.cart-items {
  max-height: 250px;
  overflow-y: auto;
  margin: 1.5rem 0;
}

.cart-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

.cart-total {
  font-size: 1.15rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

/* Buton comandă WhatsApp în coș */
.btn-whatsapp-order {
  background-color: #25d366;
  color: #ffffff;
  border: none;
  border-radius: 8px;
  padding: 0.85rem 1.2rem;
  font-size: 1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.25);
  transition: background-color 0.2s, transform 0.15s;
}

.btn-whatsapp-order:hover {
  background-color: #1ebe5d;
  transform: translateY(-1px);
}

/* 6. Subsol (Footer) */
footer {
  text-align: center;
  padding: 2.5rem 0;
  background: #181818;
  color: #888;
}

/* =========================================
   7. LIGHTBOX FULLSCREEN PE FUNDAL NEGRU
   ========================================= */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.96);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  user-select: none;
  animation: lightboxFadeIn 0.2s ease;
}

.lightbox.open {
  display: flex;
}

.lightbox-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 90vw;
  max-height: 90vh;
}

#lightboxImg {
  max-width: 88vw;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 0 35px rgba(0, 0, 0, 0.85);
  transition: opacity 0.15s ease-in-out;
}

.lightbox-caption {
  color: #f0f0f0;
  font-size: 1.05rem;
  margin-top: 1.2rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-align: center;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 2rem;
  color: #ffffff;
  font-size: 2.8rem;
  font-weight: 300;
  cursor: pointer;
  z-index: 1010;
  line-height: 1;
  transition: transform 0.2s, color 0.2s;
}

.lightbox-close:hover {
  color: var(--primary);
  transform: scale(1.15);
}

.lightbox-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  width: 58px;
  height: 58px;
  border-radius: 50%;
  font-size: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1010;
  transition: background 0.2s, transform 0.2s;
}

.lightbox-btn:hover {
  background: var(--primary);
  transform: translateY(-50%) scale(1.1);
  border-color: var(--primary);
}

.lightbox-prev { left: 1.5rem; }
.lightbox-next { right: 1.5rem; }

@keyframes lightboxFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* =========================================
   8. ADAPTARE PRECISĂ PENTRU MOBIL (UNIFICAT)
   ========================================= */
@media (max-width: 768px) {
  .nav-content {
    height: 64px;
    gap: 0.5rem;
  }
  /* Ascunde textul de lângă logo pe ecrane de telefon */
  .logo-text {
    display: none !important;
  }
  /* Logo adaptat la lățimea telefonului ca să nu împingă ecranul */
  .logo img, .logo-link img, .logo-img {
    height: 48px;
    max-width: 130px;
  }

  .nav-content nav {
    display: flex;
    align-items: center;
    gap: 0.45rem;
  }

  /* Ascunde doar textul lung "Comandă după Poză" pe ecran mic */
  #navCustomBtn {
    display: none !important;
  }

  /* Butonul Categorii afișat clar și curat pe mobil */
  .nav-categories-btn {
    display: inline-flex !important;
    align-items: center;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.35rem 0.65rem;
    background: #f4f3ee;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--dark);
    text-decoration: none;
    white-space: nowrap;
  }

  /* Butonul WhatsApp compact */
  .nav-whatsapp-btn {
    width: 35px;
    height: 35px;
  }

  .nav-whatsapp-btn .wa-icon {
    width: 18px;
    height: 18px;
  }

  .cart-btn {
    padding: 0.4rem 0.7rem;
    font-size: 0.82rem;
  }

  /* Dimensiuni normale pe telefon pentru texte (fără fonturi uriașe) */
  .hero {
    padding: 3.5rem 1rem 2.5rem;
  }

  .hero h1 {
    font-size: 1.85rem !important;
  }

  .hero p {
    font-size: 1rem !important;
  }

  .section-header h2 {
    font-size: 1.6rem;
  }

  .product-modal-grid {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }

  .detail-main-img {
    height: 240px;
  }

  .lightbox-btn {
    width: 42px;
    height: 42px;
    font-size: 1.4rem;
    background: rgba(0, 0, 0, 0.6);
  }
  .lightbox-prev { left: 0.5rem; }
  .lightbox-next { right: 0.5rem; }
  .lightbox-close { top: 1rem; right: 1.2rem; font-size: 2.2rem; }
  #lightboxImg { max-width: 95vw; max-height: 75vh; }
}

/* Buton WhatsApp flotant (opțional pe mobil) */
.floating-wa-btn {
  display: none;
}

@media (max-width: 768px) {
  .floating-wa-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: #25d366;
    color: #ffffff;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    z-index: 999;
    text-decoration: none;
  }

  .floating-wa-btn svg {
    fill: #ffffff;
    width: 26px;
    height: 26px;
  }
}
/* Extindere antet spre colțurile ecranului */
.navbar .nav-content {
  max-width: 100% !important;
  padding-left: 10px !important;  /* Spațiul față de marginea din stânga */
  padding-right: 20px !important; /* Spațiul față de marginea din dreapta */
}

.navbar .logo {
  margin-left: 0 !important;
  padding-left: 0 !important;
}