/**
 * Homepage Styles
 */

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--esimfly-primary) 0%, var(--esimfly-primary-dark) 100%);
    color: var(--esimfly-white);
    padding: 8rem 0 4rem;
    text-align: center;
    margin: 0;
    width: 100%;
    position: relative;
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-attachment: scroll !important;
}

/* Extra padding on homepage for transparent header */
body.home .hero-section {
    padding-top: 10rem;
}

/* Hero overlay when background image is present - Light overlay for text readability */
.hero-section.has-bg-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.hero-section.has-bg-image .hero-container {
    position: relative;
    z-index: 2;
}

/* Add text shadow for better readability on images */
.hero-section.has-bg-image .hero-title,
.hero-section.has-bg-image .hero-subtitle {
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--esimfly-white);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Hero Search */
.hero-search {
    max-width: 600px;
    margin: 0 auto 2rem;
}

.search-form {
    display: flex;
    gap: 0;
    background: var(--esimfly-white);
    border-radius: var(--esimfly-radius-lg);
    overflow: hidden;
    box-shadow: var(--esimfly-shadow-xl);
}

.search-input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    font-size: 1rem;
    outline: none;
}

.search-button {
    padding: 1rem 2rem;
    background: var(--esimfly-primary-dark);
    color: var(--esimfly-white);
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: var(--esimfly-transition);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-button:hover {
    background: var(--esimfly-black);
}

/* Hero Features */
.hero-features {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

/* Popular Destinations - Elegant Clean Design */
.popular-destinations {
    padding: 6rem 0;
    background: #fafbfc;
    position: relative;
    width: 100vw;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
}

.popular-destinations .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-header-wrapper {
    text-align: center;
    margin-bottom: 4rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.section-badge {
    display: inline-block;
    padding: 8px 20px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(79, 70, 229, 0.1) 100%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 50px;
    color: var(--esimfly-primary);
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
}

.section-title {
    text-align: center;
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--esimfly-text);
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.section-subtitle {
    text-align: center;
    color: var(--esimfly-text-light);
    font-size: 1.125rem;
    margin-bottom: 0;
    font-weight: 400;
    line-height: 1.6;
}

.destinations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
    justify-items: center;
}

.destination-card {
    background: transparent;
    border-radius: 0;
    padding: 1rem;
    box-shadow: none;
    transition: all 0.3s ease;
    border: none;
    text-align: center;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
    max-width: 200px;
}

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

.destination-flag-wrapper {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    border: 4px solid var(--esimfly-white);
    background: var(--esimfly-white);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.destination-card:hover .destination-flag-wrapper {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 12px 32px rgba(99, 102, 241, 0.25);
    border-color: var(--esimfly-primary);
}

.destination-flag {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.destination-flag-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
}

.destination-info {
    width: 100%;
}

.destination-name {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--esimfly-text);
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.destination-price-from {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
}

.from-label {
    font-size: 0.75rem;
    color: var(--esimfly-text-light);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.price-value {
    font-size: 1.375rem;
    font-weight: 800;
    color: var(--esimfly-primary);
    letter-spacing: -0.02em;
}

/* How It Works */
.how-it-works {
    padding: 4rem 0;
    background: var(--esimfly-gray-50);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.step-card {
    text-align: center;
    padding: 2rem;
    background: var(--esimfly-white);
    border-radius: var(--esimfly-radius-lg);
    box-shadow: var(--esimfly-shadow);
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--esimfly-primary);
    color: var(--esimfly-white);
    border-radius: var(--esimfly-radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1rem;
}

.step-card h3 {
    margin-bottom: 0.75rem;
}

.step-card p {
    color: var(--esimfly-text-light);
}

/* CTA Section */
.cta-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, var(--esimfly-primary) 0%, var(--esimfly-primary-dark) 100%);
    color: var(--esimfly-white);
}

.cta-content {
    text-align: center;
}

.cta-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--esimfly-white);
}

.cta-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.btn-white {
    background: var(--esimfly-white);
    color: var(--esimfly-primary);
}

.btn-white:hover {
    background: var(--esimfly-gray-100);
    transform: translateY(-2px);
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

.text-center {
    text-align: center;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-features {
        flex-direction: column;
        gap: 1rem;
    }

    .search-button {
        padding: 1rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .destinations-grid {
        grid-template-columns: 1fr;
    }
}
