/* 
  Alyamen Store - GOLDEN EDITION (V4 Pro)
  Clean, Organized, Luxury Design, Fully Responsive RTL
*/

:root {
  --gold: #f59e0b;
  --gold-dark: #d97706;
  --black: #111827;
  --navy: #1f2937;
  --gray-light: #f8fafc;
  --gray-border: #f1f5f9;
  --text-dark: #1e293b;
  --text-muted: #64748b;
  --white: #ffffff;
  --red: #ef4444;
  --green: #10b981;
  --shadow: 0 4px 20px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 30px rgba(0,0,0,0.1);
  --container-width: 1200px;
}

/* 1. Global Reset & Body */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: 'Poppins', 'Segoe UI', Tahoma, sans-serif; background-color: var(--gray-light); color: var(--text-dark); line-height: 1.6; direction: rtl; text-align: right; }
a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }
button { font-family: inherit; border: none; cursor: pointer; transition: 0.3s; }
input, select, textarea { font-family: inherit; outline: none; transition: 0.3s; }

/* 2. Layout Helper */
.container { max-width: var(--container-width); margin: 0 auto; padding: 0 20px; }
.section-padding { padding: 80px 0; }
.section-header { text-align: center; margin-bottom: 50px; }
.section-header h2 { font-size: 32px; font-weight: 800; color: var(--black); margin-bottom: 10px; position: relative; display: inline-block; }
.section-header h2::after { content: ''; width: 50px; height: 4px; background: var(--gold); position: absolute; bottom: -10px; right: 50%; transform: translateX(50%); border-radius: 2px; }

/* 3. Navbar (Luxury Sticky) */
.navbar { background: rgba(255,255,255,0.9); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 1000; padding: 15px 0; border-bottom: 1px solid var(--gray-border); box-shadow: var(--shadow); }
.navbar .container { display: flex; justify-content: space-between; align-items: center; }
.logo { font-size: 24px; font-weight: 900; color: var(--black); cursor: pointer; display: flex; align-items: center; gap: 8px; }
.logo span { color: var(--gold); }
.nav-menu { display: flex; gap: 25px; align-items: center; }
.nav-link { font-weight: 600; color: var(--text-muted); font-size: 14px; }
.nav-link:hover, .nav-link.active { color: var(--gold); }
.nav-actions { display: flex; gap: 20px; align-items: center; }
.action-icon { font-size: 20px; position: relative; color: var(--black); cursor: pointer; }
.badge { position: absolute; top: -8px; right: -8px; background: var(--gold); color: white; font-size: 10px; padding: 2px 6px; border-radius: 10px; font-weight: bold; }

/* 4. Hero Section */
.hero { height: 500px; display: flex; align-items: center; background: linear-gradient(135deg, #fff 0%, #fffbeb 100%); overflow: hidden; }
.hero-text { flex: 1; padding-right: 20px; }
.hero-text h1 { font-size: 48px; font-weight: 900; line-height: 1.1; margin-bottom: 20px; color: var(--black); }
.hero-text h1 span { color: var(--gold); }
.hero-text p { font-size: 18px; color: var(--text-muted); margin-bottom: 30px; }
.hero-btn { padding: 14px 35px; background: var(--gold); color: white; font-weight: 700; border-radius: 50px; box-shadow: 0 10px 20px rgba(245,158,11,0.2); }
.hero-visual { flex: 1; display: flex; justify-content: center; position: relative; }
.hero-emoji { font-size: 180px; filter: drop-shadow(0 20px 30px rgba(0,0,0,0.1)); animation: float 6s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-20px); } }

/* 5. Product Cards Grid (Bulletproof) */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 30px; }
.product-card { background: var(--white); border-radius: 16px; overflow: hidden; border: 1px solid var(--gray-border); transition: 0.4s; display: flex; flex-direction: column; position: relative; }
.product-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-lg); border-color: var(--gold); }
.p-img-box { height: 260px; overflow: hidden; position: relative; cursor: pointer; background: #fdfdfd; }
.p-img-box img { width: 100%; height: 100%; object-fit: cover; transition: 0.6s; }
.product-card:hover .p-img-box img { transform: scale(1.1); }
.p-badge { position: absolute; top: 12px; right: 12px; background: var(--gold); color: white; padding: 4px 10px; border-radius: 30px; font-size: 10px; font-weight: 700; }
.p-views { position: absolute; bottom: 10px; left: 12px; background: rgba(255,255,255,0.8); padding: 2px 8px; border-radius: 20px; font-size: 10px; font-weight: 700; color: var(--text-muted); }

.p-info { padding: 20px; flex-grow: 1; display: flex; flex-direction: column; }
.p-cat { color: var(--gold); font-weight: 700; font-size: 10px; text-transform: uppercase; margin-bottom: 8px; letter-spacing: 0.5px; }
.p-title { font-size: 16px; font-weight: 700; color: var(--black); margin-bottom: 12px; height: 42px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; cursor: pointer; }
.p-rating { display: flex; align-items: center; gap: 5px; margin-bottom: 15px; }
.p-stars { color: #fbbf24; font-size: 12px; }
.p-reviews { font-size: 11px; color: var(--text-muted); }

.p-footer { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 15px; border-top: 1px solid var(--gray-border); }
.p-price-box { display: flex; flex-direction: column; }
.p-curr { font-size: 18px; font-weight: 800; color: var(--black); }
.p-old { font-size: 12px; text-decoration: line-through; color: var(--text-muted); }
.add-btn-circle { background: var(--black); color: white; width: 40px; height: 40px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 16px; }
.add-btn-circle:hover { background: var(--gold); transform: scale(1.1); }

/* 6. Footer (Elegant) */
.footer { background: var(--black); color: white; padding-top: 80px; margin-top: 100px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.5fr; gap: 50px; padding-bottom: 50px; }
.f-h4 { color: var(--gold); font-size: 18px; margin-bottom: 25px; }
.f-links a { display: block; margin-bottom: 12px; color: #94a3b8; font-size: 14px; }
.f-links a:hover { color: white; padding-right: 5px; }
.footer-bottom { padding: 30px 0; border-top: 1px solid #1f2937; text-align: center; color: #64748b; font-size: 13px; }

/* 7. Cart Sidebar */
.cart-sidebar { position: fixed; top: 0; left: -100%; width: 380px; height: 100%; background: white; z-index: 2000; box-shadow: 10px 0 30px rgba(0,0,0,0.1); transition: 0.5s; display: flex; flex-direction: column; text-align: right; }
.cart-sidebar.active { left: 0; }
.cart-header { padding: 25px; border-bottom: 1px solid var(--gray-border); display: flex; justify-content: space-between; align-items: center; }
.cart-items { flex: 1; overflow-y: auto; padding: 20px; }
.cart-footer { padding: 25px; border-top: 1px solid var(--gray-border); background: #fafafa; }
.cart-total-row { display: flex; justify-content: space-between; font-size: 18px; font-weight: 800; margin-bottom: 20px; }
.checkout-btn-full { width: 100%; padding: 16px; background: var(--green); color: white; border-radius: 12px; font-weight: 700; font-size: 16px; }

/* 8. Mobile Fixes */
@media (max-width: 768px) {
  .nav-menu { display: none; }
  .hero { height: auto; padding: 100px 0 50px; flex-direction: column; text-align: center; }
  .hero-text { padding-right: 0; margin-bottom: 40px; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .cart-sidebar { width: 100%; }
}
