.home-media-card,
.guides-home-card {
    padding: 24px;
    overflow: hidden;
    background: #fff;
    border-radius: 16px;
}

.home-media-header {
    position: relative;
    overflow: hidden;
    min-height: 168px;
    background: #d7dde8;
    margin: -24px -24px 0;
    border-radius: 16px 16px 0 0;
    isolation: isolate;
}

.home-media-header--wide {
    min-height: clamp(236px, 26vw, 300px);
}

.home-media-header--compact {
    min-height: 146px;
}

.home-media-header img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 42%;
    display: block;
    transform: scale(1.02);
}

.home-media-header::before,
.home-media-header::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.home-media-header::before {
    border-radius: inherit;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
    z-index: 1;
}

.home-media-header::after {
    background:
        linear-gradient(180deg, rgba(15, 23, 42, 0.5) 0%, rgba(15, 23, 42, 0.24) 30%, rgba(15, 23, 42, 0.06) 56%, rgba(255, 255, 255, 0) 67%, rgba(255, 255, 255, 0.72) 84%, rgba(255, 255, 255, 1) 100%),
        linear-gradient(96deg, rgba(14, 21, 33, 0.22) 0%, rgba(14, 21, 33, 0) 42%, rgba(153, 56, 56, 0.18) 100%);
    z-index: 1;
}

.home-media-header-content {
    position: relative;
    z-index: 2;
    min-height: inherit;
    padding: 20px 24px 48px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 18px;
    color: #fff;
}

.home-media-header--compact .home-media-header-content {
    padding-bottom: 22px;
}

.home-media-kicker {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.home-media-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.home-media-row--top {
    align-items: flex-start;
}

.home-media-main {
    min-width: 0;
    max-width: 720px;
}

.home-media-inline {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.home-media-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    flex-shrink: 0;
}

.home-media-icon svg {
    width: 20px;
    height: 20px;
    color: #fff;
    stroke: #fff;
}

.home-media-title {
    margin: 0;
    font-family: 'Nunito', sans-serif;
    color: #fff;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.32);
}

.home-media-title--xl {
    font-size: clamp(2rem, 3.15vw, 2.75rem);
    line-height: 1.03;
}

.home-media-title--sm {
    font-size: 1.15rem;
    font-weight: 900;
}

.home-media-copy {
    margin: 12px 0 0;
    max-width: 700px;
    color: rgba(255, 247, 244, 0.92);
    font-size: 0.98rem;
    line-height: 1.62;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.22);
}

.home-media-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #fff;
    text-decoration: none;
    font-size: 0.84rem;
    font-weight: 800;
    white-space: nowrap;
}

.home-media-cta:hover {
    background: rgba(255, 255, 255, 0.24);
}

.home-media-card .widget-content,
.guides-home-grid,
.home-randomizer-widget .randomizer-body {
    margin: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.home-media-card .widget-content {
    padding: 12px 0 0;
}

.guides-home-hero {
    position: relative;
    display: grid;
    gap: 16px;
    align-content: space-between;
    min-height: clamp(220px, 28vw, 300px);
    padding: 24px;
    background:
        linear-gradient(135deg, rgba(16, 24, 40, 0.78), rgba(126, 29, 29, 0.82)),
        radial-gradient(circle at top right, rgba(255, 255, 255, 0.14), transparent 32%),
        url("../images/guides/travellers-coast.jpg") center 38% / cover no-repeat;
    color: #fff7f4;
}

.guides-home-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.guides-home-header {
    display: flex;
    gap: 16px;
    justify-content: space-between;
    align-items: flex-start;
    margin-top: 16px;
}

.guides-home-header h3 {
    margin: 0;
    font-family: 'Nunito', sans-serif;
    font-size: clamp(1.65rem, 3vw, 2.25rem);
    font-weight: 900;
    line-height: 1.05;
}

.guides-home-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: #fff;
    text-decoration: none;
    font-size: 0.84rem;
    font-weight: 800;
    white-space: nowrap;
}

.guides-home-cta:hover {
    background: rgba(255, 255, 255, 0.24);
}

.guides-home-copy {
    margin: 14px 0 0;
    max-width: 760px;
    color: rgba(255, 247, 244, 0.92);
    font-size: 0.98rem;
    line-height: 1.68;
}

.guides-home-grid {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    padding: 18px 0 0;
}

.guides-home-link {
    display: grid;
    gap: 8px;
    min-height: 146px;
    padding: 18px;
    border-radius: 18px;
    border: 1px solid rgba(17, 24, 39, 0.08);
    background: linear-gradient(180deg, #ffffff 0%, #fffaf8 100%);
    text-decoration: none;
    box-shadow: 0 10px 22px rgba(17, 24, 39, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.guides-home-link:hover {
    transform: translateY(-2px);
    border-color: rgba(198, 72, 72, 0.28);
    box-shadow: 0 18px 32px rgba(17, 24, 39, 0.08);
}

.guides-home-link span {
    font-size: 0.73rem;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: #9a3412;
}

.guides-home-link strong {
    font-family: 'Nunito', sans-serif;
    font-size: 1.05rem;
    font-weight: 900;
    color: #111827;
}

.guides-home-link p {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #4b5563;
}

.home-randomizer-widget {
    padding: 24px;
    overflow: hidden;
}

.home-randomizer-widget .randomizer-card {
    height: 100%;
    border: none;
    border-radius: 24px;
    box-shadow: none;
    background: transparent;
}

.home-randomizer-widget .randomizer-body {
    padding: 18px 0 0;
}

.guides-home-card .home-media-header img {
    object-position: center 36%;
}

.home-randomizer-widget .home-media-header img {
    object-position: center 56%;
}

.beaches-widget .home-media-header img {
    object-position: center 40%;
}

.airport-taxi-card .home-media-header img {
    object-position: center 32%;
}

@media (max-width: 720px) {
    .home-media-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .home-media-cta {
        width: 100%;
    }

    .guides-home-grid {
        grid-template-columns: 1fr;
    }

    .home-media-header-content {
        padding-left: 20px;
        padding-right: 20px;
    }

    .home-media-header-content {
        padding-bottom: 42px;
    }

    .home-media-header--compact .home-media-header-content {
        padding-bottom: 22px;
    }

    .home-media-header--wide {
        min-height: 220px;
    }

    .home-media-title--xl {
        font-size: clamp(1.7rem, 8vw, 2.2rem);
    }

    .home-media-card,
    .guides-home-card,
    .home-randomizer-widget {
        padding: 20px;
    }

    .home-media-header {
        margin: -20px -20px 0;
    }
}
