/* ============================================================
   /assets/css/sidebar-mobile.css
   TASK 830F-5A - the Sidebar structure's own PORTRAIT phone layout.

   Loaded ONLY by web_templates/structures/sidebar/base.php, in place of the
   shared assets/css/mobile-structures.css link the structure used to carry:
       <link rel="stylesheet" href=".../sidebar-mobile.css?v=<filemtime>"
             media="(max-width: 768px), (orientation: landscape) and (max-height: 500px)">
   Portrait is the @media (max-width: 768px) block below; the landscape half of
   that link media query is filled in by the following task.

   SCOPE
   - every selector names body[data-structure="sidebar"] ...
   - every phone rule sits behind html:not(.axm-in-frame), exactly like the
     Sidebar phone rules in assets/css/mobile-structures.css. sidebar/base.php
     adds .axm-in-frame to <html> when the page runs inside the Studio preview
     iframe, so the preview and the desktop/tablet page keep the layout they
     had and only a REAL phone page gets this one.
   - colours come from the theme tokens only (--nav-bg, --nav-text,
     --primary-color, --accent-color, --text-dark, --text-light, --card-bg,
     --footer-bg, --footer-text); the box-shadows are the only literal rgba().

   PORTRAIT (this task): one 64px header bar -> the hero -> the re-stacked live
   text -> the CTA row -> the LISTEN card -> the footer band. Every wrapper
   between a block and <body> generates no box (display: contents), so all six
   blocks are children of the page column and are ordered with `order`.

   ASCII only. Plain CSS only. No Bootstrap.
   ============================================================ */

@media (max-width: 768px) {

    /* ---- Page column: 16px content gutter, 16px between the blocks ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] {
        display: flex;
        flex-direction: column;
        gap: 16px;
        box-sizing: border-box;
        min-height: 0;
        margin: 0;
        padding: 0 16px;
    }

    /* The wrappers generate no box, so every block below is a child of the
       column and can carry its own order: header, hero, live text, buttons,
       card, footer. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .main-content,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area {
        display: contents;
    }

    /* ---- HEADER: the .sidebar as one 64px bar, full bleed ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar {
        order: 1;
        flex: none;
        width: auto;
        margin: 0 -16px;
        box-sizing: border-box;
        height: 64px;
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 0 16px;
        background-color: var(--nav-bg);
        color: var(--nav-text);
    }
    /* Logo: left edge, natural ratio, 36px cap, never stretched, and centred on
       the header line. The desktop rule body[data-structure="sidebar"]
       .sidebar-logo sets align-self: flex-start (the logo is a column flex item
       there), which pinned it to the TOP of this row header; align-self: center
       puts it back on the same line as the Call pill. The fallback .sidebar-logo
       also carries margin-bottom: 20px and height: 35px - both are neutralised
       here. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo img {
        flex: 0 0 auto;
        align-self: center;
        display: block;
        width: auto;
        height: auto;
        max-height: 36px;
        max-width: 60%;
        margin: 0;
        padding: 0;
        object-fit: contain;
    }
    /* TASK 830F-9 - Company name: hidden on a phone whenever the logo image is
       shown, so the logo and the Call pill share the bar with no truncated
       "Axi..." text. base.php paints the logo <img class="sidebar-logo"> right
       before the <div id="companyNameHeader">, and it marks a MISSING logo with
       the class d-none (+ an inline display:none !important), so the general
       sibling combinator can key off .d-none / :not(.d-none). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo:not(.d-none) ~ #companyNameHeader {
        display: none;
    }
    /* Fallback / no-logo case: the name takes the logo's place, one line, never
       truncated (it must not carry the old ellipsis). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > #companyNameHeader {
        flex: 1 1 auto;
        min-width: 0;
        overflow: hidden;
        white-space: nowrap;
        text-overflow: ellipsis;
        text-align: center;
        -webkit-text-fill-color: var(--nav-text);
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo.d-none ~ #companyNameHeader {
        display: block;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        text-align: left;
    }
    /* The phone, e-mail and address blocks are the desktop sidebar; on a phone
       they are hidden and the Call link below takes over the number. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-section {
        display: none;
    }
    /* The phone-only Call link, right-aligned by justify-content: space-between. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-m-call {
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        gap: 8px;
        height: 44px;
        padding: 0 14px;
        border-radius: 22px;
        font-family: var(--body-font);
        font-size: 14px;
        font-weight: 700;
        line-height: 1;
        white-space: nowrap;
        text-decoration: none;
        color: var(--nav-text);
        background: color-mix(in srgb, var(--nav-text) 12%, transparent);
        border: 1px solid color-mix(in srgb, var(--nav-text) 30%, transparent);
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-m-call svg {
        width: 18px;
        height: 18px;
        flex: 0 0 auto;
    }

    /* ---- HERO: full width of the gutter, rounded, deep shadow ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-hero-wrap {
        order: 2;
        flex: none;
        width: 100%;
        max-width: none;
        margin: 0;
        border-radius: 14px;
        overflow: hidden;
        box-shadow: 0 10px 24px rgba(11, 29, 58, 0.16);
    }
    /* The canvas-positioned decor and live text never print on a phone: the
       live text is re-stacked below instead. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-hero-wrap .axm-live-decor,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-hero-wrap .axm-live-text {
        display: none;
    }

    /* ---- LIVE HERO TEXT (printed by axmLiveMobileHtml in _hero_live.php) ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile {
        order: 3;
        flex: none;
        display: flex;
        flex-direction: column;
        gap: 0;
        /* 20px from the photo to the pill: the page column already puts 16px
           between the hero and this block, so only the remaining 4px is added. */
        margin-top: 4px;
    }
    /* Badge */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-pill {
        align-self: flex-start;
        display: inline-flex;
        align-items: center;
        height: auto;
        /* TASK 830J G7: 16px/600 pill on the theme primary, white text. */
        padding: 6px 14px;
        border-radius: 999px;
        font-family: var(--body-font);
        font-size: 16px;
        font-weight: 600;
        letter-spacing: 0.2px;
        line-height: 1.2;
        background-color: var(--primary-color);
        color: var(--text-light);
    }
    /* Headline */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-headline {
        font-family: var(--header-font);
        font-size: 24px;
        font-weight: 600;
        line-height: 1.2;
        letter-spacing: -0.2px;
        margin-top: 14px;
        color: var(--text-dark);
    }
    /* Sub-headline */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-sub {
        font-family: var(--body-font);
        font-size: clamp(16px, 4.4vw, 18px);
        font-weight: 400;
        line-height: 1.5;
        margin-top: 10px;
        color: var(--text-dark);
    }
    /* Message */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-message {
        font-family: var(--body-font);
        font-size: clamp(15px, 4vw, 17px);
        font-weight: 400;
        line-height: 1.5;
        margin-top: 10px;
        color: var(--secondary-color);
    }
    /* Click-to-call number */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-phone,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-phone a {
        font-family: var(--body-font);
        font-size: clamp(18px, 4.9vw, 20px);
        font-weight: 600;
        line-height: 1.2;
        letter-spacing: 0.3px;
        text-decoration: none;
        margin-top: 16px;
        color: var(--text-dark);
    }

    /* ---- CTA ROW: normal flow (no fixed or sticky bar), one row ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-button-group {
        order: 4;
        flex: none;
        position: static;
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: stretch;
        justify-content: center;
        gap: 10px;
        width: 100%;
        /* 22px from the end of the copy to the buttons: the page column already
           puts 16px between the copy and this block, so only 6px is added. */
        margin: 6px 0 0;
        padding: 0;
        box-shadow: none;
        border-top: 0;
    }
    /* Same order and colours as desktop (the markup order and the generator's
       own CTA colours); only the phone box changes. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-button-group > a {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        height: 48px;
        margin: 0;
        padding: 0 16px;
        border-radius: 10px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        box-sizing: border-box;
        font-size: 15px;
        font-weight: 600;
        line-height: 1.1;
        text-align: center;
        /* TASK 830F-6 extra 3 - a phone has no pointer, so :hover sticks after a
           tap (and it also fires under a mouse while the Phone emulation is on).
           The SHARED rules in assets/css/theme-unified.css grow the CTAs on
           hover - a.primary-cta:hover { transform: scale(1.05) } and
           a.secondary-cta:hover { transform: scale(1.03) } - and nothing in
           this sheet reset that transform. A stuck scale(1.05) on the left
           (primary) button makes it ~4px wider on each side, so the row's left
           edge landed ~4px left of the hero / audio card (12 instead of 16)
           while the un-hovered right (secondary) button stayed flush. Pinning
           the transform (and dropping the desktop 0 4px 12px glow, exactly as
           the fluid-hero phone rules do) keeps both edges on the hero's edge. */
        box-shadow: none;
        transform: none;
    }
    /* One button alone keeps the whole row. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-button-group > a:only-child {
        flex: 1 1 100%;
    }

    /* ---- LISTEN CARD ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card {
        order: 5;
        flex: none;
        width: 100%;
        box-sizing: border-box;
        margin: 0;
        padding: 22px 16px 24px;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        background: var(--card-bg);
        border-radius: 14px;
        box-shadow: 0 6px 20px rgba(11, 29, 58, 0.08);
        text-align: center;
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card::before {
        content: "LISTEN";
        display: block;
        font-family: var(--body-font);
        font-size: 14px;
        font-weight: 700;
        letter-spacing: 2px;
        color: var(--accent-color);
    }
    /* TASK 830F-9 - the audio title: centred, 20px, weight 700, line-height 1.3,
       heading colour (line-height 1.3 added). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card h2 {
        margin: 0;
        /* TASK 830J G8/G10: theme heading stack, weight 600, never italic. */
        font-family: var(--header-font);
        font-style: normal;
        font-size: 20px;
        font-weight: 600;
        line-height: 1.3;
        text-align: center;
        color: var(--text-dark);
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card > div,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card > div > div {
        width: 100%;
        max-width: none !important;
    }
    /* TASK 830F-9 - title -> player gap = 16px on the phone. The wrapper ships an
       inline margin-top: 20px, and the flex column already adds its own 8px gap
       above it, so the visible gap was 8 + 20 = 28px; pinning the inline margin
       to 8px gives 8 + 8 = 16px. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card > div {
        margin-top: 8px !important;
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card audio {
        width: 100%;
        max-width: none;
    }

    /* ---- FOOTER BAND: full width, brand dark, one centred column ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer {
        order: 6;
        flex: none;
        width: auto;
        margin: 24px -16px 0;
        box-sizing: border-box;
        padding: 32px 20px 28px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 10px;
        background-color: var(--footer-bg);
        color: var(--footer-text);
        text-align: center;
        box-shadow: none;
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .footer-content {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
        margin: 0;
        color: inherit;
    }
    /* The two phone-only contact lines (e-mail + address). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .axm-m-foot-contact {
        display: block;
        margin: 0;
        font-size: 16px;
        font-weight: 400;
        line-height: 1.4;
        color: inherit;
        overflow-wrap: anywhere;
    }
    /* The e-mail reads heavier than the address. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .axm-m-foot-contact[data-branding-key="company-email"] {
        font-weight: 600;
    }
    /* The website line (kept when present). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .footer-content p:not(.axm-m-foot-contact) {
        margin: 0;
        font-size: 14px;
        line-height: 1.4;
        color: inherit;
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .footer-content p a {
        color: inherit;
    }
    /* Powered by */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .powered-by {
        margin: 0 !important;
        font-size: 14px !important;
        font-weight: 400;
        line-height: 1.4;
        color: inherit;
    }
}

/* ============================================================
   TASK 830F-5B - the Sidebar structure's own LANDSCAPE phone layout.
   Appended AFTER the portrait block: a phone that is both narrow
   (<= 768px) and short (<= 500px) matches BOTH blocks and this one wins
   by source order. Wider-but-short phones (844x390, 932x430) match only
   this block (they are too wide for the portrait block).

   Same scope and gating as the portrait block: every selector names
   html:not(.axm-in-frame) body[data-structure="sidebar"] ... and every
   colour comes from the theme tokens only (--nav-bg, --nav-text,
   --primary-color, --card-bg, --footer-bg, --footer-text, --text-dark);
   the box-shadows are the only literal rgba().

   Shape: a 48px full-bleed header, then a two-column grid (44% / 1fr):
   the hero fills the left column across the copy + cta rows, the live
   text sits in the right column over the CTA row, the LISTEN card spans
   both columns, and the footer band closes the page. Fixed sizes only,
   never 100vh, so the page scrolls normally and long text wraps. When
   $axmLive is off the .axm-live-mobile element is absent, so the hero
   still spans the left column and the buttons stay in the right column.

   ASCII only. Plain CSS only. No Bootstrap.
   ============================================================ */

@media (orientation: landscape) and (max-height: 500px) {

    /* ---- Page grid: 44% / 1fr, 20px between columns, five named rows.
       20px side padding on the content; the header and footer bleed
       past it to the viewport edges. ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] {
        display: grid;
        grid-template-columns: 44% 1fr;
        grid-template-areas:
            "header header"
            "hero copy"
            "hero cta"
            "card card"
            "footer footer";
        row-gap: 0;
        column-gap: 20px;
        box-sizing: border-box;
        min-height: 0;
        margin: 0;
        padding: 0 20px;
    }

    /* The wrappers generate no box (exactly like the portrait block), so
       the real blocks below are the grid items of the page grid. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .main-content,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area {
        display: contents;
    }

    /* ---- HEADER: one 48px bar, full bleed, full width ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar {
        grid-area: header;
        flex: none;
        width: auto;
        margin: 0 -20px;
        box-sizing: border-box;
        height: 48px;
        display: flex;
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 0 20px;
        background-color: var(--nav-bg);
        color: var(--nav-text);
    }
    /* Logo: natural ratio, 28px cap, left edge, centred on the 48px bar. The
       same desktop align-self: flex-start / margin-bottom: 20px / height: 35px
       overrides are neutralised here too. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo img {
        flex: 0 0 auto;
        align-self: center;
        display: block;
        width: auto;
        height: auto;
        max-height: 28px;
        max-width: 60%;
        margin: 0;
        padding: 0;
        object-fit: contain;
    }
    /* The desktop sidebar phone / e-mail / address stay hidden. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-section {
        display: none;
    }
    /* TASK 830F-9 - a wide landscape phone is still a phone: hide the company
       name whenever the logo image is shown (base.php marks a missing logo with
       .d-none), exactly like the portrait block. Without this the name printed
       between the logo and the Call pill and gave way with the old ellipsis. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo:not(.d-none) ~ #companyNameHeader {
        display: none;
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .sidebar > .sidebar-logo.d-none ~ #companyNameHeader {
        display: block;
        flex: 1 1 auto;
        min-width: 0;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        text-align: left;
        -webkit-text-fill-color: var(--nav-text);
    }
    /* TASK 830F-9 - the phone-only Call link. The portrait pill rule lives inside
       the max-width: 768px block and does NOT apply at 844/932 wide, so this
       block must (a) turn the link back ON at all -- base.php's own <style>
       ships body[data-structure="sidebar"] .axm-m-call { display: none } and
       nothing here reset it, which is why the pill vanished on a wide landscape
       phone -- and (b) give it the pill look at 36px tall / 16px icon. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-m-call {
        flex: 0 0 auto;
        display: inline-flex;
        align-items: center;
        gap: 8px;
        height: 36px;
        padding: 0 14px;
        border-radius: 18px;
        font-family: var(--body-font);
        font-size: 14px;
        font-weight: 700;
        line-height: 1;
        white-space: nowrap;
        text-decoration: none;
        color: var(--nav-text);
        background: color-mix(in srgb, var(--nav-text) 12%, transparent);
        border: 1px solid color-mix(in srgb, var(--nav-text) 30%, transparent);
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-m-call svg {
        width: 16px;
        height: 16px;
        flex: 0 0 auto;
    }

    /* ---- HERO: left column, spanning the copy and cta rows ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-hero-wrap {
        grid-area: hero;
        /* TASK 830F-6 extra 1 - without this the grid stretches the hero to the
           full height of the two rows it spans, overriding the inherited
           aspect-ratio: 16 / 9 and squashing the photo. align-self: start lets
           the wrap keep its natural 16:9 height; the margin and the aspect-ratio
           (from theme-unified.css) are left untouched. */
        align-self: start;
        width: 100%;
        max-width: none;
        margin: 16px 0 0;
        border-radius: 14px;
        overflow: hidden;
        box-shadow: 0 10px 24px rgba(11, 29, 58, 0.16);
    }
    /* The canvas decor and canvas live text never print on a phone. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-hero-wrap .axm-live-decor,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-hero-wrap .axm-live-text {
        display: none;
    }

    /* ---- LIVE TEXT: right column, centred in its row ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile {
        grid-area: copy;
        align-self: center;
        display: flex;
        flex-direction: column;
        gap: 0;
        margin: 16px 0 0;
        min-width: 0;
    }
    /* Badge */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-pill {
        align-self: flex-start;
        display: inline-flex;
        align-items: center;
        height: auto;
        /* TASK 830J G7: 16px/600 pill on the theme primary, white text. */
        padding: 6px 14px;
        border-radius: 999px;
        font-family: var(--body-font);
        font-size: 16px;
        font-weight: 600;
        letter-spacing: 0.2px;
        line-height: 1.2;
        background-color: var(--primary-color);
        color: var(--text-light);
    }
    /* Headline */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-headline {
        font-size: 24px;
        font-weight: 600;
        line-height: 1.2;
        letter-spacing: -0.2px;
        margin-top: 12px;
        color: var(--text-dark);
    }
    /* Sub-headline */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-sub {
        font-size: 16px;
        font-weight: 400;
        line-height: 1.5;
        margin-top: 8px;
        color: var(--text-dark);
    }
    /* Message */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-message {
        font-size: 15px;
        font-weight: 400;
        line-height: 1.5;
        margin-top: 8px;
        color: var(--secondary-color);
    }
    /* Click-to-call number */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-phone,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-live-mobile .axm-m-phone a {
        font-size: 18px;
        font-weight: 600;
        line-height: 1.2;
        letter-spacing: 0.3px;
        text-decoration: none;
        margin-top: 14px;
        color: var(--text-dark);
    }

    /* ---- CTA ROW: right column, under the copy ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-button-group {
        grid-area: cta;
        position: static;
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: stretch;
        justify-content: center;
        gap: 10px;
        width: 100%;
        /* 18px before the buttons in the short landscape grid. */
        margin: 18px 0 0;
        padding: 0;
        box-shadow: none;
        border-top: 0;
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-button-group > a {
        flex: 1 1 0;
        width: auto;
        min-width: 0;
        height: 44px;
        margin: 0;
        padding: 0 16px;
        border-radius: 10px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        box-sizing: border-box;
        font-size: 15px;
        font-weight: 600;
        line-height: 1.1;
        text-align: center;
        /* TASK 830F-6 extra 3 - same neutralisation as the portrait block: the
           shared theme-unified.css hover scale (a.primary-cta:hover
           transform: scale(1.05)) can stick on a touch device and, because it
           scales from the centre, pushes the left button ~4px past the hero
           edge while the right button stays flush. Pin the transform and drop
           the desktop glow so both edges equal the hero's on landscape too. */
        box-shadow: none;
        transform: none;
    }
    /* One button alone keeps the whole row. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-button-group > a:only-child {
        flex: 1 1 100%;
    }

    /* ---- LISTEN CARD: spans both columns ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card {
        grid-area: card;
        width: 100%;
        box-sizing: border-box;
        margin: 20px 0 0;
        padding: 18px 20px 20px;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        background: var(--card-bg);
        border-radius: 14px;
        box-shadow: 0 6px 20px rgba(11, 29, 58, 0.08);
        text-align: center;
    }
    /* TASK 830F-9 - the portrait ::before / h2 / gap / audio rules sit inside the
       max-width: 768px block, so at 844/932 wide the landscape card had no LISTEN
       eyebrow, no 20px title and a full-width player. Restate all of it here. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card::before {
        content: "LISTEN";
        display: block;
        font-family: var(--body-font);
        font-size: 14px;
        font-weight: 700;
        letter-spacing: 2px;
        color: var(--accent-color);
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card h2 {
        margin: 0;
        /* !important: at 844/932 wide the bootstrap customer-sizing block
           (@media min-width: 769px) forces [data-branding-key="audio-title"]
           { font-size: 32px !important; font-weight: 400 !important }, which
           out-ranks a plain property; the !important plus this more specific
           selector wins it back. */
        /* TASK 830J G8/G10: theme heading stack, never italic, weight 600. */
        font-family: var(--header-font);
        font-style: normal !important;
        font-size: 20px !important;
        font-weight: 600 !important;
        line-height: 1.3;
        text-align: center;
        color: var(--text-dark);
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card > div,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card > div > div {
        width: 100%;
        max-width: none !important;
    }
    /* Title -> player gap = 16px in landscape too (inline margin-top: 20px + the
       8px flex gap was 28px; 8 + 8 = 16px). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card > div {
        margin-top: 8px !important;
    }
    /* The audio element: 60% of the card, never under 280px, never past 100%,
       centred. The element carries an inline style="width: 100%", which beat the
       old sheet rule (width: 60% with no !important) -- hence the full-width
       player. !important wins the inline style back. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] .content-area > .axm-card audio {
        display: block;
        width: 60% !important;
        min-width: 280px;
        max-width: 100%;
        margin: 0 auto;
    }

    /* ---- FOOTER: full bleed, 20px padding, 20px above ---- */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer {
        grid-area: footer;
        flex: none;
        width: auto;
        margin: 20px -20px 0;
        box-sizing: border-box;
        padding: 20px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 10px;
        background-color: var(--footer-bg);
        color: var(--footer-text);
        text-align: center;
        box-shadow: none;
    }
    /* E-mail and address share one wrapping row (36px apart, 15px text). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .footer-content {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        justify-content: center;
        gap: 36px;
        margin: 0;
        max-width: 100%;
        color: inherit;
    }
    /* The two contact lines; they wrap, they are never truncated. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .axm-m-foot-contact {
        display: block;
        flex: 0 1 auto;
        min-width: 0;
        margin: 0;
        font-size: 15px;
        font-weight: 400;
        line-height: 1.4;
        color: inherit;
        white-space: normal;
        overflow-wrap: anywhere;
        text-overflow: clip;
    }
    /* The e-mail reads heavier than the address. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .axm-m-foot-contact[data-branding-key="company-email"] {
        font-weight: 600;
    }
    /* The website line (kept when present). */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .footer-content p:not(.axm-m-foot-contact) {
        margin: 0;
        font-size: 14px;
        line-height: 1.4;
        color: inherit;
    }
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .footer-content p a {
        color: inherit;
    }
    /* Powered by, 14px, below the contact row. */
    html:not(.axm-in-frame) body[data-structure="sidebar"] footer.axm-footer .powered-by {
        margin: 0 !important;
        font-size: 14px !important;
        font-weight: 400;
        line-height: 1.4;
        color: inherit;
    }
}

/* TASK 830J G10 - the phone footer line and the Call pill always use the theme
   stack, so a serif body/heading font can never leak into them. Phone queries only. */
@media (max-width: 768px), (orientation: landscape) and (max-height: 500px) {
    html:not(.axm-in-frame) body[data-structure="sidebar"] .powered-by,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-m-call,
    html:not(.axm-in-frame) body[data-structure="sidebar"] .axm-m-call span {
        font-family: var(--body-font);
    }
}
