/* Shared calls to action. Page styles own placement, never appearance. */
.brand-action, .book-feature__purchase button, .book-feature__purchase .button { display: inline-flex; align-items: center; justify-content: center; gap: 1rem; min-height: 44px; max-width: 100%; padding: .625rem 1.5625rem; border: 0; border-radius: var(--nav-radius); background-color: var(--brand-navy); color: var(--neutral-warm-ivory); font-family: var(--font-body); font-size: 1rem; font-weight: 400; line-height: 1.5; text-align: center; text-decoration: none; }
.brand-action--light { --action-fill: var(--neutral-warm-ivory); background-color: var(--neutral-white); color: var(--brand-navy); }
/* A solid colour layer grows from the left and retracts towards the same edge. */
.brand-action, .book-feature__purchase .button, .commerce-page :is(.wc-block-components-button:not(.is-link), .woocommerce a.button, .woocommerce button.button) { background-image: linear-gradient(var(--action-fill, color-mix(in srgb, var(--brand-navy) 82%, var(--brand-steel-blue))), var(--action-fill, color-mix(in srgb, var(--brand-navy) 82%, var(--brand-steel-blue)))); background-repeat: no-repeat; background-position: left center; background-size: 0% 100%; transition: background-size 450ms cubic-bezier(.55,.055,.675,.19); }
.brand-action:not(:disabled):not(.disabled):not(.brand-action--unavailable):not([aria-disabled="true"]):focus-visible, .book-feature__purchase .button:not(:disabled):not(.disabled):focus-visible, .commerce-page :is(.wc-block-components-button:not(.is-link), .woocommerce a.button, .woocommerce button.button):not(:disabled):not(.disabled):not([aria-disabled="true"]):focus-visible { background-size: 100% 100%; }
@media (hover: hover) and (pointer: fine) {
  .brand-action:not(:disabled):not(.disabled):not(.brand-action--unavailable):not([aria-disabled="true"]):hover, .book-feature__purchase .button:not(:disabled):not(.disabled):hover, .commerce-page :is(.wc-block-components-button:not(.is-link), .woocommerce a.button, .woocommerce button.button):not(:disabled):not(.disabled):not([aria-disabled="true"]):hover { background-size: 100% 100%; }
}
.brand-action > span:first-child { min-width: 0; }
.brand-action__arrow { display: block; flex: 0 0 13px; width: 13px; height: 13px; }
.brand-action__arrow img { width: 100%; height: 100%; }
.brand-action--unavailable { cursor: not-allowed; }
:is(button.brand-action, .book-feature__purchase button):disabled { opacity: .6; cursor: not-allowed; }
.brand-action:is(a, button):focus-visible, .brand-text-link[href]:focus-visible { outline: 2px solid var(--brand-steel-blue); outline-offset: -2px; }

.brand-text-link { display: inline-flex; align-items: center; gap: 1rem; min-height: 44px; max-width: 100%; color: var(--brand-navy); text-decoration: none; font-family: var(--font-body); font-size: 1rem; font-weight: 600; line-height: 1.4; }
.brand-text-link__label { min-width: 0; overflow-wrap: anywhere; transition: opacity 250ms ease; }
.brand-text-link__icon { --arrow-exit-x: 32px; --arrow-exit-y: -32px; display: grid; place-items: center; position: relative; overflow: hidden; flex: 0 0 40px; width: 40px; height: 40px; border-radius: 50%; background: var(--brand-navy); transition: background-color 250ms; }
.brand-text-link__icon img, .brand-text-link__icon::after { grid-area: 1 / 1; width: 14px; height: 14px; transition: transform 450ms cubic-bezier(.22,.61,.36,1); }
/* The second copy enters from the opposite edge of the clipped circle. */
.brand-text-link__icon::after { content: ''; background: url('../images/arrow-ivory.svg') center / contain no-repeat; transform: translate(calc(-1 * var(--arrow-exit-x)), calc(-1 * var(--arrow-exit-y))); }
.brand-text-link--down .brand-text-link__icon { --arrow-exit-x: 0px; --arrow-exit-y: 32px; }
.brand-text-link--down .brand-text-link__icon img, .brand-text-link--down .brand-text-link__icon::after { rotate: 135deg; }
:is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):focus-visible .brand-text-link__label { opacity: .8; }
:is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):focus-visible .brand-text-link__icon { background: color-mix(in srgb, var(--brand-navy) 82%, var(--brand-steel-blue)); }
:is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):focus-visible .brand-text-link__icon img { transform: translate(var(--arrow-exit-x), var(--arrow-exit-y)); }
:is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):focus-visible .brand-text-link__icon::after { transform: translate(0, 0); }
@media (hover: hover) and (pointer: fine) {
  :is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):hover .brand-text-link__label { opacity: .8; }
  :is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):hover .brand-text-link__icon { background: color-mix(in srgb, var(--brand-navy) 82%, var(--brand-steel-blue)); }
  :is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):hover .brand-text-link__icon img { transform: translate(var(--arrow-exit-x), var(--arrow-exit-y)); }
  :is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):hover .brand-text-link__icon::after { transform: translate(0, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .brand-action, .brand-action__arrow, .brand-text-link__label, .brand-text-link__icon, .brand-text-link__icon img, .brand-text-link__icon::after, .book-feature__purchase :is(button, .button), .commerce-page :is(.wc-block-components-button:not(.is-link), .woocommerce a.button, .woocommerce button.button) { transition: none; }
  .brand-text-link__icon::after { display: none; }
  :is(.brand-text-link[href], .subject-link, .catalogue-book, .about-writing__book):is(:hover, :focus-visible) .brand-text-link__icon img { transform: none; }
}
