/* ═══════════════════════════════════════════════════
   GRUPPO ASTRO – Servizi CSS
   Compatibile con child theme Salient
════════════════════════════════════════════════════ */

:root {
  --astro-blue:       #1a3cff;
  --astro-blue-dark:  #0f28c4;
  --astro-navy:       #0d1b3e;
  --astro-grey-light: #f4f6fb;
  --astro-grey:       #e8ecf4;
  --astro-text:       #1a2340;
  --astro-muted:      #6b7a99;
  --astro-white:      #ffffff;
  --astro-radius:     8px;
  --astro-transition: 0.25s ease;
}

/* ── Reset base ── */
.astro-single-servizio *,
.astro-servizi-grid * {
  box-sizing: border-box;
}

/* ─────────────────────────────────────────
   CONTAINER
───────────────────────────────────────── */
.astro-container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ─────────────────────────────────────────
   SECTIONS
───────────────────────────────────────── */
.astro-section {
  padding: 72px 0;
}
.astro-section--processo   { background: var(--astro-grey-light); }
.astro-section--applicazioni { background: var(--astro-white); }
.astro-section--portfolio  { background: var(--astro-grey-light); }
.astro-section--tags       { padding: 32px 0; background: var(--astro-white); }

.astro-section-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--astro-blue);
  margin: 0 0 10px;
}
.astro-section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--astro-navy);
  margin: 0 0 8px;
  line-height: 1.15;
}
.astro-section-sub {
  color: var(--astro-muted);
  margin: 0 0 36px;
  font-size: .95rem;
}

/* ─────────────────────────────────────────
   HERO
───────────────────────────────────────── */
.astro-hero {
  position: relative;
  min-height: 300px;
  display: flex;
  align-items: flex-end;
  background: var(--astro-navy);
  background-size: cover;
  background-position: center;
  overflow: hidden;
}
.astro-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(13,27,62,.75) 40%, rgba(26,60,255,.45) 100%);
}
.astro-hero__content {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 48px 24px 52px;
}
.astro-breadcrumb {
  font-size: .82rem;
  color: rgba(255,255,255,.65);
  margin-bottom: 14px;
}
.astro-breadcrumb a { color: rgba(255,255,255,.75); text-decoration: none; }
.astro-breadcrumb a:hover { color: #fff; }
.astro-breadcrumb__sep { margin: 0 6px; }
.astro-hero__cats { margin-bottom: 12px; }
.astro-hero__cat {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #fff;
  background: var(--astro-blue);
  border-radius: 3px;
  padding: 3px 10px;
  margin-right: 6px;
}
.astro-hero__title {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 900;
  color: #fff;
  margin: 0;
  line-height: 1.1;
}

/* ─────────────────────────────────────────
   INTRO / DESCRIZIONE
───────────────────────────────────────── */
.astro-intro-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 48px;
  align-items: start;
}
.astro-lead {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--astro-text);
  margin: 0 0 20px;
}
.astro-desc-estesa {
  font-size: .95rem;
  line-height: 1.75;
  color: var(--astro-muted);
}
.astro-desc-estesa p { margin: 0 0 14px; }

/* Tecnologie box */
.astro-tecnologie-box {
  background: var(--astro-grey-light);
  border-radius: 10px;
  padding: 24px 28px;
  border: 1px solid var(--astro-grey);
}
.astro-box-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--astro-blue);
  margin: 0 0 14px;
}
.astro-tecnologie-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.astro-tecnologie-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .9rem;
  color: var(--astro-text);
  padding: 7px 0;
  border-bottom: 1px solid var(--astro-grey);
}
.astro-tecnologie-list li:last-child { border-bottom: none; }
.astro-check { width: 20px; height: 20px; flex-shrink: 0; }

/* ─────────────────────────────────────────
   PROCESSO
───────────────────────────────────────── */
.astro-processo-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 36px;
}
.astro-processo-item {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  background: var(--astro-white);
  border-radius: var(--astro-radius);
  border: 1px solid var(--astro-grey);
  padding: 22px 28px;
  transition: box-shadow var(--astro-transition);
}
.astro-processo-item:hover {
  box-shadow: 0 4px 24px rgba(26,60,255,.08);
}
.astro-processo-num {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  background: var(--astro-blue);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: .9rem;
  letter-spacing: .04em;
}
.astro-processo-body h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--astro-navy);
  margin: 0 0 6px;
}
.astro-processo-body p {
  font-size: .88rem;
  color: var(--astro-muted);
  margin: 0;
  line-height: 1.65;
}

/* ─────────────────────────────────────────
   APPLICAZIONI
───────────────────────────────────────── */
.astro-applicazioni-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-top: 36px;
}
.astro-appl-card {
  background: var(--astro-grey-light);
  border-radius: var(--astro-radius);
  border: 1px solid var(--astro-grey);
  padding: 24px;
}
.astro-appl-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--astro-blue);
  color: #fff;
  font-weight: 800;
  font-size: .8rem;
  border-radius: 6px;
  margin-bottom: 12px;
}
.astro-appl-card h3 {
  font-size: .95rem;
  font-weight: 700;
  color: var(--astro-blue);
  margin: 0 0 8px;
}
.astro-appl-card p {
  font-size: .87rem;
  color: var(--astro-muted);
  margin: 0;
  line-height: 1.6;
}

/* ─────────────────────────────────────────
   CTA BAND
───────────────────────────────────────── */
.astro-section--cta {
  padding: 0;
  background: var(--astro-white);
}
.astro-cta-band {
  background: var(--astro-navy);
  border-radius: 12px;
  padding: 36px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin: 0 0 4px;
}
.astro-cta-band__text h3 {
  font-size: 1.2rem;
  font-weight: 800;
  color: #fff;
  margin: 0 0 6px;
}
.astro-cta-band__text p {
  font-size: .9rem;
  color: rgba(255,255,255,.65);
  margin: 0;
}
.astro-cta-band__actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.astro-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 11px 22px;
  border-radius: 6px;
  font-weight: 700;
  font-size: .9rem;
  text-decoration: none;
  transition: all var(--astro-transition);
  white-space: nowrap;
}
.astro-btn--primary {
  background: var(--astro-blue);
  color: #fff;
}
.astro-btn--primary:hover { background: var(--astro-blue-dark); color: #fff; }
.astro-btn--ghost {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255,255,255,.3);
}
.astro-btn--ghost:hover { background: rgba(255,255,255,.1); color: #fff; }

/* ─────────────────────────────────────────
   PORTFOLIO
───────────────────────────────────────── */
.astro-portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 36px;
}
.astro-portfolio-thumb {
  border-radius: var(--astro-radius);
  overflow: hidden;
  aspect-ratio: 4/3;
  position: relative;
}
.astro-portfolio-thumb a {
  display: block;
  width: 100%;
  height: 100%;
  position: relative;
}
.astro-portfolio-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
  display: block;
}
.astro-portfolio-thumb:hover img { transform: scale(1.05); }
.astro-portfolio-thumb__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(13,27,62,.85) 0%, transparent 55%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16px;
  opacity: 0;
  transition: opacity var(--astro-transition);
}
.astro-portfolio-thumb:hover .astro-portfolio-thumb__overlay { opacity: 1; }
.astro-portfolio-thumb__title {
  font-weight: 700;
  font-size: .9rem;
  color: #fff;
  display: block;
  margin-bottom: 4px;
}
.astro-portfolio-thumb__luogo {
  font-size: .78rem;
  color: rgba(255,255,255,.75);
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 6px;
}
.astro-portfolio-thumb__desc {
  font-size: .8rem;
  color: rgba(255,255,255,.8);
  margin: 0;
  line-height: 1.5;
}

/* ─────────────────────────────────────────
   LIGHTBOX
───────────────────────────────────────── */
.astro-lb {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity .25s;
}
.astro-lb:not([hidden]) { opacity: 1; }
.astro-lb[hidden] { display: none; }
.astro-lb__close {
  position: absolute;
  top: 20px;
  right: 24px;
  background: none;
  border: none;
  color: rgba(255,255,255,.7);
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
  padding: 4px;
}
.astro-lb__close:hover { color: #fff; }
.astro-lb__inner { text-align: center; max-width: 90vw; }
.astro-lb__img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: 6px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}
.astro-lb__caption {
  margin-top: 14px;
  color: rgba(255,255,255,.8);
  font-size: .9rem;
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}
.astro-lb__cap-title { color: #fff; font-weight: 700; }

/* ─────────────────────────────────────────
   TAGS
───────────────────────────────────────── */
.astro-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.astro-tag {
  display: inline-block;
  font-size: .8rem;
  color: var(--astro-blue);
  background: rgba(26,60,255,.08);
  border-radius: 20px;
  padding: 5px 14px;
  text-decoration: none;
  transition: background var(--astro-transition);
  border: 1px solid rgba(26,60,255,.15);
}
.astro-tag:hover { background: rgba(26,60,255,.16); }

/* ─────────────────────────────────────────
   SHORTCODE GRIGLIA
───────────────────────────────────────── */
.astro-servizi-grid {
  display: grid;
  gap: 24px;
}
.astro-cols-1 { grid-template-columns: 1fr; }
.astro-cols-2 { grid-template-columns: repeat(2, 1fr); }
.astro-cols-3 { grid-template-columns: repeat(3, 1fr); }
.astro-cols-4 { grid-template-columns: repeat(4, 1fr); }

.astro-servizio-card {
  background: var(--astro-white);
  border: 1px solid var(--astro-grey);
  border-radius: 12px;
  overflow: hidden;
  transition: box-shadow var(--astro-transition), transform var(--astro-transition);
  display: flex;
  flex-direction: column;
}
.astro-servizio-card:hover {
  box-shadow: 0 8px 32px rgba(26,60,255,.1);
  transform: translateY(-3px);
}

/* Card image */
.astro-card-image {
  height: 200px;
  background: var(--astro-navy) center/cover no-repeat;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 14px;
}
.astro-card-no-image {
  background: linear-gradient(135deg, var(--astro-navy) 0%, var(--astro-blue-dark) 100%);
  align-items: center;
  justify-content: center;
}
.astro-card-icon {
  width: 40px;
  height: 40px;
  background: var(--astro-blue);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  position: absolute;
  bottom: 14px;
  left: 14px;
}
.astro-card-no-image .astro-card-icon {
  position: static;
  width: 56px;
  height: 56px;
  background: rgba(255,255,255,.15);
  border-radius: 14px;
}
.astro-card-icon svg { width: 20px; height: 20px; }

/* Card body */
.astro-card-body {
  padding: 20px 22px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.astro-card-cat {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--astro-blue);
  display: block;
  margin-bottom: 8px;
}
.astro-card-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--astro-navy);
  margin: 0 0 10px;
  line-height: 1.25;
}
.astro-card-excerpt {
  font-size: .88rem;
  color: var(--astro-muted);
  margin: 0 0 18px;
  line-height: 1.6;
  flex: 1;
}
.astro-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .87rem;
  font-weight: 700;
  color: var(--astro-blue);
  text-decoration: none;
  margin-top: auto;
  transition: gap var(--astro-transition);
}
.astro-card-link:hover { gap: 10px; }

/* ─────────────────────────────────────────
   RESPONSIVE
───────────────────────────────────────── */
@media (max-width: 1024px) {
  .astro-cols-4 { grid-template-columns: repeat(2, 1fr); }
  .astro-cols-3 { grid-template-columns: repeat(2, 1fr); }
  .astro-intro-grid { grid-template-columns: 1fr; }
  .astro-tecnologie-box { max-width: 100%; }
}
@media (max-width: 768px) {
  .astro-section { padding: 48px 0; }
  .astro-cols-2,
  .astro-cols-3,
  .astro-cols-4 { grid-template-columns: 1fr; }
  .astro-cta-band {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
  .astro-hero__title { font-size: 2rem; }
  .astro-portfolio-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .astro-portfolio-grid { grid-template-columns: 1fr; }
  .astro-cta-band { padding: 24px 20px; }
  .astro-cta-band__actions { flex-direction: column; }
  .astro-btn { text-align: center; justify-content: center; }
}
