/* AMÉLIORATIONS PAGE D'ACCUEIL - Design moderne et professionnel */

/* ===== ANIMATIONS GLOBALES ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

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

/* ===== HEADER AMÉLIORÉ ===== */
.header {
    box-shadow: 0 2px 20px rgba(0, 168, 132, 0.15);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.header__logo {
    transition: transform 0.3s ease;
}

.header__logo:hover {
    transform: scale(1.05);
}

.header__logo-icon {
    animation: pulse 2s infinite;
}

.header__nav-link {
    position: relative;
    overflow: hidden;
}

.header__nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: white;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.header__nav-link:hover::after {
    width: 80%;
}

/* ===== HERO SECTION AMÉLIORÉE ===== */
.hero {
    background: linear-gradient(135deg, #00A884 0%, #008C6F 50%, #00796B 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulse 8s infinite;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -5%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255, 183, 0, 0.15) 0%, transparent 70%);
    border-radius: 50%;
}

.hero__inner {
    position: relative;
    z-index: 1;
}

.hero__title {
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    line-height: 1.2;
}

/* ===== SEARCH BOX AMÉLIORÉE ===== */
.search-box {
    background: linear-gradient(135deg, #FFB700 0%, #FFA500 100%);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.search-box__field {
    transition: all 0.3s ease;
    position: relative;
}

.search-box__field:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.search-box__field input:focus,
.search-box__field select:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 168, 132, 0.3);
    border-radius: 4px;
}

.search-box__btn {
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 168, 132, 0.3);
}

.search-box__btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.search-box__btn:hover::before {
    width: 300px;
    height: 300px;
}

.search-box__btn:active {
    transform: scale(0.95);
}

/* ===== TABS AMÉLIORÉS ===== */
.tab {
    position: relative;
    transition: all 0.3s ease;
}

.tab:hover:not(.active) {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.tab.active {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transform: scale(1.05);
}

/* ===== STATS BAR AMÉLIORÉE ===== */
.stats-bar {
    background: linear-gradient(to bottom, #ffffff 0%, #f8f9fa 100%);
}

.stat-item {
    transition: transform 0.3s ease;
    cursor: default;
}

.stat-item:hover {
    transform: translateY(-5px);
}

.stat-item__value {
    background: linear-gradient(135deg, #00A884 0%, #1CC9A1 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-size: 28px;
    transition: all 0.3s ease;
}

.stat-item:hover .stat-item__value {
    transform: scale(1.1);
}

/* ===== SECTION HEADERS ===== */
.section__title {
    position: relative;
    display: inline-block;
    padding-bottom: 12px;
}

.section__title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #FFB700 0%, #FFA500 100%);
    border-radius: 2px;
}

/* ===== CITY CARDS AMÉLIORÉES ===== */
.cities-grid {
    gap: 20px;
}

.city-card {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.city-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius);
    background: linear-gradient(135deg, rgba(0, 168, 132, 0.3) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.city-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 35px rgba(0, 168, 132, 0.25);
}

.city-card:hover::before {
    opacity: 1;
}

.city-card__overlay {
    background: linear-gradient(transparent 30%, rgba(0, 0, 0, 0.8));
    transition: background 0.4s ease;
    position: relative;
    z-index: 2;
}

.city-card:hover .city-card__overlay {
    background: linear-gradient(transparent 20%, rgba(0, 168, 132, 0.9));
}

.city-card__name {
    transition: all 0.3s ease;
}

.city-card:hover .city-card__name {
    transform: translateY(-4px);
    font-size: 20px;
}

/* ===== PROPERTY TYPE CARDS ===== */
.type-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.type-card:hover {
    transform: translateY(-8px) scale(1.03);
    border-color: #00A884;
    box-shadow: 0 12px 30px rgba(0, 168, 132, 0.2);
    background: linear-gradient(135deg, #ffffff 0%, #f0fdf9 100%);
}

.type-card__icon {
    transition: all 0.3s ease;
}

.type-card:hover .type-card__icon {
    transform: scale(1.2) rotate(5deg);
}

/* ===== PROPERTY CARDS AMÉLIORÉES ===== */
.property-card {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.property-card:hover {
    box-shadow: 0 15px 45px rgba(0, 168, 132, 0.15);
    transform: translateY(-8px);
    border-color: #00A884;
}

.property-card__img {
    position: relative;
}

.property-card__img::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 60%, rgba(0, 0, 0, 0.3));
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 1;
}

.property-card:hover .property-card__img::before {
    opacity: 1;
}

.property-card__badge {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    position: relative;
    z-index: 2;
}

.property-card__fav {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 2;
}

.property-card__fav:hover {
    background: #FF6B6B !important;
    color: white;
    transform: scale(1.15) rotate(10deg);
}

.property-card__price {
    transition: color 0.3s ease;
}

.property-card:hover .property-card__price {
    color: #008C6F;
}

/* ===== FEATURED CARDS ===== */
.featured-card::before {
    animation: pulse 2s ease-in-out infinite;
}

/* ===== FEATURE CARDS ===== */
.feature-card {
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
}

.feature-card__icon {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.feature-card__icon::after {
    content: '';
    position: absolute;
    inset: -8px;
    background: linear-gradient(135deg, rgba(0, 168, 132, 0.2) 0%, rgba(28, 201, 161, 0.2) 100%);
    border-radius: 20px;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.feature-card:hover .feature-card__icon {
    transform: scale(1.15) rotate(5deg);
}

.feature-card:hover .feature-card__icon::after {
    opacity: 1;
}

/* ===== CTA SECTION ===== */
.cta {
    background: linear-gradient(135deg, #00A884 0%, #008C6F 50%, #00796B 100%);
    position: relative;
    overflow: hidden;
}

.cta::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -25%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 183, 0, 0.2) 0%, transparent 70%);
    animation: pulse 6s infinite;
}

.cta__title {
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
}

.cta__text {
    position: relative;
    z-index: 1;
}

.btn-accent {
    box-shadow: 0 8px 25px rgba(255, 183, 0, 0.4);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.btn-accent:hover {
    box-shadow: 0 12px 35px rgba(255, 183, 0, 0.6);
    transform: translateY(-3px) scale(1.05);
}

/* ===== FOOTER AMÉLIORÉ ===== */
.footer {
    background: linear-gradient(to bottom, #1a1a1a 0%, #0d0d0d 100%);
}

.footer__social a {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.footer__social a:hover {
    background: linear-gradient(135deg, #00A884 0%, #1CC9A1 100%);
    transform: translateY(-5px) rotate(5deg) scale(1.1);
}

.footer__links a {
    position: relative;
    transition: all 0.3s ease;
}

.footer__links a::before {
    content: '→';
    position: absolute;
    left: -20px;
    opacity: 0;
    transition: all 0.3s ease;
}

.footer__links a:hover {
    padding-left: 20px;
    color: var(--white);
}

.footer__links a:hover::before {
    opacity: 1;
    left: 0;
}

/* ===== BOUTONS GLOBAUX ===== */
.btn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::after {
    width: 300px;
    height: 300px;
}

.btn-primary {
    box-shadow: 0 4px 15px rgba(28, 201, 161, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 6px 25px rgba(28, 201, 161, 0.5);
    transform: translateY(-2px);
}

.btn-outline:hover {
    box-shadow: 0 4px 15px rgba(0, 168, 132, 0.2);
    transform: translateY(-2px);
}

.btn-ghost:hover {
    transform: translateY(-2px);
}

/* ===== AUTOCOMPLETE AMÉLIORÉ ===== */
.search-box__autocomplete {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.2);
}

.autocomplete-item {
    transition: all 0.2s ease;
}

.autocomplete-item:hover {
    background: linear-gradient(90deg, #f0fdf9 0%, var(--bg) 100%);
    padding-left: 20px;
    border-left: 3px solid #00A884;
}

/* ===== SEARCH EXTRAS ===== */
.search-extras__link {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-extras__link:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ===== RESPONSIVE AMÉLIORATIONS ===== */
@media (max-width: 1024px) {
    .hero__title {
        font-size: 40px;
    }

    .stat-item__value {
        font-size: 24px;
    }
}

@media (max-width: 768px) {
    .hero::before,
    .hero::after {
        display: none;
    }

    .hero__title {
        font-size: 28px;
    }

    .stat-item__value {
        font-size: 20px;
    }

    .search-box__btn {
        width: 100%;
    }

    .city-card:hover {
        transform: scale(1.02);
    }

    .property-card:hover {
        transform: translateY(-4px);
    }
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ===== LOADING SHIMMER ===== */
@keyframes loading-shimmer {
    0% {
        background-position: -468px 0;
    }
    100% {
        background-position: 468px 0;
    }
}

.property-card img:not([src]),
.city-card img:not([src]) {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 468px 100%;
    animation: loading-shimmer 1.2s ease-in-out infinite;
}
