/* ==========================================================================
   Linked Column - frontend + editor styles
   ========================================================================== */

/* Make the linked column the positioning context for the stretched anchor. */
.wp-block-column.has-linked-column {
	position: relative;
	cursor: pointer;
	transition: opacity 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

/* Subtle hover lift on the whole column. */
.wp-block-column.has-linked-column:hover {
	opacity: 0.80;
	/*box-shadow: 0 6px 20px -8px rgba(0, 0, 0, 0.18);*/
	box-shadow: 0;
}

/* Subtle hover lift on the whole column. */
.wp-block-column.has-linked-column:hover a {
	text-decoration: underline;
}

/* The stretched anchor: invisible, but covers the entire column. */
.wp-block-column.has-linked-column > .linked-column__link {
	position: absolute;
	inset: 0;
	z-index: 1;
	text-decoration: none;
	/* Hide any anchor text without using display:none (preserves focusability). */
	overflow: hidden;
}

.wp-block-column.has-linked-column > .linked-column__link .screen-reader-text {
	/* Standard WP-style visually-hidden helper, in case the theme doesn't define one. */
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	-webkit-clip-path: inset(50%);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute;
	width: 1px;
	word-wrap: normal !important;
}

/* Accessible keyboard focus indicator on the whole column. */
.wp-block-column.has-linked-column > .linked-column__link:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 4px;
	border-radius: 2px;
}

/* Keep nested interactive elements clickable above the stretched link. */
.wp-block-column.has-linked-column a:not(.linked-column__link),
.wp-block-column.has-linked-column button,
.wp-block-column.has-linked-column input,
.wp-block-column.has-linked-column select,
.wp-block-column.has-linked-column textarea,
.wp-block-column.has-linked-column label,
.wp-block-column.has-linked-column [role="button"],
.wp-block-column.has-linked-column [tabindex]:not([tabindex="-1"]) {
	position: relative;
	z-index: 2;
}

/* Respect users who prefer reduced motion. */
@media (prefers-reduced-motion: reduce) {
	.wp-block-column.has-linked-column,
	.wp-block-column.has-linked-column:hover {
		transition: none;
		transform: none;
	}
}

/* ==========================================================================
   Editor-only visual cue
   ========================================================================== */

.wp-block[data-type="core/column"].has-linked-column-editor {
	position: relative;
	outline: 1px dashed rgba(0, 124, 186, 0.5);
	outline-offset: -2px;
}

.wp-block[data-type="core/column"].has-linked-column-editor::after {
	content: "LINKED";
	position: absolute;
	top: 6px;
	right: 6px;
	z-index: 20;
	background: #007cba;
	color: #fff;
	font-size: 10px;
	font-weight: 600;
	letter-spacing: 0.05em;
	padding: 2px 6px;
	border-radius: 2px;
	line-height: 1.4;
	pointer-events: none;
}
