/* ============================================================================
   DIMATEC ECOSYSTEM — Unified UI/UX Design System
   Allineato 1:1 ai token visivi di Dimatec Service Hub (00_dimatec_Hub)
   ============================================================================ */

:root {
  --font-display: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-sans: 'DM Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, monospace;
  --dimatec-navy: #0B1D3A;
  --dimatec-navy-deep: #071429;
  --dimatec-navy-mid: #112A52;
  --dimatec-gold: #F5C400;
  --dimatec-gold-hover: #EAB308;
  --dimatec-surface: #F5F7FA;
  --dimatec-ink: #0F172A;
}

html,
body {
  max-width: 100%;
  overflow-x: clip;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans) !important;
  background-color: var(--dimatec-surface) !important;
  color: var(--dimatec-ink);
}

h1, h2, h3, h4, .font-display {
  font-family: var(--font-display) !important;
  overflow-wrap: break-word;
  word-break: break-word;
}

.font-mono,
.sku-code,
.tabular-nums {
  font-family: var(--font-mono) !important;
  font-variant-numeric: tabular-nums;
}

/* Identico al Hero Gradient di Dimatec Service Hub */
.dimatec-hero-grid {
  background-image:
    radial-gradient(circle at 18% 20%, rgba(245, 196, 0, 0.14), transparent 42%),
    radial-gradient(circle at 84% 12%, rgba(56, 189, 248, 0.18), transparent 44%),
    linear-gradient(135deg, #071429 0%, #0B1D3A 52%, #112A52 100%);
}

/* Scrollbar elegante coerente con Hub */
.dimatec-scroll {
  scrollbar-width: thin;
  scrollbar-color: #CBD5E1 transparent;
}
.dimatec-scroll::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.dimatec-scroll::-webkit-scrollbar-track {
  background: transparent;
}
.dimatec-scroll::-webkit-scrollbar-thumb {
  background-color: #CBD5E1;
  border-radius: 9999px;
}
.dimatec-scroll::-webkit-scrollbar-thumb:hover {
  background-color: #94A3B8;
}

/* Header unificato stile Dimatec Service Hub */
.dimatec-unified-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid rgba(226, 232, 240, 0.85);
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 2px rgba(11, 29, 58, 0.04);
}

.dimatec-nav-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  border-radius: 9999px;
  padding: 0.42rem 0.8rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #475569;
  transition: all 0.18s ease;
  white-space: nowrap;
}
.dimatec-nav-pill:hover {
  background-color: #F1F5F9;
  color: #0B1D3A;
}
.dimatec-nav-pill.is-active {
  background-color: rgba(11, 29, 58, 0.08);
  color: #0B1D3A;
  font-weight: 700;
}

/* CTA Gold stile Hub */
.dimatec-btn-gold {
  background-color: var(--dimatec-gold);
  color: var(--dimatec-navy);
  font-weight: 800;
  transition: all 0.18s ease;
}
.dimatec-btn-gold:hover {
  background-color: var(--dimatec-gold-hover);
  transform: translateY(-1px);
  box-shadow: 0 8px 20px -6px rgba(245, 196, 0, 0.55);
}

.dimatec-btn-navy {
  background-color: var(--dimatec-navy);
  color: #FFFFFF;
  font-weight: 700;
  transition: all 0.18s ease;
}
.dimatec-btn-navy:hover {
  background-color: var(--dimatec-navy-mid);
  transform: translateY(-1px);
  box-shadow: 0 10px 22px -8px rgba(11, 29, 58, 0.45);
}

/* Card prodotto moderna */
.dimatec-product-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 1.25rem;
  box-shadow: 0 2px 10px -4px rgba(11, 29, 58, 0.06);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}
.dimatec-product-card:hover {
  transform: translateY(-4px);
  border-color: rgba(11, 29, 58, 0.22);
  box-shadow: 0 18px 34px -12px rgba(11, 29, 58, 0.16);
}

/* Highlight ricerca */
mark.dimatec-hl {
  background-color: rgba(245, 196, 0, 0.38);
  color: #0B1D3A;
  padding: 0 2px;
  border-radius: 3px;
}

/* Reveal compatibilità */
.reveal {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
