/* ==========================================================================
   CardsCo — public card catalogue
   Measured from the 1440 frame: four columns from x=80, tiles 302 wide,
   24px gutter, 384px row pitch.
   ========================================================================== */

.cc-cat {
	--cc-green-600: #0F5A43;
	--cc-green-700: #0C4836;
	--cc-ink:       #14231B;
	--cc-body:      #57554F;
	--cc-quiet:     #6F6D67;
	--cc-line:      #D1CFC9;
	--cc-line-soft: #EBEAE6;
	--cc-wash:      #F2F2EF;

	--cc-font-ui:      'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
	--cc-font-display: 'EB Garamond', Georgia, 'Times New Roman', serif;

	box-sizing: border-box;
	width: 100%;
	max-width: 1360px;              /* 80px gutter each side of 1440 */
	margin: 0 auto;
	padding: 0 clamp(20px, 5vw, 40px);
	font-family: var(--cc-font-ui);
	color: var(--cc-ink);
}

.cc-cat *, .cc-cat *::before, .cc-cat *::after { box-sizing: border-box; }

/* -------------------------------------------------------------- heading */

.cc-cat-head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 16px;
	/* The frame puts the heading 133px down the page, but 72 of that is the
	   nav bar, which here is a separate element above the shortcode. The gap
	   that belongs to this block is the 61px between them, plus 3 for the
	   line box sitting above the glyph. */
	padding-top: clamp(40px, 5vw, 64px);
}

.cc-cat-head-text { flex: 1 1 520px; min-width: 0; }

.cc-cat h1 {
	margin: 0 0 14px;
	font: 400 clamp(30px, 4vw, 40px) / 1.15 var(--cc-font-display);
	letter-spacing: -.005em;
	color: var(--cc-ink);
}

.cc-cat-lede {
	max-width: 620px;
	margin: 0;
	font: 400 16px/24px var(--cc-font-ui);
	color: var(--cc-body);
}

.cc-cat-count {
	margin: 0;
	font: 400 14px/20px var(--cc-font-ui);
	color: var(--cc-quiet);
	white-space: nowrap;
}

/* --------------------------------------------------------- filter pills */

.cc-cat-filters {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 36px;
}

.cc-pill-filter {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 34px;
	padding: 7px 14px;
	border: 1px solid var(--cc-line);
	border-radius: 9999px;
	background: #FFFFFF;
	font: 400 13px/18px var(--cc-font-ui);
	color: var(--cc-ink);
	text-decoration: none;
}

.cc-pill-filter:hover { border-color: var(--cc-ink); color: var(--cc-ink); }

.cc-pill-filter.is-on {
	background: var(--cc-green-600);
	border-color: var(--cc-green-600);
	color: #FFFFFF;
}

.cc-pill-n { font-size: 12px; color: var(--cc-quiet); }
.cc-pill-filter.is-on .cc-pill-n { color: rgba(255, 255, 255, .72); }

/* ----------------------------------------------------------------- sort */

.cc-cat-sort {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-top: 32px;
}

.cc-cat-sort-label { font: 400 13px/18px var(--cc-font-ui); color: var(--cc-body); }

.cc-cat-sort select {
	height: 36px;
	padding: 0 32px 0 12px;
	border: 1px solid var(--cc-line);
	border-radius: 8px;
	background: #FFFFFF no-repeat right 10px center;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2314231B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
	font: 500 13px/18px var(--cc-font-ui);
	color: var(--cc-ink);
	appearance: none;
}

.cc-cat-sort select:focus {
	outline: none;
	border-color: var(--cc-green-600);
	box-shadow: 0 0 0 3px rgba(15, 90, 67, .18);
}

.cc-cat-sort-go {
	height: 36px;
	padding: 0 14px;
	border: 1px solid var(--cc-line);
	border-radius: 8px;
	background: #FFFFFF;
	font: 500 13px/18px var(--cc-font-ui);
	cursor: pointer;
}

/* ----------------------------------------------------------------- grid */

.cc-cat-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 58px 24px;                 /* gives the frame's 384px row pitch */
	margin: 51px 0 0;
	padding: 0;
	list-style: none;
}

.cc-cat-tile { min-width: 0; }

.cc-cat-art {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 302 / 272;
	margin-bottom: 14px;
	border-radius: 12px;
	background: #F6F6F3;
	overflow: hidden;

	/* Room for the card's shadow, which the well would otherwise clip. */
	padding: 12px;
}

.cc-cat-art img {
	display: block;

	/*
	 * As large as the well allows. These were held to 58% by 74%, which
	 * left every design floating in a field of grey — and because the
	 * cards are a mix of portrait and landscape, the smaller ones looked
	 * smaller still. Filling on both axes lets each one take whichever
	 * edge its own shape reaches first: a portrait card fills the height,
	 * a landscape one fills the width, and neither is cropped.
	 */
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	border-radius: 6px;
	box-shadow: 0 6px 18px rgba(20, 35, 27, .14);
}

.cc-cat-art-blank {
	width: 100%;
	height: 100%;
	border-radius: 6px;
	background: #E6E6E1;
}

/* Hover actions. Always reachable by keyboard, never hidden from it. */
.cc-cat-actions {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 12px;
	display: flex;
	justify-content: center;
	gap: 8px;
	opacity: 0;
	transition: opacity .12s ease-in-out;
}

.cc-cat-tile:hover .cc-cat-actions,
.cc-cat-actions:focus-within { opacity: 1; }

.cc-cat-preview,
.cc-cat-use {
	display: inline-flex;
	align-items: center;
	min-height: 32px;
	padding: 7px 12px;
	border-radius: 8px;
	font: 500 13px/18px var(--cc-font-ui);
	text-decoration: none;
	white-space: nowrap;
}

.cc-cat-preview { background: #FFFFFF; color: var(--cc-ink); border: 1px solid var(--cc-line); }
.cc-cat-preview:hover { background: var(--cc-wash); color: var(--cc-ink); }
.cc-cat-use { background: var(--cc-green-600); color: #FFFFFF; border: 1px solid var(--cc-green-600); }
.cc-cat-use:hover { background: var(--cc-green-700); color: #FFFFFF; }

/* The preview label carries the card's name for screen readers; only the
   first word is drawn, as the frame has it. */
.cc-cat-preview { position: relative; font-size: 0; }
.cc-cat-preview::before { content: "Preview"; font-size: 13px; }

.cc-cat-meta {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
}

.cc-cat-name {
	margin: 0;
	font: 500 14px/20px var(--cc-font-ui);
	color: var(--cc-ink);
}

.cc-cat-pattern {
	margin: 0;
	font: 400 12px/16px var(--cc-font-ui);
	color: var(--cc-quiet);
	white-space: nowrap;
}

.cc-cat-occasions {
	margin: 2px 0 0;
	font: 400 13px/18px var(--cc-font-ui);
	color: var(--cc-body);
}

/* ----------------------------------------------------------------- foot */

.cc-cat-foot {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	padding: 40px 0 80px;
}

.cc-cat-showing { margin: 0; font: 400 13px/18px var(--cc-font-ui); color: var(--cc-body); }

.cc-cat-more {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 12px 22px;
	border: 1px solid var(--cc-line);
	border-radius: 10px;
	background: #FFFFFF;
	font: 500 14px/20px var(--cc-font-ui);
	color: var(--cc-ink);
	text-decoration: none;
}

.cc-cat-more:hover { background: var(--cc-wash); color: var(--cc-ink); }

.cc-cat-empty {
	margin: 56px 0 80px;
	font: 400 16px/24px var(--cc-font-ui);
	color: var(--cc-body);
}

/* -------------------------------------------------------------- smaller */

@media (max-width: 1100px) { .cc-cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px 20px; } }
@media (max-width: 820px)  { .cc-cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 16px; } }

@media (max-width: 520px) {
	.cc-cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 12px; }
	.cc-cat-head { align-items: flex-start; }
	.cc-cat-count { order: -1; }
	/*
	 * No hover on a phone, so the actions have to be on the page rather
	 * than waiting for a pointer. Taking them out of position: absolute
	 * dropped them into the art well's own flex row, because that is
	 * where they sit in the markup — so a 189px pair of buttons was laid
	 * out beside the card inside a 139px tile, which squeezed the card
	 * to a sliver and pushed "Use this card" off the right edge.
	 *
	 * The well becomes a column at this width instead: card on top,
	 * buttons underneath, both inside it. Nothing overflows and nothing
	 * sits on top of the artwork.
	 */
	.cc-cat-art {
		flex-direction: column;
		align-items: center;
		justify-content: flex-start;
		aspect-ratio: auto;
		padding: 16px 12px 12px;
	}

	/*
	 * The well no longer has a fixed aspect ratio at this width, so the
	 * percentage heights these carry resolve against nothing and the
	 * card collapsed to no height at all. Both get a shape of their own.
	 */
	.cc-cat-art img {
		max-width: 100%;
		max-height: 190px;
	}

	.cc-cat-art-blank {
		width: auto;
		height: 190px;
		aspect-ratio: 5 / 7;
	}

	.cc-cat-actions {
		position: static;
		opacity: 1;
		width: 100%;
		margin-top: 12px;
		flex-wrap: wrap;
	}

	/* Share the row, and take a line each when they cannot. */
	.cc-cat-preview,
	.cc-cat-use {
		flex: 1 1 auto;
		justify-content: center;
		padding: 7px 8px;
	}
}

@media (hover: none) { .cc-cat-actions { opacity: 1; } }

/* ==========================================================================
   Collections

   The front door to the catalogue: six tiles, each landing on the catalogue
   with that collection selected. No approved frame exists for this screen —
   the catalogue is in the Figma and this is not — so it reuses the .cc-cat
   container, type scale and tile treatment rather than inventing a second
   visual language.

   Three across at 1440 rather than the catalogue's four: there are only six,
   and each carries a blurb as well as a name.
   ========================================================================== */

.cc-coll-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 32px 24px;
	margin: 44px 0 0;
	padding: 0;
	list-style: none;
}

.cc-coll-tile { min-width: 0; }

.cc-coll-card {
	display: flex;
	flex-direction: column;
	height: 100%;
	border: 1px solid var(--cc-line);
	border-radius: 14px;
	background: #FFFFFF;
	overflow: hidden;
	text-decoration: none;
	color: inherit;
	transition: border-color .15s ease, transform .15s ease;
}

a.cc-coll-card:hover {
	border-color: var(--cc-ink);
	transform: translateY(-2px);
}

a.cc-coll-card:focus-visible {
	outline: 2px solid var(--cc-green-600);
	outline-offset: 2px;
}

/* ------------------------------------------------------------------- art */

/* The same treatment as a catalogue tile: the card sits in the panel, whole
   and shadowed, rather than being cropped to fill it. Cards are portrait and
   the panel is landscape, so cover would cut the artwork in half. */
.cc-coll-art {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 302 / 176;
	background: #F6F6F3;
	overflow: hidden;
}

.cc-coll-art img {
	display: block;
	max-width: 34%;
	max-height: 78%;
	width: auto;
	height: auto;
	border-radius: 6px;
	box-shadow: 0 6px 18px rgba(20, 35, 27, .14);
}

/* Nothing in the collection yet, so there is no artwork to borrow. A blank
   in the shape of a card rather than a broken image or a stock placeholder. */
.cc-coll-art-blank {
	display: block;
	width: 34%;
	height: 78%;
	border-radius: 6px;
	background: #E6E6E1;
}

.cc-coll-chip {
	position: absolute;
	top: 12px;
	left: 12px;
	padding: 4px 10px;
	border-radius: 9999px;
	background: rgba(20, 35, 27, .82);
	font: 500 12px/16px var(--cc-font-ui);
	color: #FFFFFF;
}

/* ------------------------------------------------------------------ body */

.cc-coll-body {
	display: flex;
	flex-direction: column;
	gap: 6px;
	flex: 1 1 auto;
	padding: 18px 20px 20px;
}

.cc-coll-name {
	font: 400 21px/1.2 var(--cc-font-display);
	color: var(--cc-ink);
}

.cc-coll-blurb {
	flex: 1 1 auto;
	font: 400 14px/21px var(--cc-font-ui);
	color: var(--cc-body);
}

.cc-coll-meta {
	padding-top: 10px;
	border-top: 1px solid var(--cc-line-soft);
	font: 400 13px/18px var(--cc-font-ui);
	color: var(--cc-quiet);
}

.cc-coll-tile.is-empty .cc-coll-card { background: var(--cc-wash); }
.cc-coll-tile.is-empty .cc-coll-name { color: var(--cc-body); }

/* ------------------------------------------------------------------- foot */

.cc-coll-all { margin: 36px 0 0; }

/* ------------------------------------------------------------ breakpoints */

@media (max-width: 1100px) { .cc-coll-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 20px; } }

@media (max-width: 640px) {
	.cc-coll-grid { grid-template-columns: 1fr; gap: 20px; margin-top: 32px; }
	/* One per row on a phone, so the panel gets shallower and the card
	   smaller — otherwise a single tile fills the screen. */
	.cc-coll-art  { aspect-ratio: 302 / 132; }
	.cc-coll-art img,
	.cc-coll-art-blank { max-width: 24%; width: auto; }
	.cc-coll-art-blank { width: 24%; }
}

/* ==========================================================================
   Preview panel

   Opens over the grid from a tile's Preview action, so somebody can look
   through the library without losing their filter or their place in it.

   No approved frame for this either, so it reuses the catalogue's tokens and
   the tile's art treatment: the card whole and shadowed on a wash, never
   cropped.
   ========================================================================== */

.cc-pv {
	width: min(920px, calc(100vw - 32px));
	max-width: none;
	max-height: calc(100vh - 48px);
	padding: 0;
	border: 0;
	border-radius: 16px;
	background: #FFFFFF;
	color: var(--cc-ink);
	font-family: var(--cc-font-ui);
	overflow: visible;
}

.cc-pv::backdrop {
	background: rgba(20, 35, 27, .55);
	backdrop-filter: blur(2px);
}

.cc-pv-inner {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 380px) minmax(0, 1fr);
	gap: 0;
	max-height: calc(100vh - 48px);
	border-radius: 16px;
	overflow: hidden;
}

/* --------------------------------------------------------------------- art */

.cc-pv-art {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 36px 28px;
	background: #F6F6F3;
}

.cc-pv-art img {
	display: block;
	max-width: 100%;
	max-height: min(58vh, 460px);
	width: auto;
	height: auto;
	border-radius: 8px;
	box-shadow: 0 10px 30px rgba(20, 35, 27, .18);
}

/* -------------------------------------------------------------------- body */

.cc-pv-body {
	display: flex;
	flex-direction: column;
	gap: 0;
	padding: 36px 32px 28px;
	overflow-y: auto;
}

.cc-pv-collection {
	margin: 0 0 8px;
	font: 500 12px/16px var(--cc-font-ui);
	letter-spacing: .06em;
	text-transform: uppercase;
	color: var(--cc-quiet);
}

.cc-pv-collection:empty { display: none; }

.cc-pv-title {
	margin: 0;
	font: 400 28px/1.18 var(--cc-font-display);
	letter-spacing: -.005em;
	color: var(--cc-ink);
}

.cc-pv-pattern {
	margin: 6px 0 0;
	font: 400 14px/20px var(--cc-font-ui);
	color: var(--cc-quiet);
}

.cc-pv-pattern:empty { display: none; }

/* ------------------------------------------------------------------- facts */

.cc-pv-facts {
	margin: 22px 0 0;
	padding: 18px 0 0;
	border-top: 1px solid var(--cc-line-soft);
}

.cc-pv-fact { margin: 0 0 14px; }
.cc-pv-fact:last-child { margin-bottom: 0; }
.cc-pv-fact[hidden] { display: none; }

.cc-pv-facts dt {
	margin: 0 0 3px;
	font: 500 12px/16px var(--cc-font-ui);
	letter-spacing: .04em;
	text-transform: uppercase;
	color: var(--cc-quiet);
}

.cc-pv-facts dd {
	margin: 0;
	font: 400 15px/22px var(--cc-font-ui);
	color: var(--cc-ink);
}

.cc-pv-note {
	margin: 20px 0 0;
	font: 400 14px/21px var(--cc-font-ui);
	color: var(--cc-body);
}

/* ----------------------------------------------------------------- actions */

.cc-pv-actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
	margin-top: auto;
	padding-top: 26px;
}

.cc-pv-use {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 46px;
	padding: 12px 22px;
	border: 1px solid var(--cc-green-600);
	border-radius: 10px;
	background: var(--cc-green-600);
	font: 500 15px/1.2 var(--cc-font-ui);
	color: #FFFFFF;
	text-decoration: none;
}

.cc-pv-use:hover { background: var(--cc-green-700); border-color: var(--cc-green-700); color: #FFFFFF; }

/* ------------------------------------------------------------ close and nav */

.cc-pv-close {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 34px;
	height: 34px;
	padding: 0;
	border: 1px solid var(--cc-line-soft);
	border-radius: 50%;
	background: #FFFFFF;
	font-size: 20px;
	line-height: 1;
	color: var(--cc-body);
	cursor: pointer;
}

.cc-pv-close:hover { border-color: var(--cc-ink); color: var(--cc-ink); }

.cc-pv-nav {
	position: absolute;
	left: 0;
	bottom: 12px;
	display: flex;
	align-items: center;
	gap: 6px;
	width: 380px;
	justify-content: center;
}

.cc-pv-arrow {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 1px solid var(--cc-line);
	border-radius: 50%;
	background: #FFFFFF;
	font-size: 18px;
	line-height: 1;
	color: var(--cc-ink);
	cursor: pointer;
}

.cc-pv-arrow:hover { border-color: var(--cc-ink); background: var(--cc-wash); }

.cc-pv-count {
	min-width: 56px;
	font: 400 13px/18px var(--cc-font-ui);
	color: var(--cc-quiet);
	text-align: center;
}

.cc-pv-close:focus-visible,
.cc-pv-arrow:focus-visible,
.cc-pv-use:focus-visible {
	outline: 2px solid var(--cc-green-600);
	outline-offset: 2px;
}

/* ------------------------------------------------------------ breakpoints */

@media (max-width: 760px) {
	.cc-pv { width: calc(100vw - 20px); }

	.cc-pv-inner { grid-template-columns: 1fr; }

	/* The panel scrolls as one on a phone rather than the body scrolling
	   inside a fixed frame, which traps the actions off-screen. */
	.cc-pv-inner { overflow-y: auto; }
	.cc-pv-body  { overflow-y: visible; padding: 24px 22px 76px; }
	.cc-pv-art   { padding: 26px 22px; }
	.cc-pv-art img { max-height: 38vh; }
	.cc-pv-title { font-size: 24px; }

	.cc-pv-actions > a { flex: 1 1 100%; }

	/* Pinned to the panel, not the art column, now there is only one. */
	.cc-pv-nav {
		position: sticky;
		bottom: 0;
		width: 100%;
		padding: 10px 0;
		background: linear-gradient(to top, #FFFFFF 70%, rgba(255, 255, 255, 0));
	}
}

/* ---------------------------------------------------------- send a card */

/*
 * The Sending Card frames sit inside the signed-in app, with Drafts and
 * Sent cards down the side. This page has to work for somebody who has
 * never signed in, so what is kept is the middle of each frame — the
 * 500-wide panel the work happens in — on a plain page.
 */

.cc-send {
	max-width: 620px;
	margin: 0 auto;
	padding: clamp(24px, 5vw, 56px) 20px;
}

/* --- the four steps --- */

/*
 * Scoped one level deeper than the element it sits in, so an ordinary
 * theme rule for the wrapper cannot outrank the row itself. The markup
 * is divs with list roles for the same reason: a page builder's rule on
 * li beat this and scattered the steps onto separate baselines.
 */
.cc-send .cc-send-steps {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--cc-space-8, 8px);
	margin: 0 0 24px;
	padding: 0;
	list-style: none;
}

.cc-send .cc-send-step {
	display: flex;
	align-items: center;
	gap: 6px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 13px;
	white-space: nowrap;
}

.cc-send-step a {
	display: flex;
	align-items: center;
	gap: 6px;
	color: inherit;
	text-decoration: none;
}

.cc-send-step a:hover { color: var(--cc-ink, #14231B); }

.cc-send-step + .cc-send-step::before {
	content: "";
	width: 14px;
	height: 1px;
	margin-right: 2px;
	background: var(--cc-line, #D1CFC9);
}

.cc-send-step-n {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	border: 1px solid var(--cc-line, #D1CFC9);
	border-radius: 50%;
	font-size: 12px;
}

.cc-send-step.is-on { color: var(--cc-ink, #14231B); }
.cc-send-step.is-on .cc-send-step-n {
	border-color: var(--cc-green-600, #0F5A43);
	background: var(--cc-green-600, #0F5A43);
	color: #FFFFFF;
}

.cc-send-step.is-done .cc-send-step-n {
	border-color: var(--cc-green-600, #0F5A43);
	color: var(--cc-green-600, #0F5A43);
}

/* --- the panel --- */

.cc-send-panel {
	padding: clamp(20px, 4vw, 32px);
	border: 1px solid var(--cc-line-soft, #EBEAE6);
	border-radius: 16px;
	background: #FFFFFF;
}

.cc-send-title {
	margin: 0;
	color: var(--cc-ink, #14231B);
	font-family: var(--cc-font-display, Georgia, serif);
	font-size: clamp(26px, 4vw, 34px);
	font-weight: 400;
	letter-spacing: -0.01em;
	line-height: 1.15;
}

.cc-send-sub {
	margin: 8px 0 24px;
	color: var(--cc-body, #57554F);
	font-size: 14px;
}

.cc-send-error {
	margin: 0 0 16px;
	padding: 12px 14px;
	border: 1px solid #E7C9C2;
	border-radius: 10px;
	background: #FBF1EE;
	color: #8A3524;
	font-size: 14px;
}

/* --- fields --- */

.cc-send-fields {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
}

.cc-send .cc-field { margin: 0; }
.cc-send .cc-field-wide { grid-column: 1 / -1; }

.cc-send .cc-field label {
	display: block;
	margin-bottom: 6px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 12px;
}

/*
 * Named cc-send-opt, not cc-opt. The dashboard already uses .cc-opt for
 * a bordered, selectable option card, and both stylesheets load on this
 * page — so this little "Optional" beside a label was drawn as one of
 * those cards: a second empty box under every optional field, which
 * looked like a broken form rather than a clash of names.
 */
.cc-send .cc-send-opt {
	font-size: var(--cc-caption-size);
	font-weight: var(--cc-weight-regular);
	letter-spacing: normal;
	text-transform: none;
	color: var(--cc-text-tertiary);
}

.cc-send input[type="text"],
.cc-send textarea {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid var(--cc-line, #D1CFC9);
	border-radius: 8px;
	background: #FFFFFF;
	color: var(--cc-ink, #14231B);
	font-family: inherit;
	font-size: 15px;
}

.cc-send input[type="text"]:focus,
.cc-send textarea:focus {
	border-color: var(--cc-green-600, #0F5A43);
	outline: 2px solid rgba(15, 90, 67, 0.18);
}

.cc-send textarea { min-height: 140px; resize: vertical; }

.cc-send-count {
	display: block;
	margin-top: 6px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 12px;
}

.cc-send-count.is-over { color: #8A3524; }

/* The limit sits beside the running count, not under it: two stacked grey
   lines under the box read as one wrapped sentence. */
/* The card on the order summary: art, name and the way back to another. */
.cc-send-sum-card {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
}

.cc-send-sum-art {
	width: 44px;
	height: 44px;
	object-fit: cover;
	border-radius: 6px;
	flex: 0 0 auto;
}

.cc-send-sum-card-name { font-weight: 500; }

/* Its own, not .cc-link: that one lives in dashboard.css, which no public
   page loads, so borrowing it leaves an unstyled link on the order step. */
.cc-send-sum-change {
	font-size: 13px;
	font-weight: 500;
	color: var(--cc-illus-ink, #2F4F3E);
	text-decoration: none;
}

.cc-send-sum-change:hover { text-decoration: underline; }

.cc-send-limit {
	display: block;
	margin-top: 2px;
	/* Clear of the next field's label: without it the limit and "Sign it"
	   sit on top of each other and read as one block. */
	margin-bottom: 14px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 12px;
}

/* --- starters --- */

.cc-send-starters { margin-bottom: 18px; }

.cc-send-starters-head {
	margin: 0 0 8px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 12px;
}

.cc-send-chips { display: flex; flex-wrap: wrap; gap: 8px; }

.cc-send-chip {
	padding: 6px 12px;
	border: 1px solid var(--cc-line, #D1CFC9);
	border-radius: 999px;
	background: #FFFFFF;
	color: var(--cc-body, #57554F);
	font-family: inherit;
	font-size: 13px;
	cursor: pointer;
}

.cc-send-chip:hover {
	border-color: var(--cc-green-600, #0F5A43);
	color: var(--cc-ink, #14231B);
}

/* --- picking a card --- */

.cc-send-cards {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
	gap: 14px;
}

.cc-send-card {
	display: block;
	padding: 8px;
	border: 1px solid var(--cc-line-soft, #EBEAE6);
	border-radius: 12px;
	cursor: pointer;
}

.cc-send-card input { position: absolute; opacity: 0; width: 0; height: 0; }

.cc-send-card img {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 8px;
}

.cc-send-card-name {
	display: block;
	margin-top: 8px;
	color: var(--cc-body, #57554F);
	font-size: 13px;
}

/* Follows the radio, so the choice shows the moment it is made and not
   only after the page comes back. */
.cc-send-card:has(input:checked) {
	border-color: var(--cc-green-600, #0F5A43);
	box-shadow: inset 0 0 0 1px var(--cc-green-600, #0F5A43);
}

.cc-send-card.is-on {
	border-color: var(--cc-green-600, #0F5A43);
	box-shadow: inset 0 0 0 1px var(--cc-green-600, #0F5A43);
}

/* --- the order --- */

.cc-send-sum { margin: 0 0 20px; }

.cc-send-sum-row {
	display: grid;
	grid-template-columns: 90px minmax(0, 1fr);
	gap: 12px;
	padding: 12px 0;
	border-bottom: 1px solid var(--cc-line-soft, #EBEAE6);
}

.cc-send-sum dt { color: var(--cc-quiet, #6F6D67); font-size: 13px; }
.cc-send-sum dd { margin: 0; color: var(--cc-ink, #14231B); font-size: 14px; }

.cc-send-sum-quiet {
	display: block;
	margin-top: 2px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 13px;
}

.cc-send-sum-msg {
	color: var(--cc-body, #57554F);
	font-style: italic;
}

.cc-send-lines { margin-bottom: 16px; }

.cc-send-line {
	display: flex;
	justify-content: space-between;
	gap: 16px;
	margin: 0;
	padding: 8px 0;
	color: var(--cc-body, #57554F);
	font-size: 14px;
}

.cc-send-total {
	padding-top: 14px;
	border-top: 1px solid var(--cc-line, #D1CFC9);
	color: var(--cc-ink, #14231B);
}

.cc-send-total span:last-child {
	font-family: var(--cc-font-display, Georgia, serif);
	font-size: 26px;
}

.cc-send-note {
	margin: 0;
	color: var(--cc-quiet, #6F6D67);
	font-size: 12px;
}

.cc-send-none,
.cc-send-off { color: var(--cc-quiet, #6F6D67); font-size: 14px; }

/* --- the footer --- */

.cc-send-foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-top: 28px;
	padding-top: 20px;
	border-top: 1px solid var(--cc-line-soft, #EBEAE6);
}

/* ---------------------------------------------------------------------
 * Sending to more than one person
 *
 * An order can be a card each for several named people, or a batch of
 * the same card to one address. The list of people, the ways of adding
 * them and the nudge towards an account all live on the first step.
 * ------------------------------------------------------------------ */

.cc-send .cc-send-people {
	list-style: none;
	margin: 0 0 10px;
	padding: 0;
	border: 1px solid var(--cc-border-subtle, #E4E4DF);
	border-radius: 10px;
}

.cc-send .cc-send-person {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 14px;
	border-bottom: 1px solid var(--cc-border-subtle, #E4E4DF);
}

.cc-send .cc-send-person:last-child { border-bottom: 0; }

.cc-send-person-who { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cc-send-person-co,
.cc-send-person-at {
	font-size: 13px;
	line-height: 1.45;
	color: var(--cc-text-secondary, #5C6660);
	overflow-wrap: anywhere;
}

/*
 * Remove is a quiet thing to offer, not a thing to press. As a filled grey
 * button it carried more weight on the screen than "Add this person", which
 * is the action the step is actually for.
 */
.cc-send-person-off {
	flex: 0 0 auto;
	height: auto;
	padding: 4px 2px;
	border: 0;
	background: transparent;
	color: var(--cc-quiet, #6F6D67);
	font-size: 13px;
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}

.cc-send-person-off:hover,
.cc-send-person-off:focus { color: #8A3524; }

.cc-send-count {
	margin: 0 0 18px;
	font-size: 13px;
	color: var(--cc-text-secondary, #5C6660);
}

/*
 * Adding the person in front of you: the thing to do on this step, so it sits
 * on its own under the fields it belongs to. It used to share a row with a
 * bare file input and a second button, with nothing saying which went with
 * which.
 */
.cc-send-adds {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
	margin-top: 18px;
}

/*
 * Stronger than the Upload button beside the file, because this is the thing
 * the step is for. Its own rule rather than a dashboard class: that stylesheet
 * is loaded on this page too, and a name borrowed from it is a name that can
 * change underneath this one.
 */
.cc-send-adds .cc-btn {
	background: #FFFFFF;
	border-color: var(--cc-ink, #14231B);
	color: var(--cc-ink, #14231B);
	font-weight: 500;
}

.cc-send-adds .cc-btn:hover {
	border-color: var(--cc-green-600, #0F5A43);
	color: var(--cc-green-700, #0C4836);
}

.cc-send-adds-note {
	color: var(--cc-quiet, #6F6D67);
	font-size: 13px;
}

/* Uploading a list instead: an alternative, so it is set below a rule. */
.cc-send-upload {
	margin-top: 22px;
	padding-top: 20px;
	border-top: 1px solid var(--cc-line-soft, #EBEAE6);
}

.cc-send-upload-head {
	margin: 0 0 2px;
	color: var(--cc-ink, #14231B);
	font-size: 15px;
	font-weight: 500;
}

.cc-send-upload-sub {
	margin: 0 0 12px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 13px;
	line-height: 1.5;
}

.cc-send-upload-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px;
}

/*
 * The file control, which a browser draws as a grey box with a button in it
 * that matches nothing else on the page. Given the same border, height and
 * radius as the fields above it, and its own button restyled to read as the
 * quiet one it is.
 */
.cc-send-file {
	flex: 1 1 260px;
	min-width: 0;
	padding: 9px 12px;
	border: 1px solid var(--cc-line, #D1CFC9);
	border-radius: 8px;
	background: #FFFFFF;
	font-family: inherit;
	font-size: 14px;
	color: var(--cc-body, #57554F);
	cursor: pointer;
}

.cc-send-file::file-selector-button {
	margin-right: 12px;
	padding: 6px 12px;
	border: 1px solid var(--cc-line, #D1CFC9);
	border-radius: 6px;
	background: var(--cc-paper, #F7F6F3);
	font-family: inherit;
	font-size: 13px;
	color: var(--cc-ink, #14231B);
	cursor: pointer;
}

.cc-send-file::file-selector-button:hover {
	background: var(--cc-line-soft, #EBEAE6);
}

.cc-send-file:focus {
	border-color: var(--cc-green-600, #0F5A43);
	outline: 2px solid rgba(15, 90, 67, 0.18);
}

@media (max-width: 560px) {
	.cc-send-adds .cc-btn,
	.cc-send-upload-row .cc-btn { width: 100%; justify-content: center; }

	.cc-send-adds-note { order: 2; }
	.cc-send-file { flex: 1 1 100%; }
}

/* The account offer, once the list is as long as a guest order can be. */
.cc-send-more {
	margin: 4px 0 18px;
	padding: 16px;
	border: 1px solid var(--cc-accent-default, #14523B);
	border-radius: 12px;
	background: var(--cc-surface-subtle, #F6F6F3);
}

.cc-send-more-head { margin: 0 0 6px; font-weight: 600; }

.cc-send-more-blurb,
.cc-send-more-or {
	margin: 0 0 12px;
	font-size: 13px;
	line-height: 1.5;
	color: var(--cc-text-secondary, #5C6660);
}

.cc-send-more-or { margin: 10px 0 0; }

/*
 * The other way of ordering entirely, so it is set apart from the upload
 * block above it — pushed against it, the two read as one group and the
 * link looked like part of uploading a file.
 */
.cc-send-swap {
	margin: 20px 0 0;
	padding-top: 18px;
	border-top: 1px solid var(--cc-line-soft, #EBEAE6);
}

.cc-link-btn {
	padding: 0;
	border: 0;
	background: none;
	font: inherit;
	font-size: 13px;
	color: var(--cc-accent-default, #14523B);
	text-decoration: underline;
	cursor: pointer;
}

.cc-send-sum-to { display: block; margin-bottom: 6px; }
.cc-send-sum-to:last-child { margin-bottom: 0; }
.cc-send-saved { color: var(--cc-accent-default, #14523B); }

@media (max-width: 560px) {
	.cc-send-fields { grid-template-columns: 1fr; }
	.cc-send-steps { font-size: 12px; }
	.cc-send-step span:not(.cc-send-step-n) { display: none; }
	.cc-send-step.is-on span:not(.cc-send-step-n) { display: inline; }
}

/*
 * Buttons for the sending flow and the "not open yet" dialog.
 *
 * .cc-btn is defined in dashboard.css, which the portal loads and a public
 * page does not — so the footer arrived as a blue underlined link and a
 * grey browser button. Scoped to .cc-send and .cc-soon so it cannot reach
 * the portal, where the real definitions live.
 */

.cc-send .cc-btn,
.cc-sent .cc-btn,
.cc-soon .cc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	height: 42px;
	padding: 0 20px;
	border: 1px solid transparent;
	border-radius: 8px;
	font-family: inherit;
	font-size: 15px;
	line-height: 1;
	text-decoration: none;
	cursor: pointer;
}

.cc-send .cc-btn-primary,
.cc-sent .cc-btn-primary,
.cc-soon .cc-btn-primary {
	background: var(--cc-green-600, #0F5A43);
	color: #FFFFFF;
}

.cc-send .cc-btn-primary:hover,
.cc-sent .cc-btn-primary:hover,
.cc-soon .cc-btn-primary:hover { background: var(--cc-green-700, #0C4836); }

/* The quiet button, which only dashboard.css defined — so on a public page
   it came out as a plain grey browser button. */
.cc-send .cc-btn-ghost,
.cc-sent .cc-btn-ghost {
	background: transparent;
	border-color: var(--cc-line, #D1CFC9);
	color: var(--cc-body, #57554F);
}

.cc-send .cc-btn-ghost:hover,
.cc-sent .cc-btn-ghost:hover {
	border-color: var(--cc-ink, #14231B);
	color: var(--cc-ink, #14231B);
}

.cc-send .cc-btn-primary:disabled,
.cc-sent .cc-btn-primary:disabled,
.cc-soon .cc-btn-primary:disabled {
	background: var(--cc-line, #D1CFC9);
	cursor: not-allowed;
}

.cc-send .cc-btn-ghost,
.cc-soon .cc-btn-ghost {
	background: transparent;
	color: var(--cc-body, #57554F);
}

.cc-send .cc-btn-ghost:hover,
.cc-soon .cc-btn-ghost:hover { color: var(--cc-ink, #14231B); }

.cc-send .cc-btn:focus-visible,
.cc-soon .cc-btn:focus-visible {
	outline: 2px solid var(--cc-green-600, #0F5A43);
	outline-offset: 2px;
}

/* The writer's hidden labels, which also live in dashboard.css. */
.cc-send .cc-sr {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

/* --- after paying --- */

.cc-sent {
	max-width: 620px;
	margin: 0 auto 32px;
	padding: clamp(20px, 4vw, 32px);
	border: 1px solid var(--cc-line-soft, #EBEAE6);
	border-radius: 16px;
	background: #FFFFFF;
}

.cc-sent-title {
	margin: 0 0 12px;
	color: var(--cc-ink, #14231B);
	font-family: var(--cc-font-display, Georgia, serif);
	font-size: clamp(22px, 3vw, 28px);
	font-weight: 400;
}

.cc-sent-line {
	margin: 0 0 8px;
	color: var(--cc-body, #57554F);
	font-size: clamp(15px, 1.6vw, 16px);
	line-height: 1.55;
}

.cc-sent-line:last-of-type { margin-bottom: 0; }

/* The quiet line under them, set apart so the two do not read as one. */
.cc-sent-note {
	margin: 14px 0 0;
	color: var(--cc-quiet, #6F6D67);
	font-size: 13px;
	line-height: 1.5;
}

.cc-sent-account {
	margin-top: 24px;
	padding-top: 20px;
	border-top: 1px solid var(--cc-line-soft, #EBEAE6);
}

.cc-sent-account-head {
	margin: 0 0 6px;
	color: var(--cc-ink, #14231B);
	font-family: var(--cc-font-display, Georgia, serif);
	font-size: 19px;
	font-weight: 400;
}

.cc-sent-account p { margin: 0 0 16px; color: var(--cc-body, #57554F); font-size: 14px; }

/*
 * Stacked, not side by side.
 *
 * The field and the button sat in a row aligned to their bottom edges, and
 * the field carries help text under the input — so the button lined up with
 * the help text rather than the input, and on a narrow panel the two
 * overlapped. Stacking is also what the sign-in branch does, so the two
 * halves of this block now read the same.
 */
.cc-sent-form { display: block; }

.cc-sent-form .cc-field {
	margin: 0 0 14px;
	max-width: 320px;
}

.cc-sent-form label {
	display: block;
	margin-bottom: 6px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 12px;
}

.cc-sent-form input[type="password"] {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid var(--cc-line, #D1CFC9);
	border-radius: 8px;
	font-family: inherit;
	font-size: 15px;
}

.cc-sent-form input[type="password"]:focus {
	border-color: var(--cc-green-600, #0F5A43);
	outline: 2px solid rgba(15, 90, 67, 0.18);
}

/* The one action in the sign-in block; it carries its own spacing because
   the password form beside it has none to share. */
.cc-sent-act { margin: 0; }

/*
 * "Back to CardsCo" is the way out, not the thing to do here, and as a
 * button it competed with the account offer above it. A quiet link, set
 * apart from the block by a rule, so the order of importance reads:
 * what happened, what to do about it, and then the way out.
 */
.cc-sent-go {
	margin: 22px 0 0;
	padding-top: 18px;
	border-top: 1px solid var(--cc-line-soft, #EBEAE6);
}

.cc-sent-back {
	color: var(--cc-quiet, #6F6D67);
	font-size: 14px;
	text-decoration: none;
	border-bottom: 1px solid rgba(111, 109, 103, 0.35);
	padding-bottom: 1px;
}

.cc-sent-back:hover,
.cc-sent-back:focus {
	color: var(--cc-ink, #14231B);
	border-bottom-color: var(--cc-ink, #14231B);
}

/*
 * On the order-received page this sits between WooCommerce's own receipt and
 * its order table, both of which bring their own margins — so it is given
 * room of its own rather than being squeezed against them.
 */
.woocommerce-order .cc-sent,
.woocommerce .cc-sent { margin: 32px auto 36px; }

@media (max-width: 600px) {
	.cc-sent-form { gap: 10px; }
	.cc-sent-form .cc-field { flex: 1 1 100%; }
	.cc-sent-form .cc-btn { width: 100%; justify-content: center; }
}

.cc-sent-form .cc-field-help {
	display: block;
	margin-top: 4px;
	color: var(--cc-quiet, #6F6D67);
	font-size: 12px;
}

.cc-sent .cc-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 42px;
	padding: 0 20px;
	border: 0;
	border-radius: 8px;
	background: var(--cc-green-600, #0F5A43);
	color: #FFFFFF;
	font-family: inherit;
	font-size: 15px;
	text-decoration: none;
	cursor: pointer;
}

.cc-sent .cc-btn:hover { background: var(--cc-green-700, #0C4836); }

/*
 * A card with nothing behind it yet.
 *
 * Shares .cc-cat-use so it keeps the size and position of the button it
 * replaces — the row does not reflow depending on whether a card can be
 * bought — but reads as a label rather than something to press. It is a
 * <span>, so there is nothing to click and nothing to focus.
 */
.cc-cat-use-off {
	background: var(--cc-wash);
	color: var(--cc-quiet);
	border: 1px solid var(--cc-line-soft);
	cursor: default;
}

.cc-cat-use-off:hover {
	background: var(--cc-wash);
	color: var(--cc-quiet);
}

/* ---------------------------------------------------------------------
 * "Not open yet"
 *
 * What a coming-soon occasion opens when it is pressed. Divs rather than
 * a <dialog> so a theme's own dialog rules cannot take it over, and
 * scoped under .cc-soon so nothing here reaches the rest of the page.
 * ------------------------------------------------------------------ */

.cc-soon {
	position: fixed;
	inset: 0;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: rgba(20, 35, 27, 0.45);
}

.cc-soon[hidden] { display: none; }

.cc-soon .cc-soon-sheet {
	width: 100%;
	max-width: 420px;
	padding: 24px;
	background: #FFFFFF;
	border-radius: 14px;
	box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
}

.cc-soon .cc-soon-title {
	margin: 0 0 10px;
	font-family: var(--cc-font-display, Georgia, serif);
	font-size: 22px;
	line-height: 1.25;
	color: var(--cc-ink, #14231B);
}

.cc-soon .cc-soon-blurb {
	margin: 0 0 10px;
	font-size: 14px;
	line-height: 1.55;
	color: var(--cc-quiet, #5C6660);
}

.cc-soon .cc-soon-feet {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-top: 18px;
}

@media (max-width: 480px) {
	.cc-soon .cc-soon-sheet { padding: 20px; }
	.cc-soon .cc-soon-feet .cc-btn { flex: 1 1 100%; justify-content: center; }
}
