/* ============================================================
   CN Machinery — China Construction Machinery & Parts Supplier
   Industrial B2B theme — design tokens
   ------------------------------------------------------------
   Palette (60-30-10):
     Primary 60% : deep blue #0d2a4a family (header, footer, dark sections)
     Neutral 30% : white / #f4f6f9 / slate text
     Accent  10% : orange #f5a623 (CTAs, highlights, badges)
   Typography:
     Headings  : Archivo (industrial, heavy) — Google Fonts
     Body      : Inter — Google Fonts
     Labels    : Rajdhani (condensed, uppercase) — Google Fonts
   Motion: restrained — hover transitions only.
   ============================================================ */

:root {
  /* color tokens */
  --blue: #0d2a4a;
  --blue-deep: #081c33;
  --blue-mid: #123457;
  --blue-light: #1b4470;
  --orange: #f5a623;
  --orange-deep: #dd8f00;
  --orange-soft: #fff4e0;
  --white: #ffffff;
  --bg: #f4f6f9;
  --text: #2b3442;
  --text-light: #5f6b7a;
  --border: #dfe5ec;

  /* elevation */
  --shadow: 0 6px 24px rgba(13, 42, 74, 0.10);
  --shadow-lg: 0 14px 40px rgba(13, 42, 74, 0.16);

  /* shape & layout */
  --radius: 12px;
  --container: 1200px;
  --section-pad: 88px;
  --section-pad-mobile: 56px;

  /* typography */
  --font-heading: "Archivo", "Rajdhani", "Arial Narrow", "Segoe UI", Arial, sans-serif;
  --font-body: "Inter", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto,
    "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --font-label: "Rajdhani", "Archivo", "Arial Narrow", "Segoe UI", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--orange-deep); }
ul { list-style: none; }

:focus-visible {
  outline: 3px solid rgba(245, 166, 35, 0.55);
  outline-offset: 2px;
  border-radius: 4px;
}

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

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: 1.2;
  color: var(--blue);
  font-weight: 800;
  letter-spacing: -0.25px;
}

/* ---------- Section rhythm (uniform, restrained) ---------- */
.section { padding: var(--section-pad) 0; }
.section-alt { background: var(--bg); }
.section-dark {
  background: linear-gradient(135deg, var(--blue-deep), var(--blue-mid));
  color: #dbe6f2;
}

.section-header { text-align: center; max-width: 760px; margin: 0 auto 52px; }
.section-header h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.6rem);
  font-weight: 800;
  margin-bottom: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
/* orange accent bar under every section title */
.section-header h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  background: var(--orange);
  margin: 16px auto 0;
  border-radius: 2px;
}
.section-sub { color: var(--text-light); font-size: 1.05rem; }

.eyebrow {
  display: inline-block;
  font-family: var(--font-label);
  text-transform: uppercase;
  letter-spacing: 3px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--orange-deep);
  margin-bottom: 12px;
}

/* ---------- Buttons (primary = solid orange, hover deepens) ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 28px;
  border-radius: 6px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.98rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  text-align: center;
}
.btn-sm { padding: 8px 18px; font-size: 0.9rem; border-radius: 5px; }

.btn-primary { background: var(--orange); color: var(--blue-deep); }
.btn-primary:hover { background: var(--orange-deep); color: var(--white); box-shadow: 0 6px 16px rgba(221, 143, 0, 0.3); }

.btn-outline { border-color: rgba(255, 255, 255, 0.75); color: var(--white); background: transparent; }
.btn-outline:hover { background: var(--orange); border-color: var(--orange); color: var(--blue-deep); }

.btn-dark { background: var(--blue); color: var(--white); }
.btn-dark:hover { background: var(--blue-light); color: var(--white); }

.btn-whatsapp { background: #25d366; color: #fff; }
.btn-whatsapp:hover { background: #1eb958; color: #fff; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--blue);
  box-shadow: 0 2px 14px rgba(8, 28, 51, 0.35);
  transition: box-shadow 0.25s ease;
}
.site-header.scrolled { box-shadow: 0 6px 24px rgba(8, 28, 51, 0.5); }

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 16px;
}

.logo {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--white);
  letter-spacing: 0.3px;
  text-transform: uppercase;
}
.logo span { color: var(--orange); }
.logo small {
  font-family: var(--font-label);
  font-size: 0.62rem;
  font-weight: 600;
  color: #9fb4cc;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.nav-menu { display: flex; align-items: center; gap: 6px; }
.nav-menu a {
  color: #d7e2ef;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 8px 14px;
  border-radius: 6px;
  transition: color 0.2s ease, background 0.2s ease;
}
.nav-menu a:hover { color: var(--orange); background: rgba(245, 166, 35, 0.08); }
.nav-menu a.active {
  color: var(--orange);
  font-weight: 700;
  box-shadow: inset 0 -2px 0 var(--orange);
}

.nav-cta { white-space: nowrap; }

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.hamburger span {
  width: 24px;
  height: 3px;
  background: var(--white);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.hamburger.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: linear-gradient(120deg, var(--blue-deep) 0%, var(--blue) 55%, #14406e 100%);
  color: var(--white);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 55% at 82% 20%, rgba(245, 166, 35, 0.14), transparent 60%),
    radial-gradient(ellipse 45% 50% at 12% 85%, rgba(27, 68, 112, 0.5), transparent 65%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.025) 0 2px, transparent 2px 28px);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 12px;
  background: repeating-linear-gradient(-45deg, var(--orange) 0 22px, var(--blue-deep) 22px 44px);
  opacity: 0.9;
}
.hero-inner {
  position: relative;
  padding: 110px 20px 130px;
  max-width: 900px;
}
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-label);
  text-transform: uppercase;
  letter-spacing: 2.5px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--orange);
  border: 1px solid rgba(245, 166, 35, 0.45);
  background: rgba(245, 166, 35, 0.08);
  padding: 8px 16px;
  border-radius: 40px;
  margin-bottom: 26px;
}
.hero h1 {
  font-family: var(--font-heading);
  color: var(--white);
  font-size: clamp(2rem, 4.8vw, 3.4rem);
  font-weight: 900;
  letter-spacing: -0.5px;
  text-transform: uppercase;
  line-height: 1.12;
  margin-bottom: 22px;
}
.hero h1 .accent { color: var(--orange); }
.hero-sub {
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  color: #c3d3e4;
  max-width: 680px;
  margin-bottom: 36px;
}
.hero-btns { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 34px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-badge {
  font-size: 0.82rem;
  font-weight: 600;
  color: #e6eef7;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 30px;
  padding: 6px 16px;
  background: rgba(255, 255, 255, 0.06);
}

/* Hero background — heavy machinery action shot (industrial feel) */
.hero.hero-bg {
  background-image:
    linear-gradient(115deg, rgba(8, 28, 51, 0.9) 0%, rgba(13, 42, 74, 0.75) 55%, rgba(20, 64, 110, 0.55) 100%),
    url("../images/excavator-construction-01.jpg");
  background-size: cover;
  background-position: center;
}

/* ---------- Cards / Grids ---------- */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
  display: flex;
  flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: #c8d2de; }

/* Card top images (product line cards, category cards, machine cards) */
.card > img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  border-radius: var(--radius) var(--radius) 0 0;
}

.card-icon {
  width: 56px; height: 56px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  background: var(--orange-soft);
  margin-bottom: 16px;
}
.card-icon svg { width: 30px; height: 30px; stroke: var(--orange-deep); }

.card-body { padding: 26px; display: flex; flex-direction: column; flex: 1; }
.card-body h3 { font-size: 1.15rem; margin-bottom: 10px; }
.card-body p { color: var(--text-light); font-size: 0.94rem; flex: 1; }

.card-link {
  margin-top: 18px;
  font-weight: 700;
  color: var(--orange-deep);
  font-size: 0.92rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: var(--font-body);
}
.card-link:hover { color: var(--blue); }

/* product cards — uniform media block, equal alignment */
.product-card .card-media {
  height: 180px;
  background: linear-gradient(120deg, var(--blue-deep), var(--blue-light));
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.product-card .card-media svg { width: 44px; height: 44px; stroke: var(--orange); }
.product-card .card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}
.product-card:hover .card-media img { transform: scale(1.04); }
.product-card .cat-badge {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--orange);
  color: var(--blue-deep);
  font-family: var(--font-label);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 10px;
  border-radius: 20px;
}
.product-card h3 { font-size: 1.05rem; }
.product-card .product-short {
  font-size: 0.88rem;
  color: var(--text-light);
  margin-top: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: none;
}
.product-card .brands {
  margin-top: 14px;
  font-size: 0.8rem;
  color: var(--text-light);
}
.product-card .brands strong { color: var(--blue); font-weight: 600; }

/* ---------- Feature items ---------- */
.feature-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 4px solid var(--orange);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.feature-item:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.feature-item h4 { font-size: 1.05rem; margin-bottom: 8px; }
.feature-item p { color: var(--text-light); font-size: 0.92rem; }
.feature-num {
  display: inline-block;
  font-family: var(--font-label);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--orange-deep);
  letter-spacing: 2px;
  margin-bottom: 10px;
}

/* ---------- Brand wall ---------- */
.brand-wall { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.brand-chip {
  border: 1px solid var(--border);
  background: var(--white);
  border-radius: 8px;
  padding: 14px 26px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: 0.4px;
  color: var(--blue);
  transition: border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.brand-chip:hover { border-color: var(--orange); color: var(--orange-deep); box-shadow: var(--shadow); }

/* ---------- Market regions ---------- */
.region-item { text-align: left; }
.region-item .region-name {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--orange);
  margin-bottom: 8px;
  display: flex; align-items: center; gap: 8px;
}
.region-item p { color: #c3d3e4; font-size: 0.92rem; }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--orange-deep), var(--orange));
  padding: 54px 0;
  color: var(--blue-deep);
}
.cta-band h2 {
  color: var(--blue-deep);
  font-size: clamp(1.4rem, 2.6vw, 2rem);
  margin-bottom: 8px;
  text-transform: uppercase;
}
.cta-band p { color: rgba(8, 28, 51, 0.85); margin-bottom: 24px; }
.cta-band .btn { background: var(--blue-deep); color: var(--white); border: none; }
.cta-band .btn:hover { background: var(--blue); }

/* ---------- Page header (inner pages) ---------- */
.page-header {
  background: linear-gradient(120deg, var(--blue-deep), var(--blue-mid));
  color: var(--white);
  padding: 64px 0;
  position: relative;
  overflow: hidden;
}
.page-header::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 55% 60% at 85% 15%, rgba(245, 166, 35, 0.12), transparent 60%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.02) 0 2px, transparent 2px 26px);
  pointer-events: none;
}
.page-header::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0; height: 8px;
  background: repeating-linear-gradient(-45deg, var(--orange) 0 18px, transparent 18px 36px);
  opacity: 0.85;
}
.page-header > .container { position: relative; }
.page-header h1 {
  font-family: var(--font-heading);
  color: var(--white);
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.page-header p { color: #c3d3e4; max-width: 720px; font-size: 1.02rem; }
.breadcrumb {
  font-family: var(--font-label);
  font-size: 0.82rem;
  color: #93a9c2;
  margin-bottom: 14px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}
.breadcrumb a { color: var(--orange); }
.breadcrumb a:hover { color: var(--white); }

/* ---------- Products page ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 18px;
  margin-bottom: 40px;
  padding: 20px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.filter-group { display: flex; flex-direction: column; gap: 8px; flex: 1 1 260px; }
.filter-group .fg-title {
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-light);
}
.filter-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-btn {
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--blue);
  font-weight: 600;
  font-size: 0.88rem;
  padding: 9px 18px;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.filter-btn:hover { border-color: var(--orange); color: var(--orange-deep); }
.filter-btn.active { background: var(--blue); border-color: var(--blue); color: var(--white); }
#productSearch {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 11px 15px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--bg);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
#productSearch:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.2);
  background: var(--white);
}

.cat-section { margin-bottom: 48px; }
.cat-section:last-child { margin-bottom: 0; }
.cat-title {
  font-size: 1.35rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding-bottom: 14px;
  margin-bottom: 22px;
  border-bottom: 3px solid var(--orange);
  display: flex;
  align-items: center;
  gap: 12px;
}
.cat-title::before {
  content: "";
  width: 10px;
  height: 10px;
  background: var(--orange);
  transform: rotate(45deg);
  flex: 0 0 auto;
}

.no-results {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-light);
  display: none;
}
.no-results h3 { margin-bottom: 8px; }
.no-results.visible { display: block; }

/* ---------- Used machinery ---------- */
.machine-card { border-left: 5px solid var(--orange); }
.machine-meta {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px 18px;
  margin: 16px 0;
  font-size: 0.9rem;
}
.machine-meta .mm-item { display: flex; justify-content: space-between; gap: 10px; border-bottom: 1px dashed var(--border); padding-bottom: 6px; }
.machine-meta .mm-item span:first-child { color: var(--text-light); font-weight: 600; }
.machine-meta .mm-item span:last-child { color: var(--blue); font-weight: 700; text-align: right; }

.steps { counter-reset: step; display: grid; gap: 18px; }
.step {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
  display: flex; gap: 16px; align-items: flex-start;
}
.step .step-num {
  counter-increment: step;
  flex: 0 0 44px;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--orange-soft);
  color: var(--orange-deep);
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.05rem;
  display: flex; align-items: center; justify-content: center;
}
.step .step-num::before { content: counter(step); }
.step h4 { font-size: 1rem; margin-bottom: 4px; }
.step p { color: var(--text-light); font-size: 0.9rem; }

/* ---------- About ---------- */
.about-split { grid-template-columns: 1.4fr 1fr; gap: 44px; align-items: start; }
.about-block h3 { margin-bottom: 14px; font-size: 1.3rem; }
.about-block p { color: var(--text-light); margin-bottom: 16px; }
.about-highlight {
  background: var(--orange-soft);
  border-left: 4px solid var(--orange);
  padding: 20px 24px;
  border-radius: 0 10px 10px 0;
  margin: 22px 0;
}
.about-highlight p { color: var(--blue); margin: 0; font-weight: 600; }

.check-list li {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 9px 0;
  color: var(--text-light);
  font-size: 0.95rem;
  border-bottom: 1px dashed var(--border);
}
.check-list li::before {
  content: "✓";
  color: var(--orange-deep);
  font-weight: 800;
  flex: 0 0 18px;
}

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 36px; align-items: start; }
.contact-form {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 30px;
  display: grid;
  gap: 16px;
}
.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 13px 15px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--bg);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.2);
  background: var(--white);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-note { font-size: 0.8rem; color: var(--text-light); }

.contact-info { display: grid; gap: 14px; }
.ci-item {
  display: flex; gap: 14px; align-items: flex-start;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.ci-icon {
  flex: 0 0 42px; width: 42px; height: 42px;
  border-radius: 8px;
  background: var(--blue);
  color: var(--orange);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-heading);
  font-weight: 800; font-size: 1.05rem;
}
.ci-item strong { display: block; color: var(--blue); margin-bottom: 2px; font-size: 0.95rem; }
.ci-item span { color: var(--text-light); font-size: 0.9rem; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--blue-deep);
  color: #a9bdd4;
  padding: 60px 0 0;
  font-size: 0.92rem;
}
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: 36px; padding-bottom: 40px; }
.footer-grid h4 {
  font-family: var(--font-label);
  color: var(--white);
  font-size: 0.95rem;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 2px;
}
.footer-grid a { color: #a9bdd4; display: block; padding: 5px 0; }
.footer-grid a:hover { color: var(--orange); }
.footer-brand .logo { margin-bottom: 14px; }
.footer-brand p { max-width: 320px; }
.footer-contact li { display: flex; gap: 8px; padding: 5px 0; }
.footer-contact li::before { content: "›"; color: var(--orange); font-weight: 800; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 18px 0;
  text-align: center;
  font-size: 0.82rem;
  color: #7e94ac;
}

/* ---------- Reveal animation ----------
   Default state: fully visible (no-JS safe).
   Only when .js is present do elements start hidden and
   animate in via IntersectionObserver. */
.reveal { opacity: 1; transform: none; }
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.55s ease, transform 0.55s ease; }
.js .reveal.visible { opacity: 1; transform: none; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 780px; margin: 0 auto; display: grid; gap: 14px; }
.faq-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.faq-item summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 18px 22px;
  font-weight: 700;
  color: var(--blue);
  font-size: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--orange-deep);
  transition: transform 0.2s ease;
}
.faq-item[open] summary::after { content: "–"; }
.faq-item p { padding: 0 22px 18px; color: var(--text-light); font-size: 0.95rem; }
.faq-more { text-align: center; margin-top: 26px; color: var(--text-light); font-size: 0.98rem; }
.faq-more a { font-weight: 700; color: var(--orange-deep); }

/* ---------- Used machinery: typical specifications ---------- */
.spec-block { margin: 16px 0 4px; border-top: 1px dashed var(--border); padding-top: 14px; }
.spec-title {
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--orange-deep);
  margin-bottom: 8px;
}
.spec-list { display: grid; gap: 6px; font-size: 0.88rem; }
.spec-list li { display: flex; justify-content: space-between; gap: 10px; color: var(--text-light); }
.spec-list li span:last-child { color: var(--blue); font-weight: 600; text-align: right; }
.spec-note { margin-top: 8px; font-size: 0.78rem; color: var(--text-light); font-style: italic; }
.spec-disclaimer { margin-top: 18px; text-align: center; font-size: 0.78rem; color: var(--text-light); }

/* ---------- Product cards: Fits common models ---------- */
.product-card .fits { margin-top: 10px; font-size: 0.8rem; color: var(--text-light); }
.product-card .fits strong { color: var(--blue); font-weight: 600; }

/* ---------- Contact: global markets ---------- */
.markets-tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.market-tag {
  border: 1px solid var(--border);
  background: var(--white);
  border-radius: 30px;
  padding: 10px 22px;
  font-weight: 700;
  color: var(--blue);
  font-size: 0.95rem;
  box-shadow: var(--shadow);
}
.response-note {
  max-width: 640px;
  margin: 28px auto 0;
  text-align: center;
  background: var(--orange-soft);
  border-left: 4px solid var(--orange);
  border-radius: 0 10px 10px 0;
  padding: 16px 24px;
  color: var(--blue);
  font-weight: 600;
}

/* ---------- Product detail modal ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(8, 28, 51, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  max-width: 720px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: translateY(18px) scale(0.98);
  transition: transform 0.25s ease;
}
.modal-overlay.open .modal { transform: none; }
.modal-close {
  position: absolute;
  top: 12px; right: 12px;
  width: 38px; height: 38px;
  border: none;
  border-radius: 50%;
  background: var(--blue);
  color: var(--white);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}
.modal-close:hover { background: var(--orange-deep); }
.modal-media {
  height: 300px;
  background: linear-gradient(120deg, var(--blue-deep), var(--blue-light));
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.modal-media img { width: 100%; height: 100%; object-fit: cover; }
.modal-media svg { width: 64px; height: 64px; stroke: var(--orange); }
.modal-body { padding: 28px 30px 30px; }
.modal-body h3 { font-size: 1.35rem; margin-bottom: 10px; padding-right: 34px; }
.modal-desc { color: var(--text-light); font-size: 0.97rem; margin-bottom: 14px; }
.modal-fits { font-size: 0.9rem; color: var(--text-light); margin-bottom: 22px; }
.modal-fits strong { color: var(--blue); }
.modal-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn-email { background: var(--blue); color: var(--white); }
.btn-email:hover { background: var(--blue-light); color: var(--white); }

body.modal-open { overflow: hidden; }

/* ---------- Articles and Industry Guides ---------- */
.article-body { max-width: 860px; margin: 0 auto; }
.article-body p { color: var(--text-light); font-size: 1.02rem; line-height: 1.8; margin-bottom: 18px; }
.article-body h2 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  margin: 38px 0 14px;
  color: var(--blue-deep);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.article-body h2::before {
  content: "";
  display: inline-block;
  width: 14px;
  height: 14px;
  background: var(--orange);
  transform: rotate(45deg);
  margin-right: 12px;
}
.article-body h3 { font-size: 1.15rem; margin: 26px 0 10px; color: var(--blue-deep); }
.article-body ul, .article-body ol { color: var(--text-light); font-size: 1.02rem; line-height: 1.75; margin: 0 0 18px 22px; }
.article-body li { margin-bottom: 8px; }
.article-meta {
  font-family: var(--font-label);
  color: var(--text-light);
  font-size: 0.92rem;
  letter-spacing: 1px;
  margin-bottom: 28px;
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.article-img { width: 100%; height: 340px; object-fit: cover; border-radius: var(--radius); margin: 6px 0 28px; display: block; }
.article-cta { background: var(--orange-soft); border: 1px solid var(--orange); border-radius: var(--radius); padding: 26px 28px; margin-top: 40px; }
.article-cta h3 { margin: 0 0 8px; color: var(--blue-deep); }
.article-cta p { margin: 0 0 16px; color: var(--text-light); }
.article-cta .btn { margin-right: 10px; margin-bottom: 8px; }
.related-articles { margin-top: 44px; padding-top: 26px; border-top: 1px solid var(--border); }
.related-articles h3 { color: var(--blue-deep); margin-bottom: 16px; }
.related-articles a { display: block; color: var(--blue); text-decoration: none; margin-bottom: 10px; font-weight: 600; }
.related-articles a:hover { color: var(--orange-deep); }
.guide-card .card-body p { font-size: 0.92rem; }

/* ---------- Responsive ---------- */
@media (max-width: 992px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .about-split { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .section { padding: var(--section-pad-mobile) 0; }

  .hamburger { display: flex; }
  .nav-cta { display: none; }

  .nav-menu {
    position: absolute;
    top: 68px;
    left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    background: var(--blue-deep);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 10px 20px 18px;
    gap: 4px;
    display: none;
  }
  .nav-menu.open { display: flex; }
  .nav-menu a { padding: 13px 12px; font-size: 1rem; border-radius: 8px; }
  .nav-menu a.active { background: rgba(245, 166, 35, 0.1); box-shadow: none; }

  .hero-inner { padding: 70px 20px 100px; }
  .form-row { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .grid-4, .grid-3 { grid-template-columns: 1fr; }
  .machine-meta { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-btns .btn { width: 100%; }
  .modal-media { height: 210px; }
  .modal-body { padding: 22px 20px 24px; }
  .modal-actions .btn { width: 100%; }
  .section-header { margin-bottom: 40px; }
  .article-img { height: 220px; }
}

/* ============================================================
   i18n — language switcher
   ============================================================ */
.lang-switcher {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 30px;
  padding: 3px;
  flex: 0 0 auto;
}
.lang-btn {
  border: none;
  background: transparent;
  color: #d7e2ef;
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 5px 10px;
  border-radius: 20px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  line-height: 1;
}
.lang-btn:hover { color: var(--orange); }
.lang-btn.active {
  background: var(--orange);
  color: var(--blue-deep);
}
@media (max-width: 992px) {
  .lang-switcher { order: 2; }
  .hamburger { order: 3; }
}

/* ============================================================
   Cookie privacy banner
   ============================================================ */
.cookie-banner {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 400;
  background: var(--blue-deep);
  color: #dbe6f2;
  border-top: 4px solid var(--orange);
  box-shadow: 0 -8px 30px rgba(8, 28, 51, 0.45);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 24px;
  font-size: 0.92rem;
}
.cookie-text { max-width: 860px; margin: 0; line-height: 1.55; }
.cookie-actions { display: flex; gap: 10px; flex: 0 0 auto; }
.cookie-decline {
  border-color: rgba(255, 255, 255, 0.45);
  color: #dbe6f2;
  background: transparent;
}
.cookie-decline:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--orange);
  color: var(--orange);
}
@media (max-width: 560px) {
  .cookie-banner { padding: 14px 16px; }
  .cookie-actions .btn { width: auto; flex: 1; }
  .cookie-actions { width: 100%; }
}

/* ============================================================
   RTL (Arabic) adjustments — dir="rtl" on <html>
   ============================================================ */
html[dir="rtl"] body,
html[dir="rtl"] h1, html[dir="rtl"] h2, html[dir="rtl"] h3, html[dir="rtl"] h4,
html[dir="rtl"] input, html[dir="rtl"] textarea, html[dir="rtl"] select,
html[dir="rtl"] button, html[dir="rtl"] .btn {
  font-family: "Cairo", "Archivo", "Segoe UI", Arial, sans-serif;
}
html[dir="rtl"] h1, html[dir="rtl"] h2, html[dir="rtl"] h3, html[dir="rtl"] h4 {
  letter-spacing: 0;
}
html[dir="rtl"] .card-link,
html[dir="rtl"] .hero-btns,
html[dir="rtl"] .faq-more,
html[dir="rtl"] .filter-chips,
html[dir="rtl"] .brand-wall,
html[dir="rtl"] .markets-tags {
  /* flex rows already mirror automatically with dir=rtl */
}
html[dir="rtl"] .about-highlight { border-left: none; border-right: 4px solid var(--orange); border-radius: 10px 0 0 10px; }
html[dir="rtl"] .machine-card { border-left: none; border-right: 5px solid var(--orange); }
html[dir="rtl"] .cat-title::before { margin-left: 0; }
html[dir="rtl"] .mm-item span:last-child { text-align: left; }
html[dir="rtl"] .spec-list li span:last-child { text-align: left; }
html[dir="rtl"] .modal-close { right: auto; left: 12px; }
html[dir="rtl"] .modal-body h3 { padding-right: 0; padding-left: 34px; }
html[dir="rtl"] .product-card .cat-badge { left: auto; right: 12px; }

/* ============================================================
   Article language note (shown when lang !== en)
   ============================================================ */
.article-lang-note {
  display: none;
  margin: 14px 0 0;
  padding: 10px 16px;
  background: var(--orange-soft);
  border: 1px solid var(--orange);
  border-radius: 8px;
  color: var(--blue);
  font-weight: 600;
  font-size: 0.9rem;
  max-width: 860px;
}

/* ============================================================
   Contact form — structured inquiry extras
   ============================================================ */
.contact-form select {
  appearance: auto;
}
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
@media (max-width: 768px) {
  .form-row-3 { grid-template-columns: 1fr; }
}
.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.form-actions .btn-whatsapp {
  background: #25d366;
  color: #fff;
  border: 2px solid transparent;
}
.form-actions .btn-whatsapp:hover { background: #1eb958; color: #fff; }

/* ============================================================
   Admin page (admin.html) — internal tool, same design tokens
   ============================================================ */
.admin-wrap { max-width: 1100px; margin: 0 auto; }
.admin-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 28px;
  margin-bottom: 24px;
}
.admin-card h3 {
  font-size: 1.1rem;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.admin-card .card-sub { color: var(--text-light); font-size: 0.9rem; margin-bottom: 18px; }
.admin-login {
  max-width: 420px;
  margin: 80px auto;
  text-align: center;
}
.admin-login input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 13px 15px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--bg);
  margin-bottom: 14px;
}
.admin-login input:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.2);
  background: var(--white);
}
.admin-error { color: #c0392b; font-size: 0.9rem; margin-top: 8px; min-height: 1.2em; }
.admin-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.admin-form-grid .full { grid-column: 1 / -1; }
.admin-form-grid label {
  display: block;
  font-family: var(--font-label);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-light);
  margin-bottom: 6px;
}
.admin-form-grid label .lang-tag { color: var(--orange-deep); }
.admin-form-grid input,
.admin-form-grid select,
.admin-form-grid textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 13px;
  font-family: var(--font-body);
  font-size: 0.92rem;
  color: var(--text);
  background: var(--bg);
}
.admin-form-grid input:focus,
.admin-form-grid select:focus,
.admin-form-grid textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(245, 166, 35, 0.2);
  background: var(--white);
}
.admin-form-grid textarea { min-height: 76px; resize: vertical; }
.admin-btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.admin-table th {
  text-align: left;
  font-family: var(--font-label);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-light);
  padding: 10px 12px;
  border-bottom: 2px solid var(--orange);
}
.admin-table td { padding: 10px 12px; border-bottom: 1px solid var(--border); color: var(--text); vertical-align: middle; }
.admin-table tr:hover td { background: var(--bg); }
.admin-table .mini-btn {
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--blue);
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-body);
}
.admin-table .mini-btn:hover { border-color: var(--orange); color: var(--orange-deep); }
.admin-table .mini-btn.danger { color: #c0392b; }
.admin-table .mini-btn.danger:hover { border-color: #c0392b; color: #c0392b; }
.admin-status { font-size: 0.92rem; font-weight: 600; min-height: 1.4em; margin-top: 12px; }
.admin-status.ok { color: #1e8449; }
.admin-status.err { color: #c0392b; }
.admin-hint {
  background: var(--orange-soft);
  border-left: 4px solid var(--orange);
  border-radius: 0 10px 10px 0;
  padding: 14px 18px;
  color: var(--blue);
  font-size: 0.9rem;
  margin-bottom: 20px;
}
@media (max-width: 768px) {
  .admin-form-grid { grid-template-columns: 1fr; }
}
