/* ==========================================
   DEVITO – BOOKINGFUNKTION
========================================== */

:root {

    --booking-bg: #171717;
    --booking-border: rgba(255, 255, 255, 0.15);

    --booking-text: #ffffff;
    --booking-text-muted: #dddddd;

    --booking-input-bg: #ffffff;
    --booking-input-text: #202020;

    --booking-accent: var(--color-primary);
    --booking-accent-hover: var(--color-primary-hover);

    --booking-ledig: #60d69b;
    --booking-reserveret: #f0b44c;
    --booking-optaget: #ee7777;

    --booking-radius: 8px;
}


/* ==========================================
   BOOKING WIDGET
========================================== */

.booking-widget {
    width: 100%;
    padding: 25px 30px;

    background: var(--booking-bg);
    border: 1px solid var(--booking-border);
    border-radius: var(--booking-radius);

    color: var(--booking-text);

    box-sizing: border-box;
}

.booking-widget h2 {
    margin: 0 0 8px;

    color: #ffffff;
    font-family: var(--font-heading);
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    font-weight: 700;
    line-height: 1.2;
}

.booking-widget > p {
    margin: 0 0 15px;

    color: var(--booking-text-muted);
    font-size: 14px;
    line-height: 1.6;
}


/* ==========================================
   FORMULAR
========================================== */

.booking-check-form {
    display: flex;
    flex-direction: column;
    gap: 10px;

    margin-top: 0;
}

.booking-check-form label {
    display: block;

    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
}

.booking-check-form input[type="date"] {
    display: block;

    width: 100%;
    min-height: 48px;

    padding: 10px 14px;

    background: var(--booking-input-bg);
    color: var(--booking-input-text);

    border: 2px solid transparent;
    border-radius: 6px;

    font-family: inherit;
    font-size: 15px;

    cursor: pointer;
    box-sizing: border-box;

    color-scheme: light;

    transition: border-color 0.2s ease;
}

.booking-check-form input[type="date"]:focus {
    outline: none;
    border-color: var(--booking-accent);
}


/* ==========================================
   STATUSBESKED
========================================== */

.svar_om_ledig {
    display: block;

    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.5;
}

.svar_om_ledig:empty {
    display: none;
}

.booking-ledig .svar_om_ledig {
    color: var(--booking-ledig);
}

.booking-reserveret .svar_om_ledig {
    color: var(--booking-reserveret);
}

.booking-optaget .svar_om_ledig {
    color: var(--booking-optaget);
}


/* ==========================================
   RESERVATIONSKNAP
========================================== */

.vis_booking_knap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: flex-start;
    gap: 10px;

    padding: 12px 22px;

    background: var(--booking-accent);
    color: #ffffff;

    border: none;
    border-radius: 6px;

    font-family: var(--font-primary);
    font-size: 13px;
    font-weight: 700;

    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.4px;

    cursor: pointer;

    transition:
        background 0.2s ease,
        transform 0.2s ease;
}

.vis_booking_knap:hover {
    background: var(--booking-accent-hover);
    color: #ffffff;

    transform: translateY(-2px);
}

.vis_booking_knap:focus-visible {
    outline: 3px solid #ffffff;
    outline-offset: 3px;
}

.vis_booking_knap[hidden] {
    display: none !important;
}


/* ==========================================
   SUPPLERENDE BESKED
========================================== */

.booking-result {
    color: var(--booking-text-muted);
    font-size: 13px;
    line-height: 1.5;
}

.booking-result:empty {
    display: none;
}


/* ==========================================
   BOOKING PÅ FORSIDEN
========================================== */

.hero-booking .booking-check-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 10px 15px;
}

.hero-booking .booking-check-form label {
    grid-column: 1 / -1;
}

.hero-booking .booking-check-form input[type="date"] {
    grid-column: 1;
    grid-row: 2;
}

.hero-booking .booking-check-form .svar_om_ledig {
    grid-column: 1 / -1;
    grid-row: 3;
}

.hero-booking .booking-check-form .vis_booking_knap {
    grid-column: 2;
    grid-row: 2;

    min-height: 48px;
    margin: 0;

    white-space: nowrap;
}

.hero-booking .booking-check-form .booking-result {
    grid-column: 1 / -1;
    grid-row: 4;
}


/* ==========================================
   RESPONSIVT DESIGN
========================================== */

@media (max-width: 600px) {

    .booking-widget {
        padding: 22px 18px;
    }

    .booking-widget h2 {
        font-size: 1.8rem;
    }

    .booking-widget > p {
        font-size: 13px;
    }

    .booking-check-form {
        gap: 10px;
    }

    .booking-check-form input[type="date"] {
        font-size: 16px;
    }

    .hero-booking .booking-check-form {
        grid-template-columns: 1fr;
    }

    .hero-booking .booking-check-form label,
    .hero-booking .booking-check-form input[type="date"],
    .hero-booking .booking-check-form .svar_om_ledig,
    .hero-booking .booking-check-form .vis_booking_knap,
    .hero-booking .booking-check-form .booking-result {
        grid-column: 1;
        grid-row: auto;
    }

    .vis_booking_knap {
        width: 100%;
        box-sizing: border-box;
    }
}