/* ==========================================================================
   Hanif Aimaq Trading Ltd - main stylesheet
   Dark theme, green accent, bilingual (LTR/RTL) support, scroll animations
   ========================================================================== */

:root {
  --bg-dark: #0a0f0d;
  --bg-panel: #0f1713;
  --bg-panel-2: #111a15;
  --green: #4ade80;
  --green-strong: #22c55e;
  --green-glow: rgba(74, 222, 128, 0.35);
  --text-main: #f3f6f4;
  --text-muted: #a9b6ae;
  --border-soft: rgba(255, 255, 255, 0.08);
  --radius: 14px;
  --font-en: 'Inter', system-ui, sans-serif;
  --font-fa: 'Vazirmatn', 'Inter', system-ui, sans-serif;
  --container: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-en);
  line-height: 1.6;
  overflow-x: hidden;
}

body.rtl { font-family: var(--font-fa); }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 { margin: 0 0 12px; line-height: 1.25; font-weight: 700; }
p { margin: 0 0 16px; color: var(--text-muted); }

.accent { color: var(--green); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn .arrow { transition: transform .25s ease; }
.btn:hover .arrow { transform: translateX(4px); }
body.rtl .btn:hover .arrow { transform: translateX(-4px) scaleX(-1); }

.btn-primary {
  background: linear-gradient(135deg, var(--green), var(--green-strong));
  color: #06110a;
  box-shadow: 0 8px 24px -6px var(--green-glow);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 14px 30px -6px var(--green-glow); }

.btn-outline {
  background: transparent;
  border-color: rgba(255,255,255,0.25);
  color: var(--text-main);
}
.btn-outline:hover { border-color: var(--green); color: var(--green); transform: translateY(-3px); }

.btn-sm { padding: 10px 18px; font-size: 14px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 12, 10, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-soft);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px 24px;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo { height: 44px; width: auto; border-radius: 8px; }
.brand-logo--placeholder {
  height: 44px; width: 44px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--green), var(--green-strong));
  color: #06110a; font-weight: 800; border-radius: 10px; font-size: 15px;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-size: 16px; letter-spacing: .3px; }
.brand-text small { color: var(--text-muted); font-size: 11px; letter-spacing: .5px; }

.main-nav { display: flex; align-items: center; gap: 26px; }
.main-nav a { font-size: 14.5px; color: var(--text-muted); font-weight: 500; position: relative; padding: 4px 0; }
.main-nav a::after {
  content: ""; position: absolute; left: 0; bottom: -2px; width: 0; height: 2px;
  background: var(--green); transition: width .25s ease;
}
.main-nav a:hover, .main-nav a.active { color: var(--text-main); }
.main-nav a:hover::after, .main-nav a.active::after { width: 100%; }

.header-actions { display: flex; align-items: center; gap: 16px; }
.lang-switch { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-muted); }
.lang-switch a { padding: 4px 6px; border-radius: 6px; }
.lang-switch a.active { color: var(--green); font-weight: 700; }
.lang-switch a:hover { color: var(--green); }

.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px; }
.hamburger span { width: 22px; height: 2px; background: var(--text-main); border-radius: 2px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: radial-gradient(ellipse at 30% 20%, rgba(74,222,128,0.12), transparent 55%), var(--bg-dark);
}
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .45; }
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(6,10,8,0.95) 10%, rgba(6,10,8,0.55) 55%, rgba(6,10,8,0.85) 100%);
}
.hero-inner { position: relative; z-index: 2; padding-top: 60px; padding-bottom: 60px; }
.eyebrow {
  color: var(--green); text-transform: uppercase; letter-spacing: 2px; font-size: 13px; font-weight: 700; margin-bottom: 14px;
}
.hero-title { font-size: clamp(36px, 6vw, 62px); font-weight: 800; letter-spacing: -1px; }
.hero-tagline { font-size: clamp(18px, 2.4vw, 24px); color: var(--text-main); font-weight: 600; margin-top: 6px; }
.hero-description { max-width: 520px; margin-top: 10px; }
.hero-buttons { display: flex; gap: 16px; margin-top: 28px; flex-wrap: wrap; }

.hero-badge {
  position: absolute; z-index: 3; top: 40%; inset-inline-end: 5%;
  writing-mode: vertical-rl; text-orientation: mixed;
  color: var(--green); font-weight: 700; letter-spacing: 3px; font-size: 13px;
  border-inline-start: 2px solid var(--green); padding-inline-start: 10px;
  display: none;
}
@media (min-width: 1024px) { .hero-badge { display: block; } }

.hero-truck-anim {
  position: absolute; bottom: 0; inset-inline-start: -10%; width: 40px; height: 40px;
  background: var(--green); border-radius: 50%; opacity: 0; pointer-events: none;
}

/* ---------- Highlight cards ---------- */
.highlight-cards {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px;
  margin-top: -70px; position: relative; z-index: 5; margin-bottom: 40px;
}
.highlight-card {
  background: var(--bg-panel);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 28px 22px;
  text-align: center;
  transition: transform .3s ease, border-color .3s ease, box-shadow .3s ease;
}
.highlight-card:hover { transform: translateY(-8px); border-color: var(--green); box-shadow: 0 16px 30px -12px var(--green-glow); }
.highlight-card h3 { font-size: 16px; margin: 14px 0 6px; }
.highlight-card p { font-size: 13.5px; margin: 0; }

.icon-badge {
  width: 54px; height: 54px; border-radius: 14px; margin: 0 auto;
  background: linear-gradient(135deg, rgba(74,222,128,0.18), rgba(34,197,94,0.08));
  display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(74,222,128,0.35);
}
.icon-badge img { width: 26px; height: 26px; object-fit: contain; }
.icon-badge--sm { width: 44px; height: 44px; margin: 0 0 12px; border-radius: 10px; }
.icon-fallback { color: var(--green); font-size: 20px; }

/* ---------- Sections generic ---------- */
section { padding: 90px 0; position: relative; }
.section-heading { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 20px; margin-bottom: 44px; }
.section-heading h2 { font-size: clamp(26px, 3.4vw, 38px); }
.section-intro { color: var(--text-muted); max-width: 380px; margin: 0; }

/* ---------- About ---------- */
.about { background: var(--bg-panel); }
.about-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 60px; align-items: center; }
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; } }
.about-media { position: relative; border-radius: var(--radius); overflow: hidden; }
.about-media img { border-radius: var(--radius); }
.about-overlay-text {
  position: absolute; bottom: 24px; inset-inline-start: 24px; max-width: 60%;
  font-size: 22px; font-weight: 700; color: #fff;
  text-shadow: 0 2px 10px rgba(0,0,0,.6);
}
.stats-row { display: flex; gap: 34px; margin-top: 34px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; }
.stat-number { font-size: 30px; font-weight: 800; color: var(--green); }
.stat-label { font-size: 13px; color: var(--text-muted); }

/* ---------- Services ---------- */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 24px; }
.service-card {
  background: var(--bg-panel-2); border: 1px solid var(--border-soft); border-radius: var(--radius);
  overflow: hidden; transition: transform .3s ease, border-color .3s ease;
}
.service-card:hover { transform: translateY(-6px); border-color: var(--green); }
.service-media { height: 170px; overflow: hidden; }
.service-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.service-card:hover .service-media img { transform: scale(1.08); }
.service-body { padding: 22px; }
.service-body h3 { font-size: 17px; }
.service-body p { font-size: 14px; }
.link-more { color: var(--green); font-weight: 600; font-size: 14px; display: inline-flex; gap: 6px; align-items: center; }
.link-more .arrow { transition: transform .25s ease; }
.link-more:hover .arrow { transform: translateX(4px); }

/* ---------- Routes ---------- */
.routes { background: linear-gradient(180deg, var(--bg-dark), var(--bg-panel)); }
.routes-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 50px; align-items: center; }
@media (max-width: 900px) { .routes-grid { grid-template-columns: 1fr; } }
.route-line { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; justify-content: center; padding: 30px 10px; }
.route-stop { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.route-flag {
  width: 64px; height: 64px; border-radius: 50%; overflow: hidden; border: 2px solid var(--green);
  display: flex; align-items: center; justify-content: center; background: var(--bg-panel-2);
  animation: pulseGlow 3s ease-in-out infinite;
}
.route-flag img { width: 100%; height: 100%; object-fit: cover; }
.route-stop span { font-size: 12px; font-weight: 700; letter-spacing: .5px; color: var(--text-muted); }
.route-arrow { color: var(--green); font-size: 20px; }
.route-notes { margin-top: 20px; display: flex; flex-direction: column; gap: 10px; }
.route-notes li { font-size: 13.5px; color: var(--text-muted); }

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 0 0 var(--green-glow); }
  50% { box-shadow: 0 0 0 8px transparent; }
}

/* ---------- Why choose us ---------- */
.why-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px; }
.why-card { text-align: center; padding: 10px; }
.icon-circle {
  width: 62px; height: 62px; border-radius: 50%; margin: 0 auto 16px;
  background: linear-gradient(135deg, var(--green), var(--green-strong));
  display: flex; align-items: center; justify-content: center; color: #06110a;
}
.icon-circle img { width: 28px; height: 28px; filter: brightness(0) saturate(100%); }
.why-card h3 { font-size: 16px; }
.why-card p { font-size: 13.5px; }

/* ---------- Products ---------- */
.products-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 18px; }
.product-card { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4/3; }
.product-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.product-card:hover img { transform: scale(1.1); }
.product-label {
  position: absolute; bottom: 0; inset-inline-start: 0; inset-inline-end: 0; padding: 10px 14px;
  background: linear-gradient(0deg, rgba(0,0,0,.85), transparent); font-size: 13px; font-weight: 600;
}

/* ---------- CTA banner ---------- */
.cta-banner { position: relative; overflow: hidden; }
.cta-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cta-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(6,10,8,.92), rgba(6,10,8,.7)); }
.cta-inner {
  position: relative; z-index: 2; display: flex; justify-content: space-between; align-items: center;
  gap: 30px; flex-wrap: wrap;
}
.cta-inner h2 { font-size: 26px; margin-bottom: 6px; }
.cta-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Generic page banner (StandardPage / Contact) ---------- */
.page-banner { position: relative; padding: 130px 0 70px; overflow: hidden; }
.page-banner-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .4; }
.page-banner-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(6,10,8,.6), var(--bg-dark)); }
.page-banner--contact { background: radial-gradient(ellipse at 30% 0%, rgba(74,222,128,.15), transparent 60%); }
.page-banner-inner { position: relative; z-index: 2; }
.page-banner-inner h1 { font-size: clamp(30px, 4vw, 44px); }
.page-body { padding-top: 40px; }
.rich-text a { color: var(--green); text-decoration: underline; }

/* ---------- Contact form ---------- */
.contact-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 50px; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-details { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.contact-details strong { color: var(--text-main); }
.contact-form-wrap {
  background: var(--bg-panel); border: 1px solid var(--border-soft); border-radius: var(--radius); padding: 32px;
}
.form-row { margin-bottom: 18px; display: flex; flex-direction: column; gap: 6px; }
.form-row--half { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-row label { font-size: 13px; color: var(--text-muted); font-weight: 600; }
.contact-form input[type="text"], .contact-form input[type="email"], .contact-form textarea {
  background: var(--bg-dark); border: 1px solid var(--border-soft); border-radius: 10px;
  padding: 12px 14px; color: var(--text-main); font-family: inherit; font-size: 14px;
  transition: border-color .2s ease;
}
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: var(--green); }
.contact-form ul.errorlist { color: #f87171; font-size: 12px; margin: 4px 0 0; padding: 0; list-style: none; }
.form-success {
  background: rgba(74,222,128,.12); border: 1px solid var(--green); color: var(--green);
  padding: 14px 18px; border-radius: 10px; margin-bottom: 20px; font-size: 14px; font-weight: 600;
}
input[type="hidden"] { display: none; }

/* ---------- Footer ---------- */
.site-footer { background: #060907; border-top: 1px solid var(--border-soft); padding-top: 60px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 40px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-brand p { font-size: 13px; margin-top: 14px; }
.footer-socials { display: flex; gap: 10px; margin-top: 18px; }
.footer-socials a {
  width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--border-soft);
  display: flex; align-items: center; justify-content: center; font-size: 12px; text-transform: uppercase;
  transition: background .2s ease, border-color .2s ease;
}
.footer-socials a:hover { background: var(--green); color: #06110a; border-color: var(--green); }
.footer-col h4 { font-size: 14px; margin-bottom: 16px; color: var(--text-main); }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 13.5px; color: var(--text-muted); }
.footer-col a:hover { color: var(--green); }
.footer-contact li { font-size: 13.5px; color: var(--text-muted); }
.footer-map-placeholder {
  height: 90px; border-radius: 10px; border: 1px dashed var(--border-soft);
  background: repeating-linear-gradient(45deg, rgba(255,255,255,0.02) 0 10px, transparent 10px 20px);
}
.footer-bottom {
  border-top: 1px solid var(--border-soft); padding: 20px 24px; display: flex;
  justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px;
}
.footer-bottom p { margin: 0; font-size: 12.5px; }
.footer-legal { display: flex; gap: 18px; font-size: 12.5px; }
.footer-legal a:hover { color: var(--green); }

/* ---------- WhatsApp float button ---------- */
.whatsapp-float {
  position: fixed; bottom: 24px; inset-inline-end: 24px; z-index: 90;
  width: 56px; height: 56px; border-radius: 50%; background: #25d366; color: #06110a;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 24px rgba(37,211,102,.4);
  animation: floatBounce 2.6s ease-in-out infinite;
}
@keyframes floatBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* ---------- Scroll reveal animations ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }
.reveal.delay-2.in-view { transition-delay: .12s; }
.reveal.delay-3.in-view { transition-delay: .24s; }
.reveal.delay-4.in-view { transition-delay: .36s; }

/* ---------- Mobile nav ---------- */
@media (max-width: 900px) {
  .main-nav {
    position: fixed; top: 74px; inset-inline-start: 0; inset-inline-end: 0;
    background: var(--bg-panel); flex-direction: column; align-items: flex-start;
    padding: 20px 24px; gap: 16px; border-bottom: 1px solid var(--border-soft);
    transform: translateY(-140%); transition: transform .3s ease; z-index: 99;
  }
  .main-nav.open { transform: translateY(0); }
  .hamburger { display: flex; }
  .header-actions .btn-primary span.arrow, .header-actions .btn-primary { display: none; }
}
@media (min-width: 901px) { .hamburger { display: none; } }
