/* Shared components: text roles, button styles, plates, tags, form fields, dialog. */

/* — Text roles — */
/* Section label with a short gold hairline before it. */
.luxe-kicker {
	display: flex;
	align-items: center;
	gap: 14px;
	font-size: 12px;
	line-height: 14px;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	font-feature-settings: "tnum" 1;
	color: var(--wp--preset--color--accent-3);
	margin: 0 0 18px;
}

.luxe-kicker::before {
	content: "";
	flex: none;
	width: 32px;
	height: 1px;
	background: currentColor;
	opacity: 0.55;
}

.luxe-lead {
	max-width: 62ch;
	color: var(--luxe-soft);
}

.luxe-note {
	font-size: var(--wp--preset--font-size--x-small);
	line-height: 20px;
	max-width: 62ch;
	color: color-mix(in srgb, var(--wp--preset--color--contrast) 62%, transparent);
}

.luxe-justify {
	text-align: justify;
	hyphens: auto;
	color: var(--luxe-soft);
}

/* Sections separated by hairlines, as in the design. */
.luxe-section {
	padding-block: var(--luxe-section-pad) calc(var(--luxe-section-pad) - 12px);
}

.luxe-section .wp-block-heading {
	margin-block: 0;
	margin-inline-start: -0.042em;
}

.luxe-section > .luxe-lead {
	margin-block-start: 20px;
}

.luxe-section__head {
	gap: 16px 48px;
}

.luxe-section__head .wp-block-group > * {
	margin-block-start: 0;
}

/* A hairline between two consecutive light sections; full-bleed sections break the run. */
:is(.luxe-stats, .luxe-section, .luxe-glass) + :is(.luxe-stats, .luxe-section, .luxe-glass) {
	border-top: 1px solid var(--luxe-divider);
}

.luxe-actions {
	gap: 16px;
	margin-block-start: 40px;
}

/* — Buttons (default dark pill lives in theme.json) — */
.wp-block-button .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 54px;
	padding-block: 0;
	white-space: nowrap;
	transition: background-color 500ms var(--luxe-ease), color 500ms var(--luxe-ease), border-color 500ms var(--luxe-ease);
}

/* Hero primary: cream, warming to gold on hover. */
.wp-block-button.is-style-luxe-gold .wp-block-button__link {
	background: var(--wp--preset--color--cream);
	color: var(--wp--preset--color--night);
}

.wp-block-button.is-style-luxe-gold .wp-block-button__link:hover {
	background: var(--wp--preset--color--accent-2);
	color: var(--wp--preset--color--night);
}

.wp-block-button.is-style-luxe-outline .wp-block-button__link {
	background: transparent;
	border: 1px solid var(--wp--preset--color--accent-1);
	color: var(--wp--preset--color--accent-3);
}

.wp-block-button.is-style-luxe-outline .wp-block-button__link:hover {
	background: var(--wp--preset--color--accent-5);
	color: var(--wp--preset--color--accent-3);
}

.wp-block-button.is-style-luxe-outline-light .wp-block-button__link {
	background: transparent;
	border: 1px solid rgb(246 244 241 / 0.6);
	color: var(--wp--preset--color--cream);
}

.wp-block-button.is-style-luxe-outline-light .wp-block-button__link:hover {
	background: rgb(246 244 241 / 0.1);
	border-color: var(--wp--preset--color--cream);
	color: var(--wp--preset--color--cream);
}

.wp-block-button.luxe-button--plain-case .wp-block-button__link {
	text-transform: none;
	letter-spacing: 0.14em;
	color: var(--wp--preset--color--contrast);
}

@media (max-width: 480px) {
	.wp-block-button .wp-block-button__link {
		white-space: normal;
		text-align: center;
		padding-inline: 1.75rem;
	}
}

/* — Plate: images matted like tipped-in book plates — */
.luxe-door img,
.luxe-install__photo img {
	filter: sepia(0.22) saturate(0.82) contrast(1.05);
	border: 6px solid var(--wp--preset--color--surface);
	outline: 1px solid var(--luxe-divider);
}

/* — Inline list: each item led by a small gold diamond (wraps cleanly) — */
.luxe-inline-list {
	display: flex;
	flex-wrap: wrap;
	gap: 12px 30px;
	list-style: none;
	margin: 28px 0 0;
	padding: 0;
	font-size: 11.5px;
	letter-spacing: 0.18em;
	text-transform: uppercase;
}

.luxe-inline-list li {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0;
}

.luxe-inline-list li::before {
	content: "";
	flex: none;
	width: 5px;
	height: 5px;
	border: 1px solid var(--wp--preset--color--accent-1);
	transform: rotate(45deg);
}

/* — Form fields — */
.luxe-field > label {
	display: block;
	font-size: 12px;
	margin-bottom: 5px;
	color: var(--luxe-muted);
}

.luxe-input {
	width: 100%;
	min-height: 40px;
	padding: 6px 10px;
	font: inherit;
	font-size: 14px;
	color: var(--wp--preset--color--contrast);
	caret-color: var(--wp--preset--color--accent-1);
	background: transparent;
	border: 1px solid var(--luxe-divider);
	border-radius: 4px;
	box-sizing: border-box;
}

.luxe-input:hover {
	border-color: color-mix(in srgb, var(--wp--preset--color--contrast) 45%, transparent);
}

.luxe-input:focus-visible {
	border-color: var(--wp--preset--color--accent-1);
	outline-offset: 0;
}

textarea.luxe-input {
	min-height: 90px;
	resize: vertical;
}

/* — Dialog (door details) — */
/* The dialog itself has no padding so backdrop clicks can be told apart from content clicks. */
.luxe-dialog {
	width: min(640px, calc(100% - 32px));
	max-height: calc(100vh - 48px);
	padding: 0;
	border: 1px solid var(--luxe-divider);
	border-radius: 7px;
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--contrast);
	box-shadow: 0 12px 32px color-mix(in srgb, #2d2b2b 22%, transparent);
	overflow: auto;
}

.luxe-dialog__inner {
	padding: clamp(24px, 3vw, 40px);
}

/* Opacity-only entrance: a transform here would re-anchor the fixed prev/next arrows. */
.luxe-dialog[open],
.luxe-dialog[open]::backdrop {
	animation: luxe-fade 450ms var(--luxe-ease);
}

.luxe-dialog::backdrop {
	background: color-mix(in srgb, #2d2b2b 50%, transparent);
}

.luxe-round-button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border-radius: 50%;
	border: 1px solid var(--wp--preset--color--accent-1);
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--accent-3);
	box-shadow: var(--luxe-shadow-sm);
	cursor: pointer;
}

.luxe-round-button:hover {
	background: var(--wp--preset--color--accent-5);
}

.luxe-round-button svg {
	display: block;
	width: 20px;
	height: 20px;
}
