/* Hire dates (btg-hire.php, btg-hire.js): the day strip, the booking
   panel's dates and cost, ticking kit on the rentals pages, and the
   basket's rental controls. Colours are the site's night tokens. */

.btg-hire-on .date-time-picker,
.btg-hire-on #pickup-modal-body,
.btg-hire-on #dropoff-modal-body {
    display: none !important;
}

.btg-hire-pick {
    margin-bottom: 1rem;
}

.btg-rental-product form.rnb-cart .btg-hire-pick__title,
.btg-hire-options .btg-hire-pick__title {
    margin: 0 0 0.5rem;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.btg-hire-loading {
    margin: 0;
    padding: 1.4rem 0;
    color: var(--btg-muted);
    font-size: 0.9rem;
}

/* Collect ── n days ── return (the strip's head, the bar, the basket) */

.btg-hire-span,
.btg-strip__head {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: stretch;
    gap: 0.5rem;
}

.btg-hire-span__end,
.btg-strip__end {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--btg-line);
    border-radius: var(--btg-radius);
    background: var(--btg-raised);
    color: var(--btg-ink);
    text-align: left;
}

.btg-hire-span__end--return,
.btg-strip__end--return {
    text-align: right;
}

.btg-hire-span__label {
    font-size: 0.66rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.btg-hire-span__end strong,
.btg-strip__end strong {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.25;
    color: var(--btg-strong);
    white-space: nowrap;
}

.btg-hire-span__at {
    font-size: 0.78rem;
    color: var(--btg-muted);
}

.btg-hire-span__mid,
.btg-strip__mid {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    min-width: 6.5rem;
}

/* The hire's line between the two days */
.btg-hire-span__mid::before,
.btg-strip__mid::before {
    content: "";
    position: absolute;
    left: -0.5rem;
    right: -0.5rem;
    top: 50%;
    height: 2px;
    background: var(--btg-strong);
    opacity: 0.5;
}

.btg-hire-span__days,
.btg-strip__days {
    position: relative;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    background: var(--btg-strong);
    color: var(--btg-on-strong);
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
}

/* The strip */

.btg-strip {
    --btg-strip-cell: 2.75rem;
}

.btg-strip button {
    font-family: inherit;
    text-transform: none;
    letter-spacing: 0;
}

body.btg-hire-docked {
    padding-bottom: 5rem;
}

button.btg-strip__end {
    cursor: pointer;
    transition: border-color 0.15s ease;
}

button.btg-strip__end:hover,
button.btg-strip__end:focus,
button.btg-strip__end.is-active {
    border-color: var(--btg-strong);
    background: var(--btg-raised);
    color: var(--btg-ink);
}

button.btg-strip__end:focus-visible {
    outline: 2px solid var(--btg-strong);
    outline-offset: 2px;
}

.btg-strip__step,
.btg-hire-step button {
    position: relative;
    display: inline-grid;
    place-items: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 1px solid var(--btg-strong);
    border-radius: 50%;
    background: var(--btg-ground);
    color: var(--btg-strong);
    font-size: 1.05rem;
    font-weight: 500;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.btg-strip__step:hover,
.btg-strip__step:focus,
.btg-hire-step button:hover,
.btg-hire-step button:focus {
    background: var(--btg-strong);
    color: var(--btg-on-strong);
}

.btg-strip__step:disabled,
.btg-hire-step button:disabled {
    opacity: 0.4;
    cursor: wait;
}

.btg-strip__nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0.85rem 0 0.25rem;
}

.btg-strip__nav button {
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--btg-ink);
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
}

.btg-strip__nav button:hover,
.btg-strip__nav button:focus {
    background: var(--btg-raised);
    color: var(--btg-strong);
}

.btg-strip__month {
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.btg-strip__track {
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
    padding: 1.1rem 0 0.4rem;
}

.btg-strip__days-list {
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
}

.btg-strip__days-list li {
    position: relative;
    flex: 0 0 var(--btg-strip-cell);
    margin: 0;
}

/* The month's name over its first day */
.btg-strip__days-list li.is-month::before {
    content: attr(data-month);
    position: absolute;
    left: 0.35rem;
    top: -1.05rem;
    font-size: 0.66rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.btg-strip__days-list li.is-month {
    border-left: 1px solid var(--btg-line);
}

.btg-strip [data-day] {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.15rem;
    width: 100%;
    height: 3.4rem;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--btg-ink);
    cursor: pointer;
    touch-action: pan-x;
    user-select: none;
    -webkit-user-select: none;
}

.btg-strip__wd {
    font-size: 0.62rem;
    letter-spacing: 0.08em;
    color: var(--btg-muted);
}

.btg-strip__d {
    font-size: 0.95rem;
    font-weight: 500;
}

.btg-strip [data-day]:hover .btg-strip__d {
    text-decoration: underline;
}

.btg-strip [data-day]:focus-visible {
    outline: 2px solid var(--btg-strong);
    outline-offset: -2px;
    border-radius: var(--btg-radius);
}

/* Weekends: inside a hire, never its end */
.btg-strip [data-day].is-off {
    background: repeating-linear-gradient(135deg, transparent 0 5px, rgba(232, 228, 220, 0.06) 5px 7px);
}

.btg-strip [data-day].is-off .btg-strip__d {
    color: var(--btg-muted);
}

/* Before the lead time, or booked */
.btg-strip [data-day].is-closed {
    cursor: not-allowed;
}

.btg-strip [data-day].is-closed .btg-strip__d,
.btg-strip [data-day].is-closed .btg-strip__wd {
    opacity: 0.35;
}

.btg-strip [data-day].is-booked .btg-strip__d {
    text-decoration: line-through;
}

/* The hire across the strip */
.btg-strip [data-day].is-in {
    background: rgba(246, 243, 237, 0.14);
}

.btg-strip [data-day].is-in.is-off {
    background: repeating-linear-gradient(135deg, rgba(246, 243, 237, 0.14) 0 5px, rgba(246, 243, 237, 0.22) 5px 7px);
}

.btg-strip [data-day].is-from,
.btg-strip [data-day].is-to {
    background: var(--btg-strong);
    color: var(--btg-on-strong);
    cursor: grab;
    touch-action: none;
}

.btg-strip [data-day].is-from {
    border-radius: var(--btg-radius) 0 0 var(--btg-radius);
}

.btg-strip [data-day].is-to {
    border-radius: 0 var(--btg-radius) var(--btg-radius) 0;
}

.btg-strip [data-day].is-from .btg-strip__wd,
.btg-strip [data-day].is-to .btg-strip__wd {
    color: rgba(22, 21, 20, 0.6);
}

.btg-strip [data-day].is-from .btg-strip__d,
.btg-strip [data-day].is-to .btg-strip__d {
    font-weight: 700;
    opacity: 1;
}

/* The return is the morning: half a cell */
.btg-strip [data-day].is-to {
    background: linear-gradient(90deg, var(--btg-strong) 0 55%, rgba(246, 243, 237, 0.55) 55% 100%);
}

.btg-strip.is-clash [data-day].is-in.is-booked {
    background: rgba(214, 92, 72, 0.4);
}

.btg-strip__hint {
    min-height: 1.3em;
    margin: 0.35rem 0 0;
    font-size: 0.85rem;
    color: var(--btg-muted);
}

.btg-strip__hint.is-bad {
    color: #f0a191;
}

/* RnB's cost lines, readable on the dark panel */

.btg-rental-product form.rnb-cart .booking-pricing-info ul {
    margin: 0;
    padding: 0;
}

.btg-rental-product form.rnb-cart .booking-pricing-info ul li {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.45rem 0;
    border-bottom: 1px solid var(--btg-line) !important;
    color: var(--btg-ink) !important;
    font-size: 0.92rem;
}

.btg-rental-product form.rnb-cart .booking-pricing-info ul li:last-child {
    border-bottom: 0 !important;
    font-weight: 600;
    color: var(--btg-strong) !important;
}

.btg-rental-product form.rnb-cart .booking-pricing-info ul li .price {
    float: none;
    border: 0;
    text-decoration: none;
    white-space: nowrap;
}

.btg-rental-product form.rnb-cart .booking-pricing-info ul li .name {
    color: inherit;
}

/* Several inventories (btg-hire.js several()): the cards' control in place
   of RnB's inventory choice, quantity, cost and buttons */
.btg-hire-options-on .btg-hire-inventory,
.btg-hire-options-on .redq-quantity,
.btg-hire-options-on .booking-pricing-info,
.btg-hire-options-on .redq_add_to_cart_button,
.btg-hire-options-on .redq_request_for_a_quote,
.btg-hire-options-on .rnb-error-message {
    display: none !important;
}

.btg-hire-options {
    margin: 1.25rem 0 0.5rem;
}

/* Hire with it: another rental's control under the booking form */
.btg-hire-with {
    margin-top: 1.75rem;
}

.btg-hire-options .btg-hire-pick__title a {
    color: inherit;
}

/* A rental Mainframe has out of service (btg-mainframe.php) */
.btg-hire-unavailable {
    margin: 1rem 0;
    color: var(--btg-muted);
}

.btg-hire-options.is-checking .btg-hire-tick {
    opacity: 0.5;
    pointer-events: none;
}

.btg-rental-product form.rnb-cart .btg-hire-options .btg-hire-pick__title {
    margin: 0 0 0.5rem;
}

/* "In your hire", first in the booking panel, with the way to the basket */
.btg-hire-in {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
    margin: 0 0 1.25rem;
    padding: 0.9rem 1rem;
    border: 1px solid var(--btg-strong);
    border-radius: var(--btg-radius);
    background: var(--btg-raised);
}

.btg-hire-in[hidden] {
    display: none;
}

.btg-hire-in > div {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.btg-hire-in__label {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.btg-hire-in strong {
    color: var(--btg-strong);
}

.btg-hire-in .btg-hire-button {
    flex: none;
}

.btg-hire-single {
    display: none !important;
}

/* Steppers: quantity on the product page and in the basket, days in the basket */

.btg-hire-step {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btg-hire-step output {
    min-width: 1.6rem;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
}

.btg-rental-product form.rnb-cart .btg-hire-step--form input.inventory-qty {
    width: 3.5rem !important;
    padding: 0.5rem !important;
    text-align: center;
    -moz-appearance: textfield;
}

.btg-hire-step--form input::-webkit-outer-spin-button,
.btg-hire-step--form input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Buttons */

.btg-hire-button,
a.btg-hire-button {
    display: inline-block;
    padding: 0.8rem 1.2rem;
    border: 1px solid var(--btg-strong);
    border-radius: var(--btg-radius);
    background: var(--btg-strong);
    color: var(--btg-on-strong);
    font-family: inherit;
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    line-height: 1.2;
    text-decoration: none;
    text-transform: uppercase;
    cursor: pointer;
}

.btg-hire-button:hover,
.btg-hire-button:focus,
a.btg-hire-button:hover {
    background: var(--accent-alt);
    color: var(--btg-on-strong);
}

.btg-hire-button--quiet,
.btg-hire-button--quiet:hover {
    background: transparent;
    color: var(--btg-strong);
}

/* Rentals pages: the dates bar */

.btg-hire-bar {
    margin: 0 0 1.75rem;
    padding: 1.25rem;
    border: 1px solid var(--btg-line);
    border-radius: 8px;
}

.btg-hire-bar__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.btg-hire-bar__title {
    margin: 0 0 0.25rem;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.btg-hire-bar__lede {
    max-width: 38rem;
    margin: 0 0 1rem;
    font-size: 0.92rem;
}

.btg-hire-bar.has-dates .btg-hire-bar__lede {
    display: none;
}

.btg-hire-bar__toggle {
    flex: none;
    padding: 0.45rem 0.9rem;
    border: 1px solid var(--btg-line);
    border-radius: 999px;
    background: transparent;
    color: var(--btg-ink);
    font-family: inherit;
    font-size: 0.8rem;
    cursor: pointer;
}

.btg-hire-bar__toggle:hover,
.btg-hire-bar__toggle:focus {
    border-color: var(--btg-strong);
    background: transparent;
    color: var(--btg-strong);
}

/* The strip's head says the same while it is open */
.btg-hire-bar:has(.btg-hire-bar__strip:not([hidden])) .btg-hire-bar__summary {
    display: none;
}

.btg-hire-bar__summary:not(:empty) {
    margin: 0.75rem 0 0;
}

.btg-hire-bar__strip:not([hidden]) {
    margin-top: 1rem;
}

/* Rentals pages: each card's hire control, one row per option (the
   V-Lock's 50Wh and 99Wh): the tick, how many, the price for the dates */

.btg-rentals__card[data-product] {
    display: flex;
    flex-direction: column;
}

.btg-rentals__card[data-product] > a {
    flex: 1;
}

.btg-rentals__card.is-booked > a {
    opacity: 0.55;
}

.btg-rentals__card.is-checking .btg-hire-tick {
    opacity: 0.5;
    pointer-events: none;
}

/* With dates, the control is the card's action */
.has-hire-dates .btg-rentals__card[data-product] .btg-rentals__cta {
    display: none;
}

.btg-hire-tick {
    display: grid;
    gap: 0.4rem;
}

.btg-pick {
    display: flex;
    align-items: stretch;
    min-height: 2.75rem;
    border: 1px solid var(--btg-strong);
    border-radius: var(--btg-radius);
    color: var(--btg-strong);
    transition: background-color 0.15s ease, color 0.15s ease;
}

.btg-pick__tick {
    display: flex;
    flex: 1;
    align-items: center;
    gap: 0.6rem;
    min-width: 0;
    padding: 0.55rem 0.8rem;
    border: 0;
    border-radius: inherit;
    background: transparent;
    color: inherit;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-align: left;
    text-transform: uppercase;
    cursor: pointer;
}

.btg-pick__tick:hover,
.btg-pick__tick:focus {
    background: transparent;
    color: inherit;
}

.btg-pick:hover {
    background: var(--btg-raised);
}

.btg-pick__word {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.btg-hire-tick__box {
    position: relative;
    flex: none;
    width: 1.1rem;
    height: 1.1rem;
    border: 1.5px solid currentColor;
    border-radius: 3px;
}

.btg-pick.is-in .btg-hire-tick__box::after {
    content: "";
    position: absolute;
    left: 0.3rem;
    top: 0.05rem;
    width: 0.3rem;
    height: 0.6rem;
    border: solid currentColor;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.btg-pick__qty {
    display: flex;
    flex: none;
    align-items: center;
    border-left: 1px solid currentColor;
    border-left-color: color-mix(in srgb, currentColor 30%, transparent);
}

.btg-pick__qty button {
    width: 1.9rem;
    height: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font-family: inherit;
    font-size: 1rem;
    line-height: 1;
    cursor: pointer;
}

.btg-pick__qty button:hover,
.btg-pick__qty button:focus {
    background: transparent;
    color: inherit;
    text-decoration: underline;
}

.btg-pick__qty button:disabled {
    opacity: 0.3;
    cursor: default;
    text-decoration: none;
}

.btg-pick__qty output {
    min-width: 1.1rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-align: center;
}

.btg-pick__price {
    display: flex;
    flex: none;
    align-items: center;
    padding: 0 0.8rem 0 0.4rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.btg-pick.is-in,
.btg-pick.is-in:hover {
    background: var(--btg-strong);
    color: var(--btg-on-strong);
}

.btg-hire-tick__note {
    margin: 0;
    font-size: 0.85rem;
    color: var(--btg-muted);
}

.btg-hire-tick__note.is-bad {
    color: #f0a191;
}

/* New dates that don't suit everything in the hire: what and why */
.btg-hire-conflict {
    margin-top: 1rem;
    padding: 1rem 1.1rem;
    border: 1px solid #f0a191;
    border-radius: var(--btg-radius);
    background: rgba(240, 161, 145, 0.08);
}

.btg-hire-conflict[hidden] {
    display: none;
}

.btg-hire-conflict__title {
    margin: 0 0 0.5rem;
    font-weight: 600;
    color: #f0a191;
}

.btg-hire-conflict ul {
    margin: 0 0 1rem 1.1rem;
}

.btg-hire-conflict li {
    margin-bottom: 0.25rem;
}

.btg-hire-conflict__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* The hire so far, docked at the bottom of the rentals pages */

.btg-hire-dock {
    position: fixed;
    left: 50%;
    bottom: 1rem;
    z-index: 90;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    width: max-content;
    max-width: calc(100% - 2rem);
    padding: 0.6rem 0.6rem 0.6rem 1.1rem;
    border: 1px solid var(--btg-line);
    border-radius: 10px;
    background: var(--btg-deep);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
    transform: translateX(-50%);
}

.btg-hire-dock[hidden] {
    display: none;
}

.btg-hire-dock p {
    display: flex;
    flex-direction: column;
    margin: 0;
    font-size: 0.85rem;
    line-height: 1.3;
}

.btg-hire-dock p span {
    color: var(--btg-muted);
}

/* Basket (btg-hire/cart.php's table.btg-basket): a row per line on a grid.
   The photo on the grey tile; the name with its unit price under it; the
   hire's dates and days; quantity; subtotal; remove last. */

.btg-basket,
.btg-basket tbody {
    display: block;
    width: 100%;
    border: 0 !important;
    background: transparent !important;
}

.btg-basket thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.btg-basket tr.cart_item {
    display: grid !important;
    grid-template-columns: 6.5rem minmax(0, 1fr) 13rem 8rem 6rem 2rem;
    grid-template-areas:
        "thumb name  hire qty sub remove"
        "thumb price hire qty sub remove";
    align-items: center;
    column-gap: 1.5rem;
    padding: 1.1rem 0;
    border-top: 1px solid var(--btg-line);
}

.btg-basket tr.cart_item:not(:has(.product-hire)) {
    grid-template-columns: 6.5rem minmax(0, 1fr) 8rem 6rem 2rem;
    grid-template-areas:
        "thumb name  qty sub remove"
        "thumb price qty sub remove";
}

.btg-basket td {
    display: block !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    text-align: left !important;
}

.btg-basket td::before {
    display: none !important;
}

.btg-basket .product-remove { grid-area: remove; justify-self: end; }
.btg-basket .product-thumbnail { grid-area: thumb; }
.btg-basket .product-name { grid-area: name; align-self: end; }

.woocommerce .btg-basket tr.cart_item td.product-name,
.woocommerce .btg-basket tr.cart_item td.product-price {
    justify-self: start;
    text-align: left !important;
}
.btg-basket .product-price { grid-area: price; align-self: start; }
.btg-basket .product-hire { grid-area: hire; }
.btg-basket .product-quantity { grid-area: qty; }
.btg-basket .product-subtotal { grid-area: sub; justify-self: end; font-weight: 600; font-variant-numeric: tabular-nums; }

.btg-basket .product-thumbnail a,
.btg-basket .product-thumbnail > img {
    display: block;
}

.btg-basket .product-thumbnail img {
    display: block;
    width: 100% !important;
    max-width: none !important;
    height: auto;
    aspect-ratio: 1;
    padding: 10%;
    border-radius: 6px;
    background: var(--btg-tile);
    object-fit: contain;
    mix-blend-mode: multiply;
}

.btg-basket .product-thumbnail a {
    border-radius: 6px;
    background: var(--btg-tile);
}

.btg-basket .product-thumbnail.is-photo img {
    padding: 0;
    object-fit: cover;
    mix-blend-mode: normal;
}

.btg-basket .product-name,
.btg-basket .product-name a {
    color: var(--btg-ink);
    font-size: 1rem;
    font-weight: 500;
    line-height: 1.35;
    text-decoration: none;
}

.btg-basket .product-name a:hover {
    text-decoration: underline;
}

.btg-basket .product-price {
    margin-top: 0.2rem;
    font-size: 0.85rem;
    color: var(--btg-muted);
}

.btg-basket .product-price::after {
    content: " each";
}

.btg-basket .product-remove a.remove {
    display: grid;
    place-items: center;
    width: 1.9rem;
    height: 1.9rem;
    border: 1px solid var(--btg-line);
    border-radius: 50%;
    color: var(--btg-muted) !important;
    font-size: 1.1rem;
    line-height: 1;
    text-decoration: none;
}

.btg-basket .product-remove a.remove:hover {
    border-color: var(--btg-strong);
    background: transparent !important;
    color: var(--btg-strong) !important;
}

.btg-basket tr:not(.cart_item) {
    display: block;
    padding-top: 1.25rem;
    border-top: 1px solid var(--btg-line);
}

.btg-basket td.actions {
    display: flex !important;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.btg-basket td.actions .coupon {
    display: flex;
    gap: 0.5rem;
}

.btg-basket td.actions button[name="update_cart"] {
    order: 2;
    border: 1px solid var(--btg-line) !important;
    background: transparent !important;
    color: var(--btg-ink) !important;
}

.btg-basket__clear {
    order: 1;
    margin-right: auto;
    margin-left: 1rem;
    font-size: 0.85rem;
    color: var(--btg-muted);
    text-decoration: underline;
    text-underline-offset: 0.2em;
}

.btg-basket__clear:hover,
.btg-basket__clear.is-asking {
    color: #f0a191;
}

.btg-basket td.actions button[name="update_cart"]:disabled {
    opacity: 0.4;
}

@media (max-width: 900px) {
    .btg-basket tr.cart_item,
    .btg-basket tr.cart_item:not(:has(.product-hire)) {
        grid-template-columns: 5rem minmax(0, 1fr) auto;
        grid-template-areas:
            "thumb name  remove"
            "thumb price remove"
            "hire  hire  hire"
            "qty   qty   sub";
        row-gap: 0.6rem;
    }

    .btg-basket .product-hire {
        padding-top: 0.25rem !important;
    }

    .btg-basket .product-quantity {
        justify-self: start;
    }

    .btg-basket .product-hire .btg-hire-line {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
    }
}

.btg-hire-line {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.btg-hire-line__dates {
    font-size: 0.88rem;
    white-space: nowrap;
}

.btg-hire-line__msg,
.btg-hire-panel__msg {
    margin: 0;
    font-size: 0.85rem;
    color: #f0a191;
}

.btg-hire-line__msg[hidden],
.btg-hire-panel__msg[hidden] {
    display: none;
}

.btg-hire-none {
    color: var(--btg-muted);
}

.btg-hire-panel {
    margin: 0 0 1.75rem;
    padding: 1.25rem;
    border: 1px solid var(--btg-line);
    border-radius: 8px;
}

.btg-hire-panel__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 0.9rem;
}

.btg-hire-panel__title {
    margin: 0;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.btg-hire-panel__toggle {
    padding: 0.45rem 0.9rem;
    border: 1px solid var(--btg-line);
    border-radius: 999px;
    background: transparent;
    color: var(--btg-ink);
    font-family: inherit;
    font-size: 0.8rem;
    text-transform: none;
    letter-spacing: 0;
    cursor: pointer;
}

.btg-hire-panel__toggle:hover,
.btg-hire-panel__toggle:focus,
.btg-hire-panel__toggle[aria-expanded="true"] {
    border-color: var(--btg-strong);
    background: transparent;
    color: var(--btg-strong);
}

.btg-hire-panel > .btg-hire-span {
    max-width: 36rem;
    margin-inline: auto;
}

.btg-hire-panel__note {
    margin: 0 0 0.75rem;
    font-size: 0.9rem;
}

.btg-hire-panel__editor:not([hidden]) {
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--btg-line);
}

.btg-hire-panel__actions {
    margin-top: 0.75rem;
}

.btg-hire-panel__msg:not([hidden]) {
    margin-top: 0.75rem;
}

.btg-hire-panel__msg ul {
    margin: 0.35rem 0 0.75rem 1.1rem;
    color: var(--btg-ink);
}

.btg-hire-panel__msg p {
    margin: 0;
}

/* Lines with different dates on one timeline */

.btg-hire-timeline {
    display: grid;
    gap: 0.35rem;
    overflow-x: auto;
}

.btg-hire-timeline__axis,
.btg-hire-timeline__row {
    display: grid;
    grid-template-columns: minmax(9rem, 14rem) repeat(var(--btg-hire-cols), minmax(1.5rem, 1fr));
    align-items: center;
}

.btg-hire-timeline__axis::before {
    content: "";
}

.btg-hire-timeline__axis span {
    padding: 0.2rem 0;
    font-size: 0.68rem;
    text-align: center;
    color: var(--btg-muted);
}

.btg-hire-timeline__axis span.is-off {
    background: repeating-linear-gradient(135deg, transparent 0 4px, rgba(232, 228, 220, 0.07) 4px 6px);
}

.btg-hire-timeline__name {
    overflow: hidden;
    padding-right: 0.75rem;
    font-size: 0.85rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.btg-hire-timeline__bar {
    overflow: hidden;
    padding: 0.3rem 0.5rem;
    border-radius: 4px;
    background: var(--btg-strong);
    color: var(--btg-on-strong);
    font-size: 0.72rem;
    font-weight: 600;
    white-space: nowrap;
    text-overflow: ellipsis;
}

@media (max-width: 520px) {
    /* The two days side by side, the length under them */
    .btg-hire-span,
    .btg-strip__head {
        grid-template-columns: 1fr 1fr;
    }

    .btg-hire-span__mid,
    .btg-strip__mid {
        grid-column: 1 / -1;
        grid-row: 2;
    }

    .btg-hire-span__mid::before,
    .btg-strip__mid::before {
        left: 25%;
        right: 25%;
    }
}

@media (max-width: 700px) {
    .btg-hire-span__end,
    .btg-strip__end {
        padding: 0.5rem 0.6rem;
    }

    .btg-hire-span__end strong,
    .btg-strip__end strong {
        font-size: 0.92rem;
    }

    .btg-hire-span__mid,
    .btg-strip__mid {
        min-width: 0;
    }

    .btg-hire-bar,
    .btg-hire-panel {
        padding: 1rem;
    }

    .btg-hire-bar__head {
        flex-direction: column;
    }

    .btg-hire-bar__toggle {
        align-self: flex-start;
    }

    .btg-hire-dock {
        left: 1rem;
        right: 1rem;
        width: auto;
        max-width: none;
        justify-content: space-between;
        transform: none;
    }

    .woocommerce-cart table.cart td.product-hire {
        min-width: 0;
    }

    .woocommerce-cart table.shop_table_responsive tr td.product-hire::before {
        align-self: flex-start;
    }

    .btg-hire-timeline__axis,
    .btg-hire-timeline__row {
        grid-template-columns: minmax(6rem, 8rem) repeat(var(--btg-hire-cols), minmax(1.4rem, 1fr));
    }
}

/* Checkout and the basket's totals: the order as a panel, tables as lines
   (WooCommerce and GeneratePress shade every cell) */

.woocommerce-checkout #order_review {
    padding: 1.25rem 1.4rem;
    border: 1px solid var(--btg-line);
    border-radius: 8px;
}

.woocommerce-checkout-review-order-table,
.cart_totals table.shop_table {
    border: 0 !important;
    border-collapse: collapse !important;
    background: transparent !important;
}

.woocommerce-checkout-review-order-table th,
.woocommerce-checkout-review-order-table td,
.cart_totals table.shop_table th,
.cart_totals table.shop_table td {
    padding: 0.8rem 0 !important;
    border: 0 !important;
    border-bottom: 1px solid var(--btg-line) !important;
    background: transparent !important;
    vertical-align: top;
}

.woocommerce-checkout-review-order-table thead th {
    padding-top: 0 !important;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.woocommerce-checkout-review-order-table td:last-child,
.woocommerce-checkout-review-order-table th:last-child,
.cart_totals table.shop_table td {
    text-align: right !important;
}

.woocommerce-checkout-review-order-table .product-name {
    padding-right: 1rem !important;
    font-weight: 500;
}

.woocommerce-checkout-review-order-table .product-quantity {
    font-weight: 400;
    color: var(--btg-muted);
}

.woocommerce-checkout-review-order-table dl.variation {
    margin: 0.25rem 0 0;
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--btg-muted);
}

.woocommerce-checkout-review-order-table dl.variation dt {
    display: none;
}

.woocommerce-checkout-review-order-table dl.variation dd,
.woocommerce-checkout-review-order-table dl.variation dd p {
    margin: 0;
}

.woocommerce-checkout-review-order-table .order-total th,
.woocommerce-checkout-review-order-table .order-total td,
.cart_totals .order-total th,
.cart_totals .order-total td {
    border-bottom: 0 !important;
    font-size: 1.1rem;
}

.woocommerce-checkout #payment {
    background: transparent !important;
}

.woocommerce-checkout #payment ul.payment_methods {
    padding: 0 !important;
    border-bottom: 1px solid var(--btg-line) !important;
}

.woocommerce-checkout #payment div.payment_box {
    background: var(--btg-raised) !important;
}

.woocommerce-checkout #payment div.payment_box::before {
    border-bottom-color: var(--btg-raised) !important;
}

.woocommerce-checkout #payment div.form-row {
    padding: 1rem 0 0 !important;
}

/* Checkout: collection and return; the order notes follow it with their
   own label ("Anything to add?"), so WooCommerce's heading goes */

.woocommerce-checkout .woocommerce-additional-fields > h3 {
    display: none;
}

.btg-hire-handover {
    margin-bottom: 1.25rem;
}

.btg-hire-handover h3,
.btg-hire-handover h2 {
    margin-bottom: 0.6rem;
}

.btg-hire-handover__days {
    margin: 0 0 1.25rem;
    padding: 0;
    list-style: none;
    border-top: 1px solid var(--btg-line);
}

.btg-hire-handover__days li {
    display: grid;
    grid-template-columns: 8.5rem minmax(0, 1fr);
    gap: 0.35rem 1rem;
    padding: 0.7rem 0;
    border-bottom: 1px solid var(--btg-line);
    font-size: 0.92rem;
}

.btg-hire-handover__what {
    grid-column: 2;
}

.btg-hire-handover__what small {
    display: block;
    font-size: 0.82rem;
    color: var(--btg-muted);
}

.btg-hire-handover__lines {
    margin: 0 0 1.25rem;
    padding: 0;
    list-style: none;
    border-top: 1px solid var(--btg-line);
}

.btg-hire-handover__lines li {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.25rem 1rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--btg-line);
    font-size: 0.9rem;
}

.btg-hire-handover__lines li span + span {
    color: var(--btg-muted);
}

/* Guided (the rentals root, btg-hire.js views()): steps along the top, the
   step beside the hire so far; the dates bar and the cards move in */

.is-guided .btg-rentals__chips,
.is-guided .btg-rentals__sort,
.is-guided .btg-rentals__how,
.is-guided .btg-rentals__group {
    display: none;
}

.is-guided .btg-rentals__bar {
    justify-content: flex-start;
}

.btg-guided[hidden],
.btg-guided [hidden] {
    display: none !important;
}

.btg-guided__steps {
    display: grid;
    grid-auto-columns: minmax(0, 1fr);
    grid-auto-flow: column;
    margin: 0 0 2rem;
    padding: 0;
    list-style: none;
    counter-reset: none;
}

.btg-guided__steps li {
    position: relative;
}

/* the line joining the steps */
.btg-guided__steps li + li::before {
    content: "";
    position: absolute;
    top: 0.95rem;
    right: calc(50% + 1.15rem);
    left: calc(-50% + 1.15rem);
    height: 1px;
    background: var(--btg-line);
}

.btg-guided__steps button {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--btg-muted);
    font-family: inherit;
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
}

.btg-guided__steps button:hover,
.btg-guided__steps button:focus-visible {
    background: transparent;
    color: var(--btg-ink);
}

.btg-guided__n {
    position: relative;
    display: grid;
    place-items: center;
    width: 1.9rem;
    height: 1.9rem;
    border: 1px solid var(--btg-line);
    border-radius: 50%;
    background: var(--btg-ground);
    font-size: 0.78rem;
    letter-spacing: 0;
}

.btg-guided__steps button.is-done {
    color: var(--btg-ink);
}

.btg-guided__steps button.is-done .btg-guided__n {
    border-color: var(--btg-ink);
}

.btg-guided__steps button[aria-current="step"] {
    color: var(--btg-strong);
}

.btg-guided__steps button[aria-current="step"] .btg-guided__n {
    border-color: var(--btg-strong);
    background: var(--btg-strong);
    color: var(--btg-on-strong);
}

.btg-guided__steps button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* how many of the step's kit is in the hire */
.btg-guided__count:empty {
    display: none;
}

.btg-guided__count {
    position: absolute;
    top: -0.3rem;
    left: calc(50% + 0.55rem);
    min-width: 1.05rem;
    padding: 0 0.25rem;
    border-radius: 999px;
    background: var(--btg-strong);
    color: var(--btg-on-strong);
    font-size: 0.66rem;
    line-height: 1.05rem;
    letter-spacing: 0;
}

.btg-guided__body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 19rem;
    align-items: start;
    gap: 2.5rem;
}

.btg-guided__head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-bottom: 1.25rem;
}

.btg-guided__title {
    margin: 0 0 0.3rem;
}

.btg-guided__title:focus {
    outline: none;
}

.btg-guided__hint {
    max-width: 34rem;
    margin: 0;
    color: var(--btg-muted);
}

.btg-guided__search input {
    width: 15rem;
    padding: 0.55rem 0.9rem;
    border: 1px solid var(--btg-line);
    border-radius: 999px;
    background: var(--btg-raised);
    color: var(--btg-ink);
    font-size: 0.88rem;
}

.btg-guided__search input:focus {
    border-color: var(--btg-strong);
    outline: none;
}

.btg-guided__none,
.btg-guided__empty {
    color: var(--btg-muted);
}

.btg-guided__main .btg-hire-bar {
    margin-bottom: 1.5rem;
}

.btg-guided__nav {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.btg-guided__nav [data-go="1"] {
    margin-left: auto;
}

/* The hire so far, beside the step */
.btg-guided__aside {
    position: sticky;
    top: 5.5rem;
    padding: 1.25rem;
    border: 1px solid var(--btg-line);
    border-radius: 8px;
}

.btg-guided__aside-title {
    margin: 0 0 0.75rem;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--btg-muted);
}

.btg-guided__dates {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin: 0 0 1rem;
    font-weight: 600;
}

.btg-guided__dates span {
    font-weight: 400;
    color: var(--btg-muted);
}

.btg-guided__lines {
    margin: 0;
    padding: 0;
    list-style: none;
    border-top: 1px solid var(--btg-line);
}

.btg-guided__lines li {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.1rem 1rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--btg-line);
    font-size: 0.9rem;
}

.btg-guided__lines a {
    color: var(--btg-ink);
    text-decoration: none;
}

.btg-guided__lines a:hover {
    text-decoration: underline;
}

.btg-guided__qty {
    color: var(--btg-muted);
}

.btg-guided__lines li > a,
.btg-guided__lines li > .btg-guided__qty {
    grid-column: 1;
}

.btg-guided__lines strong {
    grid-column: 2;
    grid-row: 1;
}

.btg-guided__lines small {
    grid-column: 1 / -1;
    color: var(--btg-muted);
}

.btg-guided__total {
    display: flex;
    justify-content: space-between;
    margin: 0.9rem 0 1.1rem;
    font-size: 1.05rem;
}

.btg-guided__go {
    display: flex;
    justify-content: center;
    width: 100%;
}

.btg-guided__review .btg-guided__lines {
    max-width: 40rem;
}

.btg-guided__review .btg-guided__go {
    width: auto;
    display: inline-flex;
}

/* Guided shows the hire beside it: no dock on a wide screen */
@media (min-width: 901px) {
    body:has(.is-guided) .btg-hire-dock {
        display: none;
    }

    body:has(.is-guided).btg-hire-docked {
        padding-bottom: 0;
    }
}

@media (max-width: 900px) {
    .btg-guided__body {
        grid-template-columns: minmax(0, 1fr);
    }

    .btg-guided__aside {
        display: none;
    }
}

@media (max-width: 640px) {
    .btg-guided__steps {
        margin-right: -20px;
        margin-left: -20px;
        padding: 0 8px;
    }

    .btg-guided__steps button {
        font-size: 0.62rem;
        letter-spacing: 0.02em;
    }

    .btg-guided__search,
    .btg-guided__search input {
        width: 100%;
    }
}
