/**
 * flugbuchen.de — Home Page Styles
 * @copyright reDim GmbH | @link https://www.redim.de | @contact team@redim.de
 */

/* ========================================
   1. Hero
   ======================================== */
.hero {
    position: relative;
    overflow: hidden;
    background: var(--color-primary);
}

.hero__bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero__bg .image-placeholder {
    width: 100%;
    height: 100%;
    font-size: 0.875rem;
}

.hero__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
        to bottom,
        rgba(15, 23, 42, 0.55) 0%,
        rgba(15, 23, 42, 0.7) 100%
    );
}

.hero__content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 28rem;
    padding: 4rem 1rem;
}

@media (min-width: 768px) {
    .hero__content {
        min-height: 34rem;
        padding: 5rem 2rem;
    }
}

@media (min-width: 1024px) {
    .hero__content {
        min-height: 38rem;
    }
}

.hero__title {
    font-size: 1.75rem;
    color: #fff;
    max-width: 48rem;
    margin-bottom: 1rem;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

@media (min-width: 768px) {
    .hero__title {
        font-size: 2.75rem;
    }
}

@media (min-width: 1024px) {
    .hero__title {
        font-size: 3.25rem;
    }
}

.hero__subtitle {
    font-size: 1.0625rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 36rem;
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .hero__subtitle {
        font-size: 1.1875rem;
    }
}

/* ========================================
   1b. Hero Quick Search
   ======================================== */
.hero-search {
    width: 100%;
    max-width: 68rem;
    margin-top: 2rem;
}

.hero-search__fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
}

@media (min-width: 1024px) {
    .hero-search__fields {
        grid-template-columns: 1fr auto 1fr 8.5rem 8.5rem 6.5rem auto;
        gap: 0;
        padding: 0;
        border-radius: var(--radius-lg);
        overflow: hidden;
        align-items: stretch;
    }

    .hero-search__swap {
        align-self: center;
        margin: 0 0.25rem;
    }
}

/* Individual field wrapper */
.hero-search__field {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

@media (min-width: 1024px) {
    .hero-search__field {
        padding: 0.875rem 1.25rem;
        border-right: 1px solid rgba(255, 255, 255, 0.2);
        transition: background 0.15s ease;
    }

    .hero-search__field:hover {
        background: rgba(255, 255, 255, 0.08);
    }

    .hero-search__field:last-of-type {
        border-right: none;
    }
}

/* Labels */
.hero-search__label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: rgba(255, 255, 255, 0.88);
    user-select: none;
    pointer-events: none;
}

/* Text & date inputs */
.hero-search__input {
    width: 100%;
    min-height: 2.75rem;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-sm);
    padding: 0.5rem 0.75rem;
    font-family: var(--font-body);
    font-size: 0.9375rem;
    color: #fff;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.hero-search__input::placeholder {
    color: rgba(255, 255, 255, 0.55);
}

.hero-search__input:focus {
    background: rgba(255, 255, 255, 0.24);
    border-color: rgba(255, 255, 255, 0.55);
}

/* Date input: remove browser chrome on some platforms */
.hero-search__input--date::-webkit-calendar-picker-indicator {
    filter: invert(1) opacity(0.75);
    cursor: pointer;
}

@media (min-width: 1024px) {
    .hero-search__input {
        min-height: 2.75rem;
        background: rgba(255, 255, 255, 0.06);
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: var(--radius-sm);
        padding: 0.375rem 0.625rem;
        font-size: 1rem;
        color: #fff;
        outline: 0;
    }

    .hero-search__input:focus {
        background: rgba(255, 255, 255, 0.12);
        border-color: rgba(255, 255, 255, 0.35);
    }

    .hero-search__input::placeholder {
        color: rgba(255, 255, 255, 0.55);
    }
}

/* Submit button */
.hero-search__btn {
    grid-column: 1 / -1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 2.75rem;
    font-size: 1rem;
    font-weight: 600;
    white-space: nowrap;
    border-radius: var(--radius-sm);
    padding: 0.75rem 1.5rem;
}

@media (min-width: 1024px) {
    .hero-search__btn {
        grid-column: auto;
        width: auto;
        min-height: auto;
        align-self: stretch;
        border-radius: 0 calc(var(--radius-lg) - 1px) calc(var(--radius-lg) - 1px) 0;
        padding: 0 2rem;
        font-size: 0.9375rem;
    }
}

/* Accessibility: keyboard focus rings on inputs */
.hero-search__input:focus-visible {
    outline: 2px solid var(--color-secondary);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

@media (min-width: 1024px) {
    .hero-search__input:focus-visible {
        outline-offset: -2px;
    }
}

/* Submit button icon */
.hero-search__btn-icon {
    vertical-align: -0.15em;
    margin-right: 0.375rem;
    flex-shrink: 0;
}

/* Select input (passengers) */
.hero-search__input--select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='rgba(255,255,255,0.8)' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2rem;
    cursor: pointer;
}

.hero-search__input--select option {
    background: var(--color-primary);
    color: #fff;
}

/* Swap button between Von and Nach */
.hero-search__swap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.32);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.9);
    cursor: pointer;
    flex-shrink: 0;
    align-self: center;
    justify-self: center;
    transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.hero-search__swap:hover {
    background: rgba(255, 255, 255, 0.32);
    color: #fff;
    transform: scale(1.08);
}

.hero-search__swap:focus-visible {
    outline: 2px solid var(--color-secondary);
    outline-offset: 2px;
}

/* Mobile + Tablet layout (below desktop breakpoint) */
@media (max-width: 1023px) {
    .hero-search__fields {
        grid-template-columns: 1fr auto 1fr;
    }

    .hero-search__field--nach {
        grid-column: 3;
    }

    .hero-search__field--hinflug {
        grid-column: 1;
    }

    .hero-search__field--rueckflug {
        grid-column: 2 / -1;
    }

    .hero-search__field--pax {
        grid-column: 1 / -1;
    }

    .hero-search__swap {
        width: 2.25rem;
        height: 2.25rem;
        margin-top: 1.25rem;
    }
}

/* Smaller hero on very small screens */
@media (max-width: 480px) {
    .hero__content {
        min-height: auto;
        padding: 2.5rem 1rem;
    }

    .hero__title {
        font-size: 1.5rem;
    }

    .hero__subtitle {
        font-size: 0.9375rem;
        margin-bottom: 1.25rem;
    }
}

/* ========================================
   1c. Hero Destination Chips
   ======================================== */
.hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    margin-top: 1.25rem;
    max-width: 68rem;
}

.hero-chip {
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 2rem;
    padding: 0.375rem 1rem;
    color: rgba(255, 255, 255, 0.9);
    font-family: var(--font-body);
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
    white-space: nowrap;
    min-height: 44px;
}

.hero-chip:hover {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.4);
}

.hero-chip.is-active {
    background: var(--color-secondary);
    border-color: var(--color-secondary);
    color: #fff;
}

.hero-chip:focus-visible {
    outline: 2px solid var(--color-secondary);
    outline-offset: 2px;
}

@media (max-width: 480px) {
    .hero-chips {
        gap: 0.375rem;
        margin-top: 1rem;
    }

    .hero-chip {
        font-size: 0.75rem;
        padding: 0.25rem 0.75rem;
    }
}

/* ========================================
   2. Entry Points (Drei Einstiege)
   ======================================== */
.entry-points {
    padding: var(--section-spacing) 0;
}

.entry-points__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .entry-points__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.entry-card {
    display: flex;
    flex-direction: column;
    padding: 2rem 1.5rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    text-align: center;
    transition: box-shadow 0.25s ease;
    box-shadow: var(--shadow-sm);
}

.entry-card:hover {
    box-shadow: var(--shadow-lift);
}

.entry-card__image {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: var(--radius-md);
    margin-bottom: 1.25rem;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.8125rem;
    padding: 1rem;
    text-align: center;
    line-height: 1.4;
    overflow: hidden;
}

.entry-card__title {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.entry-card__description {
    color: var(--color-text-secondary);
    font-size: 0.9375rem;
    margin-bottom: 1.5rem;
    flex: 1;
}

.entry-card .btn {
    align-self: center;
}

/* ========================================
   3. Beliebte Reiseziele
   ======================================== */
.destinations {
    padding: var(--section-spacing) 0;
    background: var(--color-bg-alt);
}

.destinations__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .destinations__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .destinations__grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.dest-card {
    background: var(--color-bg);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.25s ease;
    display: flex;
    flex-direction: column;
}

.dest-card:hover {
    box-shadow: var(--shadow-lift);
}

.dest-card a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.dest-card__image {
    height: 12rem;
    position: relative;
}

.dest-card__image .image-placeholder {
    width: 100%;
    height: 100%;
}

.dest-card__badges {
    position: absolute;
    bottom: 0.5rem;
    left: 0.5rem;
    display: flex;
    gap: 0.375rem;
    flex-wrap: wrap;
}

.dest-card__badges .badge {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.dest-card__body {
    padding: 1rem 1.25rem 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.dest-card__name {
    font-size: 1.0625rem;
    font-weight: 700;
    margin-bottom: 0.125rem;
    color: var(--color-primary);
}

.dest-card__country {
    font-size: 0.8125rem;
    color: var(--color-text-secondary);
    margin-bottom: 0.375rem;
}

.dest-card__desc {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    margin-bottom: 0.75rem;
    flex: 1;
}

.dest-card__price {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--color-price);
}

.destinations__footer {
    text-align: center;
    margin-top: 2.5rem;
}

/* ========================================
   4. Schnellziele-Teaser
   ======================================== */
.quick-goals {
    padding: var(--section-spacing) 0;
}

.quick-goals__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (min-width: 640px) {
    .quick-goals__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1024px) {
    .quick-goals__grid {
        grid-template-columns: repeat(6, 1fr);
    }
}

.quick-tile {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    aspect-ratio: 1 / 1;
    cursor: pointer;
    transition: box-shadow 0.25s ease;
    box-shadow: var(--shadow-sm);
    display: block;
    text-decoration: none;
}

.quick-tile:hover {
    box-shadow: var(--shadow-lift);
}

.quick-tile:focus-visible {
    outline: 2px solid var(--color-secondary);
    outline-offset: 2px;
}

.quick-tile .image-placeholder {
    width: 100%;
    height: 100%;
    font-size: 0.6875rem;
    padding: 0.75rem;
}

.quick-tile__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.7) 0%, rgba(15, 23, 42, 0.1) 60%);
    z-index: 1;
}

.quick-tile__label {
    position: absolute;
    bottom: 0.75rem;
    left: 0.75rem;
    right: 0.75rem;
    z-index: 2;
    color: #fff;
    font-weight: 700;
    font-size: 0.9375rem;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.quick-goals__footer {
    text-align: center;
    margin-top: 2.5rem;
}

/* ========================================
   5. So funktioniert's
   ======================================== */
.how-it-works {
    padding: var(--section-spacing) 0;
    background: var(--color-bg-alt);
}

.how-it-works__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
}

@media (min-width: 768px) {
    .how-it-works__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
}

.step {
    text-align: center;
    position: relative;
}

.step__number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    margin: 0 auto 1.25rem;
    background: var(--color-primary);
    color: #fff;
    font-size: 1.25rem;
    font-weight: 800;
    border-radius: 50%;
}

.step__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    margin: 0 auto 1rem;
    color: var(--color-secondary);
}

.step__icon svg {
    width: 2.25rem;
    height: 2.25rem;
}

.step__title {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}

.step__description {
    color: var(--color-text-secondary);
    font-size: 0.9375rem;
    max-width: 20rem;
    margin: 0 auto;
}

/* Connector line between steps (desktop) */
@media (min-width: 768px) {
    .step:not(:last-child)::after {
        content: "";
        position: absolute;
        top: 1.75rem;
        right: -1rem;
        width: calc(100% - 5rem);
        height: 2px;
        background: var(--color-border);
        transform: translateX(100%);
    }
}

/* ========================================
   6. Blog-Teaser
   ======================================== */
.blog-teaser {
    padding: var(--section-spacing) 0;
}

.blog-teaser__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .blog-teaser__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.blog-card {
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.25s ease;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    box-shadow: var(--shadow-lift);
}

.blog-card a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.blog-card__image {
    height: 11rem;
}

.blog-card__image .image-placeholder {
    width: 100%;
    height: 100%;
}

.blog-card__body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.blog-card__meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.blog-card__time {
    font-size: 0.75rem;
    color: var(--color-text-secondary);
}

.blog-card__title {
    font-size: 1.0625rem;
    margin-bottom: 0.5rem;
    color: var(--color-primary);
    line-height: 1.35;
}

.blog-card__excerpt {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    line-height: 1.55;
    flex: 1;
}

.blog-teaser__footer {
    text-align: center;
    margin-top: 2.5rem;
}

/* ========================================
   7. Trust / Social Proof
   ======================================== */
.trust {
    padding: var(--section-spacing) 0;
    background: var(--color-primary);
    color: #fff;
}

.trust__headline {
    text-align: center;
    font-size: 1.5rem;
    color: #fff;
    margin-bottom: 2.5rem;
}

@media (min-width: 768px) {
    .trust__headline {
        font-size: 2rem;
    }
}

.trust__counter {
    color: var(--color-secondary);
}

.trust__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .trust__grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.trust-item {
    text-align: center;
    padding: 1.5rem 1rem;
    min-width: 0;
}

.trust-item__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    margin: 0 auto 1rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--color-secondary);
}

.trust-item__icon svg {
    width: 1.5rem;
    height: 1.5rem;
}

.trust-item__title {
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: #fff;
}

.trust-item__text {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
}

/* ========================================
   Utility: Section text alignment
   ======================================== */
.text-center {
    text-align: center;
}

.section-subtitle--centered {
    text-align: center;
    max-width: 42rem;
    margin-left: auto;
    margin-right: auto;
}

/* ========================================
   Hero: Airport Autocomplete Dark Variant
   ======================================== */
.hero .ac-dropdown {
    background: rgba(15, 23, 42, 0.95);
    border-color: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.hero .ac-item:hover,
.hero .ac-item.is-active {
    background: rgba(13, 148, 136, 0.18);
}

.hero .ac-item__iata {
    color: var(--color-secondary);
    background: rgba(13, 148, 136, 0.15);
}

.hero .ac-item__label {
    color: rgba(255, 255, 255, 0.9);
}

.hero .ac-item__country {
    color: rgba(255, 255, 255, 0.5);
}

.hero .ac-item--empty {
    color: rgba(255, 255, 255, 0.5);
}

.hero .ac-dropdown::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
}

/* ========================================
   Accessibility: Reduced Motion
   ======================================== */
@media (prefers-reduced-motion: reduce) {
    .entry-card,
    .dest-card,
    .quick-tile,
    .blog-card,
    .hero-chip,
    .hero-search__swap {
        transition: none !important;
    }
}
