/**
 * Bootstrap modal essentials + Grafton storefront modal styling.
 * Loaded on Grafton-themed pages that use AIZ cart/login modals.
 */

/* —— Bootstrap modal core (hidden until opened) —— */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1050;
    display: none;
    width: 100%;
    height: 100%;
    overflow: hidden;
    outline: 0;
}

.modal.fade .modal-dialog {
    transition: transform 0.3s ease-out;
    transform: translate(0, -40px);
}

.modal.show {
    display: block;
}

.modal.show .modal-dialog {
    transform: none;
}

.modal-open {
    overflow: hidden;
}

.modal-open .modal {
    overflow-x: hidden;
    overflow-y: auto;
}

.modal-dialog {
    position: relative;
    width: auto;
    margin: 1.75rem auto;
    max-width: 500px;
    pointer-events: none;
}

.modal-dialog-centered {
    display: flex;
    align-items: center;
    min-height: calc(100% - 3.5rem);
}

.modal-dialog-centered::before {
    display: block;
    height: calc(100vh - 3.5rem);
    content: "";
}

.modal-dialog.modal-lg {
    max-width: 800px;
}

.modal-content {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    pointer-events: auto;
    background-color: #fff;
    background-clip: padding-box;
    border: 0;
    border-radius: 4px;
    outline: 0;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1040;
    width: 100vw;
    height: 100vh;
    background-color: #000;
}

.modal-backdrop.fade {
    opacity: 0;
}

.modal-backdrop.show {
    opacity: 0.55;
}

/* Zoom animation (login / add to cart) */
.modal.fade .modal-dialog.modal-dialog-zoom {
    transform: scale(0.88);
    transition: transform 0.3s ease-out;
}

.modal.show .modal-dialog.modal-dialog-zoom {
    transform: scale(1);
}

/* —— Grafton-branded modal chrome —— */
#grafton-storefront-modals .modal-content {
    font-family: "Roboto Slab", Georgia, serif;
    color: #191919;
}

#grafton-storefront-modals .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 28px 16px;
    border-bottom: 1px solid #e8e8e8;
    min-height: auto;
}

#grafton-storefront-modals .modal-title,
#grafton-storefront-modals .modal-header h4,
#grafton-storefront-modals .modal-header h5,
#grafton-storefront-modals .modal-header h6 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: #191919;
    letter-spacing: 0.02em;
}

#grafton-storefront-modals .modal-header .close {
    padding: 0;
    margin: 0 0 0 16px;
    width: 36px;
    height: 36px;
    border: 1px solid #ddd;
    border-radius: 50%;
    background: #f5f5f5;
    color: #191919;
    font-size: 22px;
    line-height: 1;
    opacity: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s, border-color 0.2s;
}

#grafton-storefront-modals .modal-header .close:hover {
    background: #ebebeb;
    border-color: #bbb;
}

#grafton-storefront-modals .modal-header .close span {
    display: block;
    line-height: 1;
}

#grafton-storefront-modals .modal-header .close::before {
    content: "\00d7";
    font-size: 22px;
    font-weight: 400;
}

#grafton-storefront-modals .modal-header .close span:empty {
    display: none;
}

#grafton-storefront-modals .modal-body {
    padding: 20px 28px 28px;
    overflow-y: auto;
    max-height: 70vh;
}

#grafton-storefront-modals .modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 28px 24px;
    border-top: 1px solid #e8e8e8;
}

/* Forms & buttons inside modals */
#grafton-storefront-modals .form-control {
    display: block;
    width: 100%;
    padding: 12px 14px;
    font-size: 15px;
    line-height: 1.5;
    color: #191919;
    background-color: #fff;
    border: 1px solid #ccc;
    border-radius: 2px;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
}

#grafton-storefront-modals .form-control:focus {
    border-color: #880516;
    outline: 0;
    box-shadow: 0 0 0 3px rgba(136, 5, 22, 0.2);
}

#grafton-storefront-modals .form-label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 600;
}

#grafton-storefront-modals .form-group {
    margin-bottom: 16px;
}

#grafton-storefront-modals .btn {
    display: inline-block;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.5;
    text-align: center;
    border-radius: 2px;
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}

#grafton-storefront-modals .btn-primary {
    background: #660411;
    border-color: #660411;
    color: #fff;
}

#grafton-storefront-modals .btn-primary:hover {
    background: #52030E;
    border-color: #52030E;
    color: #fff;
}

#grafton-storefront-modals .btn-secondary {
    background: #f5f5f5;
    border-color: #ccc;
    color: #191919;
}

#grafton-storefront-modals .btn-secondary:hover {
    background: #ebebeb;
}

#grafton-storefront-modals .btn-danger {
    background: #c0392b;
    border-color: #c0392b;
    color: #fff;
}

#grafton-storefront-modals .btn-danger:hover {
    background: #a93226;
    color: #fff;
}

#grafton-storefront-modals .btn-block {
    display: block;
    width: 100%;
}

#grafton-storefront-modals .btn-link {
    background: none;
    border: none;
    color: #880516;
    padding: 0;
    font-weight: 600;
}

#grafton-storefront-modals .btn-link:hover {
    color: #880516;
}

#grafton-storefront-modals .text-primary {
    color: #880516 !important;
}

#grafton-storefront-modals .text-danger {
    color: #c0392b;
}

#grafton-storefront-modals .text-muted {
    color: #777;
}

#grafton-storefront-modals .text-reset {
    color: inherit;
    text-decoration: none;
}

#grafton-storefront-modals .text-reset:hover {
    color: #880516;
}

#grafton-storefront-modals .aiz-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
}

#grafton-storefront-modals .separator {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 20px 0;
}

#grafton-storefront-modals .separator::before,
#grafton-storefront-modals .separator::after {
    content: "";
    flex: 1;
    border-bottom: 1px solid #e5e5e5;
}

#grafton-storefront-modals .separator span {
    padding: 0 12px;
    font-size: 13px;
    color: #888;
}

#grafton-storefront-modals .social.colored a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
}

#grafton-storefront-modals .social .facebook { background: #3b5998; }
#grafton-storefront-modals .social .google { background: #dd4b39; }
#grafton-storefront-modals .social .twitter { background: #1da1f2; }
#grafton-storefront-modals .social .apple { background: #191919; }

#grafton-storefront-modals #addToCart .modal-content > .close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    margin: 0;
}

#grafton-storefront-modals #addToCart .c-preloader {
    padding: 48px;
}

/* —— Grafton cart modals (picker + success) —— */
#grafton-storefront-modals #addToCart .modal-content {
    background: #faf8f6;
    border-radius: 6px;
    overflow: hidden;
}

#grafton-storefront-modals #addToCart:has(.grafton-cart-modal--success) .modal-content > .close {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    top: 14px;
    right: 14px;
}

#grafton-storefront-modals #addToCart:has(.grafton-cart-modal--success) .modal-content > .close:hover {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.4);
}

#grafton-storefront-modals #addToCart-modal-body:has(.grafton-cart-modal--success) {
    padding: 0;
}

#grafton-storefront-modals #addToCart:has(.grafton-cart-modal--success) .modal-dialog {
    max-width: 520px;
}

#grafton-storefront-modals #addToCart:has(.grafton-cart-modal--picker) .modal-dialog {
    max-width: 860px;
}

.grafton-cart-modal {
    font-family: "Roboto Slab", Georgia, serif;
    color: #191919;
}

.grafton-cart-modal__hero {
    background: linear-gradient(135deg, #191919 0%, #2a2a2a 100%);
    color: #fff;
    text-align: center;
    padding: 32px 28px 28px;
    position: relative;
}

.grafton-cart-modal__hero::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: linear-gradient(90deg, #660411, #880516, #660411);
}

.grafton-cart-modal__check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    margin-bottom: 14px;
    border-radius: 50%;
    background: #880516;
    color: #fff;
    box-shadow: 0 8px 24px rgba(136, 5, 22, 0.35);
}

.grafton-cart-modal__title {
    margin: 0 0 6px;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #fff;
}

.grafton-cart-modal__subtitle {
    margin: 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.72);
    line-height: 1.5;
}

.grafton-cart-modal__product {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    padding: 24px 28px;
    background: #fff;
    border-bottom: 1px solid #ece8e4;
}

.grafton-cart-modal__product-image {
    flex: 0 0 88px;
    width: 88px;
    height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #faf8f6;
    border: 1px solid #ece8e4;
    padding: 8px;
    box-sizing: border-box;
}

.grafton-cart-modal__product-image img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.grafton-cart-modal__product-details {
    flex: 1;
    min-width: 0;
}

.grafton-cart-modal__product-name {
    margin: 0 0 8px;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.35;
    color: #191919;
}

.grafton-cart-modal__product-qty {
    margin: 0 0 12px;
    font-size: 13px;
    color: #666;
}

.grafton-cart-modal__price-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    padding-top: 10px;
    border-top: 1px solid #f0ece8;
}

.grafton-cart-modal__price-row--secondary {
    margin-top: 8px;
    padding-top: 8px;
    border-top: none;
}

.grafton-cart-modal__price-label {
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #888;
}

.grafton-cart-modal__price-value {
    font-size: 20px;
    font-weight: 700;
    color: #880516;
    white-space: nowrap;
}

.grafton-cart-modal__related {
    padding: 20px 28px;
    background: #faf8f6;
    border-bottom: 1px solid #ece8e4;
}

.grafton-cart-modal__related-title {
    margin: 0 0 14px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #191919;
}

.grafton-cart-modal__related-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.grafton-cart-modal__related-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 12px 8px;
    background: #fff;
    border: 1px solid #ece8e4;
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.grafton-cart-modal__related-item:hover {
    border-color: #880516;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    color: inherit;
    text-decoration: none;
}

.grafton-cart-modal__related-thumb {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 72px;
    margin-bottom: 8px;
}

.grafton-cart-modal__related-thumb img {
    max-height: 72px;
    max-width: 100%;
    object-fit: contain;
}

.grafton-cart-modal__related-name {
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
    color: #191919;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 4px;
}

.grafton-cart-modal__related-price {
    font-size: 13px;
    font-weight: 700;
    color: #880516;
}

.grafton-cart-modal__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 22px 28px 28px;
    background: #fff;
}

.grafton-cart-modal__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 12px 18px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 3px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    box-sizing: border-box;
}

.grafton-cart-modal__btn--primary {
    background: #660411;
    border-color: #660411;
    color: #fff;
}

.grafton-cart-modal__btn--primary:hover {
    background: #52030E;
    border-color: #52030E;
    color: #fff;
    text-decoration: none;
}

.grafton-cart-modal__btn--outline {
    background: #fff;
    border-color: #ccc;
    color: #191919;
}

.grafton-cart-modal__btn--outline:hover {
    background: #f5f5f5;
    border-color: #999;
    color: #191919;
}

/* Picker modal */
.grafton-cart-modal--picker {
    padding: 0;
}

.grafton-cart-modal__picker-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 360px;
}

.grafton-cart-modal__picker-media {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
    background: #faf8f6;
    border-right: 1px solid #ece8e4;
}

.grafton-cart-modal__single-image,
.grafton-cart-modal__gallery {
    width: 100%;
    max-width: 280px;
}

.grafton-cart-modal__single-image img,
.grafton-cart-modal__gallery img {
    display: block;
    max-width: 100%;
    max-height: 320px;
    margin: 0 auto;
    object-fit: contain;
}

.grafton-cart-modal__picker-details {
    padding: 28px 28px 24px;
    background: #fff;
}

.grafton-cart-modal__picker-title {
    margin: 0 0 12px;
    font-size: 22px;
    font-weight: 700;
    line-height: 1.3;
    color: #191919;
}

.grafton-cart-modal__picker-price {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #ece8e4;
}

.grafton-cart-modal__price-current {
    font-size: 22px;
    font-weight: 700;
    color: #880516;
}

.grafton-cart-modal__price-old {
    margin-left: 8px;
    font-size: 15px;
    color: #999;
    text-decoration: line-through;
}

.grafton-cart-modal__price-unit {
    margin-left: 4px;
    font-size: 14px;
    color: #777;
}

.grafton-cart-modal__field {
    margin-bottom: 16px;
}

.grafton-cart-modal__label {
    display: block;
    margin-bottom: 8px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #666;
}

.grafton-cart-modal__options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.grafton-cart-modal__option {
    margin: 0;
    cursor: pointer;
}

.grafton-cart-modal__option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.grafton-cart-modal__option span {
    display: inline-block;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 600;
    border: 1px solid #ddd;
    background: #fff;
    color: #191919;
    transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.grafton-cart-modal__option input:checked + span {
    border-color: #660411;
    background: #660411;
    color: #fff;
}

.grafton-cart-modal__option--color span.grafton-cart-modal__swatch {
    width: 32px;
    height: 32px;
    padding: 0;
    border-radius: 50%;
    border: 2px solid #ddd;
}

.grafton-cart-modal__option--color input:checked + .grafton-cart-modal__swatch {
    border-color: #191919;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #880516;
    background: inherit;
}

.grafton-cart-modal__qty-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.grafton-cart-modal__qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid #ddd;
    background: #fff;
}

.grafton-cart-modal__qty .btn {
    background: #f5f5f5;
    border: none;
    color: #191919;
    width: 36px;
    height: 36px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.grafton-cart-modal__qty .input-number {
    width: 52px;
    height: 36px;
    border: none;
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    background: #fff;
}

.grafton-cart-modal__stock {
    font-size: 13px;
    color: #777;
}

.grafton-cart-modal__total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 16px;
    padding-top: 12px;
    border-top: 1px solid #ece8e4;
}

.grafton-cart-modal__picker-actions {
    margin-top: 8px;
}

.grafton-cart-modal__picker-actions .grafton-cart-modal__btn {
    width: 100%;
}

@media (max-width: 767px) {
    .grafton-cart-modal__picker-grid {
        grid-template-columns: 1fr;
    }

    .grafton-cart-modal__picker-media {
        border-right: none;
        border-bottom: 1px solid #ece8e4;
        padding: 20px;
    }

    .grafton-cart-modal__product {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .grafton-cart-modal__price-row {
        flex-direction: column;
        align-items: center;
        gap: 4px;
    }

    .grafton-cart-modal__related-grid {
        grid-template-columns: 1fr;
    }

    .grafton-cart-modal__actions {
        grid-template-columns: 1fr;
    }
}

/* Legacy add-to-cart partial fallback styles */
#grafton-storefront-modals #addToCart-modal-body .modal-body {
    padding: 20px 28px 28px;
}

#grafton-storefront-modals #addToCart-modal-body .row {
    display: flex;
    flex-wrap: wrap;
    margin-left: -10px;
    margin-right: -10px;
}

#grafton-storefront-modals #addToCart-modal-body [class*="col-"] {
    position: relative;
    width: 100%;
    padding-left: 10px;
    padding-right: 10px;
    box-sizing: border-box;
}

@media (min-width: 992px) {
    #grafton-storefront-modals #addToCart-modal-body .col-lg-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

#grafton-storefront-modals #addToCart-modal-body .text-primary {
    color: #880516 !important;
}

#grafton-storefront-modals #addToCart-modal-body .btn-primary,
#grafton-storefront-modals #addToCart-modal-body .btn-secondary-base {
    background: #660411;
    border-color: #660411;
    color: #fff;
}

#grafton-storefront-modals #addToCart-modal-body .btn-primary:hover,
#grafton-storefront-modals #addToCart-modal-body .btn-secondary-base:hover {
    background: #52030E;
    border-color: #52030E;
    color: #fff;
}

#grafton-storefront-modals #addToCart-modal-body .btn-secondary {
    background: #f5f5f5;
    border-color: #ccc;
    color: #191919;
}

#grafton-storefront-modals #addToCart-modal-body .btn-secondary:hover {
    background: #ebebeb;
}

#grafton-storefront-modals #addToCart-modal-body .img-fit,
#grafton-storefront-modals #addToCart-modal-body img {
    max-width: 100%;
    height: auto;
}

#grafton-storefront-modals #addToCart-modal-body .input-number {
    text-align: center;
}

#grafton-storefront-modals .grafton-modal-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 3px solid rgba(136, 5, 22, 0.25);
    border-top-color: #880516;
    border-radius: 50%;
    animation: grafton-modal-spin 0.8s linear infinite;
}

@keyframes grafton-modal-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 575px) {
    .modal-dialog {
        margin: 1rem;
        max-width: calc(100% - 2rem);
    }

    #grafton-storefront-modals .modal-header,
    #grafton-storefront-modals .modal-body,
    #grafton-storefront-modals .modal-footer {
        padding-left: 20px;
        padding-right: 20px;
    }
}

/* Footer — "Follow the Journey" banner */
.grafton-follow-journey-banner {
    background-color: #880516;
    background-position: top center;
    background-repeat: no-repeat;
    background-size: cover;
    padding: 60px 0;
    margin: 0;
}

.grafton-follow-journey-banner__inner {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 15px;
    column-gap: 40px;
    row-gap: 16px;
}

.grafton-follow-journey-banner__text {
    flex: 0 0 auto;
    text-align: center;
}

.grafton-follow-journey-banner__text img {
    display: block;
    width: auto;
    max-width: 647px;
    height: auto;
}

.grafton-follow-journey-banner__social {
    flex: 0 0 auto;
    display: flex;
    flex-direction: row;
    align-items: center;
}

.grafton-follow-journey-banner__social a {
    display: inline-block;
    line-height: 0;
}

.grafton-follow-journey-banner__social a + a {
    margin-left: 30px;
}

.grafton-follow-journey-banner__social img {
    display: block;
    height: auto;
    width: auto;
}

@media (max-width: 767px) {
    .grafton-follow-journey-banner {
        padding: 30px 0;
    }

    .grafton-follow-journey-banner__text img {
        max-width: 50%;
        margin: 0 auto;
    }

    .grafton-follow-journey-banner__social {
        justify-content: center;
    }
}

/* Footer — Brewhouse Group banner */
.grafton-footer-brewhouse {
    background-color: #880516;
    background-position: top center;
    background-repeat: no-repeat;
    background-size: cover;
    text-align: center;
    padding: 60px 0;
    margin: 0;
}

.grafton-footer-brewhouse img {
    display: block;
    width: 100%;
    max-width: 770px;
    height: auto;
    margin: 0 auto;
}

@media (max-width: 767px) {
    .grafton-footer-brewhouse {
        padding: 30px 0;
    }

    .grafton-footer-brewhouse img {
        width: 90%;
    }
}

/* Footer — Certified Independent badge */
.grafton-footer-independent-beer {
    text-align: center;
}

.grafton-footer-independent-beer img {
    display: inline-block;
    width: 80%;
    max-width: 200px;
    height: auto;
}

.grafton-footer-drinkwise {
    text-align: center;
    margin-top: 1.5rem;
}

.grafton-footer-drinkwise p {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
}

.grafton-footer-drinkwise a {
    color: inherit;
    text-decoration: underline;
}

.grafton-footer-drinkwise a:hover {
    opacity: 0.85;
}

.grafton-footer-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.grafton-footer-social .btIconWidget {
    margin: 0;
    display: inline-flex;
}

.grafton-footer-social .btIconWidget .btIconWidgetIcon {
    padding: 0;
}

.grafton-footer-social .btIconWidget .bt_bb_icon_holder:before {
    font-size: 1.25rem;
}

@media (max-width: 767px) {
    .grafton-footer-independent-beer img {
        width: 38%;
        max-width: 160px;
    }

    .grafton-footer-drinkwise p {
        font-size: 15px;
        line-height: 1.5;
    }

    /* First 2 footer columns side-by-side to shorten mobile footer */
    .grafton-footer-main-row > .bt_bb_row_holder {
        display: flex;
        flex-wrap: wrap;
        gap: 12px;
    }

    .grafton-footer-col--badge,
    .grafton-footer-col--contact {
        flex: 0 0 calc(50% - 6px) !important;
        width: calc(50% - 6px) !important;
        max-width: calc(50% - 6px) !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .grafton-footer-col--menu {
        flex: 0 0 100% !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    .grafton-footer-col--badge .bt_bb_separator,
    .grafton-footer-col--contact .bt_bb_separator {
        margin-top: 0.75rem !important;
        margin-bottom: 0.75rem !important;
    }

    .grafton-footer-col--badge .bt_bb_column_content_inner > .bt_bb_separator:first-child,
    .grafton-footer-col--contact .bt_bb_column_content_inner > .bt_bb_separator:first-child {
        display: none;
    }

    .grafton-footer-col--contact .bt_bb_image img {
        height: 70px !important;
        width: auto;
    }

    .grafton-footer-col--contact .bt_bb_text p {
        font-size: 14px;
        line-height: 1.45;
    }

    .grafton-footer-col--badge .grafton-footer-drinkwise {
        margin-top: 0.75rem;
    }

    .grafton-footer-col--badge .grafton-footer-drinkwise p {
        font-size: 12px;
        line-height: 1.4;
    }

    #btSiteFooter #bt_bb_section6a1e87c7f3a7b {
        padding-top: 2rem !important;
        padding-bottom: 1.5rem !important;
    }

    /* Footer menu links — 2 columns on mobile only */
    .grafton-footer-col--menu .menu-footer-menu-container,
    .grafton-footer-col--menu .bt_bb_custom_menu > div {
        width: 100%;
    }

    .grafton-footer-col--menu #menu-footer-menu {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0.35rem 1rem;
        width: 100%;
        margin: 0;
        padding: 0;
        text-align: center;
    }

    .grafton-footer-col--menu #menu-footer-menu > .menu-item {
        margin: 0;
        padding: 0;
    }

    .grafton-footer-col--menu #menu-footer-menu a {
        font-size: 15px;
    }
}

/* Header + footer — slightly larger typography */
.mainHeader .menuPort,
.mainHeader .menuPort nav > ul > li > a,
.mainHeader .menuPort nav ul ul li a,
.btMenuVertical .mainHeader .btLogoArea .menuPort nav ul li > a,
#menu-primary-menu > li > a,
#menu-primary-menu .sub-menu a {
    font-size: 17px;
}

.mainHeader .btLogoArea .menuPort > nav > ul > li.grafton-nav-login > a.grafton-nav-login-btn,
.btStickyHeaderActive.btMenuHorizontal .mainHeader .btLogoArea .menuPort nav > ul > li.grafton-nav-login > a.grafton-nav-login-btn {
    font-size: 14px;
}

.btSiteFooter .bt_bb_custom_menu div ul a,
.btSiteFooter #menu-footer-menu a,
.btSiteFooter .menu-footer-menu-container a,
.btSiteFooter .bt_bb_text,
.btSiteFooter .bt_bb_text p {
    font-size: 17px;
}

.grafton-footer-social .btIconWidget .bt_bb_icon_holder:before {
    font-size: 1.4rem;
}

@media (max-width: 767px) {
    .mainHeader .menuPort,
    .mainHeader .menuPort nav > ul > li > a,
    .btMenuVertical .mainHeader .btLogoArea .menuPort nav ul li > a,
    #menu-primary-menu > li > a {
        font-size: 16px;
    }

    .btSiteFooter .bt_bb_custom_menu div ul a,
    .btSiteFooter #menu-footer-menu a,
    .btSiteFooter .menu-footer-menu-container a,
    .btSiteFooter .bt_bb_text,
    .btSiteFooter .bt_bb_text p {
        font-size: 16px;
    }
}

/* Full-width banners — full image visible, menu overlays top (btBelowMenu) */
body.btBelowMenu .btContentWrap,
body.btBelowMenu .btBlogHeaderContent {
    padding-top: 0 !important;
    margin-top: 0;
}

.grafton-full-banner,
.grafton-home-banner {
    position: relative;
    padding: 0 !important;
    margin: 0;
    width: 100%;
    min-height: 0 !important;
}

.grafton-full-banner .bt_bb_background_image_holder_wrapper,
.grafton-home-banner .bt_bb_background_image_holder_wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1600 / 645;
}

.grafton-full-banner .bt_bb_background_image_holder,
.grafton-home-banner .bt_bb_background_image_holder {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center center;
}

@media (max-width: 767px) {
    .grafton-full-banner .bt_bb_background_image_holder_wrapper,
    .grafton-home-banner .bt_bb_background_image_holder_wrapper {
        aspect-ratio: 16 / 10;
    }
}

/* Inner page heroes with headline text over the image */
body.btBelowMenu .grafton-page-hero,
body.btBelowMenu .btBlogHeaderContent > .bt_bb_section {
    position: relative;
    margin: 0;
    padding: 0 !important;
    min-height: 360px;
}

.grafton-page-hero > .bt_bb_background_image_holder_wrapper,
body.btBelowMenu .btBlogHeaderContent > .bt_bb_section > .bt_bb_background_image_holder_wrapper {
    position: absolute;
    inset: 0;
}

.grafton-page-hero .bt_bb_background_image_holder,
body.btBelowMenu .btBlogHeaderContent > .bt_bb_section .bt_bb_background_image_holder {
    background-size: cover;
    background-position: center center;
}

body.btBelowMenu .grafton-page-hero > .bt_bb_port,
body.btBelowMenu .btBlogHeaderContent > .bt_bb_section > .bt_bb_port {
    position: relative;
    z-index: 1;
    padding-top: 7em !important;
    padding-bottom: 2.5em !important;
}

@media (max-width: 1199px) {
    body.btBelowMenu .grafton-page-hero > .bt_bb_port,
    body.btBelowMenu .btBlogHeaderContent > .bt_bb_section > .bt_bb_port {
        padding-top: 5.5em !important;
    }
}

@media (max-width: 767px) {
    body.btBelowMenu .grafton-page-hero,
    body.btBelowMenu .btBlogHeaderContent > .bt_bb_section {
        min-height: 280px;
    }

    body.btBelowMenu .grafton-page-hero > .bt_bb_port,
    body.btBelowMenu .btBlogHeaderContent > .bt_bb_section > .bt_bb_port {
        padding-top: 4.5em !important;
    }
}

/* Home + About Us — "Our Beers" heading banner */
.grafton-our-beers-heading {
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    padding: 100px 0;
    margin: 0;
}

.grafton-our-beers-heading .grafton-our-beers-heading__inner {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 15px;
    text-align: center;
}

.grafton-our-beers-heading img {
    display: block;
    width: 100%;
    max-width: 1050px;
    height: auto;
    margin: 0 auto;
}

@media (max-width: 767px) {
    .grafton-our-beers-heading {
        padding: 25px 0;
    }

    .grafton-our-beers-heading img {
        width: 90%;
    }
}

/* Home — "Pride of the North" heading banner (compact) */
#grafton-pride-of-the-north-heading {
    padding: 55px 0;
}

#grafton-pride-of-the-north-heading img {
    max-width: 599px;
}

@media (max-width: 767px) {
    #grafton-pride-of-the-north-heading {
        padding: 20px 0;
    }
}

/* Home — Special Events heading banner (same as Pride of the North) */
#grafton-special-events-heading {
    padding: 55px 0;
}

#grafton-special-events-heading img {
    max-width: 599px;
}

@media (max-width: 767px) {
    #grafton-special-events-heading {
        padding: 20px 0;
    }
}

/* Home — "More than beer" heading banner (same as Pride of the North) */
#grafton-more-than-beer-heading {
    padding: 55px 0;
}

#grafton-more-than-beer-heading img {
    max-width: 599px;
}

@media (max-width: 767px) {
    #grafton-more-than-beer-heading {
        padding: 20px 0;
    }
}

/* Home — Special Events image gallery (masonry layout) */
.grafton-special-events-gallery {
    background: #ffffff;
    padding: 50px 0 60px;
    margin: 0;
}

.grafton-special-events-gallery__inner {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 15px;
}

.grafton-special-events-gallery__masonry {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-auto-flow: dense;
    gap: 18px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.grafton-special-events-gallery__item {
    margin: 0;
}

.grafton-special-events-gallery__figure {
    margin: 0;
    overflow: hidden;
    border-radius: 6px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    background: #f5f5f5;
    line-height: 0;
}

.grafton-special-events-gallery__image {
    display: block;
    width: 100%;
    height: auto;
    transition: transform 0.45s ease;
}

.grafton-special-events-gallery__figure:hover .grafton-special-events-gallery__image {
    transform: scale(1.03);
}

@media (min-width: 992px) {
    .grafton-special-events-gallery__masonry {
        grid-template-columns: 1.15fr 0.92fr 0.92fr;
        grid-template-rows: auto auto;
        grid-template-areas:
            "feature top1 top2"
            "feature wide wide";
        gap: 22px;
    }

    .grafton-special-events-gallery__item--feature {
        grid-area: feature;
    }

    .grafton-special-events-gallery__item:nth-child(2) {
        grid-area: top1;
    }

    .grafton-special-events-gallery__item:nth-child(3) {
        grid-area: top2;
    }

    .grafton-special-events-gallery__item--wide {
        grid-area: wide;
    }
}

@media (max-width: 991px) {
    .grafton-special-events-gallery__masonry {
        columns: 2;
        column-gap: 18px;
        display: block;
    }

    .grafton-special-events-gallery__item {
        break-inside: avoid;
        margin-bottom: 18px;
    }

    .grafton-special-events-gallery {
        padding-bottom: 40px;
    }
}

@media (max-width: 767px) {
    .grafton-special-events-gallery {
        padding: 30px 0;
    }

    .grafton-special-events-gallery__masonry {
        columns: 1;
        column-gap: 0;
    }

    .grafton-special-events-gallery__item {
        margin-bottom: 14px;
    }

    .grafton-special-events-gallery__figure {
        border-radius: 4px;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    }
}

/* Home — navigation image blocks */
.grafton-home-nav-blocks {
    padding: 80px 0;
    margin: 0;
}

.grafton-home-nav-blocks__inner {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 15px;
}

.grafton-home-nav-blocks__grid {
    display: flex;
    flex-wrap: wrap;
    gap: 3%;
    list-style: none;
    margin: 0;
    padding: 0;
}

.grafton-home-nav-blocks__item {
    width: 30%;
    margin: 0 0 3%;
}

.grafton-home-nav-blocks__link {
    display: block;
    text-decoration: none;
}

.grafton-home-nav-blocks__media {
    position: relative;
    display: block;
    overflow: hidden;
    background: #000;
}

.grafton-home-nav-blocks__image {
    display: block;
    width: 100%;
    height: auto;
    opacity: 0.6;
    transition: opacity 0.5s ease;
}

.grafton-home-nav-blocks__label {
    position: absolute;
    top: 30%;
    left: 0;
    width: 100%;
    color: #fff;
    font-family: "Roboto Condensed", sans-serif;
    font-size: clamp(36px, 5vw, 60px);
    font-weight: 700;
    line-height: 1;
    text-align: center;
    text-transform: uppercase;
    pointer-events: none;
}

.grafton-home-nav-blocks__link:hover .grafton-home-nav-blocks__image,
.grafton-home-nav-blocks__link:focus-visible .grafton-home-nav-blocks__image {
    opacity: 0.5;
}

@media (max-width: 991px) {
    .grafton-home-nav-blocks {
        padding: 50px 0;
    }

    .grafton-home-nav-blocks__item {
        width: 47%;
    }
}

@media (max-width: 575px) {
    .grafton-home-nav-blocks {
        padding: 30px 0;
    }

    .grafton-home-nav-blocks__item {
        width: 100%;
        margin-bottom: 20px;
    }

    .grafton-home-nav-blocks__label {
        top: 50%;
        transform: translateY(-50%);
    }
}

/* Home + About Us — featured beer product slider (same cards as category archive) */
.bt_bb_column_content_inner > .grafton-featured-product-slider {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
}

.grafton-featured-product-slider.bt_bb_content_slider {
    width: 100%;
    max-width: 100%;
}

.bt_bb_layout_wide .grafton-featured-product-slider.bt_bb_content_slider.bt_bb_multiple_slides .slick-list {
    max-width: none !important;
    width: 100% !important;
    margin: 0 !important;
    position: relative !important;
}

.grafton-featured-product-slider .bt_bb_content_slider_item .bt_bb_content_slider_item_content {
    max-width: none;
    padding: 0 10px;
}

.grafton-featured-product-slider .bt_bb_content_slider_item ul.products {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
}

.grafton-featured-product-slider .bt_bb_content_slider_item ul.products li.product {
    width: 100% !important;
    max-width: 100% !important;
    flex: none !important;
    float: none;
    clear: none;
    margin: 0;
    padding: 0;
}

.grafton-featured-product-slider .slick-slider {
    width: 100%;
}

.grafton-featured-product-slider .slick-slide {
    height: auto;
}

.grafton-featured-product-slider .slick-track {
    display: flex;
    align-items: stretch;
}

@media (max-width: 767px) {
    .grafton-featured-product-slider .bt_bb_content_slider_item .bt_bb_content_slider_item_content {
        padding: 0 6px;
    }

    .grafton-featured-product-slider .slick-slider {
        position: relative;
    }

    .grafton-featured-product-slider.bt_bb_arrows_size_large button.slick-arrow {
        z-index: 12;
    }
}

/* Single product — compact image with hover zoom */
body.single-product div.product div.images .woocommerce-product-gallery__wrapper {
    justify-content: center;
}

body.single-product div.product div.images .woocommerce-product-gallery__image:first-child {
    flex: 0 1 auto !important;
    max-width: 360px;
    width: 100% !important;
    margin: 0 auto 1em !important;
    float: none !important;
    overflow: hidden;
}

body.single-product div.product div.images .woocommerce-product-gallery__image:first-child > a {
    display: block;
    overflow: hidden;
    cursor: crosshair;
    background: #fafafa;
    padding: 1.25em;
    box-sizing: border-box;
}

body.single-product div.product div.images .woocommerce-product-gallery__image:first-child img {
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    max-height: 360px !important;
    height: auto !important;
    margin: 0 auto !important;
    object-fit: contain;
    border: none !important;
}

body.single-product div.product div.images .woocommerce-product-gallery__image:first-child .zoomImg {
    cursor: crosshair;
}

@media (max-width: 767px) {
    body.single-product div.product div.images .woocommerce-product-gallery__image:first-child {
        max-width: 280px;
    }

    body.single-product div.product div.images .woocommerce-product-gallery__image:first-child img {
        max-height: 300px !important;
    }
}

/* Single product — quantity + add to cart aligned height */
body.single-product div.product div.summary form.cart .quantity {
    float: none;
    display: inline-block;
    vertical-align: middle;
    width: 100px;
    height: 2.9em;
    margin: 0 0.5em 0 0;
}

body.single-product div.product div.summary form.cart .quantity input {
    height: 100%;
    box-sizing: border-box;
}

body.single-product div.product div.summary form.cart .single_add_to_cart_button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    height: 2.9em;
    line-height: 1;
    padding: 0 1.2em;
    box-sizing: border-box;
}

@media (max-width: 768px) {
    body.single-product div.product div.summary form.cart .quantity {
        display: inline-block;
        margin: 0 0.5em 0 0;
    }
}

/* Shop / category archive + home beer slider — centered product images with bottom spacing */
.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image,
.grafton-featured-product-slider.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image,
.grafton-featured-product-slider .bt_bb_content_slider_item ul.products li.product .btWooShopLoopItemInner .bt_bb_image {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5em;
    padding-bottom: 0.5em;
}

.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image a,
.grafton-featured-product-slider.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image a,
.grafton-featured-product-slider .bt_bb_content_slider_item ul.products li.product .btWooShopLoopItemInner .bt_bb_image a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image img,
.grafton-featured-product-slider.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image img,
.grafton-featured-product-slider .bt_bb_content_slider_item ul.products li.product .btWooShopLoopItemInner .bt_bb_image img {
    display: block;
    margin: 0 auto;
    max-width: 100%;
    max-height: 260px;
    width: auto;
    height: auto;
    object-fit: contain;
}

@media (max-width: 767px) {
    .woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image,
    .grafton-featured-product-slider.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image,
    .grafton-featured-product-slider .bt_bb_content_slider_item ul.products li.product .btWooShopLoopItemInner .bt_bb_image {
        margin-bottom: 1.25em;
    }

    .woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image img,
    .grafton-featured-product-slider.woocommerce ul.products li.product .btWooShopLoopItemInner .bt_bb_image img,
    .grafton-featured-product-slider .bt_bb_content_slider_item ul.products li.product .btWooShopLoopItemInner .bt_bb_image img {
        max-height: 220px;
    }
}

/* Sidebar Featured products widget — remove image border */
.btBox.widget_products .btImageTextWidgetImage a img {
    border: none;
}

/* —— Grafton address modals (checkout) —— */
.grafton-address-modal-wrap {
    z-index: 100010 !important;
}

body.modal-open:has(.grafton-address-modal-wrap.show) .modal-backdrop {
    z-index: 100009 !important;
}

body.modal-open:has(.grafton-address-modal-wrap.show) .bootstrap-select .dropdown-menu {
    z-index: 100020 !important;
}

.grafton-address-modal-wrap .modal-content.grafton-address-modal {
    color: #191919;
    background: #fff;
    border-radius: 0;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.grafton-address-modal-wrap .modal-dialog {
    max-width: 900px;
}

.grafton-address-modal-wrap .grafton-address-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    background: #fff;
}

.grafton-address-modal-wrap .grafton-address-modal__title {
    margin: 0;
    font-family: "Roboto Condensed", sans-serif;
    font-size: 1.1rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #191919;
}

.grafton-address-modal-wrap .modal-header .grafton-address-modal__close {
    padding: 0;
    margin: 0;
    width: 1.75rem;
    height: 1.75rem;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: #191919;
    font-size: 0 !important;
    line-height: 1;
    opacity: 0.6;
    box-shadow: none;
    float: none;
    text-shadow: none;
}

.grafton-address-modal-wrap .modal-header .grafton-address-modal__close::before {
    content: "\00d7" !important;
    font-family: inherit !important;
    font-weight: 300 !important;
    font-size: 1.75rem !important;
    line-height: 1 !important;
    display: block !important;
}

.grafton-address-modal-wrap .modal-header .grafton-address-modal__close:hover {
    opacity: 1;
    background: transparent;
}

.grafton-address-modal-wrap .grafton-address-modal__body {
    padding: 0;
    background: #fff;
}

.grafton-address-modal-wrap .grafton-address-modal__body.grafton-checkout-panel__body {
    padding: 0;
}

.grafton-address-modal-wrap #map,
.grafton-address-modal-wrap #edit_map {
    width: 100%;
    height: 240px;
}

@media (max-width: 575px) {
    .grafton-address-modal-wrap .modal-dialog {
        margin: 1rem;
        max-width: calc(100% - 2rem);
    }
}

.bootstrap-select .dropdown-menu li a,
.bootstrap-select .dropdown-menu li a span.text {
    color: #191919 !important;
}

.bootstrap-select .dropdown-menu li.active > a,
.bootstrap-select .dropdown-menu li a:hover,
.bootstrap-select .dropdown-menu li a:focus {
    background-color: #880516 !important;
    color: #fff !important;
}

.bootstrap-select .dropdown-menu li.active > a span.text,
.bootstrap-select .dropdown-menu li a:hover span.text,
.bootstrap-select .dropdown-menu li a:focus span.text {
    color: #fff !important;
}

.bootstrap-select .dropdown-toggle .filter-option-inner-inner {
    color: #191919;
}
