/* ============================================================
   Enrico Tech Solutions — stylesheet
   ============================================================ */

:root {
  --bg: #0b1220;
  --bg-alt: #0f1830;
  --surface: #131d36;
  --surface-2: #18244380;
  --border: #243150;
  --text: #e8edf7;
  --muted: #9fb0cc;
  --accent: #38bdf8;
  --accent-2: #6366f1;
  --accent-grad: linear-gradient(135deg, #38bdf8 0%, #6366f1 100%);
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 18px 40px -20px rgba(0, 0, 0, .7);
  --container: 1120px;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --font-display: 'Sora', var(--font);
}

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

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

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

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

h1, h2, h3 { font-family: var(--font-display); line-height: 1.12; letter-spacing: -.02em; }

a { color: inherit; text-decoration: none; }

.accent {
  background: var(--accent-grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .18em;
  font-size: .72rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 14px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  font-size: .96rem;
  padding: 13px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--accent-grad); color: #06121f; box-shadow: 0 10px 30px -10px rgba(56, 189, 248, .6); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 36px -12px rgba(56, 189, 248, .7); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-sm { padding: 9px 18px; font-size: .9rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 18, 32, .82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 1.12rem; }
.brand-mark {
  display: grid; place-items: center;
  width: 34px; height: 34px;
  background: var(--accent-grad);
  color: #06121f;
  border-radius: 9px;
  font-size: .9rem; font-weight: 800;
}
.brand-text strong { color: var(--accent); font-weight: 800; }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { font-size: .95rem; color: var(--muted); font-weight: 500; transition: color .15s; }
.nav-links a:hover { color: var(--text); }
.nav-links a.btn-primary { color: #06121f; }
.nav-right { display: flex; align-items: center; gap: 20px; }

/* Selettore lingua */
.lang-switch { display: inline-flex; align-items: center; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; flex-shrink: 0; }
.lang-switch a { padding: 6px 12px; font-size: .82rem; font-weight: 600; color: var(--muted); letter-spacing: .04em; transition: background .15s, color .15s; }
.lang-switch a:hover { color: var(--text); }
.lang-switch a.active { background: var(--accent-grad); color: #06121f; }

.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: 0; cursor: pointer; padding: 8px; }
.nav-toggle span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: .25s; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 92px 0 84px; overflow: hidden; }
.hero-bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    radial-gradient(circle at 18% 12%, rgba(56, 189, 248, .16), transparent 42%),
    radial-gradient(circle at 82% 8%, rgba(99, 102, 241, .18), transparent 40%),
    radial-gradient(circle at 50% 120%, rgba(99, 102, 241, .12), transparent 55%);
}
.hero-inner { position: relative; z-index: 1; max-width: 780px; }
.hero h1 { font-size: clamp(2.3rem, 6vw, 4rem); font-weight: 800; margin-bottom: 22px; }
.lead { font-size: clamp(1.05rem, 2.4vw, 1.28rem); color: var(--muted); max-width: 620px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin: 34px 0 46px; }
.hero-stats { display: flex; flex-wrap: wrap; gap: 40px; list-style: none; }
.hero-stats li { display: flex; flex-direction: column; }
.hero-stats strong { font-family: var(--font-display); font-size: 1.9rem; color: var(--text); }
.hero-stats span { font-size: .85rem; color: var(--muted); }

/* ---------- Sections ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 640px; margin: 0 auto 52px; text-align: center; }
.section-head h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); margin-bottom: 14px; }
.section-sub { color: var(--muted); font-size: 1.05rem; }

/* ---------- Services grid ---------- */
.grid { display: grid; gap: 22px; }
.services { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 26px;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-5px); border-color: var(--accent); box-shadow: var(--shadow); }
.card-icon {
  width: 52px; height: 52px;
  display: grid; place-items: center;
  font-size: 1.5rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 13px;
  margin-bottom: 18px;
}
.card h3 { font-size: 1.18rem; margin-bottom: 10px; }
.card p { color: var(--muted); font-size: .96rem; }

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: .8fr 1.2fr; gap: 56px; align-items: center; }
.about-media { position: relative; }
.about-photo {
  aspect-ratio: 1 / 1;
  border-radius: 22px;
  background: var(--accent-grad);
  display: grid; place-items: center;
  font-family: var(--font-display);
  font-size: 4.5rem; font-weight: 800;
  color: #06121f;
  box-shadow: var(--shadow);
}
.about-badge {
  position: absolute; bottom: -18px; right: -10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 18px;
  display: flex; flex-direction: column;
  box-shadow: var(--shadow);
}
.about-badge strong { font-family: var(--font-display); font-size: 1.02rem; }
.about-badge span { font-size: .82rem; color: var(--accent); }
.about-text h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); margin-bottom: 18px; }
.about-text p { color: var(--muted); margin-bottom: 16px; }
.check-list { list-style: none; margin: 22px 0 28px; display: grid; gap: 12px; }
.check-list li { position: relative; padding-left: 30px; color: var(--text); }
.check-list li::before {
  content: "✓"; position: absolute; left: 0; top: 0;
  width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent-grad); color: #06121f;
  font-size: .72rem; font-weight: 800;
  display: grid; place-items: center;
}

/* ---------- Skills ---------- */
.skills { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; max-width: 820px; margin: 0 auto; }
.chip {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 10px 20px;
  font-size: .94rem; font-weight: 500;
  color: var(--text);
  transition: border-color .15s, color .15s;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Steps ---------- */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.steps li {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
}
.step-num {
  font-family: var(--font-display); font-size: 1.5rem; font-weight: 800;
  background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.steps h3 { font-size: 1.12rem; margin: 12px 0 8px; }
.steps p { color: var(--muted); font-size: .94rem; }

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.contact-text h2 { font-size: clamp(1.7rem, 3.6vw, 2.3rem); margin-bottom: 16px; }
.contact-text > p { color: var(--muted); margin-bottom: 26px; }
.contact-list { list-style: none; display: grid; gap: 14px; }
.contact-list li { display: flex; align-items: center; gap: 12px; color: var(--text); }
.contact-list a:hover { color: var(--accent); }
.contact-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
}
.field { margin-bottom: 18px; }
.field label { display: block; font-size: .88rem; font-weight: 500; margin-bottom: 7px; color: var(--muted); }
.field .opt { color: var(--border); }
.field input, .field textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--text);
  font-family: inherit; font-size: .96rem;
  transition: border-color .15s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field textarea { resize: vertical; }
.form-note { font-size: .8rem; color: var(--muted); margin-top: 12px; }
.form-note.error { color: #fca5a5; }
.form-note.success { color: #86efac; }
/* Honeypot anti-spam: invisibile agli utenti reali */
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 36px 0; background: var(--bg-alt); }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.footer-meta { color: var(--muted); font-size: .88rem; }
.footer-meta a { color: var(--accent); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .services { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .about { grid-template-columns: 1fr; gap: 40px; }
  .about-media { max-width: 320px; }
  .contact { grid-template-columns: 1fr; gap: 36px; }
}

@media (max-width: 640px) {
  .nav-links {
    position: fixed; inset: 70px 0 auto 0;
    flex-direction: column; align-items: stretch;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--border);
    padding: 18px 24px; gap: 6px;
    transform: translateY(-130%);
    transition: transform .3s ease;
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links a { padding: 12px 4px; }
  .nav-links a.btn-primary { margin-top: 8px; text-align: center; }
  .nav-toggle { display: flex; }
  .services { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .hero-stats { gap: 28px; }
  .section { padding: 64px 0; }
}
