/**
 * OTA CTA Banner widget styles.
 *
 * The full width call to action band: a heading, two buttons, and a photograph
 * bleeding off the right edge behind a curved left edge. Figma node 193:4310.
 *
 * Every colour is a colour theme role, mapped once in the token block below and
 * referenced by name after that, which is what lets the band follow whatever
 * theme is in force above it: its own, else the container's, else the page's,
 * else the site's. The one exception is the band's own background, which the
 * widget offers as a colour control and which overrides the surface role for the
 * band alone: see `--ocb-section-bg` below. The roles come from the "CTA Banner"
 * component in the OTA design file, binding for binding:
 *
 *   band surface      bar/background     --ota-background
 *   heading           bar/White Text     --ota-white-text
 *   primary button    .ota-btn--primary, which reads cta-bg / cta-text itself
 *   secondary button  .ota-btn--ghost, same
 *
 * `white-text` is not literally white. It is the role for text that reads on
 * this theme's background, so it resolves navy on the light themes and white on
 * the dark ones. The frame's own mode resolves it to #003038, which is why the
 * heading looks navy in Figma.
 *
 * Typography comes from the Elementor global fonts, each as a `var()` with the
 * Figma number as its fallback, so the band still renders to spec on a site
 * whose kit has not had the type scale imported. Heading/H2 for the heading; the
 * buttons carry their own.
 *
 * THE CURVE IS BUILT, AND CURRENTLY SWITCHED OFF
 *
 * Figma draws the photograph as a 564px square (node 136:14411) with corner
 * radii, positioned so the band clips its top, bottom and right and leaves only
 * the curved left edge showing. The MCP does not report corner radius:
 * `get_design_context` hands the node back as a plain box with an image fill, so
 * the exact radii are not available to read.
 *
 * So the edge was rebuilt here as an ellipse rather than copied: a horizontal
 * radius of `--ocb-curve` against a vertical radius of half the band, which
 * draws one continuous bow down the left side with its widest point at the
 * band's centre. That is the shape the rendered frame shows, and 150px against
 * the frame's 564px panel is measured back off it.
 *
 * `--ocb-curve` is 0 as of 12 Aug 2026, so none of that is drawn: the panel is a
 * plain rectangle. The rules are left in place because one token restores it.
 * See the note on the token itself.
 *
 * THE GEOMETRY IS FIXED, AND THE PHOTOGRAPH SHOULD BE A PHOTOGRAPH
 *
 * The band's height, the photograph's width, the bow and the text measure were
 * four sliders on the widget and are four constants here now. The reasoning is
 * on OTA_CTA_Banner. What matters at this end is that the height is no longer
 * stated at all: `padding-block` and the content decide it, and the photograph
 * is anchored to both block edges so it follows.
 *
 * One thing this cannot defend against. The bow belongs to the panel, not to the
 * file inside it, so the image an editor uploads should be an ordinary
 * rectangular photograph. Upload the Figma export of node 136:14411 instead and
 * the curve arrives twice: once baked into a transparent PNG and once drawn
 * here, with the band showing through the corners the export rounded off. That
 * is what was on the Home page, and it is why zeroing the curve control looked
 * like it fixed something.
 */

/*
 * The roles. Ash values as fallbacks, so the band is never unstyled on a site
 * with no colour theme configured.
 */
.ota-cta {
	--ocb-surface: var(--ota-background, #f0e7d8);
	--ocb-text: var(--ota-white-text, #003038);

	/*
	 * The design's own measurements, and constants rather than controls. The
	 * widget offered the four below as sliders and no longer does: see the note
	 * at the top of includes/widgets/class-ota-cta-banner.php.
	 */
	--ocb-max: 1280px;
	--ocb-pad: 2rem;

	/*
	 * A ceiling, not a width. The panel is as wide as the photograph needs to be
	 * at the band's height, so this only ever bites on a very wide file. 39.17%
	 * is the frame's own proportion, 564 of 1440, which makes the design's square
	 * the widest thing that fits without being reined in.
	 */
	--ocb-media-max: 39.17%;

	/*
	 * HOW MUCH TALLER THAN THE BAND THE PHOTOGRAPH IS SCALED, AND SO HOW MUCH IT
	 * IS CROPPED AND HOW FAR LEFT IT REACHES
	 *
	 * This is the one number for the size of the photograph, and all three of
	 * those things move together, which is why it is one number rather than
	 * three. The panel is as wide as the photograph is at this height, so 100%
	 * fits the whole thing with no crop and leaves the smallest panel, and every
	 * point above that scales it up, trims the same amount off the top and the
	 * bottom, and pulls the panel's left edge closer to the heading.
	 *
	 * 125% on Bryce's call, 12 Aug 2026: "a little larger and crop in a bit more,
	 * closer to the text". On the 1440 artboard that is a 486px panel losing 48px
	 * off each of its top and bottom, sitting between the 389px that fits whole
	 * and the frame's own 564px, which crops nearly a third of the height away.
	 *
	 * The crop is centred, so it takes from both edges rather than beheading the
	 * subject, which is what `cover` on a fixed panel was doing before.
	 */
	--ocb-media-zoom: 125%;

	/*
	 * OFF, ON BRYCE'S CALL, AND THIS IS THE ONE LINE THAT TURNS IT BACK ON
	 *
	 * Figma draws the photograph as a 564px square (node 136:14411) with corner
	 * radii, and the whole of this block's identity in the frame is that bow. It
	 * is off anyway: 12 Aug 2026, "get rid of the border radius on this". So the
	 * panel is a plain rectangle and the frame is not being followed here.
	 *
	 * The mechanism is left standing rather than deleted, because the decision is
	 * a taste one and the drawing is the awkward part. Set this back to `26.6%`
	 * and the bow returns everywhere it used to be, desktop and narrow. That
	 * number is the frame's own 150px against its 564px panel, expressed as a
	 * proportion because the panel's width now follows the photograph.
	 *
	 * Worth knowing: this does not square off the photograph itself. The file on
	 * the Home page is the Figma export with the rounded shape baked into it as
	 * transparency, so its corners stay round no matter what this says. Only
	 * uploading a plain rectangular photograph fixes that.
	 */
	--ocb-curve: 0;

	/* The heading's own measure in the frame. */
	--ocb-content-max: 681px;

	--ocb-gap: 24px;

	/*
	 * THE BAND IS AS TALL AS ITS CONTENT
	 *
	 * No minimum height. The frame is 387px tall and holds 181.45px of content,
	 * so the padding is what is left of it either side, and a two line heading
	 * with its two buttons reproduces the frame to the pixel without the height
	 * being stated anywhere. A heading that runs to three lines then pushes the
	 * band taller instead of colliding with its own edges, and a one line
	 * heading closes it up instead of leaving a hole. Both of those are the
	 * behaviour the frame implies and neither is something an editor should be
	 * setting by hand.
	 *
	 * The photograph needs nothing for this: it is anchored to the top and the
	 * bottom of the band, so it is whatever height the content just decided.
	 */
	--ocb-pad-block: 103px;

	position: relative;
	display: flex;
	align-items: center;
	box-sizing: border-box;
	padding-block: var(--ocb-pad-block);
	overflow: hidden;
	background-color: var(--ocb-section-bg, var(--ocb-surface));
	color: var(--ocb-text);

	/*
	 * WHAT MAKES ELEMENTOR'S ADVANCED > BORDER RADIUS WORK ON THIS BAND
	 *
	 * It did nothing before this line, reported by Jade on 2 Sep 2026 with a
	 * value already saved on the NDIS page: `_border_radius` of 20px on widget
	 * 9889b43, which post-2712.css duly writes out as
	 * `... .elementor-element-9889b43 > .elementor-widget-container{border-radius:020px...}`.
	 *
	 * Elementor puts the radius on the widget container, and the container has
	 * no background and does not clip, so rounding it rounds nothing anybody can
	 * see. The band's own background and `overflow: hidden` are here, one level
	 * in, and this element was square.
	 *
	 * `inherit` takes the parent's computed radius, which is exactly the value
	 * Elementor just wrote, so the control an editor already reaches for is the
	 * one that works, rather than a second radius control on this widget saying
	 * the same thing twice. It survives the optimised-markup experiment too: with
	 * the container div gone the radius lands on `{{WRAPPER}}`, which is then
	 * this element's parent instead, and inherit reads that.
	 *
	 * Nothing to undo when unset: an unrounded container computes to 0.
	 */
	border-radius: inherit;
}

.ota-cta__inner {
	box-sizing: border-box;
	position: relative;
	/*
	 * Above the photograph. Both are in the same stacking context and the media
	 * is absolutely positioned, so without this the panel paints over the text
	 * at any width where the two overlap.
	 */
	z-index: 1;
	width: 100%;
	/*
	 * The padding is added to the maximum rather than taken out of it, so the
	 * content is exactly the design's 1280px at desktop and still keeps a gutter
	 * once the viewport is narrower than that. On the 1440px artboard this puts
	 * the heading at x=80, which is where the frame draws it.
	 */
	max-width: calc(var(--ocb-max) + 2 * var(--ocb-pad));
	margin-inline: auto;
	padding-inline: var(--ocb-pad);
}

/*
 * THE TEXT KEEPS OFF THE PHOTOGRAPH, AT EVERY BAND WIDTH
 *
 * Reported by Jade on 2 Sep 2026: "the body text is bleeding into the image if
 * the width of the widget is in boxed".
 *
 * The two sides of the band were measured against different things. The panel
 * is a share of the band, up to `--ocb-media-max`, so it narrows as the band
 * does. The text was a flat 681px, the frame's own measure, so it did not. On
 * the full width band there is room for both and the numbers never met; put the
 * band in a boxed container and the text keeps its 681px while the panel walks
 * left into it, and the paragraph runs under the photograph. Nothing was
 * overlapping by a little: the panel paints behind the text (`z-index: 1` on
 * the inner) so the words stay legible and the collision reads as a photograph
 * creeping under the last line, which is why it looked like a text bug.
 *
 * The fix reserves the panel's own maximum as end padding rather than capping
 * the text to another fixed number. A percentage padding resolves against this
 * element's containing block, which is the band, so `--ocb-media-max` here and
 * on the panel are the same 39.17% of the same box, and the text cannot reach
 * the panel however wide or narrow the band is. The text then fits whatever is
 * left, `--ocb-content-max` still holding it to the frame's measure wherever
 * there is room for it: at the 1440 artboard that leaves 716px of space for a
 * 681px measure, so the desktop band is unchanged to the pixel.
 *
 * It reserves the cap rather than the panel's real width, which is the panel's
 * for the asking only at render time: the box shrinks to whatever the
 * photograph comes to at the band's height (see `--ocb-media-zoom`), and CSS
 * cannot hand that measurement back up here. So a narrow photograph leaves a
 * wider gap than it strictly needs. That is the safe direction to be wrong in.
 *
 * Scoped to a band that has a photograph, via the modifier the template adds,
 * because there is nothing to keep off an empty band and the text should have
 * all of it.
 */
.ota-cta--has-media .ota-cta__inner {
	padding-inline-end: calc(var(--ocb-pad) + var(--ocb-media-max));
}

.ota-cta__content {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: var(--ocb-gap);
	max-width: var(--ocb-content-max);
}

/*
 * The eyebrow and body arrived with the SIG page's Loop band (the Loop CTA
 * Banner instance on frame 352:12396), which is this same component with a
 * small line above the heading and a supporting paragraph under it. Both are
 * optional and absent from every band that shipped before them. The negative
 * margin tucks the eyebrow against the heading, closer than the band's own
 * 24px rhythm, which is how the frame draws the pair.
 *
 * NOT THE ACCENT ROLE, which is what this reached for first. The frame draws
 * both lines as the band's own text colour held back (72% and 78% white on the
 * teal band), not as the ochre the other eyebrows on this page use. Written as
 * the text role plus an opacity so it follows whatever theme the band is set
 * to: on teal the accent role resolves to an orange that appears nowhere in
 * this frame, measured on the page.
 */
/*
 * THREE LINES, THREE COLOURS, AND WHY EACH IS TWO TOKENS RATHER THAN ONE
 *
 * Reported by Jade on 2 Sep 2026: "I'd like to be able to pick a different
 * colour between the eyebrow, header and body text, right now, under the header
 * style menu, I can change the header colour, but it affects the colours of all
 * text." She was right about the cause. The widget's one colour control wrote
 * `--ocb-text`, which is the band's text role and what all three lines read, so
 * it was never a heading control despite its label.
 *
 * Each line now reads its own token and falls back to the role, so a band with
 * nothing set is the theme-driven band it has always been and the three
 * controls are three independent overrides.
 *
 * The opacity is the second token, and it is the part that would otherwise make
 * a picked colour a lie. The eyebrow and the body are the band's text held back
 * to the frame's 72% and 78%, so a colour chosen here would arrive muted and
 * mixed with whatever is behind it: pick white on the teal band and get grey.
 * The widget sets the opacity to 1 alongside any colour it writes, so a colour
 * an editor picks is the colour that paints, and the held-back default stands
 * for as long as they pick nothing.
 */
.ota-cta__eyebrow {
	margin: 0 0 calc(8px - var(--ocb-gap));
	color: var(--ocb-eyebrow, var(--ocb-text));
	opacity: var(--ocb-eyebrow-opacity, 0.72);
	font-size: var(--e-global-typography-eyebrow-font-size, 1.0625rem);
	font-weight: var(--e-global-typography-eyebrow-font-weight, 700);
	line-height: var(--e-global-typography-eyebrow-line-height, 1.46em);
	letter-spacing: var(--e-global-typography-eyebrow-letter-spacing, 1px);
}

.ota-cta__title {
	margin: 0;
	color: var(--ocb-title, var(--ocb-text));
	font-size: var(--e-global-typography-h2-font-size, 2.75rem);
	font-weight: var(--e-global-typography-h2-font-weight, 400);
	line-height: var(--e-global-typography-h2-line-height, 1.08em);
	letter-spacing: var(--e-global-typography-h2-letter-spacing, -0.44px);
}

/* Body/Default at the frame's 78%, same reasoning as the eyebrow above. */
.ota-cta__body {
	margin: 0;
	color: var(--ocb-body, var(--ocb-text));
	opacity: var(--ocb-body-opacity, 0.78);
	font-size: 17px;
	font-weight: 300;
	line-height: 1.65;
}

.ota-cta__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--ocb-gap);
}

/*
 * A button with no destination is a <button>, not an <a>, and it needs NOTHING
 * from this stylesheet.
 *
 * This carried `font: inherit` to shake off the user agent's button font, and
 * that was the bug the Loop band showed: `font` is a shorthand, so it also
 * reset the weight, and at (0,2,1) it beat `.ota-btn`'s own (0,1,0) Bold. The
 * label came out at the band's body weight instead. Only the URL-less button
 * was affected, which is why it surfaced on the Loop band and nowhere else:
 * every other instance has a link and renders an <a>.
 *
 * Nothing was needed in the first place. A user agent rule loses to any author
 * rule, and `.ota-btn` already declares the family, the size, weight 700 and
 * line-height 1, so the <button> was fully dressed before this rule ran.
 *
 * Two earlier faults here, kept on the record because both were the same
 * mistake of resetting more than the target: `border: 0` took the design's 2px
 * line off the Outline and Ghost types, same as the Partner Board's.
 */

/* --- The photograph ------------------------------------------------------ */

/*
 * Anchored to the right edge and the full height of the band, which is how the
 * frame draws it: the square is positioned so its top and bottom are outside the
 * band and only the curved left edge is ever visible.
 */
.ota-cta__media {
	position: absolute;
	/*
	 * Both block edges, not a height. This is what makes the photograph follow a
	 * band whose height is now its content's: whatever the text and buttons come
	 * to, the panel is that, with no number to keep in step.
	 */
	inset-block: 0;
	inset-inline-end: 0;
	/*
	 * THE PANEL FOLLOWS THE PHOTOGRAPH, NOT THE OTHER WAY AROUND
	 *
	 * This was a fixed 39.17%, the frame's own proportion, and the photograph was
	 * told to `cover` it. Cover means fill the box and crop whatever does not
	 * fit, so a square photograph in a panel half as tall as it is wide lost the
	 * top and the bottom of itself: heads and legs cut off, which is what Bryce
	 * spotted on 12 Aug 2026.
	 *
	 * An auto width makes the box shrink to fit its content instead. The image
	 * below is the band's height and keeps its own aspect ratio, so the panel
	 * ends up exactly as wide as the whole photograph needs and nothing is
	 * cropped. The frame does crop its own square, so this is a departure from
	 * Figma and a deliberate one.
	 *
	 * The cap is there because the width is now the file's business: a panoramic
	 * upload would otherwise reach across the heading.
	 */
	width: auto;
	max-width: var(--ocb-media-max);
	overflow: hidden;
	/*
	 * Centres the crop. The photograph is scaled taller than this box by
	 * `--ocb-media-zoom`, and a flex centre lets it hang out of both the top and
	 * the bottom by the same amount rather than sitting on the top edge and
	 * losing all of the trim from below.
	 */
	display: flex;
	align-items: center;
	justify-content: center;
	/*
	 * The bow. Horizontal radius on the two left corners against a vertical
	 * radius of half the band, so the two arcs meet at the vertical centre and
	 * read as one curve rather than as two rounded corners. See the note at the
	 * top of this file for why it is rebuilt rather than copied.
	 */
	border-radius: var(--ocb-curve) 0 0 var(--ocb-curve) / 50% 0 0 50%;
}

/*
 * SCOPED TO THE BAND, AND IT HAS TO BE
 *
 * `.ota-cta__image` on its own is 0,1,0 and lost to Elementor's own
 * `.elementor img { height: auto }` at 0,1,1. On a replaced element an auto
 * height is not "as tall as the box", it is the file's own intrinsic height, and
 * `object-fit` then has nothing to fit against. A 1024x1024 photograph was
 * painting a 564x564 square into a 564x389 panel and hanging 175px out of the
 * bottom of it. The panel clips, so nobody ever saw the overflow; what they saw
 * was the crop sitting too high and blamed the photograph.
 *
 * Naming the band lifts this to 0,2,0 and settles it.
 */
.ota-cta .ota-cta__image {
	display: block;
	/*
	 * Height from the band, width from the file. This is the pair that sizes the
	 * photograph: it is scaled to `--ocb-media-zoom` of the section's height and
	 * its width follows its own aspect ratio, which is also what gives the panel
	 * above something to shrink to. At 100% the whole photograph fits; above it
	 * the excess hangs out of the panel and is clipped.
	 *
	 * `max-width` is claimed because the theme's `img { max-width: 100% }` would
	 * otherwise clamp this element to the width of a box that is itself waiting
	 * on this element's width, and the panel would collapse.
	 */
	width: auto;
	height: var(--ocb-media-zoom);
	max-width: none;
	flex: none;

	/*
	 * The one !important in this file, and it answers one rule rather than
	 * hedging. The theme rounds every image in the content area through
	 * `main#agendtheme-content .agendtheme-content-inner:not(...) img`, which
	 * carries an id and so cannot be outranked by any number of classes. The
	 * panel already draws the design's shape and clips to it, so all that rule
	 * contributes here is 4px of band showing through the two square corners.
	 */
	border-radius: 0 !important;
}

/* --- Narrow ------------------------------------------------------------- */

/*
 * The design file has no mobile cut of this band, so this is a decision rather
 * than a translation, and it is made to keep the one thing that identifies the
 * band: the bow.
 *
 * Below 900px the photograph stops being a panel beside the text and becomes a
 * strip under it, and the curve moves from the left edge to the top edge, which
 * is the same gesture rotated rather than a different one. The alternative,
 * leaving the panel where it is, gives the text roughly 55% of a phone screen
 * and a 44px heading does not survive that.
 */
@media (max-width: 900px) {
	.ota-cta {
		flex-direction: column;
		align-items: stretch;
		gap: 40px;
		/* No room for the frame's 103px once the band is a column. */
		padding-block: 48px 0;
		/*
		 * Off here too, so the two layouts agree. Restoring the bow means putting
		 * this back to 90px as well as the desktop token: pixels rather than the
		 * desktop proportion, because the token becomes a vertical radius on a
		 * full width strip in this layout and a percentage would be read against
		 * the screen's width, bowing the top edge harder the wider the phone.
		 */
		--ocb-curve: 0;
	}

	/*
	 * Back in the flow and the full width of the band, so the two rules that make
	 * the desktop panel shrink to its photograph both have to come off: the auto
	 * width is overridden here and the cap has to be lifted, or a strip that is
	 * meant to run edge to edge would stop at 39% of the screen.
	 *
	 * The height goes with them. It was a fixed 260px with the photograph told to
	 * `cover` it, which is the same crop the desktop panel used to do and the same
	 * complaint: on a 500px screen a square photograph lost everything above and
	 * below a 260px slice of its middle, so the two women in the Home page's
	 * banner were a pair of cropped torsos. An auto height lets the strip be
	 * whatever the photograph is at the full width of the screen.
	 */
	.ota-cta__media {
		position: static;
		order: 1;
		display: block;
		width: 100%;
		max-width: none;
		height: auto;
		border-radius: 50% 50% 0 0 / var(--ocb-curve) var(--ocb-curve) 0 0;
	}

	/*
	 * The mirror of the desktop rule: there the height is given and the width
	 * follows, here the width is given and the height follows. The zoom comes off
	 * with it, because there is nothing to crop against once the strip's height
	 * is the photograph's rather than the section's.
	 */
	.ota-cta .ota-cta__image {
		width: 100%;
		height: auto;
	}

	.ota-cta__inner {
		order: 0;
	}

	/*
	 * The reservation comes off with the panel. The photograph is a strip under
	 * the text in this layout rather than a box beside it, so there is nothing
	 * to the right of the words to keep clear of, and leaving 39% of a phone
	 * screen empty would wrap the heading to nothing. Stated as the gutter
	 * rather than 0 so `padding-inline` stays the only place it is named, and
	 * carrying the modifier because the rule it is undoing does: a plain
	 * `.ota-cta__inner` here is 0,1,0 against that rule's 0,2,0 and would lose
	 * inside the media query.
	 */
	.ota-cta--has-media .ota-cta__inner {
		padding-inline-end: var(--ocb-pad);
	}
}

@media (max-width: 600px) {
	.ota-cta {
		--ocb-pad: 1.25rem;
	}
}

/*
 * Nothing here animates, so there is no reduced-motion branch. Said out loud
 * because the sibling blocks all have one and its absence should read as
 * deliberate rather than as an oversight.
 */
