/* World Record Holder tee and mug on an approved record's certificate page (Views/Payment/Certificate.cshtml).
   The print layout below repeats the print-file renderer's (the paid queue's tools/merch-render.cjs, from
   plans/merch-personalized/scripts/render.cjs) in print-file pixels: same font, sizes, spacing and colours.
   merch-preview.js fits the title the way the renderer does and scales the layout into the photo's print area.
   Poppins: SIL Open Font License 1.1, see OFL.txt here; subset to the characters a title may use (RecordMerch.cs). */
@font-face {
    font-family: "RS Merch Poppins";
    font-style: normal;
    font-weight: 700;
    font-display: block;
    src: url("/site-static/merch/poppins-bold.woff2") format("woff2");
}

@font-face {
    font-family: "RS Merch Poppins";
    font-style: normal;
    font-weight: 600;
    font-display: block;
    src: url("/site-static/merch/poppins-semibold.woff2") format("woff2");
}

.merch {
    margin: 8px 0 24px;
}

.merch[hidden],
.merch-option[hidden],
.merch-note[hidden] {
    display: none;
}

.merch > h2 {
    font-size: 24px;
    font-weight: bold;
    line-height: 1.25;
    margin: 0 0 4px;
}

.merch-intro {
    font-size: 16px;
    line-height: 1.5;
    margin: 0 0 16px;
}

.merch-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

/* A square photo. The padding keeps the square in browsers without aspect-ratio. */
.merch-preview {
    position: relative;
    width: 100%;
    height: 0;
    padding-top: 100%;
    overflow: hidden;
    margin: 0 0 12px;
    background: #fff;
}

.merch-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    display: block;
}

/* The print area within the photo, in percent of the photo.
   Tee: Printful's front template for Bella+Canvas 3413 (3000 px; print area left 976, top 487, 1045 x 1393), cropped
   600x600+200+50 from its 1000 px image. Mug: the title side of the 2250 x 925 wrap (its left 840 px) on Printful's
   flat "handle on left" photo (1000 px; 0.496 px per print pixel, wrap x 0 at 395.7, y 0 at 327.4, measured against
   Printful's own mockup of the same print file), cropped 760x760+96+150. */
.merch-print {
    position: absolute;
    overflow: hidden;
}

.merch-preview-tee .merch-print {
    left: 20.889%;
    top: 18.722%;
    width: 58.056%;
    height: 77.389%;
}

.merch-preview-mug .merch-print {
    left: 39.434%;
    top: 23.342%;
    width: 54.821%;
    height: 60.374%;
}

/* The print file's own canvas, at print-file size until scaled. The resets give it the renderer's blank page, whatever
   the site's styles say. */
.merch-art {
    position: absolute;
    top: 0;
    left: 0;
    -webkit-transform-origin: 0 0;
    transform-origin: 0 0;
    visibility: hidden;
    font-style: normal;
    font-variant: normal;
    font-size: 16px;
    line-height: normal;
    letter-spacing: normal;
    word-spacing: normal;
    text-align: left;
    text-indent: 0;
    text-shadow: none;
    text-transform: none;
    white-space: normal;
    word-wrap: normal;
    overflow-wrap: normal;
    word-break: normal;
    -webkit-hyphens: manual;
    hyphens: manual;
}

.merch-art.is-ready {
    visibility: visible;
}

.merch-art[data-fit="tee"] {
    width: 1800px;
    height: 2400px;
}

.merch-art[data-fit="mug"] {
    width: 840px;
    height: 925px;
}

.merch-hl {
    font-family: "RS Merch Poppins";
    font-weight: 700;
    color: #FEE60E;
    text-align: center;
}

.merch-title {
    font-family: "RS Merch Poppins";
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
    text-align: center;
    line-height: 1.12;
    letter-spacing: .02em;
    text-wrap: balance;
}

.merch-tee-wrap {
    position: absolute;
    top: 0;
    left: 0;
    width: 1800px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.merch-tee-wrap .merch-hl {
    font-size: 290px;
    line-height: .93;
    letter-spacing: -2px;
}

.merch-tee-wrap .merch-title {
    width: 1440px;
    margin-top: 80px;
}

.merch-tee-wrap .merch-tee-logo {
    width: auto;
    height: 240px;
    max-width: none;
    margin-top: 90px;
}

.merch-mug-side {
    position: absolute;
    top: 0;
    left: 0;
    width: 840px;
    height: 925px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.merch-mug-side .merch-hl {
    font-size: 132px;
    line-height: .95;
    letter-spacing: -1px;
}

.merch-mug-side .merch-title {
    width: 760px;
    margin-top: 38px;
}

.merch-size {
    display: block;
    margin: 0 0 12px;
    font-size: 15px;
    font-weight: bold;
    max-width: none;
}

.merch-size span {
    display: block;
    margin: 0 0 4px;
}

.merch-size select {
    width: 100%;
    font-size: 16px;
    font-weight: normal;
    padding: 8px;
    border: 1px solid #bbb;
    border-radius: 4px;
    background: #fff;
    color: #121212;
}

@media (max-width: 760px) {
    .merch > h2 {
        font-size: 21px;
    }

    .merch-options {
        grid-template-columns: 1fr;
    }
}
