/* The new checkout (checkout.php, templates/checkout.html; store plan phase 6).
   Mobile first: one column with the order summary collapsed at the top; from
   900 pixels the summary is a column on the right that stays in view. The
   look is a set of variables, Metric Halo's by default and the partner's on
   its channel (theme-mb: Make Believe's brand notes of 2026-11-10: black and
   white, square corners, uppercase buttons, Helvetica). Inputs are 16 pixels
   so iPhones do not zoom into them. */

:root {
	--page: #f5f5f7;
	--surface: #ffffff;
	--panel: #f5f5f7;
	--text: #1d1d1f;
	--muted: #6e6e73;
	--line: #d2d2d7;
	--focus: #0070e0;
	--button-bg: #1d1d1f;
	--button-text: #ffffff;
	--header-bg: #ffffff;
	--header-text: #1d1d1f;
	--header-line: #d2d2d7;
	/* A bar of its own, so the footer reads as the page's end (B.J.
	   2026-11-18), with the dark-background logo. */
	--footer-bg: #1d1d1f;
	--footer-text: #f5f5f7;
	--error: #b3261e;
	--radius: 8px;
	--button-case: none;
	/* Which version of the logo suits the header's and the footer's
	   backgrounds (block shows it, none hides it), and its height. */
	--header-logo-light: block;
	--header-logo-dark: none;
	--footer-logo-light: none;
	--footer-logo-dark: block;
	--logo-height: 60px;
	/* Our logo's reflection already reads as space under it. */
	--header-pad-top: 18px;
	--header-pad-bottom: 4px;
	/* The lettering's middle sits 40% down the logo, so the header links
	   rise by twice the 10% gap to center on it (B.J. 2026-11-17). */
	--nav-raise: calc(var(--logo-height) * 0.19);
	/* The page's column; the header's links end where it does. */
	--column: 1080px;
	--column-inset: 24px;
	--font: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
}

.theme-mb {
	--page: #ffffff;
	--surface: #ffffff;
	--panel: #f2f2f2;
	--text: #262626;
	--muted: #525252;
	--line: #e5e5e5;
	--focus: #000000;
	--button-bg: #000000;
	--button-text: #ffffff;
	--header-bg: #000000;
	--header-text: #ffffff;
	--header-line: #262626;
	--footer-bg: #000000;
	--footer-text: #a3a3a3;
	--radius: 0;
	--button-case: uppercase;
	--header-logo-light: none;
	--header-logo-dark: block;
	--footer-logo-light: none;
	--footer-logo-dark: block;
	--logo-height: 32px;
	--header-pad-top: 12px;
	--header-pad-bottom: 12px;
	--nav-raise: 0px;
	--font: "Helvetica Neue", Helvetica, "Nimbus Sans", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--text); font-family: var(--font); font-size: 16px; line-height: 1.45; }
.hide { display: none !important; }
a { color: inherit; }
h1, h2 { line-height: 1.2; }

/* Header */
.co-header { position: relative; display: flex; align-items: center; gap: 16px; padding: var(--header-pad-top) 16px var(--header-pad-bottom) 16px; background: var(--header-bg); color: var(--header-text); border-bottom: 1px solid var(--header-line); }
.co-logo img { height: var(--logo-height); width: auto; }
.co-header .co-logo-for-light { display: var(--header-logo-light); }
.co-header .co-logo-for-dark { display: var(--header-logo-dark); }
.co-nav, .co-menu { margin-bottom: var(--nav-raise); }
.co-nav { display: flex; gap: 16px; overflow-x: auto; margin-left: auto; font-size: 14px; white-space: nowrap; scrollbar-width: none; }
.co-nav::-webkit-scrollbar { display: none; }
.co-nav a { color: var(--header-text); text-decoration: none; padding: 8px 0; }
.theme-mb .co-nav a { text-transform: uppercase; letter-spacing: 0.04em; font-size: 13px; }
.co-menu { display: none; margin-left: auto; }
.co-menu summary { display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; margin-right: -10px; list-style: none; cursor: pointer; color: var(--header-text); }
.co-menu summary::-webkit-details-marker { display: none; }
.co-menu summary:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.co-menu-links { position: absolute; left: 0; right: 0; top: 100%; z-index: 20; display: flex; flex-direction: column; padding: 8px 16px; background: var(--header-bg); border-bottom: 1px solid var(--header-line); }
.co-menu-links a { color: var(--header-text); text-decoration: none; padding: 12px 0; font-size: 15px; }
.co-menu-links a + a { border-top: 1px solid var(--header-line); }
.theme-mb .co-menu-links a { text-transform: uppercase; letter-spacing: 0.04em; font-size: 14px; }
@media (max-width: 599px) {
	.co-nav { display: none; }
	.co-menu { display: block; }
}

/* Page states: a cart, an empty one, or checkout closed. */
.co-main { max-width: var(--column); margin: 0 auto; padding: 0 0 32px 0; }
.co-notice { display: none; padding: 48px 16px; text-align: center; }
body[data-state='empty'] .co-empty, body[data-state='checkout-closed'] .co-closed { display: block; }
body[data-state='empty'] .co-form, body[data-state='checkout-closed'] .co-form { display: none; }

/* Layout */
.co-layout { display: flex; flex-direction: column; }
.co-steps { padding: 0 16px; }
.co-title { font-size: 26px; margin: 24px 0 8px 0; }
.co-back { margin: 16px 0 0 0; font-size: 14px; }
.co-back a::before { content: '\2190\00A0'; }
.co-back + .co-title { margin-top: 8px; }
.co-summary-back { margin: 16px 0 0 0; text-align: center; }
.theme-mb .co-title { text-transform: uppercase; letter-spacing: 0.02em; }

@media (min-width: 900px) {
	.co-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 32px; align-items: start; padding: 0 var(--column-inset); }
	.co-header { padding-left: max(var(--column-inset), calc((100% - var(--column)) / 2 + var(--column-inset))); padding-right: max(var(--column-inset), calc((100% - var(--column)) / 2 + var(--column-inset))); }
	.co-steps { padding: 0; grid-column: 1; grid-row: 1; }
	.co-summary { grid-column: 2; grid-row: 1; position: sticky; top: 16px; margin-top: 24px; }
}

/* Summary: collapsed at the top on a phone, a column on a desktop. */
.co-summary { background: var(--panel); border-bottom: 1px solid var(--line); }
.co-summary-toggle { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border: 0; background: none; color: var(--text); font: inherit; font-size: 15px; cursor: pointer; }
.co-summary-toggle .co-summary-hide { display: none; }
.co-summary.open .co-summary-toggle .co-summary-hide { display: inline; }
.co-summary.open .co-summary-toggle .co-summary-show { display: none; }
.co-summary-toggle::after { content: ''; width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); margin-left: -4px; order: 1; }
.co-summary.open .co-summary-toggle::after { transform: rotate(-135deg); }
.co-summary-total { margin-left: auto; font-weight: 700; font-size: 17px; }
.co-summary-body { display: none; padding: 0 16px 16px 16px; }
.co-summary.open .co-summary-body { display: block; }
.co-summary-heading { display: none; font-size: 18px; margin: 0 0 12px 0; }
@media (min-width: 900px) {
	.co-summary { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
	.co-summary-toggle { display: none; }
	.co-summary-body { display: block; padding: 20px; }
	.co-summary-heading { display: block; }
	.theme-mb .co-summary-heading { text-transform: uppercase; letter-spacing: 0.04em; font-size: 15px; }
}

.co-lines { list-style: none; margin: 0; padding: 0; }
.co-line { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.co-line-image { width: 56px; height: 56px; object-fit: contain; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.co-line-image-wide { object-fit: cover; object-position: left center; }
.co-line-text { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.co-line-name { font-weight: 600; overflow-wrap: anywhere; }
.co-line-qty { display: flex; align-items: center; gap: 4px; }
.co-line-ext { font-weight: 600; white-space: nowrap; }
.co-qty { width: 44px; height: 32px; text-align: center; border: 1px solid var(--line); border-radius: var(--radius); font: inherit; font-size: 16px; background: var(--surface); color: var(--text); -moz-appearance: textfield; }
.co-qty::-webkit-outer-spin-button, .co-qty::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.co-qty-step { width: 32px; height: 32px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--text); font-size: 18px; line-height: 1; cursor: pointer; }
.co-remove { margin-left: 8px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13px; text-decoration: underline; cursor: pointer; padding: 6px 2px; }

.co-totals { margin: 12px 0 0 0; }
.co-totals > div { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.co-totals dt { color: var(--muted); }
.co-totals dd { margin: 0; white-space: nowrap; }
.co-totals .co-total { border-top: 1px solid var(--line); margin-top: 8px; padding-top: 12px; font-size: 18px; font-weight: 700; }
.co-totals .co-total dt { color: var(--text); }
.co-paylater { margin: 8px 0 0 0; }

/* Steps */
.co-step { border: 0; border-top: 1px solid var(--line); margin: 0; padding: 20px 0 8px 0; min-width: 0; }
/* A different shipping address (templates/checkout.html, step 4). */
.co-check { display: flex; align-items: center; gap: 8px; margin: 4px 0 12px; cursor: pointer; }
.co-check input { width: 18px; height: 18px; margin: 0; }
.co-ship-to { border: 0; margin: 0; padding: 0; min-width: 0; }
.co-step legend { display: flex; align-items: center; gap: 10px; padding: 0; font-size: 18px; font-weight: 700; float: left; width: 100%; margin-bottom: 12px; }
.co-step legend + * { clear: left; }
.theme-mb .co-step legend { text-transform: uppercase; letter-spacing: 0.04em; font-size: 15px; }
.co-step-n { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; background: var(--button-bg); color: var(--button-text); font-size: 14px; }
.theme-mb .co-step-n { border-radius: 0; }

.co-field { display: block; margin: 0 0 14px 0; }
.co-label { display: block; font-size: 14px; font-weight: 600; margin: 0 0 6px 0; }
.co-optional { font-weight: 400; color: var(--muted); }
.co-hint { font-size: 13px; color: var(--muted); margin: -6px 0 14px 0; }
.co-note { font-size: 14px; background: var(--panel); padding: 10px 12px; border-radius: var(--radius); margin: 0 0 14px 0; }
.co-error { color: var(--error); font-size: 14px; margin: 8px 0; }
.co-signin-line { margin: 0 0 14px 0; font-size: 15px; }
.co-pair { display: flex; flex-wrap: wrap; column-gap: 12px; }
.co-pair > * { flex: 1 1 140px; min-width: 0; }

.co-form input:not([type='hidden']):not([type='checkbox']):not(.co-qty), .co-form select, .co-dialog input {
	display: block; width: 100%; height: 48px; padding: 0 12px; border: 1px solid var(--line); border-radius: var(--radius);
	background: var(--surface); color: var(--text); font: inherit; font-size: 16px;
}
.co-form select {
	-webkit-appearance: none; appearance: none; padding-right: 36px;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23666' stroke-width='1.6'/%3E%3C/svg%3E");
	background-repeat: no-repeat; background-position: right 14px center;
}
.co-form input:focus, .co-form select:focus, .co-dialog input:focus, .co-qty:focus { outline: none; border-color: var(--focus); box-shadow: 0 0 0 1px var(--focus); }
.co-form input:user-invalid, .co-form select:user-invalid { border-color: var(--error); }

.guest .co-signed-in-only, .signed-in .co-guest-only { display: none !important; }
/* The hardware terms, confirmed before paying (js/checkout.js). */
.co-terms-list { margin: 0 0 16px 0; padding-left: 20px; font-size: 14px; line-height: 1.45; }
.co-terms-list li { margin: 8px 0; }
.co-terms-total { margin: 0 0 12px 0; text-align: center; font-size: 16px; font-weight: 600; }

/* The split order's offer and the receipt's way to the rest (store hardware plan step 3). */
.co-split-note a { color: inherit; font-weight: 600; }
.co-split-next { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }

.co-link { border: 0; padding: 0; background: none; color: inherit; font: inherit; text-decoration: underline; cursor: pointer; }

/* Payment */
#pp-methods .pp-ways { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 4px; }
.pp-way { flex: 1 1 150px; min-width: 0; height: 48px; }
/* A cart with hardware is authorized, not captured, which Pay Later is not
   documented to do, so it is hidden unless the quote says it captures
   instead (store hardware plan step 2, SOFTWARESALES_HARDWARE_PAY_LATER_CAPTURES). */
.co-no-paylater #pp-top-paylater,
.co-no-paylater #pp-paylater-row { display: none !important; }
.pp-way > * { display: block; width: 100%; height: 48px; }
.pp-way apple-pay-button { --apple-pay-button-width: 100%; --apple-pay-button-height: 48px; --apple-pay-button-border-radius: 4px; }
.pp-or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; margin: 16px 0; }
.pp-or::before, .pp-or::after { content: ''; flex: 1; border-top: 1px solid var(--line); }
#pp-card-fields .pp-field { min-height: 48px; margin: 0 0 10px 0; }
#pp-card-fields paypal-hosted-card-field { display: block; height: 48px; width: 100%; }
/* Each robot check sits below its button, so when it does show (rarely,
   to ask the visitor to click) the button stays put (B.J. 2026-11-18). */
#turnstile-checkout { margin: 8px 0; }
#turnstile-login, #turnstile-demo { margin-top: 8px; }

.co-button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 24px; border: 0; border-radius: var(--radius);
	background: var(--button-bg); color: var(--button-text); font: inherit; font-size: 16px; font-weight: 700; text-decoration: none; text-transform: var(--button-case); letter-spacing: 0.02em; cursor: pointer; }
.co-pay { width: 100%; margin: 8px 0 4px 0; font-size: 17px; }
.co-button:disabled { opacity: 0.4; cursor: default; }
/* A sign-in still waiting after a second (js/checkout.js, js/store.js): a
   spinner in place of the label, which stays for screen readers. */
.co-button.co-spinning, .co-button.co-spinning:disabled { position: relative; color: transparent; opacity: 1; }
.co-button.co-spinning::after { content: ''; position: absolute; top: 50%; left: 50%; width: 20px; height: 20px; margin: -10px 0 0 -10px; border: 2px solid var(--button-text); border-right-color: transparent; border-radius: 50%; animation: co-spin 0.8s linear infinite; }
@keyframes co-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .co-button.co-spinning::after { animation-duration: 2.4s; } }
.co-button-secondary { background: var(--surface); color: var(--text); box-shadow: inset 0 0 0 1px var(--text); }

/* The sign-in offer at the top of checkout, for a buyer not signed in. */
.co-signin-panel { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 16px; margin: 0 0 20px 0; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.co-signin-text { flex: 1 1 220px; margin: 0; font-size: 15px; }
.co-signin-text strong { display: block; margin-bottom: 2px; }
.co-signin-panel .co-button { flex: 0 0 auto; }
/* Signed in: the welcome and a Sign out button (B.J. 2026-11-18: a link
   was "too easy to miss"). */
/* The order summary's offer code (SoftwareSalesCheckoutOfferHtml()). */
.co-offer { margin: 12px 0 4px; }
.co-offer .co-offer-open { width: 100%; }
.co-offer-applied { margin: 0; font-size: 0.95em; }
#co-offer-why p { margin: 0; }
.co-signed-in-panel { margin-bottom: 14px; padding: 12px 16px; }
.co-signout { min-height: 40px; padding: 0 18px; font-size: 15px; }
.co-processed { text-align: center; font-size: 13px; color: var(--muted); margin: 10px 0 4px 0; }
.co-processed::before { content: '\1F512\00A0'; }
.co-terms { font-size: 14px; color: var(--muted); margin: 0 0 20px 0; }
.co-terms .co-link { font-size: inherit; color: var(--text); }

/* Dialogs: sign in, and progress or a message. */
.co-dialog { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(0, 0, 0, 0.5); }
.co-dialog-box { width: 100%; max-width: 420px; max-height: 100%; overflow: auto; background: var(--surface); color: var(--text); border-radius: var(--radius); padding: 24px; text-align: left; }
.co-dialog-box h2 { margin: 0 0 16px 0; font-size: 20px; }
.co-dialog-box .co-button { width: 100%; margin-top: 8px; }
.co-dialog-links { display: flex; justify-content: space-between; margin: 14px 0 0 0; font-size: 14px; }
#co-dialog-text p { margin: 8px 0; }
#co-cart-choice .co-dialog-box { max-width: 560px; }
.co-choice { display: grid; grid-template-columns: 1fr; gap: 12px; margin: 16px 0 8px 0; }
@media (min-width: 520px) { .co-choice { grid-template-columns: 1fr 1fr; } }
.co-choice-cart { border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; }
.co-choice-cart h3 { margin: 0 0 8px 0; font-size: 15px; }
.co-choice-cart ul { margin: 0; padding-left: 18px; }
.co-choice-cart li { margin: 4px 0; }
.co-spinner { width: 36px; height: 36px; margin: 8px auto 16px auto; border: 3px solid var(--line); border-top-color: var(--text); border-radius: 50%; animation: co-spin 0.9s linear infinite; }
@keyframes co-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .co-spinner { animation-duration: 3s; } }

/* Footer */
.co-footer { background: var(--footer-bg); color: var(--footer-text); padding: 32px 16px; font-size: 14px; text-align: center; }
.co-footer-logo { display: block; margin-bottom: 12px; }
.co-footer-logo img { height: 32px; width: auto; margin: 0 auto; }
.co-footer .co-logo-for-light { display: var(--footer-logo-light); }
.co-footer .co-logo-for-dark { display: var(--footer-logo-dark); }
.theme-mh .co-footer-logo { display: none; }
.co-footer-line { max-width: 560px; margin: 0 auto 16px auto; }
.co-footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 20px; margin-bottom: 16px; }
.co-footer-links a { color: var(--footer-text); }
.co-footer-contact span { display: block; }
.co-footer-bottom { margin: 16px 0 0 0; font-size: 12px; }
.co-footer-bottom span + span::before { content: '· '; }

/* The receipt (templates/checkout-receipt.html) */
/* The receipt is one narrower column, and its header lines up with it at
   every width. */
.co-receipt-page { --column: 720px; --column-inset: 16px; }
.co-receipt { max-width: var(--column); padding: 0 var(--column-inset) 32px var(--column-inset); }
.co-receipt-page .co-header { padding-left: max(var(--column-inset), calc((100% - var(--column)) / 2 + var(--column-inset))); padding-right: max(var(--column-inset), calc((100% - var(--column)) / 2 + var(--column-inset))); }
.co-receipt-number { color: var(--muted); margin: 0 0 16px 0; }
.co-receipt-heading { font-size: 18px; margin: 28px 0 12px 0; }
.theme-mb .co-receipt-heading { text-transform: uppercase; letter-spacing: 0.04em; font-size: 15px; }
.co-licenses { list-style: none; margin: 0 0 16px 0; padding: 0; }
.co-license { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.co-license-name { font-weight: 600; }
.co-license-code-line { grid-column: 1; font-size: 14px; color: var(--muted); }
.co-license-code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 14px; overflow-wrap: anywhere; }
.co-license-download { grid-column: 2; grid-row: 1 / span 2; align-self: center; min-height: 40px; padding: 0 18px; }
.co-receipt-help { margin: 0 0 24px 0; }
.co-set-password { margin: 0 0 24px 0; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.co-set-password .co-receipt-heading { margin-top: 0; }
.co-set-password p { margin: 0 0 12px 0; }
.co-set-password .co-set-password-action { text-align: center; margin: 24px 0; }
.co-set-password .co-hint { text-align: center; }
.co-set-password p:last-child { margin-bottom: 0; }
.co-receipt-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 16px; }
