/* General Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Roboto", sans-serif;
    background-color: #f8f8f8;
    color: #333;
    line-height: 1.5;
}

/* Header styling */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background-color: #fff;
    border-bottom: 1px solid #ddd;
}

header h1 {
    font-family: "Playfair Display", serif;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
}

header nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

header nav a {
    text-decoration: none;
    color: #000;
}

/* Image Grid */
.image-grid {
    
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    padding: 20px;
}

/* Image Wrapper */
.image-wrapper {
    margin-top: 40px;
    position: relative;
    overflow: hidden;
    border: 2px solid #ddd;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    background-color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures the image fits its container */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.image-wrapper:hover img {
    transform: scale(1.05);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
}

/* Spacer */
.break {
    flex-basis: 100%;
    height: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .image-wrapper {
        width: 100%;
        height: auto;
    }

    .image-wrapper img {
        height: auto;
    }
}

.image-wrapper.rollover .hover-image {
    opacity: 0; /* Hover image is hidden initially */
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.3s ease;
    z-index: 2;
}

.image-wrapper.rollover:hover .default-image {
    opacity: 0; /* Hide default image on hover */
}

.image-wrapper.rollover:hover .hover-image {
    opacity: 1; /* Show hover image on hover */
}

/* Shop */
.site-title {
    color: inherit;
    text-decoration: none;
}

header nav a.active {
    text-decoration: underline;
    text-underline-offset: 4px;
}

.shop-page {
    background: #fff;
    min-height: 100vh;
    padding: 48px 20px 80px;
}

.shop-intro {
    max-width: 720px;
    margin: 0 auto 64px;
    text-align: center;
    font-size: 15px;
}

.shop-intro p + p {
    margin-top: 10px;
}

.product-grid {
    max-width: 1180px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 78px 60px;
    align-items: start;
}

.product-card {
    text-align: center;
}

.product-card img {
    display: block;
    width: 100%;
    height: auto;
    background: #fff;
}

.product-meta {
    padding-top: 16px;
}

.product-meta h2 {
    font: inherit;
    font-size: 14px;
    font-weight: 400;
    letter-spacing: 0.03em;
}

.product-meta p {
    font-size: 13px;
    margin-top: 3px;
}

.buy-button {
    display: inline-block;
    margin-top: 12px;
    padding: 7px 22px;
    color: #000;
    background: #fff;
    border: 1px solid #000;
    text-decoration: none;
    font-size: 13px;
    letter-spacing: 0.05em;
}

.buy-button:hover {
    background: #000;
    color: #fff;
}

.shop-footer {
    max-width: 760px;
    margin: 90px auto 0;
    text-align: center;
    font-size: 13px;
}

.shop-footer a {
    color: inherit;
}

.checkout-note[hidden] { display: none; }
.checkout-note {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(255,255,255,0.94);
    display: grid;
    place-items: center;
    padding: 20px;
}
.checkout-note-inner {
    width: min(440px, 100%);
    border: 1px solid #000;
    background: #fff;
    padding: 36px;
    text-align: center;
    position: relative;
}
.checkout-note-inner button {
    position: absolute;
    top: 7px;
    right: 10px;
    border: 0;
    background: transparent;
    font-size: 24px;
    cursor: pointer;
}
.checkout-note-inner .small {
    margin-top: 10px;
    font-size: 13px;
}

@media (max-width: 768px) {
    header {
        align-items: flex-start;
        gap: 14px;
    }
    header h1 {
        font-size: 19px;
    }
    header nav ul {
        gap: 12px;
        font-size: 13px;
    }
    .shop-page {
        padding-top: 32px;
    }
    .shop-intro {
        margin-bottom: 42px;
    }
    .product-grid {
        grid-template-columns: 1fr;
        gap: 58px;
    }
}

/* Basket / SumUp checkout */
.basket-link { border:0; background:transparent; font:inherit; cursor:pointer; padding:0; color:#000; }
.add-to-basket { cursor:pointer; font-family:inherit; }
.basket-panel[hidden] { display:none; }
.basket-panel { position:fixed; inset:0; z-index:3000; background:rgba(255,255,255,.94); overflow:auto; padding:20px; }
.basket-inner { width:min(560px,100%); margin:30px auto; border:1px solid #000; background:#fff; padding:36px; position:relative; }
.basket-inner h2,.basket-inner h3 { font:inherit; letter-spacing:.05em; font-weight:400; }
.basket-inner h2 { margin-bottom:22px; }
.basket-inner h3 { margin:28px 0 12px; font-size:13px; }
.basket-close { position:absolute; top:7px; right:10px; border:0; background:transparent; font-size:24px; cursor:pointer; }
.basket-row { display:grid; grid-template-columns:1fr auto auto; gap:12px; align-items:center; padding:9px 0; border-bottom:1px solid #ddd; font-size:13px; }
.qty-controls { display:flex; align-items:center; gap:8px; }
.qty-controls button { width:25px; height:25px; border:1px solid #000; background:#fff; cursor:pointer; }
.basket-totals { margin-top:20px; font-size:13px; }
.basket-totals p { display:flex; justify-content:space-between; margin-top:5px; }
.basket-grand { border-top:1px solid #000; padding-top:8px; margin-top:10px!important; }
#checkout-form input { display:block; width:100%; border:1px solid #aaa; background:#fff; padding:10px; margin:8px 0; font:inherit; font-size:13px; }
#checkout-form .small { font-size:12px; margin:8px 0 14px; }
.checkout-button { width:100%; border:1px solid #000; background:#000; color:#fff; padding:11px; font:inherit; font-size:13px; letter-spacing:.04em; cursor:pointer; }
.checkout-button:disabled { opacity:.55; cursor:wait; }
.checkout-error { margin-top:10px; font-size:13px; }
.empty-basket { font-size:13px; }
@media(max-width:768px){ .basket-inner{margin:0 auto;padding:30px 20px;} header nav ul{flex-wrap:wrap;} }

/* Responsive sizing patch — preserves the original composition while scaling to the browser */
html, body { max-width: 100%; overflow-x: hidden; }
main { width: 100%; }
.image-grid {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding-left: 0;
    padding-right: 0;
}
.image-wrapper {
    width: min(var(--w, 100%), 100%);
    max-width: 100%;
    height: auto !important;
    aspect-ratio: var(--ratio, auto);
    flex: 0 1 auto;
}
.image-wrapper > a {
    display: block;
    width: 100%;
    height: 100%;
}
.image-wrapper img {
    display: block;
    width: 100%;
    height: 100% !important;
    object-fit: contain;
}
.image-wrapper.rollover .hover-image {
    width: 100%;
    height: 100% !important;
    object-fit: contain;
}

.image-wrapper:hover img {
    transform: none;
}

/* Keep shop product photography uniform when rolling over to the original A3 artwork */
.product-card > img {
    width: 100%;
    aspect-ratio: 1 / 1;
    height: auto;
    object-fit: contain;
}
.product-grid {
    width: min(1180px, 100%);
}

@media (max-width: 900px) {
    header {
        padding: 16px;
        flex-wrap: wrap;
    }
    header nav { min-width: 0; }
    header nav ul { flex-wrap: wrap; row-gap: 8px; }
    .image-grid { width: calc(100% - 24px); gap: 20px; padding-top: 8px; }
    .image-wrapper { margin-top: 24px !important; }
    .shop-page { padding-left: 16px; padding-right: 16px; }
    .product-grid { gap: 48px 28px; }
}

@media (max-width: 640px) {
    header { display: block; }
    header h1 { margin-bottom: 12px; }
    header nav ul { gap: 10px 14px; }
    .image-grid { width: calc(100% - 20px); }
    .image-wrapper {
        width: 100%;
        max-width: 100%;
        margin-top: 18px !important;
    }
    .product-grid { grid-template-columns: 1fr; gap: 46px; }
    .shop-intro { margin-bottom: 36px; }
}
