* { font-family: 'Vazirmatn', sans-serif; }
body {
  margin: 0; padding: 0; overflow-x: hidden;
  font-feature-settings: 'ss02' 0, 'lnum' 1, 'tnum' 1;
  -webkit-font-feature-settings: 'ss02' 0, 'lnum' 1, 'tnum' 1;
  -moz-font-feature-settings: 'ss02' 0, 'lnum' 1, 'tnum' 1;
}
img { max-width: 100%; height: auto; }
a { text-decoration: none; }

/* ========== TOP BAR ========== */
.top-bar { background: #1a1a2e; }
.header-main { background: #fff; }

/* ========== NAVBAR ========== */
.navbar { padding: 0; }
.navbar-nav .nav-link {
  font-weight: 500;
  font-size: 0.9rem;
  padding: 0.7rem 0.8rem !important;
  white-space: nowrap;
  color: #333 !important;
  position: relative;
  transition: color 0.2s, background 0.2s;
}
.navbar-nav > .nav-item > .nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px; left: 50%;
  width: 0; height: 2px;
  background: #1a1a2e;
  transition: width 0.3s, left 0.3s;
}
.navbar-nav > .nav-item > .nav-link:hover::after {
  width: 70%; left: 15%;
}
.navbar-nav .nav-link:hover { background: rgba(0,0,0,0.04); }

/* ========== DROPDOWN ========== */
.dropdown-menu {
  border: 1px solid #e0e0e0;
  border-radius: 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  padding: 0.3rem 0;
  min-width: 220px;
  font-size: 0.9rem;
}
.dropdown-item {
  padding: 0.45rem 1.2rem;
  border-bottom: 1px solid #f0f0f0;
  transition: background 0.2s, padding-right 0.2s, color 0.2s;
}
.dropdown-item:last-child { border-bottom: none; }
.dropdown-item:hover {
  background: #f5f7fa;
  padding-right: 1.6rem;
  color: #1a1a2e;
}
.dropdown-submenu { position: relative; }

/* Hover dropdowns - desktop only */
@media (min-width: 992px) {
  .dropdown:hover > .dropdown-menu,
  .dropdown-submenu:hover > .dropdown-menu {
    display: block; visibility: visible; opacity: 1;
  }
  .dropdown-menu {
    display: block; visibility: hidden; opacity: 0;
    transition: opacity 0.2s, visibility 0.2s;
    margin-top: 0;
    pointer-events: none;
  }
  .dropdown:hover > .dropdown-menu,
  .dropdown-submenu:hover > .dropdown-menu {
    pointer-events: auto;
  }
}

/* ========== COUNTERS ========== */
.counter-box { transition: transform 0.3s; }
.counter-box:hover { transform: translateY(-5px); }

/* ========== SCROLL REVEAL BASE ========== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delays for children */
.reveal-stagger > * { opacity: 0; transform: translateY(24px); transition: opacity 0.5s, transform 0.5s; }
.reveal-stagger > *.visible { opacity: 1; transform: translateY(0); }

/* ========== CARD HOVER ========== */
.card.shadow-sm {
  transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              box-shadow 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}
.card.shadow-sm:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.1) !important;
}

/* Product card image zoom */
.product-item .card img {
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.product-item .card:hover img {
  transform: scale(1.08);
}

/* ========== BUTTONS ========== */
.btn {
  transition: all 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative;
  overflow: hidden;
}
.btn-outline-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(13, 110, 253, 0.25);
}

/* ========== SECTION DIVIDER ========== */
section { overflow: hidden; }

/* ========== BREADCRUMB ========== */
.breadcrumb a { transition: color 0.2s; }

/* ========== PAGE LOAD FADE ========== */
.page-wrap {
  animation: pageIn 0.5s ease-out;
}
@keyframes pageIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ========== PRODUCT PAGE ANIMATIONS ========== */

/* Image entrance: zoom + fade + float */
.anim-img {
  animation: imgIn 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}
@keyframes imgIn {
  from { opacity: 0; transform: scale(0.85) rotate(-2deg); }
  to   { opacity: 1; transform: scale(1) rotate(0); }
}
.anim-img:hover {
  animation: imgFloat 3s ease-in-out infinite;
}
@keyframes imgFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

/* Title slide-in from left */
.anim-title {
  animation: titleIn 0.7s 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}
@keyframes titleIn {
  from { opacity: 0; transform: translateX(-40px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* Spec badges pop in staggered */
.anim-badge {
  animation: badgePop 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55) both;
}
@keyframes badgePop {
  from { opacity: 0; transform: scale(0.3); }
  to   { opacity: 1; transform: scale(1); }
}

/* Description fade in */
.anim-desc {
  animation: fadeUp 0.6s 0.4s both;
}

/* Card slide-in: left side */
.anim-card-left {
  animation: slideLeft 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}
@keyframes slideLeft {
  from { opacity: 0; transform: translateX(-60px); }
  to   { opacity: 1; transform: translateX(0); }
}
/* Card slide-in: right side */
.anim-card-right {
  animation: slideRight 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}
@keyframes slideRight {
  from { opacity: 0; transform: translateX(60px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* Coating section fade up */
.anim-coating {
  animation: fadeUp 0.6s 0.3s both;
}

/* List item stagger */
.anim-list li {
  opacity: 0;
  animation: listItemIn 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}
@keyframes listItemIn {
  from { opacity: 0; transform: translateX(-20px); }
  to   { opacity: 1; transform: translateX(0); }
}

/* Table row stagger */
.anim-table tbody tr {
  opacity: 0;
  animation: tableRowIn 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}
@keyframes tableRowIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Catalog button stagger */
.anim-catalog {
  animation: catalogIn 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55) both;
}
@keyframes catalogIn {
  from { opacity: 0; transform: scale(0.6) translateY(20px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

/* Button hover: glow pulse */
.btn-catalog {
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative; overflow: hidden;
}
.btn-catalog:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 8px 25px rgba(13, 110, 253, 0.3);
}
.btn-catalog::after {
  content: '';
  position: absolute; inset: 0; border-radius: inherit;
  background: radial-gradient(circle at var(--mx,50%) var(--my,50%), rgba(255,255,255,0.3), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
}
.btn-catalog:hover::after { opacity: 1; }

/* Card hover for product page */
.product-detail-card {
  transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              box-shadow 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.product-detail-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0,0,0,0.1) !important;
}

/* Parts image hover zoom */
.anim-parts-img {
  transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.anim-parts-img:hover {
  transform: scale(1.03);
}

/* ========== IMAGE HOVER OVERLAY ========== */
.img-hover {
  position: relative; overflow: hidden; display: block;
}
.img-hover::after {
  content: '';
  position: absolute; inset: 0;
  background: rgba(26,26,46,0);
  transition: background 0.3s;
}
.img-hover:hover::after { background: rgba(26,26,46,0.06); }

/* ========== SPECS BADGE ========== */
.badge.bg-light {
  transition: background 0.2s, color 0.2s, transform 0.2s;
}
.badge.bg-light:hover {
  background: #1a1a2e !important;
  color: #fff !important;
  transform: scale(1.05);
}

/* ========== RESPECT REDUCED MOTION ========== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal, .reveal-stagger > * { opacity: 1; transform: none; }
}

/* ========== MOBILE ========== */
@media (max-width: 991px) {
  .navbar-nav .nav-link { white-space: normal; padding: 0.5rem 0.8rem !important; }
  .dropdown-menu { box-shadow: 0 4px 12px rgba(0,0,0,0.1); border: none; background: #fafafa; }
  .navbar-nav > .nav-item > .nav-link::after { display: none; }
  .navbar-collapse { background: #fff; border-radius: 12px; padding: 0.5rem; box-shadow: 0 8px 24px rgba(0,0,0,0.12); margin-top: 0.5rem; }
  .product-item .card .row { flex-direction: column; }
  .product-item .card .col-4 { width: 100%; text-align: center; padding: 1rem 1rem 0 !important; }
  .product-item .card .col-8 { width: 100%; }
  .product-item .card img { max-height: 120px; }
  .counter-box { padding: 1.5rem 1rem !important; }
  .counter-box .display-3 { font-size: 2rem !important; }
  section .container { padding-left: 1rem; padding-right: 1rem; }
  .header-main table tr { display: flex; flex-wrap: wrap; gap: 10px; }
  .header-main table td { display: block; width: 100% !important; text-align: center !important; padding: 0 !important; }
  .header-main table td:first-child { text-align: center !important; }
  .header-main table td:last-child { text-align: center !important; }
  .top-bar .d-flex { flex-wrap: wrap; gap: 4px; }
  .category-filters { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
  .category-filters .filter-btn { font-size: 0.8rem; padding: 0.35rem 0.9rem !important; }
  .card-body.p-5 { padding: 1.5rem !important; }
  .product-detail-page .row.g-5 > * { padding-bottom: 1rem; }
  .icon-box-lg { width: 44px; height: 44px; font-size: 1.2rem; }
  .service-card { margin-bottom: 1rem; }
  .breadcrumb { font-size: 0.85rem; }
}

@media (max-width: 576px) {
  h1 { font-size: 1.5rem !important; }
  h2 { font-size: 1.3rem !important; }
  h3 { font-size: 1.1rem !important; }
  h4 { font-size: 1rem !important; }
  .navbar-brand img { max-height: 50px !important; }
  .display-3 { font-size: 1.8rem !important; }
  .py-5 { padding-top: 2rem !important; padding-bottom: 2rem !important; }
  .g-4 { --bs-gutter-y: 1rem; }
}

/* ========== CATEGORY FILTERS ========== */
.filter-btn { border-radius: 25px !important; padding: 0.45rem 1.2rem !important; font-weight: 600 !important; transition: all 0.3s !important; }
.filter-btn .cat-diamond { color: #0d6efd; font-size: 0.6rem; vertical-align: middle; margin-left: 4px; }
.filter-btn.active .cat-diamond { color: #fff; }
.filter-btn.active { background: #0d6efd !important; color: #fff !important; box-shadow: 0 2px 8px rgba(13,110,253,0.3); }
.filter-btn:hover:not(.active) { background: #e8f0fe !important; border-color: #0d6efd !important; }

/* ========== IMPROVED ICONS ========== */
.icon-box { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 12px; background: linear-gradient(145deg, #ffffff, #e6e6e6); box-shadow: 4px 4px 10px rgba(0,0,0,0.08), -4px -4px 10px rgba(255,255,255,0.7); transition: all 0.3s; color: #1a1a2e; font-size: 1.2rem; }
.icon-box-sm { width: 36px; height: 36px; font-size: 1rem; border-radius: 10px; }
.icon-box-lg { width: 56px; height: 56px; font-size: 1.6rem; border-radius: 14px; }
.icon-box-primary { color: #0d6efd; background: linear-gradient(145deg, #e8f0fe, #d0e2ff); box-shadow: 4px 4px 10px rgba(13,110,253,0.1), -4px -4px 10px rgba(255,255,255,0.8); }
.icon-box:hover { transform: translateY(-2px); box-shadow: 6px 6px 14px rgba(0,0,0,0.12), -6px -6px 14px rgba(255,255,255,0.8); }
.icon-box-primary:hover { box-shadow: 6px 6px 14px rgba(13,110,253,0.15), -6px -6px 14px rgba(255,255,255,0.8); }
.icon-inline { display: inline-flex; align-items: center; gap: 8px; }
.icon-inline .fa { font-size: 1.1rem; width: 20px; text-align: center; }

/* ========== GLOBAL SHADOW/VOLUME ========== */
.card, .shadow-volume { box-shadow: 0 4px 16px rgba(0,0,0,0.06), 0 1px 4px rgba(0,0,0,0.04); transition: box-shadow 0.3s, transform 0.3s; }
.card:hover, .shadow-volume:hover { box-shadow: 0 8px 28px rgba(0,0,0,0.1), 0 2px 8px rgba(0,0,0,0.06); }
.btn { box-shadow: 0 2px 6px rgba(0,0,0,0.06); }
.btn:hover { box-shadow: 0 4px 14px rgba(0,0,0,0.12); }
.btn-primary { box-shadow: 0 4px 12px rgba(13,110,253,0.2); }
.btn-primary:hover { box-shadow: 0 6px 20px rgba(13,110,253,0.3); transform: translateY(-1px); }
section.py-5 { position: relative; }
.bg-white.rounded.shadow-sm, .bg-white.rounded { box-shadow: 0 4px 16px rgba(0,0,0,0.06), 0 1px 4px rgba(0,0,0,0.04) !important; }
.bg-white.rounded.shadow-sm:hover, .bg-white.rounded:hover { box-shadow: 0 8px 28px rgba(0,0,0,0.1) !important; transform: translateY(-2px); }
.bg-light.rounded { box-shadow: inset 0 1px 3px rgba(0,0,0,0.04), 0 4px 16px rgba(0,0,0,0.04); }

/* Service card images with volume */
.rounded-circle.shadow-volume-img { box-shadow: 0 4px 16px rgba(0,0,0,0.1), 0 1px 4px rgba(0,0,0,0.06); border: none !important; transition: transform 0.3s, box-shadow 0.3s; }
.rounded-circle.shadow-volume-img:hover { transform: scale(1.05); box-shadow: 0 8px 28px rgba(0,0,0,0.15); }

/* Counter boxes neumorphic */
.counter-box { background: linear-gradient(145deg, #ffffff, #f0f0f0); box-shadow: 6px 6px 14px rgba(0,0,0,0.06), -6px -6px 14px rgba(255,255,255,0.8); border: none; }

/* Product card on listing page */
.product-item .card { box-shadow: 0 4px 16px rgba(0,0,0,0.06), 0 1px 4px rgba(0,0,0,0.04); transition: transform 0.35s, box-shadow 0.35s; }
.product-item .card:hover { transform: translateY(-6px); box-shadow: 0 12px 32px rgba(0,0,0,0.1), 0 2px 8px rgba(0,0,0,0.06); }

/* Header/section title underline shadow */
h1.fw-bold, h2.fw-bold, h3.fw-bold, h4.fw-bold, h5.fw-bold { text-shadow: 0 1px 2px rgba(0,0,0,0.04); }

/* Footer separator */
footer hr { opacity: 0.15; }

/* Navbar shadow volume */
.navbar { box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
