/*
 * Pricing cards and tier tables.
 *
 * Loaded from functions.php, after the styles core prints inline. That order
 * matters: our selectors and core's layout selectors have the same specificity,
 * so the later one wins, and every grid on the site depends on ours winning.
 */

/* -------------------------------------------------------------------- plans */

/*
 * Auto fit rather than a fixed column count: there are three plans today and
 * there will be more, and the grid should not need editing when that happens.
 */
.ghizo-plans {
	display: grid;
	gap: var(--wp--preset--spacing--30);
	grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
	margin: 0;
	padding: 0;
	list-style: none;
}

.ghizo-plan {
	display: flex;
	flex-direction: column;
	background: var(--wp--preset--color--paper);
	border: 1px solid var(--wp--preset--color--line);
	border-radius: 14px;
	padding: var(--wp--preset--spacing--40);
}

/* The one you can actually buy today gets the emphasis. */
.ghizo-plan--now {
	border-color: var(--wp--preset--color--blue);
	box-shadow: var(--wp--preset--shadow--card);
}

.ghizo-plan__tag {
	align-self: flex-start;
	background: var(--wp--preset--color--wash);
	border-radius: 999px;
	color: var(--wp--preset--color--ink-muted);
	font-size: var(--wp--preset--font-size--micro);
	font-weight: 600;
	letter-spacing: 0.08em;
	padding: 0.3rem 0.7rem;
	text-transform: uppercase;
}

.ghizo-plan--now .ghizo-plan__tag {
	background: var(--wp--preset--color--blue);
	color: var(--wp--preset--color--paper);
}

.ghizo-plan__title {
	font-size: var(--wp--preset--font-size--large);
	line-height: 1.25;
	margin: var(--wp--preset--spacing--20) 0 0;
}

.ghizo-plan__price {
	align-items: baseline;
	color: var(--wp--preset--color--ink);
	display: flex;
	flex-wrap: wrap;
	gap: 0.4rem;
	margin-top: var(--wp--preset--spacing--10);
}

.ghizo-plan__amount {
	/* Tabular figures, so 96 and 288 line up down the row of cards. */
	font-feature-settings: 'tnum';
	font-size: var(--wp--preset--font-size--x-large);
	font-weight: 600;
	line-height: 1;
}

.ghizo-plan__per {
	color: var(--wp--preset--color--ink-muted);
	font-size: var(--wp--preset--font-size--small);
}

.ghizo-plan__text {
	color: var(--wp--preset--color--ink-muted);
	font-size: var(--wp--preset--font-size--small);
	margin: var(--wp--preset--spacing--20) 0 0;
}

.ghizo-plan .ghizo-ticks {
	margin-top: var(--wp--preset--spacing--30);
}

/* Pushes the button to the bottom edge whatever the list above it does. */
.ghizo-plan__foot {
	margin-top: auto;
	padding-top: var(--wp--preset--spacing--30);
}

.ghizo-plan__cta {
	background: var(--wp--preset--color--navy-deep);
	border-radius: 8px;
	color: var(--wp--preset--color--paper);
	display: block;
	font-size: var(--wp--preset--font-size--small);
	font-weight: 600;
	padding: 0.8rem 1rem;
	text-align: center;
	text-decoration: none;
}

.ghizo-plan--now .ghizo-plan__cta {
	background: var(--wp--preset--color--blue);
}

.ghizo-plan__cta:hover,
.ghizo-plan__cta:focus {
	background: var(--wp--preset--color--navy);
	color: var(--wp--preset--color--paper);
}

.ghizo-plan__cta--off {
	background: var(--wp--preset--color--wash);
	color: var(--wp--preset--color--ink-muted);
	cursor: default;
}

/* ----------------------------------------------------------- two card pricing */

/*
 * Free beside Pro. The shared grid auto fits, which would let two cards stretch
 * to half a very wide page each; capped so a pair reads as a pair.
 */
.ghizo-plans--pair {
	grid-template-columns: repeat(auto-fit, minmax(17rem, 26rem));
	justify-content: center;
}

/* ------------------------------------------------------------- licence tiers */

.ghizo-tiers th[scope='row'] {
	width: auto;
}

/* The tier name, then what it covers, on the line below it. */
.ghizo-tiers th[scope='row'] span {
	color: var(--wp--preset--color--ink-muted);
	display: block;
	font-size: var(--wp--preset--font-size--micro);
	font-weight: 400;
	margin-top: 0.15rem;
}

.ghizo-tiers td {
	font-feature-settings: 'tnum';
	white-space: nowrap;
}

.ghizo-tier-buy {
	background: var(--wp--preset--color--blue);
	border-radius: 8px;
	color: var(--wp--preset--color--paper);
	display: inline-block;
	font-size: var(--wp--preset--font-size--micro);
	font-weight: 600;
	padding: 0.45rem 1.1rem;
	text-decoration: none;
}

.ghizo-tier-buy:hover,
.ghizo-tier-buy:focus-visible {
	background: var(--ghizo-cta-hover);
	color: var(--wp--preset--color--paper);
}

/* ============================================================================
   Marketing surfaces
   Added in the design pass. Everything above is the original theme; everything
   here is the components the store's pages are actually built from.
   ========================================================================= */
