* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --green: #6b7b3c;
  --green-dark: #5a6832;
  --text: #333;
  --muted: #666;
  --light: #999;
  --line: #e5e5e5;
  --bg: #fff;
}

body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  font-size: 14px;
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }

/* Top Banner */
.top-banner {
  background: var(--green);
  color: #fff;
  text-align: center;
  padding: 8px 20px;
  font-size: 12px;
  letter-spacing: 0.5px;
}

/* Header */
.header {
  border-bottom: 1px solid var(--line);
  padding: 16px 0;
}
.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  font-size: 24px;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo:hover { text-decoration: none; }
.logo-icon { width: 40px; height: 40px; flex-shrink: 0; }
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.logo-sub { font-size: 10px; font-weight: 400; letter-spacing: 2px; text-transform: uppercase; color: var(--muted); }

.header-center {
  flex: 1;
  max-width: 400px;
  margin: 0 40px;
}
.search-box {
  display: flex;
  border: 1px solid var(--line);
  border-radius: 0;
}
.search-box input {
  flex: 1;
  border: none;
  padding: 10px 14px;
  font-size: 13px;
  outline: none;
}
.search-box button {
  background: none;
  border: none;
  padding: 10px 14px;
  cursor: pointer;
  color: var(--muted);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 16px;
}
.lang-switch {
  display: flex;
  gap: 4px;
  font-size: 12px;
}
.lang-switch a {
  padding: 4px 8px;
  color: var(--muted);
}
.lang-switch a.active {
  background: var(--green);
  color: #fff;
}
.lang-switch a:hover { text-decoration: none; }
.header-btn {
  background: var(--green);
  color: #fff;
  padding: 10px 20px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
}
.header-btn:hover { background: var(--green-dark); text-decoration: none; }
.header-icons {
  display: flex;
  gap: 16px;
  font-size: 18px;
  color: var(--text);
}
.header-icons a { position: relative; }
.cart-count {
  position: absolute;
  top: -6px;
  right: -8px;
  background: var(--green);
  color: #fff;
  font-size: 10px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* User Menu */
.user-menu {
  position: relative;
  display: none;
}
.user-menu.show { display: block; }
.user-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: var(--bg);
  border-radius: 20px;
  font-size: 13px;
  color: var(--text);
  cursor: pointer;
}
.user-btn:hover { background: #e5e5e5; text-decoration: none; }
.user-icon { font-size: 16px; }
.user-name { font-weight: 500; max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 8px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  min-width: 160px;
  display: none;
  z-index: 1000;
}
[dir="rtl"] .user-dropdown { right: auto; left: 0; }
.user-dropdown.open { display: block; }
.user-dropdown a {
  display: block;
  padding: 12px 16px;
  font-size: 13px;
  color: var(--text);
}
.user-dropdown a:hover { background: var(--bg); text-decoration: none; }
.dropdown-divider { height: 1px; background: var(--line); margin: 4px 0; }
.login-link {
  font-size: 13px;
  color: var(--text);
  padding: 6px 12px;
  display: none;
}
.login-link:hover { color: var(--green); }
.login-link.show { display: block; }

/* Navigation */
.nav {
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  justify-content: center;
  gap: 40px;
}
.nav a {
  padding: 16px 0;
  font-size: 13px;
  color: var(--text);
  letter-spacing: 0.3px;
}
.nav a:hover { color: var(--green); text-decoration: none; }

/* Page Header */
.page-header {
  text-align: center;
  padding: 40px 20px 30px;
  border-bottom: 1px solid var(--line);
}
.page-title {
  font-size: 28px;
  font-weight: 400;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.page-desc {
  color: var(--muted);
  font-size: 14px;
  max-width: 600px;
  margin: 0 auto 20px;
}
.page-cats {
  display: flex;
  justify-content: center;
  gap: 40px;
}
.page-cats a {
  font-size: 13px;
  color: var(--text);
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
}
.page-cats a:hover, .page-cats a.active {
  border-bottom-color: var(--text);
  text-decoration: none;
}

/* Main Layout */
.main {
  max-width: 1400px;
  margin: 0 auto;
  padding: 30px 40px 60px;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 40px;
}

/* Sidebar Filters */
.sidebar {}
.filter-title {
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 16px;
}
.filter-group {
  border-bottom: 1px solid var(--line);
}
.filter-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
  cursor: pointer;
  font-size: 12px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--text);
}
.filter-header:hover { color: var(--green); }
.filter-toggle {
  font-size: 16px;
  color: var(--light);
}
.filter-content {
  padding-bottom: 14px;
  display: none;
}
.filter-content.open { display: block; }
.filter-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
}
.filter-option:hover { color: var(--text); }
.filter-option input { margin: 0; }

/* Products Header */
.products-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}
.products-count {
  font-size: 13px;
  color: var(--muted);
}
.sort-by {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}
.sort-by label { color: var(--muted); }
.sort-by select {
  border: none;
  font-size: 13px;
  color: var(--text);
  cursor: pointer;
  padding: 4px;
}

/* Product Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
@media (max-width: 1100px) { .products-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 800px) {
  .main { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .products-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Product Card */
.product-card {
  display: flex;
  flex-direction: column;
}
.product-card:hover .product-image img { transform: scale(1.03); }
.product-image {
  aspect-ratio: 1;
  overflow: hidden;
  margin-bottom: 12px;
  background: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}
.product-artisan {
  font-size: 11px;
  color: var(--green);
  margin-bottom: 4px;
}
.product-name {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  line-height: 1.4;
  margin-bottom: 6px;
  color: var(--text);
  display: block;
}
.product-name:hover { color: var(--green); text-decoration: none; }
.product-price {
  font-size: 20px;
  font-weight: 800;
  color: #1a1a1a;
  margin-bottom: 10px;
  letter-spacing: -0.3px;
  display: flex;
  align-items: baseline;
  gap: 4px;
  flex-wrap: wrap;
}
.product-price .currency {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a1a;
}
.product-price .amount {
  font-size: 24px;
  font-weight: 800;
  color: #1a1a1a;
  line-height: 1;
}
.product-price .old-price {
  font-size: 13px;
  font-weight: 400;
  color: #999;
  text-decoration: line-through;
  margin-left: 6px;
}
[dir="rtl"] .product-price .old-price {
  margin-left: 0;
  margin-right: 6px;
}
.product-variants {
  font-size: 11px;
  color: var(--light);
  font-style: italic;
  margin-bottom: 8px;
}
.product-add {
  margin-top: auto;
  padding: 10px 16px;
  border: 1px solid var(--green);
  background: #fff;
  font-size: 11px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--green);
  width: 100%;
}
.product-add:hover {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}
.product-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #c41e3a;
  color: #fff;
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
[dir="rtl"] .product-badge { left: auto; right: 10px; }
.product-stock-tag {
  font-size: 12px;
  color: #e65100;
  font-weight: 500;
  margin-bottom: 8px;
  padding: 4px 0;
}
.product-stock-tag.out-of-stock {
  color: #c62828;
}
.product-card.out-of-stock .product-image img {
  opacity: 0.5;
}
.product-card.out-of-stock .product-add {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* Cart Drawer */
.overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.4);
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s;
  z-index: 100;
}
.overlay.open { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; right: 0; height: 100%;
  width: 400px;
  max-width: 90vw;
  background: #fff;
  transform: translateX(100%);
  transition: transform 0.3s;
  z-index: 101;
  display: flex;
  flex-direction: column;
}
[dir="rtl"] .drawer { right: auto; left: 0; transform: translateX(-100%); }
.drawer.open { transform: translateX(0); }
.drawer-header {
  padding: 20px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.drawer-title {
  font-size: 14px;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.drawer-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--muted);
}
.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}
.cart-empty {
  text-align: center;
  padding: 40px;
  color: var(--muted);
}
.cart-item {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.cart-item-img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  background: #f5f5f5;
}
.cart-item-info { flex: 1; }
.cart-item-name {
  font-size: 12px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.cart-item-brand {
  font-size: 11px;
  color: var(--light);
  margin-bottom: 8px;
}
.cart-item-qty {
  display: flex;
  align-items: center;
  gap: 12px;
}
.cart-item-qty button {
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  font-size: 14px;
}
.cart-item-qty span { font-size: 13px; }
.cart-item-remove {
  background: none;
  border: none;
  font-size: 11px;
  color: var(--light);
  cursor: pointer;
  margin-top: 8px;
  text-decoration: underline;
}
.cart-item-price {
  font-size: 13px;
  text-align: right;
}
.drawer-footer {
  padding: 20px;
  border-top: 1px solid var(--line);
}
.cart-total {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  margin-bottom: 16px;
}
.cart-total span:last-child { font-weight: 600; }
.checkout-btn {
  width: 100%;
  padding: 14px;
  background: var(--green);
  color: #fff;
  border: none;
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
}
.checkout-btn:hover { background: var(--green-dark); }
.checkout-btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* Footer */
.footer {
  background: #1a1a1a;
  color: #fff;
  padding: 60px 40px 0;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
}
@media (max-width: 800px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 500px) {
  .footer-inner { grid-template-columns: 1fr; text-align: center; }
}
.footer-col { }
.footer-brand {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
}
@media (max-width: 500px) { .footer-brand { justify-content: center; } }
.footer-text {
  font-size: 13px;
  color: #999;
  margin-bottom: 20px;
  line-height: 1.6;
}
.footer-social {
  display: flex;
  gap: 12px;
}
@media (max-width: 500px) { .footer-social { justify-content: center; } }
.social-link {
  width: 40px;
  height: 40px;
  background: #333;
  border-radius: 50%;
  color: #fff;
  transition: all 0.2s;
  text-decoration: none;
  position: relative;
}
.social-link svg {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 20px;
  height: 20px;
}
.social-link:hover { background: var(--green); transform: translateY(-2px); }
.footer-title {
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 20px;
  color: #fff;
}
.footer-col a {
  display: block;
  font-size: 13px;
  color: #999;
  margin-bottom: 12px;
}
.footer-col a:hover { color: #fff; text-decoration: none; }
.footer-contact-info {
  font-size: 13px;
  color: #999;
  line-height: 2;
}
.footer-bottom {
  border-top: 1px solid #333;
  margin-top: 40px;
  padding: 20px 0;
  text-align: center;
  font-size: 12px;
  color: #666;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-payments { display: flex; align-items: center; }
@media (max-width: 600px) { .footer-bottom { justify-content: center; } }

/* Popup */
.popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
}
.popup {
  background: #fff;
  padding: 40px;
  max-width: 400px;
  text-align: center;
  position: relative;
}
.popup-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: var(--muted);
}
[dir="rtl"] .popup-close { right: auto; left: 12px; }
.popup h2 {
  font-size: 18px;
  font-weight: 400;
  margin-bottom: 12px;
}
.popup p {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 20px;
}
.discount-code {
  background: #f5f5f5;
  border: 2px dashed var(--green);
  padding: 16px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--green);
  margin-bottom: 20px;
}
.popup .btn {
  background: var(--green);
  color: #fff;
  border: none;
  padding: 12px 24px;
  font-size: 12px;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
}
.popup .btn:hover { opacity: 0.9; }

/* Promo Popup */
.promo-popup {
  background: linear-gradient(135deg, #fff 0%, #fff5f5 100%);
  border: 3px solid #c41e3a;
  padding: 48px 40px;
  max-width: 420px;
  animation: popIn 0.3s ease-out;
}
@keyframes popIn {
  0% { transform: scale(0.8); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
.promo-code {
  background: #c41e3a;
  border: none;
  color: #fff;
  font-size: 32px;
  padding: 20px;
  letter-spacing: 4px;
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.02); }
}
.promo-btn {
  background: #c41e3a !important;
  padding: 16px 32px !important;
  font-size: 14px !important;
}
.promo-btn:hover { background: #a01830 !important; }

/* Loading Skeletons */
.skeleton-card {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.skeleton-img {
  width: 100%;
  height: 200px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
.skeleton-info { padding: 16px; }
.skeleton-text {
  height: 14px;
  background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 4px;
  margin-bottom: 10px;
}
.skeleton-text.short { width: 60%; }
.skeleton-text.price { width: 40%; height: 18px; }
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Search Dropdown */
.search-box { position: relative; }
.search-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #fff;
  border: 1px solid var(--line);
  border-top: none;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  z-index: 100;
  display: none;
  max-height: 400px;
  overflow-y: auto;
}
.search-result-item {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-bottom: 1px solid var(--line);
  align-items: center;
  transition: background 0.15s;
}
.search-result-item:hover {
  background: #f9f9f9;
  text-decoration: none;
}
.search-result-item img {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 4px;
}
.search-result-info { flex: 1; }
.search-result-name {
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 4px;
}
.search-result-price {
  font-size: 12px;
  color: var(--green);
  font-weight: 600;
}
.search-no-results {
  padding: 20px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}
.search-view-all {
  display: block;
  padding: 14px;
  text-align: center;
  background: #f9f9f9;
  font-size: 13px;
  color: var(--green);
  font-weight: 500;
}
.search-view-all:hover {
  background: #f0f0f0;
  text-decoration: none;
}

/* Recently Viewed */
.recently-viewed {
  background: #f8f8f8;
  padding: 50px 40px;
}
.recently-viewed-inner {
  max-width: 1200px;
  margin: 0 auto;
}
.section-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 24px;
  text-align: center;
}
.recently-viewed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
}
.recently-viewed-item {
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
}
.recently-viewed-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
  text-decoration: none;
}
.recently-viewed-item img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}
.recently-viewed-name {
  padding: 12px 12px 4px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}
.recently-viewed-price {
  padding: 0 12px 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--green);
}

/* Social Login */
.social-login {
  margin: 24px 0;
}
.social-login-title {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 16px;
  position: relative;
}
.social-login-title::before,
.social-login-title::after {
  content: '';
  position: absolute;
  top: 50%;
  width: calc(50% - 60px);
  height: 1px;
  background: var(--line);
}
.social-login-title::before { left: 0; }
.social-login-title::after { right: 0; }
.social-buttons {
  display: flex;
  gap: 12px;
}
.social-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 20px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}
.social-btn:hover {
  background: #f9f9f9;
  border-color: #ccc;
}
.social-btn.google { color: #333; }
.social-btn.facebook { background: #1877f2; color: #fff; border-color: #1877f2; }
.social-btn.facebook:hover { background: #166fe5; }
.social-btn svg { width: 20px; height: 20px; }

@media (max-width: 600px) {
  .social-buttons { flex-direction: column; }
}
