.spcad-card-shell {
    --spcad-accent: #5b4bdb;
    --spcad-background: #f1f3f8;
    --spcad-outer-background: var(--spcad-background);
    --spcad-card: #fff;
    --spcad-text: #20242d;
    font-family: inherit;
    color: var(--spcad-text)
}

/* The shell is the area the outer background is painted on, so it is always the
   full width of whatever it sits in and is never narrowed by the card's width.
   The card's width is a cap on the card and not on this, which is what keeps a
   card with a width set looking like a card on a background rather than a strip
   of background with a card stacked on it. */
.spcad-card-shell {

    margin: 20px auto;
    padding: 24px;
    width: 100%;
    background: var(--spcad-outer-background)
}

/* The card fills the shell and is centred on it, so a card narrower than the
   space it is given sits in the middle of that space with the background showing
   equally on both sides. Filling rather than a fixed width is what keeps it
   inside a narrow column, a phone or a popup: the cap can only ever take width
   away, never push the card out of the space it is in. */
.spcad-card-shell>.spcad-profile-card {
    width: 100%;
    margin-left: auto;
    margin-right: auto
}

/* The default widths, for a card that was not given one. They sit on the card for
   the same reason a chosen width does: a default is a fact about the card, not
   about the space it has been put in. */
.spcad-card-shell.spcad-layout-vertical>.spcad-profile-card {
    max-width: 600px
}

.spcad-card-shell.spcad-layout-horizontal>.spcad-profile-card {
    max-width: 800px
}

.spcad-outer-background-no {
    padding: 0;
    background: transparent
}

.spcad-profile-card {
    position: relative;
    overflow: hidden;
    background: var(--spcad-card);
    color: var(--spcad-text);
    border-radius: 8px;
    box-shadow: 0 14px 38px rgba(18, 25, 38, .16);
    isolation: isolate
}

.spcad-cover {
    height: var(--spcad-cover-size, 112px);
    background: linear-gradient(135deg, var(--spcad-accent), color-mix(in srgb, var(--spcad-accent) 45%, #17141f));
    background-position: center;
    background-size: cover
}

.spcad-profile-content {
    padding: 0
}

.spcad-header-row {
    padding: 28px
}

.spcad-card-bio {
    padding: 28px;
}

.spcad-card-shell .spcad-profile-card.spcad-buttons-tight-yes .spcad-card-bio {
    padding-top: 0 !important;
}

/* The contact panel's button is pinned to the card's top left corner. Every rule
   that draws it is in one section at the end of this file, which is where it has
   to be: it has to outrank the spacing rules and the button design rules that are
   declared above it, and a rule that wins on order alone is a rule that loses the
   day somebody adds a new one in the middle. */

.spcad-avatar {
    display: grid;
    place-items: center;
    width: 96px;
    height: 96px;
    margin: -48px 0 15px;
    border: 4px solid var(--spcad-card);
    border-radius: 50%;
    overflow: hidden;
    background: var(--spcad-accent);
    color: #fff;
    font-weight: 700;
    font-size: 28px;
    letter-spacing: 0
}

.spcad-avatar img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover
}

.spcad-profile-heading h3 {
    margin: 0;
    font-size: 24px;
    line-height: 1.2;
    color: var(--spcad-text);
}

.spcad-role {
    margin: 0;
    color: var(--spcad-accent);
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 0 !important;
}

.spcad-bio {
    margin: 0;
    margin-bottom: 0 !important;
    margin-top: 0 !important;
    font-size: 14px;
    line-height: 1.6;
    color: var(--spcad-text);
}

.spcad-network-list,
.spcad-custom-list {
    display: grid;
    gap: 8px;
    box-sizing: border-box
}

/* When dividers are present the list is a plain block and the button runs carry
   the layout classes, so a divider can own the vertical space around it. */
.spcad-custom-list-mixed {
    display: block;
    gap: 0
}

/* A run reproduces the spacing the list used to provide on its own. */
.spcad-custom-run {
    display: grid;
    gap: 8px
}

.spcad-custom-run.spcad-custom-layout-horizontal {
    display: flex;
    flex-wrap: wrap
}

.spcad-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: var(--spcad-divider-top, 16px);
    margin-bottom: var(--spcad-divider-bottom, 16px);
    color: var(--spcad-divider-color, var(--spcad-text));
    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;
    text-transform: none;
    letter-spacing: 0
}

.spcad-divider::before,
.spcad-divider::after {
    content: "";
    height: 1px;
    background: currentColor;
    opacity: .28
}

.spcad-divider-align-left::before,
.spcad-divider-align-right::after {
    display: none
}

.spcad-divider-align-left::after,
.spcad-divider-align-right::before {
    flex: 1
}

.spcad-divider-align-center::before,
.spcad-divider-align-center::after {
    flex: 1
}

.spcad-divider-title {
    flex: 0 0 auto;
    max-width: 100%
}

.spcad-divider-style-uppercase .spcad-divider-title,
.spcad-divider-style-uppercase {
    text-transform: uppercase;
    letter-spacing: .06em
}

.spcad-divider-style-small .spcad-divider-title,
.spcad-divider-style-small {
    font-size: 11px
}

.spcad-divider-style-uppercase-small {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: 11px
}

/* No title and the line is hidden: the block is only there to create space. */
.spcad-divider-empty::before,
.spcad-divider-empty::after {
    display: none
}

/* -------------------------------------------------------------------------
   Embedded player block (YouTube, Spotify, Calendly, TikTok, Pinterest, Twitch)
   The toggle carries .spcad-custom-button and the wrapper carries the block
   design classes, so it inherits the chosen design, shape and colours. Only the
   full width behaviour and the panel are specific to this block.
------------------------------------------------------------------------- */
/* Always full width and always a plain block, so it is excluded from the row
   grid and from the wrapping flex row the layout classes would otherwise set
   up. The second selector keeps this winning over .spcad-custom-layout-*. */
.spcad-embed,
.spcad-custom-layout-horizontal.spcad-embed {
    display: block;
    width: 100%;
    /* The mixed list is a plain block, so these collapse with the neighbouring
       block margins. That reproduces the 8px the button grid provides, and a
       divider next to it still wins with its larger own margin. */
    margin: 8px 0;
    gap: 0;
    box-sizing: border-box
}

.spcad-embed:first-child {
    margin-top: 0
}

.spcad-embed:last-child {
    margin-bottom: 0
}

.spcad-embed .spcad-embed-toggle,
.spcad-custom-layout-horizontal.spcad-embed .spcad-embed-toggle {
    width: 100%;
    margin: 0;
    flex: none
}

.spcad-embed-head {
    margin: 0
}

.spcad-embed-chevron {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    font-size: 18px;
    margin-left: auto;
    transition: transform .15s ease-in-out
}

.spcad-embed-open .spcad-embed-chevron {
    transform: rotate(180deg)
}

.spcad-embed-panel[hidden] {
    display: none
}

.spcad-embed-panel {
    margin-top: 8px
}

/* -------------------------------------------------------------------------
   Shortcode block
   The panel here holds what a shortcode printed, so it has no frame, no fixed
   height and no background of its own: the shortcode owns all of that. Only the
   empty result needs styling, so the failure is visible rather than an empty
   box nobody can read.
   ------------------------------------------------------------------------- */
.spcad-embed-inline {
    /* Inline has no button above it, so the content starts at the top of the
       block rather than sitting below a heading. */
    margin-top: 8px
}

.spcad-shortcode-empty {
    margin: 0;
    padding: 12px 14px;
    border: 1px dashed color-mix(in srgb, var(--spcad-text) 28%, transparent);
    border-radius: 8px;
    color: color-mix(in srgb, var(--spcad-text) 70%, var(--spcad-card));
    font-size: 13px;
    line-height: 1.5
}

/* The live preview stands in for a shortcode's output, which it cannot run. It
   is drawn in the same tinted box the empty result uses so the block reads the
   same either way. */
.spcad-shortcode-preview {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px 14px;
    border: 1px dashed color-mix(in srgb, var(--spcad-text) 28%, transparent);
    border-radius: 8px;
    background: color-mix(in srgb, var(--spcad-text) 5%, transparent)
}

.spcad-shortcode-preview-tag {
    font-family: Consolas, Monaco, monospace;
    font-size: 13px;
    color: var(--spcad-text);
    word-break: break-word
}

.spcad-shortcode-preview-note {
    font-size: 12px;
    line-height: 1.5;
    color: color-mix(in srgb, var(--spcad-text) 65%, var(--spcad-card))
}

/* -------------------------------------------------------------------------
   WooCommerce product block
   The panel holds a product: its picture, its name, its price and a way to buy
   it. The picture sits above the text rather than beside it, because a product
   photograph is the thing being sold and a card is narrow.

   The price is styled rather than restyled: WooCommerce brought its own markup
   and its own sizes, and the only thing worth doing here is making sure the
   strikethrough on a sale price and the current price read as a pair rather than
   as two unrelated numbers. Overriding its typography would fight whichever
   theme styles WooCommerce on the rest of the site.
   ------------------------------------------------------------------------- */
/* A column is the default shape of the panel and the only one Default and Medium
   ever use, so it is declared once here rather than repeated per size. Small
   overrides it with a wrapping row below. */
.spcad-product {
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    /* The two colours of the area, each only set when one was chosen, so a blank
       field leaves the card's own text colour over no background. */
    background: var(--spcad-product-bg, transparent);
    color: var(--spcad-product-fg, var(--spcad-text));
    border-radius: 8px
}

/* Inset for when the area has a background of its own to sit on, and nothing
   else. There is deliberately no border here: a line of any colour drawn around
   a chosen background reads as a mistake, because the background is already the
   edge of the area. The padding is what makes it a box rather than a patch of
   colour, and on its own that is enough. */
.spcad-product-tinted {
    padding: 14px
}

.spcad-product-media {
    border-radius: 8px;
    overflow: hidden;
    background: color-mix(in srgb, var(--spcad-text) 8%, var(--spcad-card))
}

/* Default fills the panel. Medium and Small take the share the renderer resolved,
   so the proportion is the same on every card whatever the card is set to. */
.spcad-product-media {
    width: var(--spcad-product-image-scale, 100%);
    margin: 0 auto 10px
}

.spcad-product-image {
    display: block;
    width: 100%;
    /* Square, so a portrait and a landscape photograph of the same product sit
       on the card at the same size and the panel does not jump about as blocks
       are reordered. The picture is cropped rather than squashed. */
    aspect-ratio: 1 / 1;
    object-fit: cover;
    object-position: center
}

/* Small is the one size that changes the shape of the panel: at a third of the
   width there is no longer any point giving the photograph a row to itself, so
   it goes to the left and the name and the price come beside it.

   This is a grid rather than a wrapping flex row, and the reason is the button.
   With a flex row the button has to sit outside the photograph's row, which
   leaves it spanning the full width underneath both. A grid can place the three
   parts independently, which is what puts the button under the name and the
   price instead, in the same column as them. */
.spcad-product-size-small {
    display: grid;
    grid-template-columns: var(--spcad-product-image-scale, 30%) 1fr;
    align-items: start;
    column-gap: 12px
}

.spcad-product-size-small .spcad-product-media {
    grid-area: 1 / 1;
    /* The grid column is already the width the renderer resolved, so the media
       only has to fill it. */
    width: 100%;
    margin: 0
}

.spcad-product-size-small .spcad-product-body {
    grid-area: 1 / 2;
    margin-bottom: 10px;
    min-width: 0
}

/* Under the name and the price, in their column, which is the whole point of
   this size: the button belongs to the product, so it sits with the product
   rather than across the bottom of the whole panel. */
.spcad-product-size-small .spcad-product-actions {
    grid-area: 2 / 2
}

/* The one shape this size cannot describe: a product with no photograph at all.
   The grid above is built around the photograph being there, and with it missing
   there is nothing in the first column, so the name would sit in the second
   column with a gap to its left. A missing photograph also means the body is the
   first thing in the panel, which is the only thing that tells us this is the
   case, so the two rules below put the name and the button back across the full
   width, the same as the other two sizes.

   These come after the three above so they win on order where the specificity is
   the same, and the body's rule wins on specificity as well. */
.spcad-product-size-small > .spcad-product-body:first-child {
    grid-area: 1 / 1
}

.spcad-product-size-small > .spcad-product-actions {
    grid-area: 2 / 1
}

/* The row the button sits in. Flex so the button can be given an alignment of
   its own, and nothing else: no basis and no width, because in the column
   layout the panel already stretches it, and in the small layout the grid places
   it, where a flex basis would only fight the grid. */
.spcad-product-actions {
    display: flex
}

.spcad-product-body {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-bottom: 10px;
    min-width: 0
}

.spcad-product-title {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.35;
    color: inherit;
    /* A product name can be any length, and a name is the one thing on this panel
       that must never be cut off, so it wraps. */
    overflow-wrap: anywhere
}

.spcad-product-price {
    font-size: 14px;
    line-height: 1.4
}

/* A sale price arrives as the struck through original and the current price. The
   original is dimmed so the two read as one figure that has been reduced, and the
   current one is the one that carries the weight. */
.spcad-product-price del {
    margin-right: 5px;
    opacity: .55;
    font-size: 13px
}

.spcad-product-price ins {
    text-decoration: none;
    font-weight: 700
}

.spcad-product-note {
    font-size: 13px;
    line-height: 1.4;
    color: #b32d2e
}

/* The buy button and the view product link are both plain .spcad-custom-button,
   so they take the block design, shape and alignment from the classes the wrapper
   already carries, and neither is given a colour of its own anywhere. All they
   need is to fill the row, and for the two states a click puts them through. */
.spcad-product-buy,
.spcad-product-view {
    width: 100%
}

/* While the add to cart request is in flight the button says so and cannot be
   pressed again, since a second click would put a second one in the cart. */
.spcad-product-buy:disabled {
    cursor: progress;
    opacity: .7;
    pointer-events: none
}

.spcad-product-buying {
    position: relative;
    color: transparent
}

.spcad-product-buying::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 15px;
    height: 15px;
    margin: -7.5px 0 0 -7.5px;
    border: 2px solid currentColor;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spcad-product-spin .7s linear infinite
}

@keyframes spcad-product-spin {
    to {
        transform: rotate(360deg)
    }
}

@media (prefers-reduced-motion: reduce) {
    .spcad-product-buying::after {
        animation: none;
        border-top-color: currentColor;
        opacity: .6
    }
}

/* The one moment of feedback a failed add to cart gives, since the button keeps
   its own label so the reader can simply try again. */
.spcad-product-failed .spcad-product-actions {
    animation: spcad-product-shake .3s ease-in-out
}

@keyframes spcad-product-shake {
    0%, 100% { transform: translateX(0) }
    25% { transform: translateX(-4px) }
    75% { transform: translateX(4px) }
}

@media (prefers-reduced-motion: reduce) {
    .spcad-product-failed .spcad-product-actions {
        animation: none
    }
}

/* -------------------------------------------------------------------------
   WooCommerce coupon block
   The panel holds a note, the coupon and a link. The link is an ordinary
   .spcad-custom-button and so needs nothing here: it takes the block design,
   shape and alignment from the classes the wrapper already carries. Only the
   note and the coupon itself are styled below.

   The coupon reads --spcad-network, which the renderer sets on the wrapper so
   that it reaches both the coupon and the link underneath it, and the same
   --spcad-btn-* tokens a button declares. That is what lets the design rules
   and the theme/custom colour choice below be written once and land on the
   coupon exactly as they land on the block's own button.
   ------------------------------------------------------------------------- */
.spcad-coupon {
    --spcad-btn-color: var(--spcad-network);
    --spcad-btn-fill: var(--spcad-btn-color);
    --spcad-btn-fg: #fff;
    --spcad-btn-ink: var(--spcad-btn-color);
    --spcad-btn-stroke: var(--spcad-btn-color);
    /* The note's spacing, resolved server side to one of three paddings. Declared
       here so the stylesheet has its own answer for it, and the inline value the
       renderer prints simply wins over this one. */
    --spcad-coupon-note-pad: 25px;
    box-sizing: border-box
}

.spcad-custom-design-colors-theme .spcad-coupon {
    --spcad-btn-color: var(--spcad-accent);
    --spcad-btn-fill: var(--spcad-button-bg, var(--spcad-accent));
    --spcad-btn-fg: var(--spcad-button-text, #fff);
    --spcad-btn-ink: var(--spcad-button-bg, var(--spcad-accent));
    --spcad-btn-stroke: var(--spcad-accent)
}

.spcad-coupon-note {
    margin: 0 0 8px;
    /* The note's own three settings. The colours are only set on the wrapper when
       one was actually chosen for them, so a blank field leaves them unset and the
       note takes the card's own text colour over no background at all. That is the
       difference between "as the card is" and "as it was last time". */
    padding: var(--spcad-coupon-note-pad, 25px);
    border-radius: 6px;
    background: var(--spcad-coupon-note-bg, transparent);
    color: var(--spcad-coupon-note-fg, var(--spcad-text));
    font-size: 13px;
    line-height: 1.5
}

/* The coupon is the one part of the block that is not a button, so it is drawn
   as a coupon: a dashed edge and a fixed, wide, monospaced code, which is what
   makes the code readable and worth copying. It is position relative because the
   copy message hangs off its top edge. */
/* A fixed padding, because what this holds is a code and a code is always about
   the same size: the spacing setting belongs to the note above, which is text of
   any length.

   All three colours are fallbacks, not values. Each design rule below names the
   same properties with its own values behind them, so a colour picked for the
   coupon wins under every design while an unpicked one lets the design show
   through. That is what saves this from a specificity fight with the four design
   rules, which would otherwise need a class late in the file to outrank.

   The edge is named separately from the text because a coupon is read as one
   shape: leaving the dashed line at the design colour while the inside was
   repainted is the one way a custom coupon can still look like it came from the
   theme. It follows the text colour, or the background when only that is set. */
.spcad-coupon-ticket {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 13px 15px;
    border: 2px dashed var(--spcad-coupon-edge, var(--spcad-btn-stroke));
    border-radius: 8px;
    background: var(--spcad-coupon-bg, color-mix(in srgb, var(--spcad-btn-color) 10%, var(--spcad-card)));
    color: var(--spcad-coupon-fg, var(--spcad-text));
    transition: border-color .16s ease, background .16s ease
}

.spcad-custom-design-filled .spcad-coupon-ticket {
    border-color: var(--spcad-coupon-edge, var(--spcad-btn-fill));
    background: var(--spcad-coupon-bg, var(--spcad-btn-fill));
    color: var(--spcad-coupon-fg, var(--spcad-btn-text, var(--spcad-btn-fg)))
}

.spcad-custom-design-outline .spcad-coupon-ticket {
    background: var(--spcad-coupon-bg, transparent)
}

.spcad-custom-design-simple .spcad-coupon-ticket {
    border-style: solid;
    border-width: 0;
    border-left: 3px solid var(--spcad-coupon-edge, var(--spcad-btn-ink));
    background: var(--spcad-coupon-bg, color-mix(in srgb, var(--spcad-btn-ink) 10%, transparent))
}

.spcad-custom-design-modern .spcad-coupon-ticket {
    border: 1px dashed var(--spcad-coupon-edge, var(--spcad-btn-stroke));
    border-left: 4px solid var(--spcad-coupon-edge, var(--spcad-btn-stroke));
    background: var(--spcad-coupon-bg, color-mix(in srgb, var(--spcad-btn-color) 10%, var(--spcad-card)))
}

/* The shape follows the block, but not all the way: a circle shape would round a
   dashed coupon into a pill, so the ticket stops well short of it. */
.spcad-custom-shape-square .spcad-coupon-ticket {
    border-radius: 0
}

.spcad-custom-shape-rounded .spcad-coupon-ticket {
    border-radius: 6px
}

.spcad-custom-shape-circle .spcad-coupon-ticket {
    border-radius: 20px
}

.spcad-coupon-kicker {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .09em;
    text-transform: uppercase;
    opacity: .65
}

/* A real button, because activating it is the only way to ask for the code to be
   copied and a button is what a keyboard already knows how to activate. It is
   stripped of its own chrome so the ticket around it is what looks clickable. */
.spcad-coupon-code {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer
}

.spcad-coupon-code:focus-visible {
    outline: 2px solid var(--spcad-btn-stroke);
    outline-offset: 4px;
    border-radius: 3px
}

.spcad-coupon-code-text {
    /* Break anywhere rather than only at separators: a code is a single token
       and a long one has to wrap rather than push the panel sideways. */
    font-family: Consolas, Monaco, monospace;
    font-size: 19px;
    font-weight: 700;
    letter-spacing: .06em;
    word-break: break-all
}

.spcad-coupon-code-hint {
    flex: none;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .05em;
    text-transform: uppercase;
    opacity: .6;
    transition: opacity .16s ease
}

.spcad-coupon-code:hover .spcad-coupon-code-hint {
    opacity: 1
}

/* The copy message hangs off the top edge rather than sitting inside the coupon,
   so it never covers the code it just copied. It is the one thing in the block
   that appears on its own, and the ticket is what anchors it.

   Its own two colours follow the coupon's rather than the block's, for the same
   reason the border does: a solid pill in the block's colour sitting on top of a
   custom coloured coupon is the giveaway that only half the coupon was
   repainted. It is the inverse of the coupon, so it reads as a message about
   that coupon and not as a button from somewhere else. */
.spcad-coupon-toast {
    position: absolute;
    top: -10px;
    right: 14px;
    z-index: 2;
    max-width: calc(100% - 28px);
    padding: 5px 11px;
    border-radius: 999px;
    background: var(--spcad-coupon-toast-bg, var(--spcad-btn-fill));
    color: var(--spcad-coupon-toast-fg, var(--spcad-btn-text, var(--spcad-btn-fg)));
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity .16s ease, transform .16s ease, visibility .16s
}

.spcad-coupon-toast-on {
    opacity: 1;
    visibility: visible;
    transform: translateY(0)
}

/* The hint and the copy message say the same thing twice over, so the hint steps
   aside rather than sitting under the badge. */
.spcad-coupon-copied .spcad-coupon-code-hint {
    opacity: 0
}

/* Nothing else is restyled while copied. An earlier version also reset the
   ticket's border colour here, which looked like it was meant to be a flash and
   did nothing except snap a chosen border colour back to the design's the moment
   the coupon was clicked. The message is the only feedback this block gives. */

.spcad-coupon-link {
    margin-top: 8px
}

.spcad-embed-frame {
    position: relative;
    width: 100%;
    /* A video is 16:9. The Spotify, Calendly, TikTok and Twitch embeds ask for a
       fixed height instead, which is what data-spcad-kind on the frame selects. */
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    overflow: hidden;
    background: color-mix(in srgb, var(--spcad-text) 8%, var(--spcad-card))
}

.spcad-embed-frame[data-spcad-kind] {
    aspect-ratio: auto
}

.spcad-embed-frame[data-spcad-kind="track"] {
    height: 152px
}

.spcad-embed-frame[data-spcad-kind="episode"] {
    height: 232px
}

.spcad-embed-frame[data-spcad-kind="album"],
.spcad-embed-frame[data-spcad-kind="playlist"] {
    height: 352px
}

.spcad-embed-frame[data-spcad-kind="show"],
.spcad-embed-frame[data-spcad-kind="artist"] {
    height: 392px
}

/* The Calendly scheduler asks for one height whatever was linked, so the three
   kinds it can resolve to share a single rule. */
.spcad-embed-frame[data-spcad-kind="event"],
.spcad-embed-frame[data-spcad-kind="profile"],
.spcad-embed-frame[data-spcad-kind="routed"] {
    height: 700px
}

/* Same for TikTok, which is a different shape per kind. The creator card is
   short and bounded: measured, its content ends around 355px at the 340px the
   card gives it by default. A post is a portrait player with its caption
   underneath, which measures about 490px at that same width. Both leave room
   rather than cropping, since a cropped card would cut off its own button. */
.spcad-embed-frame[data-spcad-kind="creator"] {
    height: 420px
}

.spcad-embed-frame[data-spcad-kind="video"],
.spcad-embed-frame[data-spcad-kind="photo"] {
    height: 490px
}

/* The Twitch player is a portrait video with its channel bar under it. Measured
   at the card's own width, 378px squeezes the bar until the buttons are unusable
   and 700px leaves a band of dead space, so 600px is where the whole thing fits. */
.spcad-embed-frame[data-spcad-kind="channel"] {
    height: 600px
}

/* The Pinterest card is drawn by the plugin's own script from a feed, not framed,
   so the frame only has to give the card a box. It is a fixed height rather than a
   ratio because the card is a three across grid of fixed tiles, and the tiles
   hold their own shape whichever width the card ends up at. */
.spcad-embed-frame[data-spcad-kind="grid"] {
    height: 560px
}

.spcad-embed-frame[data-spcad-kind="pin"] {
    height: 560px
}

/* The card is laid out inside the frame, so the frame must not clip it and must
   not paint the empty box background behind it. */
.spcad-embed-frame.spcad-embed-grid {
    aspect-ratio: auto;
    background: none;
    overflow: visible
}

.spcad-pinterest {
    display: flex;
    flex-direction: column;
    gap: 10px;
    height: 100%
}

.spcad-pinterest-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    border: 1px solid color-mix(in srgb, var(--spcad-text) 12%, transparent);
    border-radius: 10px;
    background: color-mix(in srgb, var(--spcad-card) 92%, var(--spcad-text));
    text-decoration: none
}

.spcad-pinterest-avatar {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    background: color-mix(in srgb, var(--spcad-text) 8%, var(--spcad-card))
}

.spcad-pinterest-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0
}

.spcad-pinterest-name {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--spcad-text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap
}

.spcad-pinterest-stats {
    font-size: 12px;
    line-height: 1.25;
    color: color-mix(in srgb, var(--spcad-text) 65%, transparent)
}

.spcad-pinterest-follow {
    flex: 0 0 auto;
    margin-left: auto;
    padding: 7px 14px;
    border-radius: 999px;
    background: #e60023;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    text-decoration: none
}

.spcad-pinterest-follow:hover {
    background: #ad081b;
    color: #fff
}

.spcad-pinterest-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    min-height: 0
}

.spcad-pinterest-cell {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    border-radius: 8px;
    overflow: hidden;
    background: color-mix(in srgb, var(--spcad-text) 8%, var(--spcad-card));
    text-decoration: none
}

.spcad-pinterest-cell img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover
}

/* A single pin fills the width it is given, still on the card's own ratio. */
.spcad-pinterest-pin .spcad-pinterest-grid {
    grid-template-columns: 1fr;
    place-items: center
}

.spcad-pinterest-pin .spcad-pinterest-cell {
    width: 100%;
    max-width: 340px;
    aspect-ratio: 2 / 3
}

/* What a panel holds before the feed arrives, and what is left if it cannot be
   read. It is a link either way, so the block is never a dead box. */
.spcad-pinterest-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 0;
    margin: 0;
    padding: 16px;
    border: 1px dashed color-mix(in srgb, var(--spcad-text) 20%, transparent);
    border-radius: 10px;
    font-size: 13px;
    text-align: center;
    text-decoration: none
}

a.spcad-pinterest-empty {
    color: var(--spcad-text)
}

a.spcad-pinterest-empty:hover {
    border-style: solid
}

.spcad-pinterest-empty + .spcad-pinterest-empty {
    margin-top: 8px
}

.spcad-embed-frame iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0
}

/* No title but the line is shown: one continuous rule. The alignment variants
   are neutralised so the line always spans the whole width, and the flex gap is
   removed so the two halves do not render as separate segments. */
.spcad-divider-blank-line {
    gap: 0
}

.spcad-divider-blank-line::before,
.spcad-divider-blank-line::after {
    display: block;
    flex: 1 1 0
}

.spcad-divider-align-left.spcad-divider-blank-line::before,
.spcad-divider-align-right.spcad-divider-blank-line::after {
    display: none
}

.spcad-network-link,
.spcad-custom-button {
    --spcad-btn-color: var(--spcad-network);
    --spcad-btn-fill: var(--spcad-btn-color);
    --spcad-btn-fg: #fff;
    --spcad-btn-ink: var(--spcad-btn-color);
    --spcad-btn-stroke: var(--spcad-btn-color);
    --spcad-btn-icon: var(--spcad-btn-text, var(--spcad-network));
    box-sizing: border-box;
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 42px;
    padding: 9px 12px;
    background: color-mix(in srgb, var(--spcad-network) 10%, var(--spcad-card));
    border: 1px solid color-mix(in srgb, var(--spcad-network) 26%, transparent);
    border-left: 3px solid var(--spcad-network);
    border-radius: 4px;
    color: var(--spcad-btn-text, var(--spcad-text));
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: transform .16s ease, background .16s ease
}

.spcad-social-design-colors-theme .spcad-network-link,
.spcad-custom-design-colors-theme .spcad-custom-button {
    --spcad-btn-color: var(--spcad-accent);
    --spcad-btn-fill: var(--spcad-button-bg, var(--spcad-accent));
    --spcad-btn-fg: var(--spcad-button-text, #fff);
    --spcad-btn-ink: var(--spcad-button-bg, var(--spcad-accent));
    --spcad-btn-stroke: var(--spcad-accent)
}

.spcad-network-link:hover,
.spcad-custom-button:hover {
    transform: translateX(3px);
    background: color-mix(in srgb, var(--spcad-network) 17%, var(--spcad-card));
    color: var(--spcad-text)
}

.spcad-button-disabled {
    cursor: default;
    pointer-events: none
}

/* Icon and image size. One class on each list sets the single custom property
   every icon, image and icon only button reads, so the two sections can never
   disagree and no per button inline styles are needed. Default is the original
   19px, which is also the fallback for anything outside a sized list. */
.spcad-social-icons-medium,
.spcad-custom-icons-medium {
    --spcad-icon-size: 24px
}

.spcad-social-icons-large,
.spcad-custom-icons-large {
    --spcad-icon-size: 32px
}

.spcad-social-icons-xlarge,
.spcad-custom-icons-xlarge {
    --spcad-icon-size: 40px
}

.spcad-network-svg {
    flex: 0 0 var(--spcad-icon-size, 19px);
    width: var(--spcad-icon-size, 19px);
    height: var(--spcad-icon-size, 19px);
    color: var(--spcad-icon-color, var(--spcad-network));
    fill: var(--spcad-icon-color, var(--spcad-network))
}

/* A block image sits in the same slot as the icon, so it is sized to match
   .spcad-network-svg exactly and rounded into a circle. */
.spcad-custom-image {
    display: block;
    flex: 0 0 var(--spcad-icon-size, 19px);
    width: var(--spcad-icon-size, 19px);
    height: var(--spcad-icon-size, 19px);
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
    background: color-mix(in srgb, var(--spcad-network) 14%, transparent)
}

.spcad-network-fallback {
    display: grid;
    place-items: center;
    width: var(--spcad-icon-size, 19px);
    height: var(--spcad-icon-size, 19px);
    border-radius: 50%;
    background: var(--spcad-network);
    color: #fff;
    font-size: 11px
}

/* The horizontal card's own default width is set with the other defaults, on the
   card inside the shell, so there is no width left to say here. */
.spcad-layout-horizontal .spcad-profile-card {
    display: grid;
    grid-template-columns: var(--spcad-cover-size, 200px) 1fr
}

.spcad-layout-horizontal .spcad-cover {
    grid-row: 1 / 3;
    height: auto;
    min-height: 100%;
    background-color: var(--spcad-accent)
}

.spcad-layout-horizontal .spcad-header-row {
    padding-top: 28px
}

.spcad-layout-horizontal .spcad-avatar {
    position: absolute;
    top: 27px;
    left: 151px;
    margin: 0
}

.spcad-layout-horizontal .spcad-network-list {
    grid-template-columns: repeat(2, minmax(0, 1fr))
}

@media(max-width:600px) {
    .spcad-card-shell {
        padding: 14px
    }

    .spcad-layout-horizontal .spcad-profile-card {
        display: block
    }

    .spcad-layout-horizontal .spcad-cover {
        height: var(--spcad-cover-size, 112px);
        min-height: 0;
        background-image: linear-gradient(135deg, var(--spcad-accent), #17141f) !important
    }

    .spcad-layout-horizontal .spcad-avatar {
        position: relative;
        top: auto;
        left: auto;
        margin: -48px 0 15px
    }

    .spcad-layout-horizontal .spcad-header-row {
        padding-top: 0
    }

    .spcad-layout-horizontal .spcad-network-list {
        grid-template-columns: 1fr
    }
}

.spcad-header-row {
    display: block
}

.spcad-header-compact .spcad-cover {
    height: var(--spcad-cover-size, 64px);
    background-size: cover;
}

.spcad-header-compact .spcad-header-row {
    display: flex;
    align-items: center;
    gap: 14px
}

.spcad-header-compact .spcad-avatar {
    flex: 0 0 auto;
    margin: -34px 0 0
}

.spcad-header-compact .spcad-profile-heading {
    padding-top: 12px
}

.spcad-header-compact .spcad-bio {
    margin-top: 22px
}

.spcad-header-row {
    background: var(--spcad-header-background, transparent)
}

.spcad-header-align-center .spcad-header-row {
    text-align: center
}

.spcad-header-align-right .spcad-header-row {
    text-align: right
}

.spcad-header-align-center:not(.spcad-cover-no) .spcad-avatar {
    margin: -48px auto 15px
}

.spcad-header-align-right:not(.spcad-cover-no) .spcad-avatar {
    margin: -48px 0 15px auto
}

.spcad-header-align-center.spcad-cover-no .spcad-avatar {
    margin: 0 auto 15px
}

.spcad-header-align-right.spcad-cover-no .spcad-avatar {
    margin: 0 0 15px auto
}

.spcad-header-compact.spcad-header-align-center .spcad-header-row {
    justify-content: center;
    text-align: left
}

.spcad-header-compact.spcad-header-align-right .spcad-header-row {
    justify-content: flex-end;
    text-align: left
}

.spcad-bio-align-center .spcad-bio {
    text-align: center
}

.spcad-bio-align-right .spcad-bio {
    text-align: right
}

.spcad-cover-no .spcad-header-row {
    padding: 28px;
}

.spcad-cover-no .spcad-card-bio {
    padding: 28px;
}

.spcad-cover-no .spcad-avatar {
    margin: 0 0 15px
}

.spcad-cover-no.spcad-header-compact .spcad-avatar {
    margin: 0
}

.spcad-cover-no.spcad-header-compact .spcad-profile-heading {
    padding-top: 0;
    width: 100%;
}

.spcad-cover-no.spcad-avatar-size-smaller .spcad-avatar,
.spcad-cover-no.spcad-avatar-size-bigger .spcad-avatar {
    margin-top: 0;
    margin-bottom: 15px
}

.spcad-layout-horizontal .spcad-profile-card.spcad-cover-no {
    display: block
}

.spcad-layout-horizontal .spcad-cover-no .spcad-avatar {
    position: relative;
    top: auto;
    left: auto;
    margin: 0 0 15px
}

.spcad-layout-horizontal .spcad-cover-no.spcad-header-compact .spcad-avatar {
    margin: 0
}

.spcad-layout-horizontal .spcad-header-compact .spcad-avatar {
    position: relative;
    top: auto;
    left: auto;
    margin: -34px 0 0
}

.spcad-layout-horizontal .spcad-profile-card:not(.spcad-header-compact) .spcad-profile-content {
    padding-left: 30px;
}

.spcad-avatar-rounded .spcad-avatar {
    border-radius: 12px
}

.spcad-avatar-square .spcad-avatar {
    border-radius: 0
}

.spcad-avatar-size-smaller .spcad-avatar {
    width: 72px;
    height: 72px;
    margin-top: -48px;
    font-size: 21px
}

.spcad-avatar-size-bigger .spcad-avatar {
    width: 124px;
    height: 124px;
    margin-top: -62px;
    font-size: 34px
}

.spcad-header-compact.spcad-avatar-size-smaller .spcad-avatar {
    margin-top: -26px
}

.spcad-header-compact.spcad-avatar-size-bigger .spcad-avatar {
    margin-top: -48px
}

.spcad-card-shadow-tiny {
    box-shadow: 0 3px 10px rgba(18, 25, 38, .12)
}

.spcad-card-shadow-bigger {
    box-shadow: 0 24px 58px rgba(18, 25, 38, .36)
}

.spcad-card-shadow-none {
    box-shadow: none
}

.spcad-card-shape-square {
    border-radius: 0
}

.spcad-card-shape-circle {
    border-radius: 50px
}

.spcad-social-layout-horizontal,
.spcad-custom-layout-horizontal {
    display: flex;
    flex-wrap: wrap;
    gap: 8px
}

.spcad-social-layout-horizontal .spcad-network-link {
    flex: 1 1 auto
}

.spcad-custom-layout-horizontal .spcad-custom-button {
    flex: 1 1 auto
}

/* An icon only button is a square around its icon: the same 19px + 25px that
   gave 44px at the default size, so a larger icon grows the button with it. */
.spcad-social-type-icon,
.spcad-custom-type-icon {
    justify-content: center;
    min-height: calc(var(--spcad-icon-size, 19px) + 25px);
    padding: 9px
}

.spcad-social-layout-horizontal .spcad-social-type-icon {
    flex: 0 0 calc(var(--spcad-icon-size, 19px) + 25px);
    width: calc(var(--spcad-icon-size, 19px) + 25px)
}

.spcad-custom-layout-horizontal .spcad-custom-type-icon {
    flex: 0 0 calc(var(--spcad-icon-size, 19px) + 25px);
    width: calc(var(--spcad-icon-size, 19px) + 25px)
}

.spcad-social-type-text,
.spcad-custom-type-text {
    justify-content: center
}

.spcad-social-design-modern .spcad-network-link,
.spcad-custom-design-modern .spcad-custom-button {
    border: 1px solid color-mix(in srgb, var(--spcad-network) 26%, transparent);
    border-left: 3px solid var(--spcad-network);
    background: color-mix(in srgb, var(--spcad-network) 10%, var(--spcad-card));
    color: var(--spcad-btn-text, var(--spcad-text));
    --spcad-btn-icon: var(--spcad-btn-text, var(--spcad-network))
}

.spcad-social-design-filled .spcad-network-link,
.spcad-custom-design-filled .spcad-custom-button {
    border: 1px solid var(--spcad-btn-fill);
    background: var(--spcad-btn-fill);
    color: var(--spcad-btn-text, var(--spcad-btn-fg));
    --spcad-btn-icon: var(--spcad-btn-text, var(--spcad-btn-fg))
}

.spcad-social-design-filled .spcad-network-link:hover,
.spcad-custom-design-filled .spcad-custom-button:hover {
    background: color-mix(in srgb, var(--spcad-btn-fill) 88%, #000);
    color: var(--spcad-btn-text, var(--spcad-btn-fg))
}

.spcad-social-design-outline .spcad-network-link,
.spcad-custom-design-outline .spcad-custom-button {
    border: 2px solid var(--spcad-btn-stroke);
    background: transparent;
    color: var(--spcad-btn-text, var(--spcad-btn-stroke));
    --spcad-btn-icon: var(--spcad-btn-text, var(--spcad-btn-stroke))
}

.spcad-social-design-outline .spcad-network-link:hover,
.spcad-custom-design-outline .spcad-custom-button:hover {
    background: color-mix(in srgb, var(--spcad-btn-stroke) 12%, transparent);
    color: var(--spcad-btn-text, var(--spcad-btn-stroke))
}

.spcad-social-design-simple .spcad-network-link,
.spcad-custom-design-simple .spcad-custom-button {
    border: 0;
    background: transparent;
    color: var(--spcad-btn-text, var(--spcad-btn-ink));
    --spcad-btn-icon: var(--spcad-btn-text, var(--spcad-btn-ink))
}

.spcad-social-design-simple .spcad-network-link:hover,
.spcad-custom-design-simple .spcad-custom-button:hover {
    background: color-mix(in srgb, var(--spcad-btn-ink) 10%, transparent);
    color: var(--spcad-btn-text, var(--spcad-btn-ink))
}

.spcad-social-design-filled .spcad-network-svg,
.spcad-custom-design-filled .spcad-custom-button .spcad-network-svg,
.spcad-social-design-outline .spcad-network-svg,
.spcad-custom-design-outline .spcad-custom-button .spcad-network-svg,
.spcad-social-design-simple .spcad-network-svg,
.spcad-custom-design-simple .spcad-custom-button .spcad-network-svg {
    --spcad-icon-color: var(--spcad-btn-icon)
}

.spcad-social-design-filled .spcad-network-fallback,
.spcad-custom-design-filled .spcad-custom-button .spcad-network-fallback {
    background: var(--spcad-btn-fg);
    color: var(--spcad-btn-fill)
}

.spcad-social-design-outline .spcad-network-fallback,
.spcad-custom-design-outline .spcad-custom-button .spcad-network-fallback,
.spcad-social-design-simple .spcad-network-fallback,
.spcad-custom-design-simple .spcad-custom-button .spcad-network-fallback {
    background: var(--spcad-btn-icon);
    color: var(--spcad-card)
}

.spcad-social-design-filled .spcad-network-fallback,
.spcad-custom-design-filled .spcad-custom-button .spcad-network-fallback,
.spcad-social-design-outline .spcad-network-fallback,
.spcad-custom-design-outline .spcad-custom-button .spcad-network-fallback,
.spcad-social-design-simple .spcad-network-fallback,
.spcad-custom-design-simple .spcad-custom-button .spcad-network-fallback {
    box-shadow: 0 0 0 2px var(--spcad-card)
}

.spcad-social-shape-square .spcad-network-link {
    border-radius: 0
}

.spcad-custom-shape-square .spcad-custom-button {
    border-radius: 0
}

.spcad-social-shape-rounded .spcad-network-link {
    border-radius: 6px
}

.spcad-custom-shape-rounded .spcad-custom-button {
    border-radius: 6px
}

.spcad-social-shape-circle .spcad-network-link {
    border-radius: 999px
}

.spcad-custom-shape-circle .spcad-custom-button {
    border-radius: 999px
}

.spcad-social-shape-circle .spcad-social-type-icon,
.spcad-custom-shape-circle .spcad-custom-type-icon {
    border-radius: 50%
}

.spcad-buttons-align-left:not(.spcad-social-layout-horizontal) .spcad-network-link,
.spcad-custom-align-left:not(.spcad-custom-layout-horizontal) .spcad-custom-button {
    justify-content: flex-start
}

.spcad-buttons-align-center:not(.spcad-social-layout-horizontal) .spcad-network-link,
.spcad-custom-align-center:not(.spcad-custom-layout-horizontal) .spcad-custom-button {
    justify-content: center
}

.spcad-buttons-align-right:not(.spcad-social-layout-horizontal) .spcad-network-link,
.spcad-custom-align-right:not(.spcad-custom-layout-horizontal) .spcad-custom-button {
    justify-content: flex-start;
    flex-direction: row-reverse
}

.spcad-social-layout-horizontal.spcad-buttons-align-center {
    justify-content: center
}

.spcad-custom-layout-horizontal.spcad-custom-align-center {
    justify-content: center
}

.spcad-social-layout-horizontal.spcad-buttons-align-right {
    justify-content: flex-end
}

.spcad-custom-layout-horizontal.spcad-custom-align-right {
    justify-content: flex-end
}

.spcad-social-layout-horizontal.spcad-buttons-align-center .spcad-network-link,
.spcad-social-layout-horizontal.spcad-buttons-align-right .spcad-network-link {
    flex: 0 0 auto
}

.spcad-custom-layout-horizontal.spcad-custom-align-center .spcad-custom-button,
.spcad-custom-layout-horizontal.spcad-custom-align-right .spcad-custom-button {
    flex: 0 0 auto
}

@media(max-width:600px) {
    .spcad-layout-horizontal .spcad-header-compact .spcad-avatar {
        margin-top: -34px
    }

    .spcad-social-layout-horizontal .spcad-network-link:not(.spcad-social-type-icon) {
        flex-basis: calc(50% - 4px)
    }

    .spcad-custom-layout-horizontal .spcad-custom-button:not(.spcad-custom-type-icon) {
        flex-basis: calc(50% - 4px)
    }
}

.spcad-popup {
    position: fixed;
    inset: 0;
    z-index: 999998;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box
}

.spcad-popup.spcad-popup-visible {
    display: flex
}

.spcad-popup-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(13, 17, 26, .55)
}

.spcad-popup-window {
    position: relative;
    max-width: calc(100vw - 40px);
    max-height: 90vh;
    animation: spcad-popup-in .24s ease-out
}

.spcad-popup-window .spcad-card-shell {
    margin: 0
}

.spcad-popup-close {
    position: absolute;
    top: -14px;
    right: -14px;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    background: var(--spcad-text);
    color: var(--spcad-card);
    font-size: 22px;
    line-height: 1;
    box-shadow: 0 2px 10px rgba(13, 17, 26, .28);
    transition: transform .16s ease;
    box-sizing: border-box
}

.spcad-popup-close span {
    text-transform: uppercase;
    font-size: 18px;
}


.spcad-popup-close:focus {
    outline: 2px solid var(--spcad-text);
    outline-offset: 2px
}

body.spcad-popup-open {
    overflow: hidden
}

@keyframes spcad-popup-in {
    from {
        opacity: 0;
        transform: translateY(12px) scale(.98)
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1)
    }
}

@media(max-width:600px) {
    .spcad-popup {
        padding: 12px
    }

    .spcad-popup-window {
        max-width: calc(100vw - 24px);
        max-height: 94vh
    }

    /* The card needs nothing here for a narrow screen. It fills the window and is
       only ever capped, so on a phone it is the window that decides the width. */

    .spcad-popup-close {
        top: -12px;
        right: -6px
    }
}

.spcad-profile-heading h3 {
    font-family: var(--spcad-font-name-family, inherit);
    font-size: var(--spcad-font-name-size, 24px);
    font-weight: var(--spcad-font-name-weight, 700)
}

/* The initials that stand in for a missing picture are that person's name, so
   they are set in the name font: the same one the title beside them is in.
   Without this they inherit from the page instead, which on a card printed on
   its own, with the theme's own stylesheet left out, is the browser's default
   serif and not a font anybody chose.

   The family only. The size and the weight stay the avatar's own, because they
   are not a piece of running text that has to read at a normal size: they are
   two letters in a circle, and a title set at 300 would leave them looking
   weightless rather than like a name. */
.spcad-avatar {
    font-family: var(--spcad-font-name-family, inherit)
}

.spcad-role {
    font-family: var(--spcad-font-role-family, inherit);
    font-size: var(--spcad-font-role-size, 14px);
    font-weight: var(--spcad-font-role-weight, 700)
}

.spcad-bio {
    font-family: var(--spcad-font-bio-family, inherit);
    font-size: var(--spcad-font-bio-size, 14px);
    font-weight: var(--spcad-font-bio-weight, 400)
}

.spcad-network-link,
.spcad-custom-button {
    font-family: var(--spcad-font-buttons-family, inherit);
    font-size: var(--spcad-font-buttons-size, 14px);
    font-weight: var(--spcad-font-buttons-weight, 600);
    text-decoration: none !important;
}

/* The credit under the buttons. A text link and nothing more.

   It wears the button's own two colours: its background is the button
   background and its text is the button text. Those are the one pair on the card
   that already works together, because the person who set them set them to be
   readable against each other. An earlier version wore the accent on a plate of
   the card colour, which is a pair nobody chose as a pair and can come out
   unreadable on a dark card with a light accent or the other way round.

   Centred because it is a footnote, not a button, and a footnote reads better
   centred under a column of buttons than hung off one of its edges. Small because
   it is not the point of the card, and in the bio font because that is the body
   text of the card. */
.spcad-badge {
    margin: 0;
    padding: 0 28px 28px;
    text-align: center;
    font-family: var(--spcad-font-bio-family, inherit);
    font-size: 11px;
    line-height: 1.5
}

.spcad-badge a,
.spcad-badge a:link {
    display: inline-block;
    padding: 2px 6px;
    border-radius: 3px;
    background: var(--spcad-button-bg, var(--spcad-accent));
    color: var(--spcad-button-text, #fff);
    text-decoration: none
}

/* Both colours are stated again on every state the link can be in, and they are
   the same colours each time. Two things are being defended against here, and the
   second is the reason the rule exists at all.

   A theme's own link rules are usually written as a bare a:hover and a bare
   a:visited, which are exactly as specific as a bare .spcad-badge a: one class
   against one pseudo class, one type against one type. Nothing in the cascade then
   separates them except the order the two stylesheets happen to be printed in,
   and a theme loaded after this one wins. That is how a card ends up with a
   footnote in the theme's link colour on hover, sitting on the card's button
   colour where that colour was never chosen to be readable. Saying both colours
   on the hover and visited states as well puts the rule at one extra class, which
   is enough to beat a:hover outright whatever order the files are in. The
   background is repeated for the same reason: a theme is free to put one on a
   hover, and a footnote that changes colour under the pointer reads as a fault.

   The second is this stylesheet itself: the other link rules in it drop
   text-decoration with !important, and without the same insurance here a theme
   rule would win that too. The underline is kept on hover because it is the only
   thing that changes, and it is how the link says it is a link. */
.spcad-badge a:visited,
.spcad-badge a:hover,
.spcad-badge a:active,
.spcad-badge a:focus {
    background: var(--spcad-button-bg, var(--spcad-accent));
    color: var(--spcad-button-text, #fff)
}

.spcad-badge a:hover,
.spcad-badge a:focus {
    text-decoration: underline;
    text-underline-offset: 2px
}

/* The ring is the button's own text colour, so it is the one thing on the card
   guaranteed to be visible against the plate it is drawn around. */
.spcad-badge a:focus-visible {
    outline: 2px solid var(--spcad-button-text, #fff);
    outline-offset: 2px
}

/* No top padding at all. The space above the credit is the card's own bottom
   padding on the bio block, or the header row's own padding when there is no
   cover, and adding more on top of that is what pushed the credit away from the
   card. The bottom padding is the card's last edge and is still needed, and it
   follows the card's spacing setting like everything else. */
.spcad-spacing-smaller .spcad-badge {
    padding-bottom: 20px
}

.spcad-spacing-bigger .spcad-badge {
    padding-bottom: 36px
}

.spcad-spacing-smaller .spcad-header-row,
.spcad-spacing-smaller .spcad-card-bio,
.spcad-spacing-smaller.spcad-cover-no .spcad-header-row,
.spcad-spacing-smaller.spcad-cover-no .spcad-card-bio {
    padding: 15px
}

.spcad-spacing-bigger .spcad-header-row,
.spcad-spacing-bigger .spcad-card-bio,
.spcad-spacing-bigger.spcad-cover-no .spcad-header-row,
.spcad-spacing-bigger.spcad-cover-no .spcad-card-bio {
    padding: 40px
}

/* --------------------------------------------------------------------------
   The two corner buttons: the contact card on the left, the share button on
   the right.

   Last in the file on purpose. Two families of rules above are written to be
   overridden: the spacing rules that set the header row's padding, and the four
   button designs, two of which are transparent. This section has to come after
   both to win on order, and saying so at the top of it is cheaper than the four
   !important declarations it would otherwise take.

   One block of rules draws both of them, and the only thing that says which
   corner a control belongs to is the two lines under it. They are the same
   control in two places — a 42px circle with a 24px icon in it, filled with the
   card's accent, out of the flow of both button lists — and a second copy of
   that geometry would be a second thing to keep in step with the first, which is
   how two corners come to differ by a pixel or a shade with nothing having been
   changed on purpose. The class both wrappers carry is the hook. */

.spcad-corner-wrap {
    position: absolute;
    top: 14px;
    z-index: 3;
    /* Never past the card's own edge. A long button label on a narrow card would
       otherwise run off it, and the card clips its overflow, so the tail of the
       text would simply disappear. */
    max-width: calc(100% - 28px)
}

.spcad-vcard-wrap {
    left: 14px
}

.spcad-share-wrap {
    right: 14px
}

/* A round button, and only an icon.

   The width and the padding are both dropped because the button is display:flex
   for the button lists, where filling the row is the point — here it would
   stretch the full width of the card and read as a header strip. A fixed square
   and a 50% radius is what makes it a circle; the icon is centred in it by the
   flex alignment rather than by padding, so the two cannot disagree about where
   the middle is. min-height is zeroed because the list rule asks for 42px of
   minimum and that would stop the circle being shorter than it is wide on a card
   whose button size is set larger.

   42px is the same height as the buttons in the lists, so the corner controls
   and the row of buttons below them share a rhythm instead of looking like three
   different things from two different plugins.

   appearance and the pointer are here because one of these two is a <button>
   and the other an <a>: the first brings the platform's own button styling with
   it — a border, a background, and in some engines a font that is not the card's
   — and the second has no pointer to give. */
.spcad-corner-wrap>.spcad-network-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    min-height: 0;
    max-width: 100%;
    padding: 0;
    gap: 0;
    border: 0;
    border-radius: 50%;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    /* 24px is the library's own "medium" icon size rather than a number picked by
       eye, and it was picked by eye: at 21px the person is legible but recedes,
       and at 26px it crowds the rim. The icon's ink is about two thirds of its
       box, so this fills a little under half the circle.

       The card's icon size setting is deliberately not read here. That setting
       runs to 40px for the button lists, where it is right, and it would fill this
       circle edge to edge. */
    --spcad-icon-size: 24px;
    /* Filled in the card's own button colour rather than on a neutral plate.

       This is the pairing the rest of the card's buttons use — the button's fill
       colour with its own text colour on top — so a corner control looks like one
       of the card's buttons instead of a chip that happens to share their corner,
       and it picks up the accent the card was designed with instead of the neutral
       grey. It is also opaque by construction, which is what makes it readable
       over an arbitrary cover photograph: there is no scrim and no fallback plate,
       because the fill is a colour and not a tint of whatever is underneath.

       The one case this cannot survive is an accent equal to the card's own
       background, which is a card whose every filled button is already invisible
       rather than one this corner makes worse. */
    background: var(--spcad-button-bg, var(--spcad-accent));
    color: var(--spcad-button-text, #fff);
    /* Two shadows rather than one, and the reason is a card whose accent is close
       to its cover — the circle then sits on a background very close to its own and
       a single soft shadow does not separate it. The tight one gives the edge a
       line, the wide one lifts it off the photograph underneath. */
    box-shadow: 0 1px 3px rgba(18, 25, 38, .26), 0 4px 12px rgba(18, 25, 38, .22);
    /* The hover nudge the button lists use — a three pixel step along the reading
       direction — would push this circle into the card's edge rather than away from
       the corner it sits in, so the movement is dropped and only the colour moves. */
    transition: background .16s ease
}

/* The icon, asked for by element rather than through --spcad-btn-icon.

   That variable only becomes the icon's colour when one of the four design rules
   is present to map it across, and a card can be drawn with the design classes
   off — and then the icon falls back to the button's own fill colour, which on a
   fill of that same colour is invisible. Naming the element rather than the
   variable is what makes this hold at every design setting, including none. */
.spcad-corner-wrap>.spcad-network-link .spcad-network-svg {
    color: var(--spcad-button-text, #fff);
    fill: var(--spcad-button-text, #fff)
}

.spcad-corner-wrap>.spcad-network-link:hover,
.spcad-corner-wrap>.spcad-network-link:focus {
    transform: none;
    background: color-mix(in srgb, var(--spcad-button-bg, var(--spcad-accent)) 86%, #000);
    /* Re-asked rather than inherited: the rule above changes the background, and the
       foreground is the one thing that has to keep matching it. */
    color: var(--spcad-button-text, #fff)
}

/* The message the share button reports with, pinned under the corner it belongs
   to. The coupon's copy message is the same shape and the same two colours, so
   the two read as one card's furniture rather than as two plugins' ideas.

   nowrap because the containing block here is the 42px wrapper: a box that wraps
   would be shrunk to the wrapper's width and stand up as a narrow column of
   broken words, which is what shrink-to-fit does when the available width is
   narrower than the text. */
.spcad-share-toast {
    position: absolute;
    top: 50px;
    right: 0;
    z-index: 2;
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--spcad-button-bg, var(--spcad-accent));
    color: var(--spcad-button-text, #fff);
    font-family: var(--spcad-font-buttons-family, inherit);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
    text-align: center;
    white-space: nowrap;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity .16s ease, transform .16s ease, visibility .16s
}

.spcad-share-toast-on {
    opacity: 1;
    visibility: visible;
    transform: translateY(0)
}

/* Room for the corners, on the headers where a corner is occupied.

   The button is a fixed 42px square at 14px from the top, so its bottom edge is
   at 56px and every clearance below is 70px: 14px of gap below the button. That
   one number is why the button has a hard height at all.

   With a cover, the normal header's avatar starts below the cover and the button
   sits over the cover above it, so nothing has to move — that is the case the
   design was drawn for. The two below are the cases where the header reaches up
   into a corner a button is in.

   Compact pulls the avatar 34px up over a 64px cover, which puts it under a
   button sitting at 14px, so it stops doing that and sits under the cover
   instead. Without a cover the header row is the top of the card, so it takes
   enough top padding to clear the button's height.

   Both of these are asked of the spcad-has-vcard and spcad-has-share classes the
   renderer puts on the card, which are only there when there is a button to make
   room for. Written for both corners in one rule rather than one each: they are
   the same clearance for the same geometry, and a card can have both buttons on
   it at once, where two rules would be arguing about one property. */
.spcad-header-compact.spcad-has-vcard:not(.spcad-cover-no) .spcad-avatar,
.spcad-header-align-right.spcad-header-compact.spcad-has-share:not(.spcad-cover-no) .spcad-avatar {
    margin-top: 10px
}

.spcad-has-vcard.spcad-cover-no .spcad-header-row,
.spcad-has-share.spcad-cover-no .spcad-header-row {
    padding-top: 70px
}

/* The horizontal card, whose corner is not an avatar but the heading.

   Above 600px this layout is a grid: the cover is the first column and the
   profile is the second, whose heading starts 28px from the top and runs to 28px
   from the card's right edge — which is inside the 56px the corner button covers.
   Measured across all 72 combinations of layout, header style, cover, alignment
   and avatar size, this is the only place the two ever touch.

   The right padding rather than the top one, because the button then sits beside
   the name rather than above it and the card does not grow: nothing in this
   layout moves down, and the card's height is the thing that has already bitten
   once on this layout, where the profile content is clipped by the card's own
   overflow.

   Asked of every alignment rather than of the right-aligned ones only. On a
   right-aligned heading the overlap is certain; on the others it needs a name
   long enough to fill its own line, which is not a thing to leave to chance —
   a filled circle drawn over somebody's name is a defect, and 70px of a 570px
   column is a cheaper thing to pay than that. Measured with a 36 character name
   on every combination: with this inset the name's ink never reaches the button.

   Inside the min-width query on purpose: under 600px this layout stops being a
   grid and stacks, the avatar drops below the cover at 64px where the corner is
   already clear, and the heading follows the avatar. The inset would be 70px of
   a phone's width for a collision that cannot happen there. */
@media(min-width:601px) {
    .spcad-layout-horizontal.spcad-has-share:not(.spcad-cover-no) .spcad-header-row {
        padding-right: 70px
    }
}

/* The horizontal card is a grid whose first column is the cover, so its own top
   left corner is a corner the contact button goes in, and its top right corner
   holds the heading rather than the avatar.

   Nothing has to move for the circle on the left: the card's avatar is absolutely
   positioned at 151px, which is 95px clear of a 42px button's right edge, and
   the heading is further right still, behind the cover column.

   That was not true of the wider chip this replaced, which reached 158px and
   landed on the avatar — so there WAS a rule here, pushing the avatar down to 70px,
   and it was wrong. On a horizontal card with no buttons and a one line bio the
   card is 124px tall, so moving a 104px avatar 43px further down pushed it 50px
   past the bottom of the card, where overflow:hidden cut it in half. The card was
   already clipping that avatar by 7px before the button existed; the button made
   it seven times worse.

   The grid still has to be told the wrapper is out of flow, or an absolutely
   positioned child of a grid container is placed by its own grid area and the
   second column shifts. */
.spcad-layout-horizontal .spcad-corner-wrap {
    grid-column: 1 / -1
}
