/* index.css — stili home (e pagine che lo includono, es. 404): subset da global.css (hero, blobs, bottoni glass, signup). Nessun filtro offerte/bandi. */
/* =========================   RESET + VARIABILI GLOBALI   ========================= */
:root {
  /* Colori di default (se nessun tema è attivo) */
  --bg-color: #f4f4f4;
  --text-color: #333333;
  --heading-color: #111827;

  --primary-color: #007bff;
  --primary-color-darker: #004a99;
  --primary-color-soft: rgba(0, 123, 255, 0.1);

  --card-bg: #ffffff;
  --card-border: rgba(0, 0, 0, 0.05);
  --card-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);

  --input-bg: #ffffff;
  --input-border: #e0e0e0;
  --input-focus-border: #007bff;
  --input-focus-ring: rgba(0, 123, 255, 0.1);

  --button-bg: rgba(255, 255, 255, 0.85);
  --button-text: #111827;
  --button-hover-bg: #f9fafb;

  --glass-bg: rgba(255, 255, 255, 0.65);
  --glass-border: rgba(255, 255, 255, 0.9);
  --glass-blur: 10px;
  --glass-shadow: 0 10px 30px rgba(15, 23, 42, 0.12);

  --blob-blue: #dcff90;
  --blob-fuchsia: #eb7dff;
  --blob-yellow: #ffcb64;

  --font-family-base: 'Inter', system-ui, -apple-system, BlinkMacSystemFont,
    'Segoe UI', sans-serif;

  /* Variabili usate per il telefono/parallasse */
  --screen-scroll-y: 0px;
  --card-scroll-y: 0px;

  --screen-perspective: 800px;
  --screen-rotate-x: 0deg;
  --screen-rotate-y: 12deg;
  --screen-rotate-z: -15.5deg;
  --screen-skew-y: 0deg;

  --card-perspective: 1200px;
  --card-rotate-x: 2deg;
  --card-rotate-y: 14deg;
  --card-rotate-z: -15deg;

  /* Navbar generica */
  --nav-inactive: #b0b0b0;
  --nav-active: #4a4a4a;
  --nav-border-color: #dbdbdb;
  --nav-bg-blur: rgba(255, 255, 255, 0.0);
  --nav-accent-color: #0066cc;

  /* Footer generico */
  --footer-bg: #f7f9fc;
  --footer-text: #4a4a4a;
  --footer-link: #777;
  --footer-link-hover: #0066cc;
  --footer-border-top: #e0e0e0;

  /* Icone social footer */
  --footer-whatsapp: #25d366;
  --footer-telegram: #0088cc;
  --footer-facebook: #3b5998;

  /* Evidenziazione testo animato footer */
  --footer-highlight-bg: #f0f0f0;
}

/* Reset di base */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

body {
  font-family: var(--font-family-base);
  color: var(--text-color);
  line-height: 1.6;
  font-size: 16px;
  background: var(--bg-color);
  padding-top: 60px;
}

/* =========================   LAYOUT GENERALE   ========================= */
.container,
.container-dashboard {
  width: 90%;
  max-width: 1200px;
  margin: 20px auto;
}

.container {
  min-height: calc(100vh - 167px);
}

.container-dashboard {
  min-height: 80vh;
}

/* section {
  margin-top: 5px;
} */

section h1 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 5px;
  color: var(--heading-color);
}

section h2 {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 10px;
  color: var(--heading-color);
}
@media (max-width: 768px) {
    section h2 {
    font-size: 1rem;
    }
}

.subtitle-bandi {
  text-align: center;
  font-size: 0.95rem;
  margin-bottom: 20px;
  color: #555;
  line-height: 1.5;
  padding: 0 15px;
}

.subtitle-bandi a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: bold;
}

.subtitle-bandi a:hover {
  text-decoration: underline;
}

/* =========================   HERO (HOME)   ========================= */
.hero {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  padding: 50px 10%;
  min-height: 85vh;
  overflow: hidden;
  position: relative;
  background: transparent;
  text-align: left;
  background: rgb(0 29 255 / 11%);
}

.hero .content {
  flex: 1;
  z-index: 2;
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 20px;
  font-weight: 700;
  color: var(--heading-color);
}

.hero-title--invite {
  line-height: 1.18;
  letter-spacing: -0.02em;
}

.hero-invite-name {
  position: relative;
  display: inline-block;
  color: inherit;
  font-weight: inherit;
  z-index: 0;
  white-space: nowrap;
}

.hero-invite-name::before {
  content: none;
}

/* Polilinea 2 segmenti: 1° lungo ~-1.8°, 2° più corto e meno angolato.
   Altezza tratto ≈ quasi quanto il testo (un po' meno). */
.hero-invite-name::after {
  content: "";
  position: absolute;
  z-index: -1;
  left: -0.12em;
  right: -0.14em;
  top: 0.08em;
  bottom: 0.06em;
  border-radius: 0;
  pointer-events: none;
  background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 40' preserveAspectRatio='none'%3E%3Cpolyline points='4,22.5 129,18 196,15.6' fill='none' stroke='%23ffffff' stroke-width='28' stroke-linecap='square' stroke-linejoin='miter'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 100% 100%;
}

.hero p {
  font-size: 1.2rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 20px;
}

/* Testo SEO */
.content-width {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
  text-align: center;
}

.content-width h3 {
  font-size: 1.8rem;
  margin-top: 70px;
  margin-bottom: 15px;
  color: #004a99;
}

.content-width p {
  font-size: 1.1rem;
  line-height: 1.6;
  margin-bottom: 30px;
  color: #555;
}

/* =========================   BOTTONI GLOBALI (GLASS HERO STYLE)   ========================= */
.button-group,
.general,
.button-as-link {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
  margin-top: 25px;
  padding: 0 20px;
}

.button-as-link a {
  text-decoration: none;
  color: inherit;
}

/* Bottoni principali con effetto vetro + animazione */
.button-group button,
.general button,
.signup button,
.hero button:not(.carousel-btn),
.job-carousel button:not(.carousel-btn),
.btn-candidati,
.btn-login-for-apply,
.apply-filters-btn,
.save-search-btn {
  flex-grow: 1;
  min-width: 300px;
  max-width: fit-content;
  padding: 15px 25px;
  font-size: 1.1em;
  border-radius: 12px;
  cursor: pointer;
  white-space: nowrap;
  color: #1a1a1a;
  font-weight: bold;
  position: relative;
  overflow: hidden;

  /* Background: vetro trasparente */
  background: rgba(255, 255, 255, 0.0);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);

  /* Bordi di rifrazione */
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.4);
  border-left: 1px solid rgba(255, 255, 255, 0.5);

  /* Shadow multiple per spessore */
  box-shadow:
    0 8px 20px rgba(0, 0, 0, 0.1),
    inset 1px 1px 1px rgba(255, 255, 255, 0.4),
    inset -1px -1px 2px rgba(0, 0, 0, 0.05);

  transition: background-color 0.3s ease, transform 0.2s ease,
    box-shadow 0.3s ease, opacity 0.3s ease;

  /* Animazioni iniziali */
  opacity: 0;
  animation-fill-mode: forwards;
  animation-name: bounceIn, buttonJump;
  animation-duration: 1s, 1.5s;
  animation-timing-function: ease-out, ease-in-out;
  animation-iteration-count: 1, infinite;
  animation-delay: var(--initial-delay, 0s), var(--loop-delay, 1s);
}

/* Delay personalizzati (se usi nth-child) */
.button-group button:nth-child(1) {
  --initial-delay: 1.5s;
  --loop-delay: 1s;
}

.button-group button:nth-child(2) {
  --initial-delay: 1.7s;
  --loop-delay: 1.3s;
}

.button-group button:nth-child(3) {
  --initial-delay: 1.9s;
  --loop-delay: 1.6s;
}

/* Hover effetto vetro */
.button-group button:hover,
.general button:hover,
.hero button:not(.carousel-btn):hover {
  transform: translateY(-3px) scale(1.03);
  background: rgba(255, 255, 255, 0.6);
  box-shadow:
    0 12px 25px rgba(0, 0, 0, 0.12),
    inset 2px 2px 4px rgba(255, 255, 255, 0.6);
  opacity: 1;
  animation-play-state: paused;
}

/* Bottoni del carosello (frecce) – tenerli separati */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.3) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: #333 !important;
  border: 1px solid rgba(255, 255, 255, 0.5) !important;
  border-radius: 12px !important;
  cursor: pointer;
  z-index: 10;
  box-shadow:
    0 4px 15px rgba(0, 0, 0, 0.1),
    inset 1px 1px 2px rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
  padding: 0 !important;
  min-width: 0 !important;
}

.carousel-btn:hover {
  background: rgba(255, 255, 255, 0.5) !important;
  transform: translateY(-50%) scale(1.1);
}

/* Keyframes per i bottoni */
@keyframes bounceIn {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.9);
  }
  60% {
    opacity: 1;
    transform: translateY(-5px) scale(1.05);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes buttonJump {
  0% {
    transform: translateY(0);
  }
  20% {
    transform: translateY(-5px);
  }
  40% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(0);
  }
}

.prev {
  left: 10px;
}

.next {
  right: 10px;
}

/* =========================   SFONDO ANIMATO (BLOBS)   ========================= */
.animated-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  z-index: -2;
  pointer-events: none;
  background: transparent;
  animation: fadeInBackground 2s ease-in forwards;
}

.animated-background::before,
.animated-background::after,
.animated-background .blob-yellow {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(150px);
  will-change: transform, opacity;
  backface-visibility: hidden;
  transform: translateZ(0);
}

/* BLOB BLU (sinistra -> destra) */
.animated-background::before {
  background: radial-gradient(circle, var(--blob-blue), transparent);
  width: 450px;
  height: 450px;
  top: 80%;
  left: 10%;
  animation: moveBlobBlueLR 15s linear infinite, blobFade 15s ease-in-out infinite;
}

/* BLOB FUCSIA (destra -> sinistra) */
.animated-background::after {
  background: radial-gradient(circle, var(--blob-fuchsia), transparent);
  width: 350px;
  height: 350px;
  top: 75%;
  right: 10%;
  animation: moveBlobFuchsiaRL 9s linear infinite, blobFade 9s ease-in-out infinite;
}

/* BLOB GIALLO (sotto -> sopra) */
.animated-background .blob-yellow {
  background: radial-gradient(circle, var(--blob-yellow), transparent);
  width: 300px;
  height: 300px;
  top: 90%;
  left: 50%;
  animation: moveBlobYellowUpDown 11s linear infinite, blobFade 11s ease-in-out infinite;
}

/* Dissolvenza */
@keyframes blobFade {
  0%,
  100% {
    opacity: 0;
  }
  20%,
  80% {
    opacity: 0.7;
  }
  50% {
    opacity: 1;
  }
}

/* Fade-in generale background */
@keyframes fadeInBackground {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* BLOB BLU (Sinistra -> Destra + Pulsazione) */
@keyframes moveBlobBlueLR {
    0% { 
        transform: translateX(0vw) translateY(-90vh) scale(0.8); 
    }
    25% { 
        transform: translateX(20vw) translateY(-80vh) scale(1.1); /* Si ingrandisce */
    }
    50% { 
        transform: translateX(65vw) translateY(-50vh) scale(0.7); /* Si rimpicciolisce */
    }
    75% { 
        transform: translateX(100vw) translateY(-30vh) scale(0.5); 
    }
    100% { 
        transform: translateX(150vw) translateY(0%) scale(1.6); /* Pulsazione massima */
    }
}

/* BLOB FUCSIA (Destra -> Sinistra + Pulsazione) */
@keyframes moveBlobFuchsiaRL {
    0% { 
        transform: translateX(0) translateY(-50%) scale(1.2); 
    }
    33% { 
        transform: translateX(-80vw) translateY(-30%) scale(1.6); 
    }
    66% { 
        transform: translateX(-160vw) translateY(-70%) scale(1.1); 
    }
    100% { 
        transform: translateX(-250vw) translateY(-50%) scale(1.4); 
    }
}

/* BLOB GIALLO (Sotto -> Sopra + Effetto "Respiro") */
@keyframes moveBlobYellowUpDown {
    0% { 
        transform: translateX(-50%) translateY(0) scale(0.5); 
    }
    50% { 
        /* Quando è in alto, diventa enorme e "morbido" */
        transform: translateX(-50%) translateY(-65vh) scale(1.8); 
    }
    100% { 
        transform: translateX(-50%) translateY(0) scale(0.5); 
    }
}

/* Adattamenti mobile */
@media (max-width: 768px) {
  .animated-background::before {
    width: 280px;
    height: 280px;
    top: 80%;
  }

  .animated-background::after {
    width: 250px;
    height: 250px;
    top: 75%;
  }

  .animated-background .blob-yellow {
    width: 220px;
    height: 220px;
    top: 90%;
  }

  @keyframes moveBlobBlueLR {
    0% {
      transform: translateX(0%) translateY(-50%) scale(0.6);
      opacity: 0.7;
    }
    50% {
      transform: translateX(120vw) translateY(-50%) scale(0.9);
      opacity: 1;
    }
    100% {
      transform: translateX(250vw) translateY(-50%) scale(0.6);
      opacity: 0.7;
    }
  }
}

/* =========================   HERO PHONE / PARALLAX CARD   ========================= */
.hero-image-container {
  flex: 1.2;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 600px;
  position: relative;
}

.phone-wrapper {
  position: relative;
  width: 400px;
  height: auto;
}

.phone-frame {
  position: relative;
  width: 100%;
  display: block;
  z-index: 10;
  pointer-events: none;
  filter: drop-shadow(0px 20px 40px rgba(0, 0, 0, 0.25));
}

.screen-content-mask {
  position: absolute;
  z-index: 5;
  overflow: hidden;
  border-radius: 34px;
  top: 2.5%;
  left: 22%;
  width: 62%;
  height: 94%;
  transform: perspective(var(--screen-perspective))
    rotateX(var(--screen-rotate-x)) rotateY(var(--screen-rotate-y))
    rotateZ(var(--screen-rotate-z)) skewY(var(--screen-skew-y));
  transform-style: preserve-3d;
}

.scrolling-images-wrapper {
  display: flex;
  flex-direction: column;
  width: 100%;
  transform: translateY(var(--screen-scroll-y));
  will-change: transform;
  transition: transform 0.1s linear;
}

.scrolling-images-wrapper img {
  width: 100%;
  height: auto;
  display: block;
  margin-bottom: 1px;
}

.parallax-card {
  position: absolute;
  z-index: 20;
  top: 20%;
  right: 10%;
  width: 220px;
  background: var(--glass-bg);
  backdrop-filter: blur(calc(var(--glass-blur) * 1.5));
  -webkit-backdrop-filter: blur(calc(var(--glass-blur) * 1.5));
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
  transform: perspective(var(--card-perspective))
    rotateX(var(--card-rotate-x)) rotateY(var(--card-rotate-y))
    rotateZ(var(--card-rotate-z)) translateY(var(--card-scroll-y));
  will-change: transform;
  transition: transform 0.1s ease-out;
}

.parallax-card.bottom {
  top: 64%;
  right: -11%;
  top: 54%;
  transform: perspective(calc(var(--card-perspective) - 250px)) rotateX(calc(var(--card-rotate-x) - 09deg)) rotateY(calc(var(--card-rotate-y) + 08deg)) rotateZ(calc(var(--card-rotate-z) + 0deg)) translatey(calc(var(--card-scroll-y) - 30px));
  width: 290px;
}

.card-glass-content {
  padding: 15px;
  text-align: left;
}

.t-title {
  font-weight: 800;
  font-size: 0.9rem;
  margin-bottom: 5px;
  color: var(--heading-color);
}

.t-date {
  font-size: 0.8rem;
  color: #6b7280;
}

.t-wish {
  font-weight: 700;
  color: var(--primary-color-darker);
  margin-top: 8px;
  font-size: 0.85rem;
}

/* =========================   FORM REGISTRAZIONE (HOME)   ========================= */
.signup {
  background: rgba(0, 29, 255, 0.11);
  /* border: 1px solid rgba(255, 255, 255, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.4);
  border-left: 1px solid rgba(255, 255, 255, 0.5); */
  padding: 80px 10%;
  text-align: center;
  padding-top:20px;
  color: #fff;
}

.signup h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
  color: #fff;
}

/* Totale reale in HTML (fallback), nascosto finché parte il count-up */
.signup .user-count.is-pending {
  visibility: hidden;
}

.signup h2[data-referral-invite="1"] {
  font-size: 2rem;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.signup form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  max-width: 450px;
  margin: 0 auto;
}

.signup input,
.signup button {
  padding: 14px;
  border: none;
  border-radius: 5px;
  font-size: 1.1rem;
}

.signup input {
  background: #f4f7fa;
}

/* Pack Google + email (home / landing) */
.home-signup-oauth {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 2px;
}

.home-signup-google-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 12px;
  background: #fff;
  color: #0f172a;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
  transition: opacity 0.15s ease, box-shadow 0.15s ease;
}

.home-signup-google-btn.is-disabled {
  opacity: 0.72;
}

.home-signup-google-btn:hover {
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.12);
}

.home-signup-consent {
  text-align: left;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.12);
  transition: box-shadow 0.2s ease, background 0.2s ease;
}

.home-signup-consent.is-collapsed[hidden] {
  display: none;
}

.home-signup-consent.is-nudge {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.95), 0 8px 22px rgba(15, 23, 42, 0.12);
  background: rgba(255, 255, 255, 0.2);
}

.home-signup-consent-hint {
  margin: 0 0 10px;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.35;
}

.home-signup-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 4px 0 2px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.home-signup-divider::before,
.home-signup-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(255, 255, 255, 0.35);
}

.home-signup-checks {
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}

.home-signup-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: #fff;
  font-size: 0.92rem;
  line-height: 1.4;
  cursor: pointer;
  border-radius: 8px;
  padding: 4px 2px;
  transition: box-shadow 0.2s ease, background 0.2s ease;
}

.home-signup-check input {
  margin-top: 3px;
  flex: 0 0 auto;
  min-width: auto;
  width: auto;
  padding: 0;
}

.home-signup-check a {
  color: #fff;
  text-decoration: underline;
}

.home-signup-check.is-nudge {
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.95);
  background: rgba(255, 255, 255, 0.12);
}

.home-signup-privacy {
  margin: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.86rem;
  line-height: 1.45;
}

.home-signup-privacy a {
  color: #fff;
  text-decoration: underline;
}

.signup .home-signup-submit {
  align-self: center;
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  margin-left: auto;
  margin-right: auto;
  border-radius: 12px;
}

/* =========================   MEDIA QUERIES   ========================= */
@media (max-width: 900px) {
  .hero {
    flex-direction: column;
    padding: 40px 15px 0 15px;
    justify-content: flex-start;
    text-align: center;
  }

  .hero .content {
    width: 100%;
    margin-bottom: 30px;
  }

  .hero-title--invite {
    font-size: clamp(1.55rem, 6.2vw, 2.15rem);
  }

  .hero-invite-name {
    white-space: normal;
  }

  .hero-invite-name::after {
    top: 0.07em;
    bottom: 0.05em;
  }

  .hero-image-container {
    width: 100%;
    height: auto;
    min-height: 500px;
    align-items: flex-start;
  }

  .phone-wrapper {
    width: 280px;
    margin: 0 auto;
  }

  .parallax-card {
    width: 160px;
    right: auto;
    left: 40%;
    top: 25%;
  }

  .parallax-card.bottom {
    top: 80%;
    width: 240px;
  }

  .animated-background::before {
    width: 280px;
    height: 280px;
    top: 80%;
  }

  .animated-background::after {
    width: 250px;
    height: 250px;
    top: 75%;
  }

  .animated-background .blob-yellow {
    width: 220px;
    height: 220px;
    top: 90%;
  }

  @keyframes moveBlobBlueLR {
    0% {
      transform: translateX(0%) translateY(-50%) scale(0.6);
      opacity: 0.7;
    }
    50% {
      transform: translateX(120vw) translateY(-50%) scale(0.9);
      opacity: 1;
    }
    100% {
      transform: translateX(250vw) translateY(-50%) scale(0.6);
      opacity: 0.7;
    }
  }
}

@media (max-width: 600px) {
  .hero {
    padding: 0 15px;
  }

  .hero h1 {
    margin-top: 40px;
    font-size: 1.8rem;
    line-height: 1.2;
  }

  .signup h2[data-referral-invite="1"] {
    font-size: 1.5rem;
  }

  .hero p {
    padding: 0 20px;
    font-size: 1rem;
  }

  .job-card {
    width: 80%;
    min-width: 70vw;
    margin-inline: auto;
  }
}
