/* ReplicaRegalia brand system — pulled from the live replicaregalia.com: Caudex/Open Sans
   (their actual Google Fonts), a forest-green + antique-gold heraldic palette grounded in the
   family coat of arms used in their own header, and a wax-seal red held in reserve for the one
   thing that should never blend in: the custom-commission call to action. */

:root {
    --rr-ink: #17231c;
    --rr-parchment: #f2ecda;
    --rr-parchment-deep: #e6dcbc;
    --rr-forest: #1e4634;
    --rr-forest-deep: #122c20;
    --rr-gold: #ad8a3f;
    --rr-gold-bright: #cda758;
    /* Gold for TEXT on parchment. --rr-gold is 2.7:1 there, below the 4.5:1 small text needs;
       this is 5.4:1. On forest backgrounds use --rr-gold-bright (4.7:1). */
    --rr-gold-text: #765b24;
    --rr-wax: #7a2426;
    --rr-wax-deep: #5e1a1c;
    --rr-hairline: #c9bc97;
    --rr-parchment-rgb: 242, 236, 218;
    --rr-ink-soft: #4a4638;   /* body text in tiles and captions */

    /* Bootstrap's own colour variables, so the components we do not restyle one by one — links,
       pagination, nav tabs, checked boxes, focus rings — use the theme instead of default blue. */
    --bs-primary: #1e4634;
    --bs-primary-rgb: 30, 70, 52;
    --bs-link-color: #1e4634;
    --bs-link-color-rgb: 30, 70, 52;
    --bs-link-hover-color: #122c20;
    --bs-link-hover-color-rgb: 18, 44, 32;
    --bs-focus-ring-color: rgba(30, 70, 52, .3);
    /* Muted text: Bootstrap's grey is 3.97:1 on parchment, short of 4.5:1. This warm grey is 5.9:1. */
    --bs-secondary-color: #575b52;
    --bs-secondary-color-rgb: 87, 91, 82;

    --rr-font-display: 'Caudex', Georgia, 'Times New Roman', serif;
    --rr-font-body: 'Open Sans', system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--rr-font-body);
    color: var(--rr-ink);
    background: var(--rr-parchment);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--rr-font-display);
    font-weight: 700;
    color: var(--rr-ink);
    letter-spacing: -0.01em;
}

a { color: var(--rr-forest); }
a:hover { color: var(--rr-forest-deep); }

::selection { background: var(--rr-gold); color: var(--rr-ink); }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ── Eyebrow / label utility (no third typeface — letterspaced Open Sans caps) ───────────── */
.rr-eyebrow {
    display: inline-block;
    font-family: var(--rr-font-body);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--rr-gold-text);
}
.rr-hero .rr-eyebrow,
.rr-section--forest .rr-eyebrow,
.rr-footer .rr-eyebrow,
.rr-header .rr-eyebrow { color: var(--rr-gold-bright); }

/* ── Shield rule — the recurring signature mark, a simple drawn shield, not the family crest ── */
.rr-shield-rule {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    margin: 0.9rem 0 1.6rem;
}
.rr-shield-rule::before,
.rr-shield-rule::after {
    content: "";
    flex: 1 1 auto;
    height: 1px;
    background: var(--rr-hairline);
}
.rr-shield-rule.rr-shield-rule--light::before,
.rr-shield-rule.rr-shield-rule--light::after {
    background: rgba(var(--rr-parchment-rgb), 0.35);
}
.rr-shield-rule svg { flex: 0 0 auto; display: block; }

/* ── Header / navbar ───────────────────────────────────────────────────────────────────── */
.rr-header {
    background: var(--rr-forest);
    border-bottom: 3px solid var(--rr-gold);
}
.rr-header .navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-family: var(--rr-font-display);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--rr-parchment) !important;
    letter-spacing: 0.02em;
}
.rr-header .navbar-brand img {
    height: 34px;
    width: auto;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.4));
}
.rr-header .nav-link {
    font-size: 0.88rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: rgba(var(--rr-parchment-rgb), 0.82) !important;
    padding: 0.5rem 0.85rem !important;
}
.rr-header .nav-link:hover,
.rr-header .nav-link.active {
    color: var(--rr-gold-bright) !important;
}
.rr-header .dropdown-menu {
    background: var(--rr-forest-deep);
    border: 1px solid var(--rr-gold);
    border-radius: 0.25rem;
}
.rr-header .dropdown-item {
    color: var(--rr-parchment);
}
.rr-header .dropdown-item:hover,
.rr-header .dropdown-item:focus {
    background: var(--rr-forest);
    color: var(--rr-gold-bright);
}
.rr-header .cart-count {
    background: var(--rr-wax) !important;
    color: var(--rr-parchment) !important;
}
.rr-header .navbar-toggler {
    border-color: var(--rr-gold);
}

/* ── Admin/Vendor dark navbar — used with the Bootstrap "navbar-dark" text-color helper, which
   only sets light text colors and assumes something else supplies the dark background. */
.bg-rr-dark {
    background-color: var(--rr-forest-deep) !important;
}

/* ── Subtle highlight tint — staff message bubbles, pinned notes. */
.bg-rr-light {
    background-color: var(--rr-parchment-deep) !important;
}

/* ── Buttons ────────────────────────────────────────────────────────────────────────────── */
.btn {
    font-weight: 600;
    letter-spacing: 0.03em;
    border-radius: 0.2rem;
}
/* Every state comes from Bootstrap's --bs-btn-* variables. Setting only background-color, as before,
   left pressed and keyboard-focused buttons Bootstrap blue — or, for the gold and wax buttons, with
   no background at all. */
.btn-primary {
    --bs-btn-color: var(--rr-parchment);
    --bs-btn-bg: var(--rr-forest);
    --bs-btn-border-color: var(--rr-forest);
    --bs-btn-hover-color: var(--rr-parchment);
    --bs-btn-hover-bg: var(--rr-forest-deep);
    --bs-btn-hover-border-color: var(--rr-forest-deep);
    --bs-btn-active-color: var(--rr-parchment);
    --bs-btn-active-bg: var(--rr-forest-deep);
    --bs-btn-active-border-color: var(--rr-forest-deep);
    --bs-btn-disabled-color: var(--rr-parchment);
    --bs-btn-disabled-bg: var(--rr-forest);
    --bs-btn-disabled-border-color: var(--rr-forest);
    --bs-btn-focus-shadow-rgb: 30, 70, 52;
}
.btn-outline-primary {
    --bs-btn-color: var(--rr-forest);
    --bs-btn-border-color: var(--rr-forest);
    --bs-btn-hover-color: var(--rr-parchment);
    --bs-btn-hover-bg: var(--rr-forest);
    --bs-btn-hover-border-color: var(--rr-forest);
    --bs-btn-active-color: var(--rr-parchment);
    --bs-btn-active-bg: var(--rr-forest-deep);
    --bs-btn-active-border-color: var(--rr-forest-deep);
    --bs-btn-disabled-color: var(--rr-forest);
    --bs-btn-disabled-border-color: var(--rr-forest);
    --bs-btn-focus-shadow-rgb: 30, 70, 52;
}
.btn-outline-secondary {
    --bs-btn-color: var(--rr-ink);
    --bs-btn-border-color: var(--rr-hairline);
    --bs-btn-hover-color: var(--rr-ink);
    --bs-btn-hover-bg: var(--rr-parchment-deep);
    --bs-btn-hover-border-color: var(--rr-hairline);
    --bs-btn-active-color: var(--rr-ink);
    --bs-btn-active-bg: var(--rr-hairline);
    --bs-btn-active-border-color: var(--rr-hairline);
    --bs-btn-focus-shadow-rgb: 201, 188, 151;
}
.btn-outline-dark {
    --bs-btn-color: var(--rr-ink);
    --bs-btn-border-color: var(--rr-ink);
    --bs-btn-hover-bg: var(--rr-ink);
    --bs-btn-hover-border-color: var(--rr-ink);
    --bs-btn-active-bg: var(--rr-ink);
    --bs-btn-active-border-color: var(--rr-ink);
}

/* The storefront's main action: browse, pay, check out. */
.btn-rr-gold {
    --bs-btn-color: var(--rr-ink);
    --bs-btn-bg: var(--rr-gold);
    --bs-btn-border-color: var(--rr-gold);
    --bs-btn-hover-color: var(--rr-ink);
    --bs-btn-hover-bg: var(--rr-gold-bright);
    --bs-btn-hover-border-color: var(--rr-gold-bright);
    --bs-btn-active-color: var(--rr-ink);
    --bs-btn-active-bg: var(--rr-gold-bright);
    --bs-btn-active-border-color: var(--rr-gold-bright);
    --bs-btn-disabled-color: var(--rr-ink);
    --bs-btn-disabled-bg: var(--rr-gold);
    --bs-btn-disabled-border-color: var(--rr-gold);
    --bs-btn-focus-shadow-rgb: 173, 138, 63;
}

/* Reserved for the one action that should read as urgent/singular: requesting a custom order. */
.btn-rr-wax {
    --bs-btn-color: var(--rr-parchment);
    --bs-btn-bg: var(--rr-wax);
    --bs-btn-border-color: var(--rr-wax);
    --bs-btn-hover-color: var(--rr-parchment);
    --bs-btn-hover-bg: var(--rr-wax-deep);
    --bs-btn-hover-border-color: var(--rr-wax-deep);
    --bs-btn-active-color: var(--rr-parchment);
    --bs-btn-active-bg: var(--rr-wax-deep);
    --bs-btn-active-border-color: var(--rr-wax-deep);
    --bs-btn-disabled-color: var(--rr-parchment);
    --bs-btn-disabled-bg: var(--rr-wax);
    --bs-btn-disabled-border-color: var(--rr-wax);
    --bs-btn-focus-shadow-rgb: 122, 36, 38;
}

/* Form focus, checked boxes and pagination: compiled into Bootstrap as blue, so restated here. */
.form-control:focus,
.form-select:focus,
.form-check-input:focus {
    border-color: #7f9a8b;
    box-shadow: 0 0 0 .25rem rgba(30, 70, 52, .25);
}
.form-check-input:checked {
    background-color: var(--rr-forest);
    border-color: var(--rr-forest);
}
.pagination {
    --bs-pagination-color: var(--rr-forest);
    --bs-pagination-hover-color: var(--rr-forest-deep);
    --bs-pagination-focus-color: var(--rr-forest-deep);
    --bs-pagination-focus-box-shadow: 0 0 0 .25rem rgba(30, 70, 52, .25);
    --bs-pagination-active-bg: var(--rr-forest);
    --bs-pagination-active-border-color: var(--rr-forest);
}
.nav-pills {
    --bs-nav-pills-link-active-bg: var(--rr-forest);
}

/* ── Hero ───────────────────────────────────────────────────────────────────────────────── */
.rr-hero {
    position: relative;
    overflow: hidden;
    background: var(--rr-forest);
    color: var(--rr-parchment);
    padding: 4.5rem 1.5rem 4rem;
    border-radius: 0;
}
.rr-hero__row {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2.5rem;
}
.rr-hero__crest {
    /* The family crest, its own column between the copy and Carl's photo. It used to sit behind
       the copy as a translucent overlay, where the lead paragraph ran over it and the red button
       covered its motto scroll. On mid-width screens there is no room for three columns, so it
       is left out there (below); on a phone it stacks in sequence (see the mobile block). */
    flex: 0 1 auto;
    width: clamp(150px, 18vw, 250px);
    height: auto;
    object-fit: contain;
    pointer-events: none;
}
@media (min-width: 768px) and (max-width: 991.98px) {
    .rr-hero__crest { display: none; }
}
.rr-hero__inner {
    max-width: 560px;
}
.rr-hero__photo {
    flex: 0 0 auto;
    max-width: 240px;
    width: 100%;
    height: auto;   /* the img's height attribute is only there to reserve space before it loads */
    border: 3px solid var(--rr-gold);
    box-shadow: 0 16px 32px -16px rgba(0, 0, 0, 0.5);
}
.rr-hero h1 {
    color: var(--rr-parchment);
    font-size: clamp(2.5rem, 5vw, 4rem);
    line-height: 1.05;
    margin-bottom: 1.1rem;
}
.rr-hero p.lead {
    color: rgba(var(--rr-parchment-rgb), 0.86);
    font-size: 1.1rem;
    max-width: 34rem;
}
.rr-hero .rr-hero-actions {
    margin-top: 1.75rem;
    display: flex;
    gap: 0.9rem;
    flex-wrap: wrap;
}

/* ── Section rhythm ─────────────────────────────────────────────────────────────────────── */
.rr-section { padding: 3.25rem 0; }
.rr-section--forest {
    background: var(--rr-forest);
    color: var(--rr-parchment);
}
.rr-section--forest h2 { color: var(--rr-parchment); }
.rr-section--forest p { color: rgba(var(--rr-parchment-rgb), 0.82); }

/* Break a section out of the Bootstrap .container it sits inside (Pages/Shared/_Layout.cshtml
   wraps @@RenderBody() in one) so hero/band sections can go full-bleed without restructuring the
   shared layout for every other page. */
.rr-bleed {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
}


/* ── Collection tiles (Knightly Orders / Historic & Unique / Bespoke) ─────────────────────── */
.rr-tile {
    display: block;
    position: relative;
    background: var(--rr-parchment-deep);
    border: 1px solid var(--rr-hairline);
    border-top: 3px solid var(--rr-gold);
    padding: 2rem 1.5rem;
    text-align: center;
    text-decoration: none;
    color: var(--rr-ink);
    height: 100%;
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}
.rr-tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px -12px rgba(23, 35, 28, 0.35);
    border-top-color: var(--rr-wax);
    color: var(--rr-ink);
}
.rr-tile h3 {
    font-size: 1.3rem;
    margin: 0.4rem 0 0.5rem;
}
.rr-tile p {
    color: var(--rr-ink-soft);
    font-size: 0.92rem;
    margin-bottom: 0;
}
.rr-tile svg { color: var(--rr-gold); }

/* ── Featured work strip (Achievements / Accessories / Public Displays) ───────────────────── */
.rr-work figure { margin: 0; }
.rr-work img {
    width: 100%;
    height: auto;   /* lets aspect-ratio win over the img's height attribute */
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border: 1px solid var(--rr-hairline);
}
/* A tall photo whose subject is at the top (the statue's face and collar), not its middle. */
.rr-work img.rr-work__img--top { object-position: 50% 6%; }
.rr-work figcaption {
    margin-top: 0.75rem;
}
.rr-work figcaption .rr-eyebrow { display: block; margin-bottom: 0.25rem; }

/* ── Testimonial ────────────────────────────────────────────────────────────────────────── */
.rr-testimonial {
    max-width: 46rem;
    margin: 0 auto;
    text-align: center;
}
.rr-testimonial blockquote {
    font-family: var(--rr-font-display);
    font-size: clamp(1.3rem, 2.4vw, 1.75rem);
    line-height: 1.45;
    color: var(--rr-ink);
    margin-bottom: 1.25rem;
}
.rr-testimonial cite {
    font-style: normal;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.8rem;
    color: var(--rr-forest);
}

/* ── Product cards / catalog ───────────────────────────────────────────────────────────────── */
.card {
    border: 1px solid var(--rr-hairline);
    border-radius: 0.2rem;
}
.product-card-img {
    height: 220px;
    object-fit: cover;
    background: var(--rr-parchment-deep);
}
.product-thumb {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 0.2rem;
}
.badge.bg-light {
    background-color: var(--rr-parchment-deep) !important;
    color: var(--rr-ink) !important;
    border-color: var(--rr-hairline) !important;
    font-weight: 600;
    letter-spacing: 0.02em;
}

/* ── Footer ─────────────────────────────────────────────────────────────────────────────── */
.rr-footer {
    background: var(--rr-forest-deep);
    color: rgba(var(--rr-parchment-rgb), 0.75);
    border-top: 3px solid var(--rr-gold);
}
.rr-footer a {
    color: rgba(var(--rr-parchment-rgb), 0.85);
    text-decoration: none;
}
.rr-footer a:hover { color: var(--rr-gold-bright); }
.rr-footer h6 {
    color: var(--rr-gold);
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
}
.rr-footer .form-control {
    background: rgba(var(--rr-parchment-rgb), 0.08);
    border-color: rgba(var(--rr-parchment-rgb), 0.25);
    color: var(--rr-parchment);
}
.rr-footer .form-control::placeholder { color: rgba(var(--rr-parchment-rgb), 0.5); }

@media (max-width: 767.98px) {
    .rr-hero { padding: 3rem 1.25rem 2.75rem; text-align: center; }
    .rr-hero__row { flex-direction: column; gap: 1.75rem; }
    .rr-hero__inner { max-width: none; }
    .rr-hero .rr-hero-actions { justify-content: center; }
    .rr-hero__photo { max-width: 180px; }
    /* Stacks between the copy and Carl's photo, centred, once the row is a single column. */
    .rr-hero__crest {
        width: 100%;
        max-width: 200px;
        margin: 0 auto;
    }
}

/* ── Moved out of style attributes and <style> blocks ─────────────────────────
   The Content-Security-Policy's style-src carries no 'unsafe-inline', so a style attribute in a
   view or in script-built markup is ignored by the browser. Sizes live here as classes instead;
   a width that depends on the data uses data-width (see wwwroot/js/behaviours.js). */

.u-w-60px { width: 60px; }
.u-w-64px { width: 64px; }
.u-w-70px { width: 70px; }
.u-w-90px { width: 90px; }
.u-w-110px { width: 110px; }
.u-w-120px { width: 120px; }
.u-w-130px { width: 130px; }
.u-w-150px { width: 150px; }
.u-w-1_5rem { width: 1.5rem; }
.u-w-5rem { width: 5rem; }
.u-w-7rem { width: 7rem; }
.u-w-8rem { width: 8rem; }
.u-w-16rem { width: 16rem; max-width: 100%; }
.u-w-9rem { width: 9rem; }
.u-h-14px { height: 14px; }
.u-minh-22px { min-height: 22px; }
.u-minh-44px { min-height: 44px; }
.u-minh-60px { min-height: 60px; }
.u-minw-9rem { min-width: 9rem; }
.u-minw-11rem { min-width: 11rem; }
.u-mw-9rem { max-width: 9rem; }
.u-mw-10rem { max-width: 10rem; }
.u-mw-12rem { max-width: 12rem; }
.u-mw-16rem { max-width: 16rem; }
.u-mw-26rem { max-width: 26rem; }
.u-mw-38rem { max-width: 38rem; }
.u-mw-320px { max-width: 320px; }
.u-mw-400px { max-width: 400px; }
.u-mw-480px { max-width: 480px; }
.u-mw-720px { max-width: 720px; }
.u-scroll-300 { max-height: 300px; overflow-y: auto; }
.u-ls-wide { letter-spacing: .4em; }
.u-gold { color: var(--rr-gold); }
.u-square { aspect-ratio: 1 / 1; height: auto; }
.u-thumb-96 { width: 96px; height: 96px; }
.u-thumb-72 { width: 72px; height: 72px; object-fit: cover; }

/* Registration honeypot: off-screen rather than display:none, which bots tend to skip. */
.rr-honeypot { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }

/* Production → Who's On What */
.person-dropzone { min-height: 54px; }
.work-chip { cursor: default; }
.can-assign .work-chip { cursor: grab; }
.can-assign .work-chip:active { cursor: grabbing; }
.sortable-ghost { opacity: .4; }

/* Drawflow canvases: Production → Process Map and the process-template builder. Drawflow's own
   stylesheet sets a fixed cyan box on ".drawflow .drawflow-node"; scoping under the canvas id
   beats it outright rather than fighting for selector specificity. */
#map-canvas,
#drawflow-canvas {
    width: 100%;
    border: 1px solid #dee2e6;
    border-radius: .375rem;
    position: relative;
    background-color: #fafaf7;
    background-image: radial-gradient(#ddd 1px, transparent 1px);
    background-size: 16px 16px;
}
#map-canvas { height: 680px; }
#drawflow-canvas { height: 650px; }
/* On a phone the canvas would be taller than the screen, trapping the scroll inside it. */
@media (max-width: 767.98px) {
    #map-canvas, #drawflow-canvas { height: 70vh; }
}
#map-canvas .drawflow-node,
#drawflow-canvas .drawflow-node { background: #fff; min-height: 0; border: none; border-radius: .375rem; box-shadow: 0 1px 4px rgba(0,0,0,.15); padding: 0; }
#map-canvas .drawflow-node { width: 240px; }
#drawflow-canvas .drawflow-node { width: 230px; }
#map-canvas .drawflow-node.selected,
#drawflow-canvas .drawflow-node.selected { background: #fff; box-shadow: 0 0 0 2px var(--bs-primary); }
#map-canvas .drawflow-node.critical-node-wrap { box-shadow: 0 0 0 2px var(--bs-danger), 0 1px 4px rgba(0,0,0,.15); }
.drawflow .connection .main-path { stroke: #9aa0a6; stroke-width: 3px; }
.map-node-inner { padding: .5rem; }
.palette-item { cursor: grab; }
.palette-item:active { cursor: grabbing; }
.workflow-node-inner { width: 100%; padding: .5rem; }
.workflow-node-inner.critical-node { outline: 2px solid var(--bs-danger); border-radius: .375rem; }
.component-chip { font-weight: normal; }

/* Admin sidebar: a column on desktop, a slide-in panel on phones (Bootstrap offcanvas-md). */
.sidebar {
    border-right: 1px solid var(--rr-hairline);
    min-height: calc(100vh - 56px);
}
/* The tint sits on the inner body: Bootstrap makes .offcanvas-md transparent (!important) at md
   and up, which wiped a background set on the nav itself. */
.sidebar .offcanvas-body {
    background: var(--rr-parchment-deep);
    display: block;
    padding: 0;
}
@media (min-width: 768px) {
    .sidebar.offcanvas-md { background-color: var(--rr-parchment-deep) !important; }
}
.sidebar .nav-link { color: var(--rr-ink); padding-top: .3rem; padding-bottom: .3rem; }
.sidebar .nav-link:hover { color: var(--rr-forest); }
.sidebar .nav-link.active {
    color: var(--rr-forest);
    font-weight: 600;
    background: rgba(30, 70, 52, .08);
    border-left: 3px solid var(--rr-forest);
}
@media (max-width: 767.98px) {
    .sidebar { min-height: 0; border-right: 0; }
    /* The open panel is screen-height; the link list scrolls inside it so the last links can be reached. */
    .sidebar .offcanvas-body { overflow-y: auto; padding-bottom: 1rem; }
}

/* ── Photo picker (product photos: camera, shrink, label) ─────────────────────────────────── */
.rr-photo-picker__files { flex: 1 1 16rem; width: auto; }
.rr-photo-list { display: grid; gap: 0.5rem; }
.rr-photo-item {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    padding: 0.5rem;
    border: 1px solid var(--rr-hairline);
    border-radius: 0.375rem;
}
.rr-photo-item > div { min-width: 0; }
.rr-photo-item__thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 0.25rem; flex: none; }
/* Molds, tools and materials: the cover in the lists, and each photo on the edit page. */
.rr-component-thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 0.25rem; flex: none; }
.rr-component-thumb--sm { width: 36px; height: 36px; vertical-align: middle; }
.rr-component-photo { width: 120px; height: 120px; object-fit: cover; border-radius: 0.25rem; display: block; }
.flex-none { flex: none; }
/* A name block beside a number or photo: lets long names and labels wrap inside it rather than
   pushing the row wider than a phone. */
.rr-name { min-width: 0; flex: 1 1 auto; overflow-wrap: anywhere; }
.rr-name-cell { min-width: 14rem; }
.rr-clamp-2, .rr-clamp-3 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; }
.rr-clamp-2 { -webkit-line-clamp: 2; line-clamp: 2; }
.rr-clamp-3 { -webkit-line-clamp: 3; line-clamp: 3; }
/* The amount box in a process step's component chip. */
.component-chip-qty { width: 4.5rem; padding: 0 0.25rem; border: 1px solid var(--bs-border-color); border-radius: 0.25rem; font: inherit; }
.rr-camera__view {
    display: block;
    width: 100%;
    max-height: 60vh;
    background: #000;
    border-radius: 0.375rem;
    transition: opacity 0.15s;
}
.rr-camera.is-flash .rr-camera__view { opacity: 0.3; }

/* Product photos: a thumbnail shows in the main spot when picked; the main one opens full size. */
.rr-gallery__main { cursor: zoom-in; }
.rr-gallery__thumb { display: inline-block; border-radius: 0.375rem; outline: 2px solid transparent; outline-offset: 2px; opacity: 0.75; transition: opacity 0.15s; }
.rr-gallery__thumb:hover, .rr-gallery__thumb:focus-visible { opacity: 1; }
.rr-gallery__thumb.is-current { opacity: 1; outline-color: var(--rr-gold-text); }

/* The shop's category panel: a tappable heading when folded. */
.rr-filter > summary { cursor: pointer; list-style-position: inside; }

@media (max-width: 767.98px) {
    /* The product photo stops at most of the screen, so the price and Add to cart show without scrolling past it. */
    .rr-gallery__main img, [data-gallery-main] img { max-height: 55vh; width: 100%; object-fit: contain; }
}
