@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;1,300;1,400&family=DM+Sans:opsz,wght@9..40,300;9..40,400;9..40,500&display=swap');

/* ══ RESET BASE ══ */
.adgv3-wrap * { box-sizing: border-box; }

/* ══ EFFETTO SIRI — bordo arcobaleno marcato ══ */
@property --adg-angle { syntax:'<angle>'; inherits:false; initial-value:0deg; }
@keyframes adgSpin { to { --adg-angle: 360deg; } }

.adgv3-outer {
    position: relative;
    border-radius: 22px;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.10);
    box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}
/* Bordo Siri — sempre presente ma opaco */
.adgv3-outer::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 25px;
    padding: 3px;
    background: conic-gradient(from var(--adg-angle),
        #ff6b6b 0%, #ffa94d 16%, #ffd43b 33%,
        #69db7c 50%, #4dabf7 66%, #da77f2 83%, #ff6b6b 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    animation: adgSpin 3s linear infinite;
    transition: opacity .4s ease;
    z-index: 0;
}
/* Glow esterno */
.adgv3-outer::after {
    content: '';
    position: absolute;
    inset: -10px;
    border-radius: 32px;
    background: conic-gradient(from var(--adg-angle),
        #ff6b6b, #ffa94d, #ffd43b, #69db7c, #4dabf7, #da77f2, #ff6b6b);
    filter: blur(18px);
    opacity: 0;
    animation: adgSpin 3s linear infinite;
    transition: opacity .4s ease;
    z-index: -1;
}
/* ON: utente digita */
.adgv3-outer.adgv3-on::before { opacity: 1; }
.adgv3-outer.adgv3-on::after  { opacity: 0.20; }
/* GENERA: più veloce */
.adgv3-outer.adgv3-gen::before { opacity: 1; animation-duration: 1s; }
.adgv3-outer.adgv3-gen::after  { opacity: 0.35; animation-duration: 1s; }

/* ══ LAYOUT BANNER ══ */
.adgv3-banner {
    position: relative;
    z-index: 1;
    padding: 36px 32px;
    display: grid;
    grid-template-columns: 1fr 1.6fr;
    gap: 36px;
    align-items: start;
    max-width: 900px;
    margin: 0 auto;
}
.adgv3-wrap { width: 92%; max-width: 940px; margin: 24px auto; }

/* ══ LATO SINISTRO ══ */
.adgv3-kicker {
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #4dabf7;
    margin-bottom: 10px;
    font-family: 'DM Sans', sans-serif;
}
.adgv3-title {
    font-family: 'Playfair Display', serif;
    font-size: 30px;
    font-style: italic;
    font-weight: 300;
    color: #1a1a1a;
    line-height: 1.2;
    margin-bottom: 10px;
}
.adgv3-sub {
    font-size: 13px;
    color: #888;
    line-height: 1.7;
    font-family: 'DM Sans', sans-serif;
    font-weight: 300;
    margin-bottom: 16px;
}
.adgv3-nums {
    display: flex;
    gap: 20px;
    margin-bottom: 16px;
}
.adgv3-num-val {
    display: block;
    font-size: 34px;
    font-weight: 300;
    color: #4dabf7;
    font-family: 'DM Sans', sans-serif;
    line-height: 1;
}
.adgv3-num-lbl {
    display: block;
    font-size: 9px;
    color: #aaa;
    font-family: 'DM Sans', sans-serif;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-top: 2px;
}
.adgv3-bullets { list-style: none; padding: 0; margin: 0; }
.adgv3-bullets li {
    font-size: 12px;
    color: #888;
    font-family: 'DM Sans', sans-serif;
    line-height: 2.2;
    padding-left: 14px;
    position: relative;
}
.adgv3-bullets li::before {
    content: '●';
    position: absolute;
    left: 0;
    font-size: 5px;
    top: 7px;
    color: #4dabf7;
}

/* ══ LATO DESTRO — FORM ══ */
.adgv3-field-lbl {
    font-size: 11px;
    color: #999;
    font-family: 'DM Sans', sans-serif;
    letter-spacing: .5px;
    text-transform: uppercase;
    margin-bottom: 7px;
    margin-top: 14px;
    display: block;
}
.adgv3-field-lbl:first-child { margin-top: 0; }

/* Searchbox */
.adgv3-sbox {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 11px 14px;
    background: #f9f9f9;
    border: 1.5px solid #e8e8e8;
    border-radius: 12px;
    transition: border-color .2s, box-shadow .2s;
}
.adgv3-sbox:focus-within {
    border-color: #4dabf7;
    box-shadow: 0 0 0 3px rgba(77,171,247,0.12);
    background: #fff;
}
.adgv3-sbox input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    font-size: 14px;
    color: #1a1a1a;
    font-family: 'DM Sans', sans-serif;
    font-weight: 300;
}

/* Autocomplete */
.adgv3-ac-list {
    position: absolute;
    top: calc(100% + 4px);
    left: 0; right: 0;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.10);
    border-radius: 14px;
    box-shadow: 0 8px 28px rgba(0,0,0,0.10);
    z-index: 9999;
    display: none;
    overflow: hidden;
}
.adgv3-ac-list.open { display: block; }
.adgv3-ac-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid rgba(0,0,0,0.04);
    font-family: 'DM Sans', sans-serif;
    transition: background .1s;
}
.adgv3-ac-item:hover { background: rgba(77,171,247,0.06); }
.adgv3-ac-label { font-size: 13px; color: #1a1a1a; font-weight: 500; flex: 1; }
.adgv3-ac-sub   { font-size: 11px; color: #bbb; }
.adgv3-ac-badge { font-size: 10px; background: #e8f5e9; color: #2e7d32; padding: 2px 7px; border-radius: 8px; }

/* Chips */
.adgv3-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 4px;
}
.adgv3-chip {
    padding: 5px 13px;
    border: 1.5px solid #e0e0e0;
    border-radius: 20px;
    font-size: 12px;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    transition: all .15s;
    color: #555;
    background: #fff;
    user-select: none;
}
.adgv3-chip:hover { border-color: #4dabf7; color: #4dabf7; }
.adgv3-chip.on {
    background: #4dabf7;
    border-color: #4dabf7;
    color: #fff;
    font-weight: 500;
}
.adgv3-chip-hint { font-size: 10px; color: #bbb; font-family: 'DM Sans', sans-serif; margin-bottom: 8px; }

/* Durata / Dormire */
.adgv3-durs { display: flex; gap: 6px; flex-wrap: wrap; }
.adgv3-dur {
    padding: 5px 14px;
    border: 1.5px solid #e0e0e0;
    border-radius: 20px;
    font-size: 12px;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    transition: all .15s;
    color: #555;
    background: #fff;
    user-select: none;
}
.adgv3-dur:hover { border-color: #4dabf7; color: #4dabf7; }
.adgv3-dur.on { background: #4dabf7; border-color: #4dabf7; color: #fff; font-weight: 500; }

/* Bottone genera */
.adgv3-btn {
    margin-top: 20px;
    width: 100%;
    padding: 13px;
    background: linear-gradient(135deg, #4dabf7, #da77f2);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    transition: opacity .2s, transform .1s;
    letter-spacing: .3px;
}
.adgv3-btn:hover   { opacity: .92; }
.adgv3-btn:active  { transform: scale(.99); }
.adgv3-btn:disabled{ opacity: .6; cursor: wait; }

/* Divider */
.adgv3-divider { height: 1px; background: #f0f0f0; margin: 24px 0; }

/* Loading */
.adgv3-loading {
    display: none;
    text-align: center;
    padding: 32px 20px;
    font-family: 'DM Sans', sans-serif;
    color: #888;
    font-size: 14px;
}
.adgv3-loading.on { display: block; }
.adgv3-loading::after {
    content: '';
    display: block;
    width: 32px;
    height: 32px;
    border: 3px solid #f0f0f0;
    border-top-color: #4dabf7;
    border-radius: 50%;
    animation: adgSpin3 .8s linear infinite;
    margin: 12px auto 0;
}
@keyframes adgSpin3 { to { transform: rotate(360deg); } }

/* ══ RISULTATI ══ */
.adgv3-results { display: none; }
.adgv3-results.on { display: block; }
.adgv3-res-head {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 20px;
}
.adgv3-res-city {
    font-family: 'Playfair Display', serif;
    font-size: 22px;
    font-style: italic;
    color: #1a1a1a;
}
.adgv3-res-meta { font-size: 12px; color: #aaa; font-family: 'DM Sans', sans-serif; }

/* Giorno */
.adgv3-day { margin-bottom: 24px; }
.adgv3-day-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #aaa;
    font-family: 'DM Sans', sans-serif;
    margin-bottom: 12px;
    padding-bottom: 6px;
    border-bottom: 1px solid #f0f0f0;
}

/* Tappa */
.adgv3-tappa {
    display: flex;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    position: relative;
}
.adgv3-tappa:last-child { border-bottom: none; }
.adgv3-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg,#4dabf7,#da77f2);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
    margin-top: 2px;
    font-family: 'DM Sans', sans-serif;
}
.adgv3-num.hotel { background: #1a1a1a; font-size: 14px; }
.adgv3-tappa-body { flex: 1; }
.adgv3-tappa-ora {
    font-size: 11px;
    color: #bbb;
    font-family: 'DM Sans', sans-serif;
    margin-bottom: 2px;
}
.adgv3-tappa-nome {
    font-family: 'Playfair Display', serif;
    font-size: 17px;
    font-style: italic;
    color: #1a1a1a;
    margin-bottom: 4px;
}
.adgv3-badges { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 6px; }
.adgv3-badge {
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
    font-family: 'DM Sans', sans-serif;
    font-weight: 500;
}
.adgv3-badge.v   { background: #e8f5e9; color: #2e7d32; }
.adgv3-badge.web { background: #e3f2fd; color: #1565c0; }
.adgv3-badge.osm { background: #fff8e1; color: #f57f17; }
.adgv3-badge.m   { background: #fce4ec; color: #c62828; }
.adgv3-badge.b   { background: #f3e5f5; color: #6a1b9a; }

.adgv3-tappa-testo {
    font-size: 12px;
    color: #666;
    line-height: 1.6;
    font-family: 'DM Sans', sans-serif;
    margin-bottom: 6px;
}
.adgv3-tappa-links { display: flex; flex-wrap: wrap; gap: 6px; }
.adgv3-link {
    font-size: 11px;
    padding: 4px 10px;
    border: 1px solid #e0e0e0;
    border-radius: 16px;
    text-decoration: none;
    color: #555;
    font-family: 'DM Sans', sans-serif;
    transition: all .15s;
}
.adgv3-link:hover { border-color: #4dabf7; color: #4dabf7; }
.adgv3-link.maps { background: #e3f2fd; border-color: #4dabf7; color: #1565c0; }

/* Azioni */
.adgv3-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #f0f0f0;
}
.adgv3-act {
    padding: 8px 16px;
    border: 1.5px solid #e0e0e0;
    border-radius: 20px;
    font-size: 12px;
    font-family: 'DM Sans', sans-serif;
    cursor: pointer;
    background: #fff;
    color: #555;
    transition: all .15s;
}
.adgv3-act:hover { border-color: #4dabf7; color: #4dabf7; }
.adgv3-act.primary { background: linear-gradient(135deg,#4dabf7,#da77f2); border-color: transparent; color: #fff; }

/* Modal registrazione */
.adgv3-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}
.adgv3-modal-overlay.on { display: flex; }
.adgv3-modal {
    background: #fff;
    border-radius: 20px;
    padding: 32px;
    max-width: 420px;
    width: 90%;
    box-shadow: 0 24px 64px rgba(0,0,0,0.16);
    text-align: center;
}
.adgv3-modal-title {
    font-family: 'Playfair Display', serif;
    font-size: 22px;
    font-style: italic;
    margin-bottom: 8px;
}
.adgv3-modal-sub {
    font-size: 13px;
    color: #888;
    line-height: 1.6;
    margin-bottom: 20px;
    font-family: 'DM Sans', sans-serif;
}

/* Responsive */
@media(max-width:700px){
    .adgv3-banner { grid-template-columns: 1fr; padding: 24px 18px; gap: 20px; }
    .adgv3-nums   { gap: 14px; }
    .adgv3-num-val{ font-size: 26px; }
    .adgv3-title  { font-size: 24px; }
    .adgv3-actions{ flex-direction: column; }
}
