/* ============================================================
   Genix Egypt - Main stylesheet
   Works with Tailwind utility classes (loaded via CDN).
   This file holds brand-specific overrides & components.
   ============================================================ */

:root {
  --color-primary: #0B6E4F;
  --color-primary-dark: #064C36;
  --color-accent:  #F2881F;
  --color-ink:     #0F172A;
  --color-bg:      #ffffff;
  --radius:        14px;
  --shadow-sm: 0 1px 2px rgba(15,23,42,.04);
  --shadow-md: 0 6px 20px rgba(15,23,42,.06);
  --shadow-lg: 0 18px 40px rgba(15,23,42,.10);
}

html { scroll-behavior: smooth; }
body { overflow-x: hidden; }

::selection { background: var(--color-primary); color: #fff; }

/* Scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: var(--color-primary); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .75rem 1.5rem; border-radius: 12px;
  font-weight: 700; font-size: .875rem;
  transition: all .2s ease; cursor: pointer;
  border: 1px solid transparent;
}
.btn-primary { background: var(--color-primary); color: #fff; }
.btn-primary:hover { background: var(--color-primary-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-accent  { background: var(--color-accent); color: #fff; }
.btn-accent:hover { filter: brightness(.92); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-outline { background: transparent; border-color: var(--color-primary); color: var(--color-primary); }
.btn-outline:hover { background: var(--color-primary); color: #fff; }
.btn-ghost { background: transparent; color: var(--color-ink); }
.btn-ghost:hover { background: rgba(11,110,79,.06); }
.btn-block { display: flex; width: 100%; justify-content: center; }

/* ---- Cards ---- */
.card {
  background: #fff; border-radius: var(--radius);
  box-shadow: var(--shadow-sm); border: 1px solid #f1f5f9;
  overflow: hidden; transition: all .25s ease;
}
.card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); border-color: #e2e8f0; }

/* ---- Product card ---- */
.product-card { position: relative; }
.product-card .product-media {
  position: relative; overflow: hidden; aspect-ratio: 1;
  background: linear-gradient(135deg, #f8fafc 0%, #eef2f7 100%);
}
.product-card .product-media img {
  width: 100%; height: 100%; object-fit: contain; padding: 1.5rem;
  transition: transform .5s ease;
}
.product-card:hover .product-media img { transform: scale(1.06); }
.product-card .product-actions {
  position: absolute; top: 12px; inset-inline-end: 12px;
  display: flex; flex-direction: column; gap: .5rem;
  opacity: 0; transform: translateX(10px); transition: all .25s ease;
}
.product-card:hover .product-actions { opacity: 1; transform: translateX(0); }
.product-card .product-action-btn {
  width: 36px; height: 36px; border-radius: 50%;
  background: #fff; color: var(--color-ink);
  display: grid; place-items: center; box-shadow: var(--shadow-sm);
  transition: all .2s;
}
.product-card .product-action-btn:hover { background: var(--color-primary); color: #fff; }
.product-card .product-badge {
  position: absolute; top: 12px; inset-inline-start: 12px;
  background: var(--color-accent); color: #fff;
  padding: 4px 10px; border-radius: 8px;
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: .5px;
}
.product-card .product-badge.new  { background: var(--color-primary); }
.product-card .product-badge.hot  { background: #ef4444; }
.product-card .product-badge.sale { background: var(--color-accent); }
.product-card .price-old { text-decoration: line-through; color: #94a3b8; font-size: .85em; }

/* ---- Section title ---- */
.section-title {
  text-align: center; margin-bottom: 2.5rem;
}
.section-title h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 800; color: var(--color-ink);
  position: relative; display: inline-block; padding-bottom: .8rem;
}
.section-title h2::after {
  content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 60px; height: 3px; background: var(--color-accent); border-radius: 2px;
}
.section-title p { color: #64748b; margin-top: .75rem; font-size: 1rem; }

/* ---- Breadcrumb ---- */
.breadcrumb { background: #f8fafc; padding: 14px 0; font-size: .85rem; color: #64748b; }
.breadcrumb a { color: var(--color-primary); font-weight: 600; }
.breadcrumb a:hover { color: var(--color-accent); }
.breadcrumb .sep { margin: 0 .5rem; opacity: .5; }

/* ---- Forms ---- */
.form-input, .form-textarea, .form-select {
  width: 100%; padding: .75rem 1rem;
  border: 1px solid #e2e8f0; border-radius: 10px;
  background: #fff; color: var(--color-ink);
  transition: all .2s; outline: none;
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(11,110,79,.15);
}
.form-label { display: block; font-weight: 600; font-size: .85rem; color: #334155; margin-bottom: .35rem; }

/* ---- Star rating ---- */
.stars { display: inline-flex; gap: 2px; color: #f59e0b; font-size: .8rem; }
.stars i.empty { color: #e2e8f0; }

/* ---- Badges & pills ---- */
.pill {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .35rem .9rem; border-radius: 999px;
  font-size: .75rem; font-weight: 700;
}
.pill-primary { background: rgba(11,110,79,.1); color: var(--color-primary); }
.pill-accent  { background: rgba(242,136,31,.12); color: var(--color-accent); }

/* ---- Hero ---- */
.hero {
  background:
    radial-gradient(circle at 20% 30%, rgba(11,110,79,.06), transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(242,136,31,.06), transparent 50%),
    linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}
.hero-stat {
  background: #fff; border-radius: 14px; padding: 1.25rem;
  text-align: center; box-shadow: var(--shadow-sm); border: 1px solid #f1f5f9;
}
.hero-stat .num { font-size: 1.75rem; font-weight: 800; color: var(--color-primary); }
.hero-stat .lbl { font-size: .75rem; color: #64748b; }

/* ---- Category card ---- */
.cat-card {
  background: #fff; border-radius: 16px; padding: 1.5rem; text-align: center;
  border: 1px solid #f1f5f9; transition: all .25s; cursor: pointer;
}
.cat-card:hover {
  border-color: var(--color-primary); transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}
.cat-card .icon {
  width: 60px; height: 60px; margin: 0 auto .85rem;
  border-radius: 16px; background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  color: #fff; display: grid; place-items: center; font-size: 1.5rem;
}

/* ---- Service card ---- */
.service-card {
  background: #fff; border-radius: 16px; padding: 2rem 1.5rem;
  text-align: center; border: 1px solid #f1f5f9; transition: all .25s;
}
.service-card:hover {
  background: var(--color-primary); color: #fff; transform: translateY(-4px);
}
.service-card:hover h3, .service-card:hover p { color: #fff; }
.service-card:hover .service-icon { background: rgba(255,255,255,.15); color: #fff; }
.service-icon {
  width: 64px; height: 64px; border-radius: 18px; margin: 0 auto 1rem;
  background: rgba(11,110,79,.08); color: var(--color-primary);
  display: grid; place-items: center; font-size: 1.5rem;
  transition: all .25s;
}

/* ---- Why us ---- */
.why-card {
  background: #fff; padding: 1.75rem; border-radius: 16px;
  border: 1px solid #f1f5f9; transition: all .25s;
  display: flex; gap: 1rem; align-items: flex-start;
}
.why-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.why-card .why-icon {
  width: 52px; height: 52px; border-radius: 14px;
  background: rgba(242,136,31,.12); color: var(--color-accent);
  display: grid; place-items: center; font-size: 1.25rem; flex-shrink: 0;
}

/* ---- Testimonials ---- */
.testimonial-card {
  background: #fff; padding: 1.75rem; border-radius: 16px;
  border: 1px solid #f1f5f9; height: 100%;
}
.testimonial-card .quote-mark {
  font-size: 3rem; line-height: 1; color: var(--color-accent); opacity: .25; font-family: serif;
}
.testimonial-card .avatar {
  width: 50px; height: 50px; border-radius: 50%;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  color: #fff; display: grid; place-items: center; font-weight: 700;
}

/* ---- Page header ---- */
.page-header {
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
  color: #fff; padding: 3rem 0; position: relative; overflow: hidden;
}
.page-header::before {
  content: ''; position: absolute; top: -50%; inset-inline-end: -10%;
  width: 400px; height: 400px; border-radius: 50%;
  background: rgba(242,136,31,.15); filter: blur(60px);
}
.page-header h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); font-weight: 800; position: relative; }
.page-header p { color: rgba(255,255,255,.85); margin-top: .5rem; position: relative; }

/* ---- Tables ---- */
.table-clean { width: 100%; border-collapse: collapse; }
.table-clean th, .table-clean td { padding: .85rem 1rem; text-align: start; border-bottom: 1px solid #f1f5f9; }
.table-clean th { font-size: .8rem; color: #64748b; text-transform: uppercase; letter-spacing: .5px; }

/* ---- Helpers ---- */
.text-balance { text-wrap: balance; }
.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* Animate on scroll */
.reveal { opacity: 0; transform: translateY(20px); transition: all .6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

/* Print */
@media print {
  header, footer, .floating-whatsapp, #scrollTop { display: none !important; }
  body { color: #000; }
}
