/* ═══ Twip AI — pagina "Descrivi il viaggio" ═════════════════════════════
   Muro di fotografie che scorre (colonne alternate su/giù), velo scuro sopra,
   e al centro la richiesta all'agente. */
.aipage { margin: 0; height: 100dvh; background: #17191C; color: #fff; overflow: hidden;
  font-family: var(--font-body, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif); }

.wall { position: fixed; inset: -4vh -2vw; display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; z-index: 0; pointer-events: none; }
.wcol { overflow: hidden; }
.wtrack { display: grid; gap: 14px; will-change: transform; }
.wtrack img { width: 100%; display: block; border-radius: 14px; object-fit: cover; background: #24272B; }
.wcol:nth-child(odd) .wtrack { animation: wallUp var(--dur, 64s) linear infinite; }
.wcol:nth-child(even) .wtrack { animation: wallDown var(--dur, 78s) linear infinite; }
.wcol:nth-child(1) { --dur: 66s; } .wcol:nth-child(2) { --dur: 84s; } .wcol:nth-child(3) { --dur: 72s; }
.wcol:nth-child(4) { --dur: 92s; } .wcol:nth-child(5) { --dur: 76s; }
@keyframes wallUp   { from { transform: translate3d(0, 0, 0); }    to { transform: translate3d(0, -50%, 0); } }
@keyframes wallDown { from { transform: translate3d(0, -50%, 0); } to { transform: translate3d(0, 0, 0); } }
@media (prefers-reduced-motion: reduce) { .wtrack { animation: none !important; } }

/* mappa dell'Italia: al centro, tra le foto e il velo */
.ai-map { position: fixed; inset: 0; z-index: 1; pointer-events: none; display: grid; place-items: center; }
.ai-map::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 55% at 50% 50%, rgba(16,18,20,.55) 0%, rgba(16,18,20,0) 70%); }
.ai-map > * { width: min(98vw, 98vh); height: 130vh; transform: translateY(5vh); opacity: 1;
  filter: drop-shadow(0 30px 70px rgba(3,22,38,.6)) saturate(1.05) brightness(1.06); }
.ai-map svg { width: 100%; height: 100%; display: block; overflow: visible; }

/* velo: le foto restano leggibili ma il testo domina */
.veil { position: fixed; inset: 0; z-index: 2; pointer-events: none;
  background: radial-gradient(110% 80% at 50% 46%, rgba(18,20,23,.90) 0%, rgba(18,20,23,.70) 40%, rgba(18,20,23,.44) 72%, rgba(18,20,23,.34) 100%); }

.aistage { position: relative; z-index: 3; pointer-events: none; box-sizing: border-box; height: 100dvh; display: grid; align-content: center; justify-items: center;
  gap: 18px; padding: 96px clamp(18px, 5vw, 48px) 96px; text-align: center; overflow: hidden; }
.aipage.has-out .aistage { display: none; }
.ai-brand { position: fixed; top: 22px; left: clamp(18px, 4vw, 40px); z-index: 6; display: block; }
.ai-brand img { width: 108px; height: auto; display: block; }

.aistage h1 { font-family: var(--font-display, -apple-system, "Helvetica Neue", Arial, sans-serif); font-weight: 700; margin: 0;
  font-size: clamp(30px, 4.6vw, 62px); line-height: 1.04; letter-spacing: -.025em; text-wrap: balance;
  text-shadow: 0 14px 40px rgba(3,22,38,.6); }
.aistage .sub { margin: 0; font-size: clamp(15px, 1.5vw, 19px); color: rgba(255,255,255,.82); }

.aistage form, .aistage a, .aistage button { pointer-events: auto; }
.ai-ask { display: flex; align-items: center; gap: 8px; width: min(680px, 100%); margin-top: 10px;
  background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.24); border-radius: 999px; padding: 7px 7px 7px 24px;
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); transition: border-color .2s, background .2s; }
.ai-ask:focus-within { background: rgba(255,255,255,.2); border-color: rgba(255,255,255,.5); }
.ai-ask input { flex: 1 1 auto; min-width: 0; border: 0; outline: none; background: transparent; color: #fff;
  font: inherit; font-size: 16px; font-weight: 500; padding: 13px 0; }
.ai-ask input::placeholder { color: rgba(255,255,255,.62); }
.ai-ask button { flex: none; width: 46px; height: 46px; border: 0; border-radius: 50%; cursor: pointer; display: grid; place-items: center;
  color: #fff; background: var(--azzurro-twip, #16AFC6); transition: transform .18s, background .2s; }
.ai-ask button:hover { transform: scale(1.06); background: #12A0B6; }
.ai-ask button svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.ai-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; max-width: 780px; }
.ai-chips button { border: 1px solid rgba(255,255,255,.26); background: rgba(255,255,255,.08); color: rgba(255,255,255,.92);
  font: inherit; font-size: 14px; font-weight: 500; padding: 10px 18px; border-radius: 999px; cursor: pointer;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); transition: background .18s, border-color .18s, transform .18s; }
.ai-chips button:hover { background: rgba(22,175,198,.34); border-color: rgba(255,255,255,.5); transform: translateY(-1px); }

/* ── risposta: Twipper costruisce il viaggio ─────────────────────────── */
.ai-out { position: relative; z-index: 3; box-sizing: border-box; height: 100dvh; width: min(880px, 100%); margin: 0 auto; padding: 88px clamp(18px, 5vw, 48px) 40px;
  display: grid; grid-template-rows: auto minmax(0, 1fr); align-content: center; text-align: left; overflow: hidden; }
.ai-out[hidden] { display: none; }
.ai-you { display: flex; align-items: center; gap: 12px; justify-content: center; margin-bottom: 26px; }
.ai-you span { background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22); border-radius: 999px; padding: 10px 20px; font-size: 15px; font-weight: 600; }
.ai-card { background: rgba(255,255,255,.96); color: #0B2C4A; border-radius: 24px; padding: 28px 30px;
  box-shadow: 0 50px 90px -40px rgba(0,0,0,.6); min-height: 0; overflow-y: auto; overscroll-behavior: contain;
  scrollbar-width: none; -ms-overflow-style: none; }
.ai-card::-webkit-scrollbar { display: none; }
.ai-think { display: flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 600; color: #12456E; }
.ai-dots { display: inline-flex; gap: 5px; }
.ai-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--azzurro-twip, #16AFC6); animation: aiDot 1.1s ease-in-out infinite; }
.ai-dots i:nth-child(2) { animation-delay: .15s; } .ai-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes aiDot { 0%,100% { opacity: .3; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-4px); } }
.ai-card h2 { font-family: var(--font-display, -apple-system, "Helvetica Neue", Arial, sans-serif); font-size: 24px; margin: 0 0 6px; letter-spacing: -.02em; }
.ai-card .ai-lead { margin: 0 0 20px; color: #3A5A73; font-size: 15px; line-height: 1.5; }
.ai-days { display: grid; gap: 12px; }
.ai-day { display: grid; grid-template-columns: 76px 1fr; gap: 16px; align-items: start; padding: 11px 0; border-top: 1px solid rgba(11,44,74,.1); }
.ai-day b { font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--azzurro-twip, #16AFC6); padding-top: 2px; }
.ai-day p { margin: 0; font-size: 15px; line-height: 1.5; color: #12456E; }
.ai-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.ai-cta { display: inline-flex; align-items: center; gap: 9px; border: 0; cursor: pointer; text-decoration: none;
  background: #0B2C4A; color: #fff; font: inherit; font-weight: 700; font-size: 15px; padding: 14px 26px; border-radius: 999px; transition: transform .18s, background .2s; }
.ai-cta:hover { transform: translateY(-2px); background: #0E3A5C; color: #fff; }
.ai-ghost { display: inline-flex; align-items: center; gap: 9px; border: 1px solid rgba(11,44,74,.22); background: transparent; color: #0B2C4A;
  font: inherit; font-weight: 600; font-size: 15px; padding: 13px 24px; border-radius: 999px; cursor: pointer; transition: border-color .18s, background .2s; }
.ai-ghost:hover { border-color: #0B2C4A; background: rgba(11,44,74,.05); }
.ai-note { margin: 16px 0 0; font-size: 12.5px; color: #6B8399; }

@media (max-width: 860px) {
  .wall { grid-template-columns: repeat(3, 1fr); }
  .ai-brand img { width: 88px; }
  .ai-map > * { width: min(98vw, 80vh); height: 102vh; transform: translateY(4vh); }
  .ai-day { grid-template-columns: 62px 1fr; gap: 12px; }
}
a { color: var(--azzurro-twip, #16AFC6); }
a:hover { color: #0E7C86; }
/* confini delle regioni: grigio neutro sul fondo scuro */
.ai-map .iregion { stroke: #565C63; }
