
/* Prevent viewport resizing issues on mobile */
html {
    height: 100%;
}

/* Body padding for fixed navbar */
body {
    padding-top: 70px;
    min-height: 100%;
    position: relative;
}

/* Fade In Up Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content-animated {
    opacity: 0;
    animation: fadeInUp 0.5s ease-out forwards;
}

.hero-animated-1 {
    animation-delay: 0s;
}

.hero-animated-2 {
    animation-delay: 0.1s;
}

.hero-animated-3 {
    animation-delay: 0.2s;
}

.hero-animated-4 {
    animation-delay: 0.3s;
}

.hero-animated-5 {
    animation-delay: 0.4s;
}

/* Topbar Styles */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 70px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    background-color: #fff !important;
    padding: 0;
    z-index: 1030;
}

.navbar .container-fluid {
    padding-left: 0;
    padding-right: 0;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    height: 40px;
    display: flex;
    align-items: center;
    padding-left: 20px;
    margin-right: 0;
}

.navbar-brand img {
    height: 100%;
    width: auto;
}

/* Desktop: logo più grande e centrato */
@media (min-width: 992px) {
    .navbar-brand {
        height: 50px;
        display: flex;
        align-items: center;
        padding: 0 0 0 20px;
        margin-top: -8px;
    }
}

.navbar-toggler {
    border: none;
    padding: 0;
    font-size: 1.5rem;
    color: #333;
}

.navbar-toggler:focus {
    box-shadow: none;
}

.dropdown-menu {
    position: fixed !important;
    top: 70px !important;
    left: 0 !important;
    right: 0 !important;
    width: 100vw !important;
    margin: 0 !important;
    transform: none !important;
    border: none;
    border-radius: 0;
    border-top: 1px solid #e0e0e0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 0;
    background-color: #fff;
    z-index: 1029;
}

.dropdown-divider {
    border-top: 1px solid #e0e0e0;
    margin: 0;
    opacity: 1;
}

.dropdown-item {
    padding: 15px 30px;
    font-size: 1.1rem;
    color: #333;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item i {
    margin-right: 15px;
    width: 20px;
    color: #666;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
}

/* Pulsante Ricomincia nella navbar */
.navbar-restart {
    display: flex;
    align-items: center;
    gap: 12px;
    height: 40px;
    padding-right: 20px;
}

/* Desktop Menu */
.navbar-menu-desktop {
    display: flex;
    align-items: center;
    gap: 30px;
    padding-right: 20px;
}

.nav-link-desktop {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    color: #333;
    text-decoration: none;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.nav-link-desktop i {
    color: #e65100;
    font-size: 1rem;
}

.nav-link-desktop:hover {
    color: #e65100;
}

/* Dropdown container allineato a destra */
.dropdown {
    padding-right: 20px;
}

.btn-restart {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: transparent;
    border: 2px solid #333;
    border-radius: 25px;
    color: #333;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-restart:hover {
    background: #333;
    color: white;
    text-decoration: none;
}

.btn-restart i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.btn-restart:hover i {
    transform: rotate(-180deg);
}

.btn-restart span {
    font-size: 0.85rem;
    font-weight: 700;
}

/* Pulsante Home nella navbar */
.btn-home {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: transparent;
    border: none;
    color: #e65100;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.btn-home:hover,
.btn-home:focus {
    color: #333;
    text-decoration: none;
}

.btn-home i {
    font-size: 1rem;
}

.btn-home span {
    font-size: 0.85rem;
    font-weight: 700;
}

/* Responsive per mobile */
@media (max-width: 576px) {
    .navbar-brand {
        padding-left: 15px;
    }
    
    .navbar-restart {
        padding-right: 15px;
    }
    
    .dropdown {
        padding-right: 15px;
    }
    
    .navbar-restart {
        gap: 8px;
    }
    
    .btn-restart {
        padding: 6px 12px;
        font-size: 0.8rem;
        gap: 6px;
    }
    
    .btn-restart span {
        font-size: 0.75rem;
    }
    
    .btn-restart i {
        font-size: 0.9rem;
    }
    
    .btn-home {
        padding: 8px 10px;
        gap: 0;
    }
    
    .btn-home span {
        display: none;
    }
    
    .btn-home i {
        font-size: 1.1rem;
    }
    
    /* Search Card Responsive */
    .search-card {
        padding: 2rem 1.5rem;
        margin: 0 20px;
        border-radius: 20px;
    }
    
    .search-icon {
        width: 70px;
        height: 70px;
        margin-bottom: 1.2rem;
    }
    
    .search-icon i {
        font-size: 1.8rem;
    }
    
    .search-buttons {
        flex-direction: column-reverse;
        gap: 12px;
    }
    
    .btn-continue,
    .btn-location {
        width: 100%;
        justify-content: center;
    }
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.6)), url('/images/bg-risto.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    min-height: 100svh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    color: white;
    padding: 100px 0 40px 0;
    position: relative;
}

/* Desktop: dimezza altezza hero */
@media (min-width: 992px) {
    .hero-section {
        min-height: 50vh;
    }
}

/* Testi bianchi per hero */
.text-white-75 {
    color: rgba(255, 255, 255, 0.85) !important;
}

/* Search Card nella Hero */
.search-card {
    background: white;
    border-radius: 24px;
    border: none;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    text-align: center;
    position: relative;
    overflow: hidden;
    color: #333;
    max-width: 600px;
    margin: 0 auto;
    padding: 2.5rem 2rem;
}

.search-card:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

/* Search Icon Circle */
.search-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(230, 81, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem auto;
    position: relative;
    transition: all 0.4s ease;
}

.search-icon i {
    font-size: 2rem;
    margin-bottom: 0;
    color: #e65100;
}

/* Search Input */
.search-input-container {
    position: relative;
    margin-bottom: 2rem;
}

.search-input {
    width: 100%;
    height: 55px;
    padding: 15px 50px 15px 20px;
    border: 2px solid #ddd;
    border-radius: 15px;
    font-size: 1rem;
    font-weight: 500;
    color: #333;
    background: white;
    transition: all 0.3s ease;
}

.search-input:focus {
    outline: none;
    border-color: #e65100;
    box-shadow: 0 0 0 3px rgba(230, 81, 0, 0.1);
}

.search-gps-icon {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.3s ease;
    transform-origin: center;
}

.search-gps-icon.fa-spin {
    transform: translateY(-50%);
}

.search-gps-icon:hover {
    color: #e65100;
}

/* Search Radius Slider */
.search-radius-container {
    margin-bottom: 2rem;
}

.radius-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
    text-align: center;
}

.radius-slider {
    width: 100%;
    height: 8px;
    border-radius: 15px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.radius-slider::-webkit-slider-thumb {
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #e65100;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.radius-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #e65100;
    cursor: pointer;
    border: 3px solid white;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

/* Search Buttons */
.search-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Desktop: scambia ordine bottoni */
@media (min-width: 992px) {
    .btn-continue {
        order: 2;
    }
    
    .btn-location {
        order: 1;
    }
}

.btn-continue {
    background: #e65100;
    color: white;
    border: 2px solid #e65100;
    padding: 15px 25px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    cursor: pointer;
    white-space: nowrap;
}

.btn-continue:hover,
.btn-continue:focus {
    background: #333;
    color: white;
    border: 2px solid #333;
}

.btn-continue:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-location {
    background: white;
    color: #e65100;
    border: 2px solid #e65100;
    padding: 15px 25px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-location:hover {
    background: #e65100;
    color: white;
}

/* AI Badge */
.ai-badge {
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    padding: 12px 24px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 2rem;
}

.badge-icon {
    margin-right: 8px;
    font-size: 1rem;
}

/* Hero Title */
.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 2rem;
    letter-spacing: -0.02em;
}

.gradient-text {
    background: linear-gradient(135deg, #fff, #e65100, #f87171);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

/* Hero Subtitle */
.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 1.4;
    margin-bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
}

.mood-text {
    color: #e65100;
    font-weight: 600;
}

/* Hero Description */
.hero-description {
    font-size: 1.2rem;
    font-weight: 400;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 3rem;
}

/* CTA Buttons */
.hero-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.btn-cta {
    background: #e65100;
    border: 2px solid #e65100;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(230, 81, 0, 0.3);
}

.btn-cta:hover,
.btn-cta:focus {
    background: white;
    color: #e65100;
    border: 2px solid white;
}

.btn-outline {
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.btn-outline:hover,
.btn-outline:focus {
    background: #333 !important;
    border-color: #333 !important;
    color: white !important;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        padding: 60px 0 80px 0;
        background-attachment: scroll;
        min-height: auto;
    }
    
    .hero-title {
        font-size: 2.8rem;
        margin-bottom: 1.5rem;
        line-height: 1.2;
    }
    
    .hero-subtitle {
        font-size: 1.4rem;
        margin-bottom: 1.5rem;
        line-height: 1.3;
    }
    
    .hero-description {
        font-size: 1.1rem;
        margin-bottom: 2.5rem;
        line-height: 1.4;
    }
    
    .ai-badge {
        margin-bottom: 1.5rem;
        font-size: 0.9rem;
        padding: 10px 18px;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 15px;
    }
    
    .btn-cta,
    .btn-outline {
        width: 100%;
        max-width: 300px;
        padding: 18px 35px;
        font-size: 1.1rem;
        font-weight: 600;
    }
}

@media (max-width: 576px) {
    .hero-section {
        padding: 50px 20px 70px 20px;
    }
    
    .hero-title {
        font-size: 2.2rem;
        margin-bottom: 1.2rem;
        line-height: 1.15;
    }
    
    .hero-subtitle {
        font-size: 1.25rem;
        margin-bottom: 1.2rem;
        line-height: 1.3;
    }
    
    .hero-description {
        font-size: 1rem;
        margin-bottom: 2rem;
        line-height: 1.4;
    }
    
    .ai-badge {
        font-size: 0.85rem;
        padding: 8px 16px;
        margin-bottom: 1.2rem;
    }
    
    .btn-cta,
    .btn-outline {
        padding: 16px 30px;
        font-size: 1rem;
        max-width: 280px;
    }
}

/* Brand Color Utility Classes */
.text-brand {
    color: #e65100 !important;
}

.bg-brand {
    background-color: #e65100 !important;
}

.border-brand {
    border-color: #e65100 !important;
}

/* Black Color Utility Classes */
.text-black {
    color: #000000 !important;
}

.bg-black {
    background-color: #000000 !important;
}

.border-black {
    border-color: #000000 !important;
}

/* White Color Utility Classes */
.text-white {
    color: #ffffff !important;
}

.bg-white {
    background-color: #ffffff !important;
}

.border-white {
    border-color: #ffffff !important;
}

/* Link Hover States */
a, a:focus, a:active, a:visited {
    text-decoration: none;
}

a:hover {
    color: #e65100 !important;
    text-decoration: none;
}

/* Come Funziona Section */
.come-funziona-section {
    background-color: #f8f9fa;
    padding: 60px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.2rem;
    color: #666;
    font-weight: 400;
}

/* Step Cards - Modern Style */
.step-card {
    background: white;
    padding: 2.5rem 2rem;
    border-radius: 24px;
    border: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    text-align: center;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #333;
}

.step-card:hover {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* Step Number Badge */
.step-number {
    position: absolute;
    top: 16px;
    left: 16px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Icon Circle */
.step-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(230, 81, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem auto;
    position: relative;
    transition: all 0.4s ease;
}

.step-icon i {
    font-size: 2rem;
    margin-bottom: 0;
    color: #e65100;
}

.step-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.step-description {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 0;
    font-weight: 500;
    color: #666;
}

/* Trust Points Strip */
.trust-strip {
    background: white;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.trust-point {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 1.1rem;
    color: #333;
    padding: 1rem;
}

.trust-point i {
    font-size: 1.3rem;
    margin-right: 0.5rem;
}

/* Section CTA Button */
.btn-cta-section {
    background: linear-gradient(135deg, #007bff, #0056b3);
    border: none;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 15px 35px;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.btn-cta-section:hover {
    background: linear-gradient(135deg, #0056b3, #004085);
    color: white;
}

/* Sticky CTA Mobile */
.sticky-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: white;
    padding: 15px;
    padding-bottom: calc(15px + env(safe-area-inset-bottom));
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    transform: translateY(calc(100% + 50px));
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.sticky-cta.show {
    transform: translateY(0);
}

.btn-sticky {
    background: #e65100;
    border: 2px solid #e65100;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 16px 35px;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(230, 81, 0, 0.3);
}

.btn-sticky:hover,
.btn-sticky:focus {
    background: white;
    color: #e65100;
    border: 2px solid white;
}

/* Mobile First Responsive */
@media (max-width: 576px) {
    .come-funziona-section {
        padding: 40px 0 100px 0; /* Extra padding bottom for sticky CTA */
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .section-subtitle {
        font-size: 1.1rem;
    }
    
    .step-card {
        padding: 2rem 1.5rem;
        margin-bottom: 1.5rem;
        border-radius: 20px;
    }
    
    .step-icon {
        width: 70px;
        height: 70px;
        margin-bottom: 1.2rem;
    }
    
    .step-icon i {
        font-size: 1.8rem;
    }
    
    .step-title {
        font-size: 1.2rem;
    }
    
    .step-description {
        font-size: 0.95rem;
    }
    
    .step-number {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }
    
    .trust-strip {
        padding: 1.5rem 1rem;
    }
    
    .trust-point {
        padding: 0.8rem;
        font-size: 1rem;
    }
    
    .trust-point i {
        font-size: 1.2rem;
    }
}

@media (min-width: 768px) {
    .step-card:hover .step-number {
        background: rgba(0, 0, 0, 0.9);
    }
    
    .step-card:hover .step-icon {
        background: rgba(230, 81, 0, 0.3);
    }
}

/* Percorso Section */
.percorso-section {
    background: linear-gradient(135deg, #e65100 0%, #f87171 100%);
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.percorso-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="80" cy="40" r="1.5" fill="rgba(255,255,255,0.1)"/><circle cx="40" cy="80" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="90" cy="90" r="1" fill="rgba(255,255,255,0.1)"/></svg>');
    pointer-events: none;
}

/* Section titles on orange background */
.percorso-section .section-title {
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.percorso-section .section-subtitle {
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.percorso-card {
    background: white;
    padding: 24px;
    border-radius: 24px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
    border: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    text-align: center;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.percorso-card.bounce-animation {
    animation: cardBounce 0.8s ease-in-out;
}

@keyframes cardBounce {
    0%, 100% {
        transform: translateY(0);
    }
    25% {
        transform: translateY(-15px);
    }
    50% {
        transform: translateY(0);
    }
    75% {
        transform: translateY(-8px);
    }
}

.percorso-card:hover {
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.25);
    transform: scale(1.03);
}

.percorso-card::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, #fff, #f8f9fa);
    border-radius: 26px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.percorso-card:hover::after {
    opacity: 1;
}

.percorso-icon {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, #e65100, #ff8a50);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem auto;
    transition: all 0.4s ease;
}

.percorso-icon i {
    font-size: 2.5rem;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.percorso-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.percorso-description {
    font-size: 1.1rem;
    color: #666;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

/* Domande Esempio */
.domande-esempio {
    text-align: center;
    margin: 1.5rem 0;
}

.domanda-item {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.2rem;
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
    background-color: #f8f9fa;
    padding: 0.8rem 1rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.domanda-item i {
    margin-right: 0.8rem;
    color: #e65100;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.domanda-item:last-child {
    margin-bottom: 0;
}

/* AI Esempio */
.ai-esempio {
    text-align: left;
    margin: 1.5rem 0;
}

.ai-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.2rem;
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
    background-color: #f8f9fa;
    padding: 0.8rem 1rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.ai-header i {
    margin-right: 0.8rem;
    color: #e65100;
    font-size: 1rem;
}

.ai-input-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 1rem;
}

.ai-input-wrapper .ai-user-icon {
    width: 32px;
    height: 32px;
    background: #e65100;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 3px;
}

.ai-input-wrapper .ai-user-icon i {
    color: white;
    font-size: 0.85rem;
}

.ai-esempio .ai-input {
    background-color: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.2);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    font-style: italic;
    color: #666;
    font-size: 0.9rem;
    line-height: 1.4;
    position: relative;
    flex: 1;
}

/* Triangolo bordo esterno */
.ai-esempio .ai-input::before {
    content: '';
    position: absolute;
    left: -9px;
    top: 10px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 9px 8px 0;
    border-color: transparent rgba(248, 113, 113, 0.2) transparent transparent;
}

/* Triangolo riempimento interno */
.ai-esempio .ai-input::after {
    content: '';
    position: absolute;
    left: -8px;
    top: 10px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 8px 8px 0;
    border-color: transparent rgba(248, 113, 113, 0.1) transparent transparent;
}

.ai-esempio .ai-input span {
    display: block;
}

/* Vignetta nello step 2 (stessi colori della home) */
#ai-input-wrapper-step2 .ai-input {
    background-color: rgba(248, 113, 113, 0.1);
    border: 1px solid rgba(248, 113, 113, 0.2);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    font-style: italic;
    color: #666;
    font-size: 0.9rem;
    line-height: 1.4;
    position: relative;
    flex: 1;
}

/* Triangolo bordo esterno */
#ai-input-wrapper-step2 .ai-input::before {
    content: '';
    position: absolute;
    left: -9px;
    top: 10px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 9px 8px 0;
    border-color: transparent rgba(248, 113, 113, 0.2) transparent transparent;
}

/* Triangolo riempimento interno */
#ai-input-wrapper-step2 .ai-input::after {
    content: '';
    position: absolute;
    left: -8px;
    top: 10px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 8px 8px 0;
    border-color: transparent rgba(248, 113, 113, 0.1) transparent transparent;
}

.ai-response {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.2rem;
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
    background-color: #f8f9fa;
    padding: 0.8rem 1rem;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.ai-response i {
    margin-right: 0.8rem;
    color: #e65100;
    font-size: 1rem;
}

.btn-percorso {
    padding: 15px 35px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    width: 100%;
    max-width: 350px;
}

.btn-guidato {
    background: #e65100;
    color: white;
    border: 2px solid #e65100;
    box-shadow: 0 4px 15px rgba(230, 81, 0, 0.3);
    font-weight: 700;
}

.btn-guidato:hover,
.btn-guidato:focus {
    background: white;
    color: #e65100;
    border-color: white;
}

.btn-ai {
    background: #333;
    color: white;
    border: 2px solid #333;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    font-weight: 700;
}

.btn-ai:hover,
.btn-ai:focus {
    background: #e65100 !important;
    color: white !important;
    border-color: #e65100 !important;
}

/* Responsive Percorso Section */
@media (max-width: 768px) {
    .percorso-section {
        padding: 60px 0;
    }
    
    .percorso-card {
        padding: 24px;
        margin-bottom: 2rem;
    }
    
    .percorso-icon {
        width: 80px;
        height: 80px;
        margin-bottom: 1.5rem;
    }
    
    .percorso-icon i {
        font-size: 2rem;
    }
    
    .percorso-title {
        font-size: 1.3rem;
    }
    
    .percorso-description {
        font-size: 1rem;
        margin-bottom: 1.2rem;
    }
    
    .domande-esempio {
        margin: 1.2rem 0;
    }
    
    .domanda-item {
        font-size: 0.85rem;
        margin-bottom: 1rem;
        padding: 0.7rem 0.8rem;
    }
    
    .domanda-item i {
        font-size: 0.8rem;
        margin-right: 0.7rem;
    }
    
    .ai-esempio {
        margin: 1.2rem 0;
    }
    
    .ai-header {
        font-size: 0.85rem;
        margin-bottom: 1rem;
        padding: 0.7rem 0.8rem;
    }
    
    .ai-input-wrapper {
        gap: 8px;
    }
    
    .ai-input-wrapper .ai-user-icon {
        width: 28px;
        height: 28px;
    }
    
    .ai-input-wrapper .ai-user-icon i {
        font-size: 0.75rem;
    }
    
    .ai-esempio .ai-input {
        padding: 0.7rem 0.9rem;
        font-size: 0.85rem;
    }
    
    .ai-response {
        font-size: 0.85rem;
        margin-bottom: 1rem;
        padding: 0.7rem 0.8rem;
    }
    
    .btn-percorso {
        padding: 16px 30px;
        font-size: 1rem;
        max-width: none;
        width: 100%;
    }
}

/* Footer Section */
.footer-section {
    background: #333;
    color: white;
    padding: 60px 0 10px 0;
    margin-top: 80px;
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
}

.footer-logo {
    margin-bottom: 2rem;
}

.footer-logo-img {
    height: 60px;
    width: auto;
    filter: brightness(0) invert(1);
}

.footer-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #e65100;
    margin-bottom: 1.5rem;
    text-transform: lowercase;
}

.footer-description {
    font-size: 1.2rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
    font-weight: 400;
}

.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-link {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: #e65100;
}

.footer-divider {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    font-weight: 400;
}

.footer-copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 10px;
    margin-top: 2rem;
}

.footer-copyright p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.5;
}

.no-link {
    text-decoration: none !important;
    pointer-events: none;
    color: inherit;
}

/* Footer Responsive */
@media (max-width: 768px) {
    .footer-section {
        padding: 50px 0 10px 0;
        margin-top: 60px;
    }
    
    .footer-logo-img {
        height: 50px;
    }
    
    .footer-title {
        font-size: 2rem;
    }
    
    .footer-description {
        font-size: 1.1rem;
        margin-bottom: 1.5rem;
    }
    
    .footer-description br {
        display: none;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 1rem;
        margin-bottom: 2rem;
    }
    
    .footer-copyright p {
        font-size: 0.8rem;
        line-height: 1.4;
    }
}

@media (min-width: 992px) {
    .sticky-cta {
        display: none !important;
    }
    
    .come-funziona-section {
        padding: 80px 0;
    }
    
    .trust-point {
        justify-content: flex-start;
    }
}

/* ==========================================
   MULTI-STEP FORM STYLES
   ========================================== */

/* Step Indicators */
.step-indicators {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 40px;
    padding-bottom: 10px;
    order: 999;
}

.step-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ddd;
    transition: all 0.3s ease;
    cursor: pointer;
}

.step-dot.active {
    background: #e65100;
    width: 14px;
    height: 14px;
    box-shadow: 0 0 0 4px rgba(230, 81, 0, 0.2);
}

.step-dot.completed {
    background: #4CAF50;
}

/* Form Steps */
.search-form {
    position: relative;
    overflow: hidden;
    min-height: 450px;
    display: flex;
    flex-direction: column;
}

.form-step {
    display: none;
    opacity: 0;
    transition: opacity 0.2s ease;
    min-height: 400px;
    flex: 1;
}

.form-step.active {
    display: flex;
    flex-direction: column;
    opacity: 1;
}

.form-step.fading-out {
    opacity: 0;
}

/* Step Title */
.step-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Step Subtitle (AI Mode) */
.step-subtitle {
    font-size: 1rem;
    font-weight: 400;
    color: #666;
    margin-bottom: 25px;
    text-align: center;
    line-height: 1.5;
}

/* AI Input Display */
.ai-input-display {
    margin-bottom: 1.5rem;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 10px;
    padding: 0 15px;
    max-width: 100%;
}

.ai-input-display.visible {
    opacity: 1;
    transform: translateY(0);
}

/* User Icon (fuori dal bubble) */
.ai-input-display .ai-user-icon {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 3px;
}

.ai-input-display .ai-user-icon i {
    color: #e65100;
    font-size: 0.9rem;
}

/* Speech Bubble */
.ai-input {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    padding: 10px 16px;
    position: relative;
    flex: 1;
    min-width: 0;
}

/* Punta del bubble verso l'icona */
.ai-input::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 10px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 8px 8px 0;
    border-color: transparent rgba(255, 255, 255, 0.95) transparent transparent;
    filter: drop-shadow(-1px 0px 1px rgba(0, 0, 0, 0.05));
}

.ai-input-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-align: left;
    width: 100%;
}

.ai-input-label {
    color: #6c757d;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1.2;
}

.ai-input-text {
    color: #333;
    font-size: 0.85rem;
    font-weight: 500;
    font-style: italic;
    line-height: 1.3;
}

/* Responsive per schermi più grandi */
@media (min-width: 576px) {
    .ai-input-display {
        gap: 12px;
        padding: 0 30px;
        justify-content: flex-start;
    }
    
    .ai-input-display .ai-user-icon {
        width: 36px;
        height: 36px;
    }
    
    .ai-input-display .ai-user-icon i {
        font-size: 1rem;
    }
    
    .ai-input {
        padding: 12px 18px;
        max-width: calc(100% - 50px);
    }
    
    .ai-input-label {
        font-size: 0.75rem;
    }
    
    .ai-input-text {
        font-size: 0.9rem;
        line-height: 1.35;
    }
}

@media (min-width: 768px) {
    .ai-input {
        max-width: 600px;
    }
}

/* Desktop: vignetta larga quanto la card (500px) */
@media (min-width: 992px) {
    .ai-input-display {
        max-width: 500px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .ai-input {
        max-width: none;
    }
}

/* AI Textarea Container */

.ai-textarea {
    width: 100%;
    padding: 18px 20px;
    font-size: 1rem;
    font-family: inherit;
    color: #333;
    background: #fff;
    border: 2px solid #ddd;
    border-radius: 15px;
    resize: vertical;
    min-height: 120px;
    transition: all 0.3s ease;
    line-height: 1.6;
}

.ai-textarea:focus {
    outline: none;
    border-color: #e65100;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(230, 81, 0, 0.1);
}

.ai-textarea::placeholder {
    color: #999;
    font-weight: 400;
}

/* Back Button */
.btn-back {
    background: white;
    color: #666;
    border: 2px solid #ddd;
    padding: 14px 32px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-back:hover {
    background: #f5f5f5;
    border-color: #999;
    color: #333;
}

.btn-back:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-back i {
    font-size: 0.9rem;
}

/* Wizard Options */
.wizard-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.wizard-option {
    position: relative;
    cursor: pointer;
    margin: 0;
    text-align: left;
}

.wizard-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.wizard-option .option-content {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px 25px;
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 15px;
    transition: all 0.3s ease;
    font-size: 1.1rem;
    font-weight: 500;
    color: #333;
}

.wizard-option .option-content i {
    font-size: 1.5rem;
    color: #666;
    min-width: 30px;
    text-align: center;
}

.wizard-option .option-content .option-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #e0e0e0;
    color: #666;
    border-radius: 50%;
    font-weight: 700;
    font-size: 1rem;
    min-width: 32px;
    flex-shrink: 0;
}

.wizard-option input[type="radio"]:checked + .option-content .option-number {
    background: #e65100;
    color: white;
}

.wizard-option:hover .option-content {
    background: #fff;
    border-color: #e65100;
}

.wizard-option input[type="radio"]:checked + .option-content {
    background: #fff5f0;
    border-color: #e65100;
    border-width: 3px;
    padding: 17px 24px;
}

.wizard-option input[type="radio"]:checked + .option-content i {
    color: #e65100;
}

/* Wizard Summary */
.wizard-summary {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 15px 20px;
    margin-bottom: 25px;
    display: none;
}

.wizard-summary.visible {
    display: block;
}

.wizard-summary-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #666;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wizard-summary-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.wizard-summary-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.95rem;
    color: #333;
    border: 1px solid #ddd;
}

.wizard-summary-item i {
    color: #e65100;
    font-size: 0.9rem;
}

.wizard-summary-item strong {
    color: #666;
    font-weight: 600;
}

/* ==========================================
   SEARCH PAGE STYLES
   ========================================== */

/* Search Hero */
.search-hero {
    min-height: 100svh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    padding: 100px 0 40px 0;
}

@media (max-width: 768px) {
    .search-hero {
        min-height: auto;
        padding: 80px 0 40px 0;
    }
}

/* Loading Icon */
.search-loading-icon {
    margin-bottom: 40px;
}

.search-loading-icon i {
    font-size: 4rem;
    color: #e65100;
}

/* Loading state: animated icon */
#loading-state .search-loading-icon i {
    animation: magicPulse 2s ease-in-out infinite;
}

/* Results state: static icon */
#results-state .search-loading-icon i {
    animation: none;
}

@keyframes magicPulse {
    0%, 100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
    50% {
        transform: scale(1.2) rotate(10deg);
        opacity: 0.8;
    }
}

/* Dynamic Titles */
.search-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 30px;
}

/* Loading state titles */
#loading-state .search-title {
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease;
}

#loading-state .search-subtitle {
    font-size: 1.3rem;
    margin-bottom: 30px;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.3s ease;
}

/* Desktop: rimuovi margin-bottom per loading state */
@media (min-width: 992px) {
    #loading-state .search-title {
        margin-bottom: 0;
    }
}

/* Search Info Wrapper */
.search-info-wrapper {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.search-info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 500;
}

.search-info-item i {
    color: #e65100;
    font-size: 1.2rem;
}

.search-info-item strong {
    font-weight: 700;
    color: white;
}

/* Search Info Compact (inline version) */
.search-info-compact {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.9);
}

.info-compact-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.info-compact-item i {
    color: #e65100;
    font-size: 1rem;
}

.info-compact-item strong {
    color: white;
    font-weight: 600;
}

.info-compact-separator {
    color: rgba(255, 255, 255, 0.5);
    font-weight: 300;
}

/* Search Details Accordion (Mobile Only) */
.search-details-accordion {
    display: none; /* Hidden by default on desktop */
    max-width: 600px;
    margin: 20px auto 30px auto;
}

.accordion-toggle {
    width: 100%;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: white;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.accordion-toggle:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

.accordion-toggle i.fa-search {
    color: #e65100;
    font-size: 1rem;
    flex-shrink: 0;
}

.accordion-toggle span {
    flex: 1;
}

.accordion-icon {
    font-size: 0.9rem;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.accordion-toggle.active .accordion-icon {
    transform: rotate(180deg);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, opacity 0.3s ease;
    opacity: 0;
}

.accordion-content.active {
    max-height: 1000px;
    opacity: 1;
    padding-top: 20px;
}

/* Desktop: Show content directly without accordion */
.search-details-desktop {
    display: block; /* Show on desktop by default */
}

@media (min-width: 769px) {
    .search-details-accordion {
        display: none !important; /* Force hide accordion on desktop */
    }
}

@media (max-width: 768px) {
    .search-details-desktop {
        display: none !important; /* Hide desktop version on mobile */
    }
}

/* User Input Box */
.user-input-box {
    margin-bottom: 30px;
}

/* Radius Expansion Alert */
.radius-expansion-alert {
    background: rgba(230, 81, 0, 0.1);
    border: 2px solid rgba(230, 81, 0, 0.3);
    border-radius: 12px;
    padding: 15px 20px;
    margin: 0 auto 30px auto;
    max-width: 600px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.radius-expansion-alert .alert-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: #e65100;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.radius-expansion-alert .alert-icon i {
    color: white;
    font-size: 1.2rem;
}

.radius-expansion-alert .alert-content {
    flex: 1;
    text-align: left;
    color: white;
    font-size: 0.95rem;
    line-height: 1.5;
}

.radius-expansion-alert .alert-content strong {
    color: #e65100;
    font-weight: 700;
}

@media (max-width: 768px) {
    .radius-expansion-alert {
        padding: 12px 15px;
        margin: 0 15px 25px 15px;
        max-width: 100%;
    }
    
    .radius-expansion-alert .alert-icon {
        width: 35px;
        height: 35px;
    }
    
    .radius-expansion-alert .alert-icon i {
        font-size: 1rem;
    }
    
    .radius-expansion-alert .alert-content {
        font-size: 0.9rem;
    }
    
    /* Show accordion ONLY on mobile */
    .search-details-accordion {
        display: block !important;
        margin: 15px 15px 25px 15px;
        max-width: 100%;
    }
    
    .accordion-toggle {
        padding: 12px 16px;
        font-size: 0.9rem;
    }
    
    .accordion-toggle i.fa-search {
        font-size: 0.95rem;
    }
    
    .accordion-icon {
        font-size: 0.85rem;
    }
    
    /* Compact info for mobile */
    .search-info-compact {
        font-size: 0.9rem;
        padding: 0 15px;
    }
    
    .info-compact-item i {
        font-size: 0.95rem;
    }
}

.user-input-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
}

.user-input-icon {
    width: 36px;
    height: 36px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 3px;
}

.user-input-icon i {
    color: #e65100;
    font-size: 1rem;
}

.user-input-bubble {
    background: white;
    border-radius: 12px;
    padding: 12px 18px;
    position: relative;
    flex: 1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.user-input-bubble::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 10px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 8px 8px 8px 0;
    border-color: transparent white transparent transparent;
}

.user-input-label {
    color: #6c757d;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 4px;
}

.user-input-text {
    color: #333;
    font-size: 0.95rem;
    font-weight: 500;
    font-style: italic;
    line-height: 1.4;
}

/* Search Answers */
.search-answers {
    margin-bottom: 40px;
}

.search-answers-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.search-answers-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.search-answer-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 10px 18px;
    border-radius: 25px;
    font-size: 0.95rem;
    color: #333;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.search-answer-badge i {
    color: #e65100;
    font-size: 0.9rem;
}

/* Results Cards Wrapper */
.results-cards-wrapper {
    margin-top: 50px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

/* Results Sort Bar */
.results-sort-bar {
    grid-column: 1 / -1;
    background: white;
    border-radius: 16px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 10px;
    position: sticky;
    top: 80px;
    z-index: 100;
}

.sort-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}

.sort-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    color: #333;
    margin: 0;
    white-space: nowrap;
}

.sort-label i {
    color: #e65100;
    font-size: 1.1rem;
}

.sort-select {
    flex: 1;
    min-width: 0;
    padding: 10px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 500;
    color: #333;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23e65100' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px;
}

.sort-select:hover {
    border-color: #e65100;
}

.sort-select:focus {
    outline: none;
    border-color: #e65100;
    box-shadow: 0 0 0 3px rgba(230, 81, 0, 0.1);
}

.btn-show-map {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: linear-gradient(135deg, #e65100 0%, #f57c00 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-show-map i {
    font-size: 1.1rem;
}

.btn-show-map:hover {
    background: linear-gradient(135deg, #d84315 0%, #e65100 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(230, 81, 0, 0.3);
}

.btn-show-map:active {
    transform: translateY(0);
}

/* Mobile responsive sort bar */
@media (max-width: 768px) {
    .results-sort-bar {
        padding: 12px 15px;
        top: 70px;
        border-radius: 12px;
    }
    
    .sort-label {
        font-size: 0.85rem;
    }
    
    .sort-label i {
        font-size: 1rem;
    }
    
    .sort-select {
        font-size: 0.85rem;
        padding: 8px 12px;
        padding-right: 36px;
        background-position: right 10px center;
    }
    
    .btn-show-map {
        padding: 8px 14px;
        font-size: 0.85rem;
    }
    
    .btn-show-map span {
        display: none;
    }
    
    .btn-show-map i {
        margin: 0;
    }
}

@media (max-width: 480px) {
    .sort-label {
        font-size: 0;
    }
    
    .sort-label i {
        font-size: 1.1rem;
        margin: 0;
    }
    
    .sort-select {
        font-size: 0.8rem;
    }
}

/* Restaurant Card */
.restaurant-card {
    background: white;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    position: relative;
    transition: all 0.3s ease;
}

.restaurant-card:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    transform: translateY(-5px);
}

/* Card Links */
.card-image-link {
    display: block;
    text-decoration: none;
    cursor: pointer;
}

.card-title-link {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.card-title-link:hover {
    text-decoration: none;
    color: #e65100;
}

/* Restaurant Image Wrapper */
.restaurant-image-wrapper {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.restaurant-image-wrapper.has-image {
    padding: 12px 12px 0 12px;
    background: #f8f9fa;
}

.restaurant-image-bg {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 12px 12px 0 0;
}

.restaurant-logo-bg {
    background-size: 100% auto;
}

.restaurant-image-placeholder {
    width: 100%;
    height: 100%;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px 12px 0 0;
}

.no-image-icon {
    max-width: 40%;
    max-height: 40%;
    object-fit: contain;
    opacity: 0.3;
}

/* Match Badge */
.match-badge {
    position: absolute;
    top: 27px;
    right: 27px;
    background: linear-gradient(135deg, #e65100, #ff8a50);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    z-index: 2;
}

.match-badge i {
    font-size: 0.85rem;
}

/* Position Badge */
.position-badge {
    position: absolute;
    top: 27px;
    left: 27px;
    width: 45px;
    height: 45px;
    background: #000;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    z-index: 2;
}

/* Restaurant Header */
.restaurant-header {
    margin-top: 0;
    margin-bottom: 20px;
    padding: 25px 30px 0 30px;
}

.restaurant-name {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 8px;
}

/* Restaurant Rating */
.restaurant-rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    justify-content: center;
}

.rating-stars {
    display: flex;
    gap: 2px;
}

.rating-stars i {
    font-size: 0.95rem;
    color: #ffa726;
}

.rating-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: #333;
}

.rating-reviews {
    font-size: 0.9rem;
    color: #666;
}

.restaurant-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.95rem;
    color: #666;
    font-weight: 500;
}

.meta-item i {
    color: #e65100;
    font-size: 0.9rem;
}

/* Restaurant Description */
.restaurant-description {
    font-size: 1rem;
    line-height: 1.6;
    color: #555;
    margin-bottom: 25px;
    padding: 0 30px;
}

/* AI Motivazioni */
.restaurant-motivations {
    margin: 0 30px 25px 30px;
    padding: 20px;
    background: #fff5f0;
    border-radius: 16px;
    border: 2px solid rgba(230, 81, 0, 0.1);
}

.motivations-title {
    font-size: 1rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: left;
}

.motivations-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.motivation-item {
    display: flex;
    align-items: center;
    padding: 6px 0;
    gap: 10px;
}

.motivation-item i {
    color: #4CAF50;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.motivation-item span {
    font-size: 0.95rem;
    color: #333;
    font-weight: 500;
}

/* Restaurant Info */
.restaurant-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0 30px 25px 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 16px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    color: #333;
    text-align: left;
}

.info-item.address-item {
    align-items: flex-start;
}

.info-item span {
    text-align: left;
}

.info-item i {
    color: #e65100;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.info-item.address-item i {
    padding-top: 2px;
}

/* Restaurant Tags */
.restaurant-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 25px;
    padding: 0 30px;
}

.restaurant-tag {
    background: rgba(230, 81, 0, 0.1);
    color: #e65100;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid rgba(230, 81, 0, 0.2);
}

/* Restaurant Features */
.restaurant-features {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 25px;
    padding: 0 30px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #555;
    font-weight: 500;
}

.feature-item i {
    color: #4CAF50;
    font-size: 0.8rem;
}

/* Restaurant Dishes */
.restaurant-dishes {
    margin: 0 30px 25px 30px;
    padding: 20px;
    background: #fff5f0;
    border-radius: 16px;
    border: 2px solid rgba(230, 81, 0, 0.1);
}

.dishes-title {
    font-size: 1rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: left;
}

.dishes-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dish-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.dish-item:last-child {
    border-bottom: none;
}

.dish-name {
    font-size: 0.95rem;
    color: #333;
    font-weight: 500;
}

.dish-price {
    font-size: 1rem;
    color: #e65100;
    font-weight: 700;
}

/* Restaurant Actions */
.restaurant-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    padding: 0 30px 30px 30px;
}

.btn-view-menu {
    flex: 1;
    min-width: 150px;
    padding: 14px 24px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    background: #e65100;
    color: white;
    border: 2px solid #e65100;
    text-transform: uppercase;
}

.btn-view-menu:hover {
    background: #333;
    border-color: #333;
    color: white;
}

/* No Results */
.no-results {
    text-align: center;
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    padding: 40px 20px;
}

/* Skeleton Cards */
.skeleton-cards {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.skeleton-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    width: 100%;
}

/* Mobile: mostra solo la prima skeleton card */
.skeleton-card:nth-child(2),
.skeleton-card:nth-child(3) {
    display: none;
}

/* Desktop: 3 skeleton cards in linea */
@media (min-width: 992px) {
    .skeleton-card:nth-child(2),
    .skeleton-card:nth-child(3) {
        display: block;
    }
    
    .skeleton-card {
        flex: 0 0 calc(33.333% - 14px);
        max-width: calc(33.333% - 14px);
    }
}

.skeleton-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

.skeleton-content {
    padding: 20px;
}

.skeleton-line {
    height: 16px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
    margin-bottom: 12px;
}

.skeleton-line-title {
    height: 24px;
    width: 70%;
}

.skeleton-line-short {
    width: 40%;
}

.skeleton-line-medium {
    width: 60%;
}

.skeleton-badges {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.skeleton-badge {
    height: 28px;
    width: 80px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 14px;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Tablet - 2 columns */
@media (max-width: 991px) {
    .results-cards-wrapper {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}

/* Responsive Search Page */
@media (max-width: 768px) {
    .search-loading-icon {
        margin-bottom: 30px;
    }
    
    .search-loading-icon i {
        font-size: 3rem;
    }
    
    .search-title {
        font-size: 1.8rem;
        margin-bottom: 20px;
    }
    
    #loading-state .search-title {
        min-height: 60px;
    }
    
    #loading-state .search-subtitle {
        font-size: 1.1rem;
        min-height: 40px;
    }
    
    .search-info-wrapper {
        gap: 20px;
        margin-bottom: 25px;
    }
    
    .search-info-item {
        font-size: 1rem;
    }
    
    .search-info-item i {
        font-size: 1.1rem;
    }
    
    .user-input-box {
        margin-bottom: 25px;
        padding: 0 15px;
    }
    
    .user-input-wrapper {
        gap: 10px;
        max-width: 100%;
    }
    
    .user-input-icon {
        width: 32px;
        height: 32px;
    }
    
    .user-input-icon i {
        font-size: 0.9rem;
    }
    
    .user-input-bubble {
        padding: 10px 15px;
    }
    
    .user-input-label {
        font-size: 0.7rem;
    }
    
    .user-input-text {
        font-size: 0.9rem;
    }
    
    .search-answers {
        margin-bottom: 30px;
    }
    
    .search-answers-title {
        font-size: 0.85rem;
    }
    
    .search-answer-badge {
        font-size: 0.9rem;
        padding: 8px 15px;
    }
    
    .results-cards-wrapper {
        margin-top: 35px;
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .restaurant-image-wrapper {
        height: 200px;
    }
    
    .restaurant-image-wrapper.has-image {
        padding: 10px 10px 0 10px;
    }
    
    .no-image-icon {
        max-width: 35%;
        max-height: 35%;
    }
    
    .match-badge {
        top: 17px;
        right: 17px;
        font-size: 0.8rem;
        padding: 6px 12px;
    }
    
    .position-badge {
        top: 17px;
        left: 17px;
        width: 35px;
        height: 35px;
        font-size: 0.95rem;
    }
    
    .restaurant-header {
        padding: 20px 20px 0 20px;
    }
    
    .restaurant-name {
        font-size: 1.4rem;
    }
    
    .restaurant-rating {
        gap: 6px;
        margin-bottom: 10px;
    }
    
    .rating-stars i {
        font-size: 0.85rem;
    }
    
    .rating-value {
        font-size: 0.85rem;
    }
    
    .rating-reviews {
        font-size: 0.8rem;
    }
    
    .restaurant-meta {
        gap: 10px;
    }
    
    .meta-item {
        font-size: 0.85rem;
    }
    
    .restaurant-description {
        font-size: 0.95rem;
        padding: 0 20px;
    }
    
    .restaurant-motivations {
        margin: 0 20px 20px 20px;
        padding: 15px;
    }
    
    .motivations-title {
        font-size: 0.9rem;
    }
    
    .motivation-item span {
        font-size: 0.9rem;
    }
    
    .restaurant-info {
        margin: 0 20px 20px 20px;
        padding: 15px;
    }
    
    .info-item {
        font-size: 0.9rem;
    }
    
    .restaurant-tags {
        padding: 0 20px;
    }
    
    .restaurant-tag {
        font-size: 0.85rem;
        padding: 6px 12px;
    }
    
    .restaurant-features {
        padding: 0 20px;
    }
    
    .feature-item {
        font-size: 0.85rem;
    }
    
    .restaurant-dishes {
        margin: 0 20px 20px 20px;
        padding: 15px;
    }
    
    .dishes-title {
        font-size: 0.9rem;
    }
    
    .dish-name {
        font-size: 0.9rem;
    }
    
    .dish-price {
        font-size: 0.95rem;
    }
    
    .restaurant-actions {
        flex-direction: column;
        gap: 10px;
        padding: 0 20px 20px 20px;
    }
    
    .btn-view-menu {
        width: 100%;
        min-width: auto;
        padding: 12px 20px;
        font-size: 0.95rem;
    }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .search-form {
        min-height: 500px;
    }
    
    .form-step {
        min-height: 450px;
    }
    
    .step-indicators {
        gap: 10px;
        margin-top: 30px;
    }
    
    .step-dot {
        width: 10px;
        height: 10px;
    }
    
    .step-dot.active {
        width: 12px;
        height: 12px;
    }
    
    .step-title {
        font-size: 1.4rem;
        margin-bottom: 25px;
    }
    
    .btn-back {
        padding: 12px 24px;
        font-size: 0.95rem;
    }
    
    .search-buttons {
        flex-direction: column-reverse;
        gap: 12px;
    }
    
    .btn-back,
    .btn-continue,
    .btn-location {
        width: 100%;
        justify-content: center;
    }
    
    .btn-continue {
        font-size: 0.9rem;
        padding: 12px 20px;
    }
    
    .wizard-option .option-content {
        padding: 15px 20px;
        font-size: 1rem;
    }
    
    .wizard-option .option-content i {
        font-size: 1.3rem;
        min-width: 25px;
    }
    
    .wizard-summary-items {
        flex-direction: column;
    }
    
    .wizard-summary-item {
        width: 100%;
        justify-content: flex-start;
    }
}