/**
 * Block Patterns CSS - Ernesto Theme
 * Utility classes and styling for native WordPress block patterns
 *
 * @package Ernesto
 * @since 1.0.0
 */

/* ==========================================================================
   Layout Utilities
   ========================================================================== */

/* Container widths */
.ernesto-container {
	max-width: var(--content-width, 1200px);
	margin-left: auto;
	margin-right: auto;
	padding-left: var(--space-md, 1.5rem);
	padding-right: var(--space-md, 1.5rem);
}

.ernesto-container-wide {
	max-width: var(--wide-width, 1400px);
	margin-left: auto;
	margin-right: auto;
	padding-left: var(--space-md, 1.5rem);
	padding-right: var(--space-md, 1.5rem);
}

.ernesto-container-full {
	max-width: 100%;
	padding-left: var(--space-md, 1.5rem);
	padding-right: var(--space-md, 1.5rem);
}

/* ==========================================================================
   Grid System
   ========================================================================== */

/* 2 Column Grid */
.ernesto-grid-2 {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: var(--space-lg, 2rem);
}

/* 3 Column Grid */
.ernesto-grid-3 {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: var(--space-lg, 2rem);
}

/* 4 Column Grid */
.ernesto-grid-4 {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: var(--space-lg, 2rem);
}

/* Auto-fit grid (responsive without media queries) */
.ernesto-grid-auto {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
	gap: var(--space-lg, 2rem);
}

/* Responsive grid adjustments */
@media (max-width: 1024px) {
	.ernesto-grid-4 {
		grid-template-columns: repeat(2, 1fr);
	}

	.ernesto-grid-3 {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 768px) {
	.ernesto-grid-2,
	.ernesto-grid-3,
	.ernesto-grid-4 {
		grid-template-columns: 1fr;
		gap: var(--space-md, 1.5rem);
	}
}

/* ==========================================================================
   Bootstrap-Style 12-Column Grid System
   ========================================================================== */

/* Grid Variables */
:root {
	--grid-gutter: var(--space-lg, 2rem);
	--grid-columns: 12;
}

/* Row - Container for columns */
.row {
	display: flex;
	flex-wrap: wrap;
	margin-left: calc(var(--grid-gutter) / -2);
	margin-right: calc(var(--grid-gutter) / -2);
}

/* Base column - All columns share this */
[class*="col-"] {
	position: relative;
	width: 100%;
	padding-left: calc(var(--grid-gutter) / 2);
	padding-right: calc(var(--grid-gutter) / 2);
}

/* Auto-width column */
.col {
	flex: 1 0 0%;
}

/* Base columns (mobile-first, no breakpoint) */
.col-1  { flex: 0 0 8.333333%; max-width: 8.333333%; }
.col-2  { flex: 0 0 16.666667%; max-width: 16.666667%; }
.col-3  { flex: 0 0 25%; max-width: 25%; }
.col-4  { flex: 0 0 33.333333%; max-width: 33.333333%; }
.col-5  { flex: 0 0 41.666667%; max-width: 41.666667%; }
.col-6  { flex: 0 0 50%; max-width: 50%; }
.col-7  { flex: 0 0 58.333333%; max-width: 58.333333%; }
.col-8  { flex: 0 0 66.666667%; max-width: 66.666667%; }
.col-9  { flex: 0 0 75%; max-width: 75%; }
.col-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
.col-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
.col-12 { flex: 0 0 100%; max-width: 100%; }

/* Small devices (tablets, 576px and up) */
@media (min-width: 576px) {
	.col-sm   { flex: 1 0 0%; }
	.col-sm-1  { flex: 0 0 8.333333%; max-width: 8.333333%; }
	.col-sm-2  { flex: 0 0 16.666667%; max-width: 16.666667%; }
	.col-sm-3  { flex: 0 0 25%; max-width: 25%; }
	.col-sm-4  { flex: 0 0 33.333333%; max-width: 33.333333%; }
	.col-sm-5  { flex: 0 0 41.666667%; max-width: 41.666667%; }
	.col-sm-6  { flex: 0 0 50%; max-width: 50%; }
	.col-sm-7  { flex: 0 0 58.333333%; max-width: 58.333333%; }
	.col-sm-8  { flex: 0 0 66.666667%; max-width: 66.666667%; }
	.col-sm-9  { flex: 0 0 75%; max-width: 75%; }
	.col-sm-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
	.col-sm-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
	.col-sm-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) {
	.col-md   { flex: 1 0 0%; }
	.col-md-1  { flex: 0 0 8.333333%; max-width: 8.333333%; }
	.col-md-2  { flex: 0 0 16.666667%; max-width: 16.666667%; }
	.col-md-3  { flex: 0 0 25%; max-width: 25%; }
	.col-md-4  { flex: 0 0 33.333333%; max-width: 33.333333%; }
	.col-md-5  { flex: 0 0 41.666667%; max-width: 41.666667%; }
	.col-md-6  { flex: 0 0 50%; max-width: 50%; }
	.col-md-7  { flex: 0 0 58.333333%; max-width: 58.333333%; }
	.col-md-8  { flex: 0 0 66.666667%; max-width: 66.666667%; }
	.col-md-9  { flex: 0 0 75%; max-width: 75%; }
	.col-md-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
	.col-md-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
	.col-md-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Large devices (desktops, 1024px and up) */
@media (min-width: 1024px) {
	.col-lg   { flex: 1 0 0%; }
	.col-lg-1  { flex: 0 0 8.333333%; max-width: 8.333333%; }
	.col-lg-2  { flex: 0 0 16.666667%; max-width: 16.666667%; }
	.col-lg-3  { flex: 0 0 25%; max-width: 25%; }
	.col-lg-4  { flex: 0 0 33.333333%; max-width: 33.333333%; }
	.col-lg-5  { flex: 0 0 41.666667%; max-width: 41.666667%; }
	.col-lg-6  { flex: 0 0 50%; max-width: 50%; }
	.col-lg-7  { flex: 0 0 58.333333%; max-width: 58.333333%; }
	.col-lg-8  { flex: 0 0 66.666667%; max-width: 66.666667%; }
	.col-lg-9  { flex: 0 0 75%; max-width: 75%; }
	.col-lg-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
	.col-lg-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
	.col-lg-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Extra large devices (large desktops, 1280px and up) */
@media (min-width: 1280px) {
	.col-xl   { flex: 1 0 0%; }
	.col-xl-1  { flex: 0 0 8.333333%; max-width: 8.333333%; }
	.col-xl-2  { flex: 0 0 16.666667%; max-width: 16.666667%; }
	.col-xl-3  { flex: 0 0 25%; max-width: 25%; }
	.col-xl-4  { flex: 0 0 33.333333%; max-width: 33.333333%; }
	.col-xl-5  { flex: 0 0 41.666667%; max-width: 41.666667%; }
	.col-xl-6  { flex: 0 0 50%; max-width: 50%; }
	.col-xl-7  { flex: 0 0 58.333333%; max-width: 58.333333%; }
	.col-xl-8  { flex: 0 0 66.666667%; max-width: 66.666667%; }
	.col-xl-9  { flex: 0 0 75%; max-width: 75%; }
	.col-xl-10 { flex: 0 0 83.333333%; max-width: 83.333333%; }
	.col-xl-11 { flex: 0 0 91.666667%; max-width: 91.666667%; }
	.col-xl-12 { flex: 0 0 100%; max-width: 100%; }
}

/* Offset classes - Push columns to the right */
.offset-1  { margin-left: 8.333333%; }
.offset-2  { margin-left: 16.666667%; }
.offset-3  { margin-left: 25%; }
.offset-4  { margin-left: 33.333333%; }
.offset-5  { margin-left: 41.666667%; }
.offset-6  { margin-left: 50%; }
.offset-7  { margin-left: 58.333333%; }
.offset-8  { margin-left: 66.666667%; }
.offset-9  { margin-left: 75%; }
.offset-10 { margin-left: 83.333333%; }
.offset-11 { margin-left: 91.666667%; }

@media (min-width: 576px) {
	.offset-sm-0  { margin-left: 0; }
	.offset-sm-1  { margin-left: 8.333333%; }
	.offset-sm-2  { margin-left: 16.666667%; }
	.offset-sm-3  { margin-left: 25%; }
	.offset-sm-4  { margin-left: 33.333333%; }
	.offset-sm-5  { margin-left: 41.666667%; }
	.offset-sm-6  { margin-left: 50%; }
	.offset-sm-7  { margin-left: 58.333333%; }
	.offset-sm-8  { margin-left: 66.666667%; }
	.offset-sm-9  { margin-left: 75%; }
	.offset-sm-10 { margin-left: 83.333333%; }
	.offset-sm-11 { margin-left: 91.666667%; }
}

@media (min-width: 768px) {
	.offset-md-0  { margin-left: 0; }
	.offset-md-1  { margin-left: 8.333333%; }
	.offset-md-2  { margin-left: 16.666667%; }
	.offset-md-3  { margin-left: 25%; }
	.offset-md-4  { margin-left: 33.333333%; }
	.offset-md-5  { margin-left: 41.666667%; }
	.offset-md-6  { margin-left: 50%; }
	.offset-md-7  { margin-left: 58.333333%; }
	.offset-md-8  { margin-left: 66.666667%; }
	.offset-md-9  { margin-left: 75%; }
	.offset-md-10 { margin-left: 83.333333%; }
	.offset-md-11 { margin-left: 91.666667%; }
}

@media (min-width: 1024px) {
	.offset-lg-0  { margin-left: 0; }
	.offset-lg-1  { margin-left: 8.333333%; }
	.offset-lg-2  { margin-left: 16.666667%; }
	.offset-lg-3  { margin-left: 25%; }
	.offset-lg-4  { margin-left: 33.333333%; }
	.offset-lg-5  { margin-left: 41.666667%; }
	.offset-lg-6  { margin-left: 50%; }
	.offset-lg-7  { margin-left: 58.333333%; }
	.offset-lg-8  { margin-left: 66.666667%; }
	.offset-lg-9  { margin-left: 75%; }
	.offset-lg-10 { margin-left: 83.333333%; }
	.offset-lg-11 { margin-left: 91.666667%; }
}

@media (min-width: 1280px) {
	.offset-xl-0  { margin-left: 0; }
	.offset-xl-1  { margin-left: 8.333333%; }
	.offset-xl-2  { margin-left: 16.666667%; }
	.offset-xl-3  { margin-left: 25%; }
	.offset-xl-4  { margin-left: 33.333333%; }
	.offset-xl-5  { margin-left: 41.666667%; }
	.offset-xl-6  { margin-left: 50%; }
	.offset-xl-7  { margin-left: 58.333333%; }
	.offset-xl-8  { margin-left: 66.666667%; }
	.offset-xl-9  { margin-left: 75%; }
	.offset-xl-10 { margin-left: 83.333333%; }
	.offset-xl-11 { margin-left: 91.666667%; }
}

/* Row alignment utilities */
.row-align-start   { align-items: flex-start; }
.row-align-center  { align-items: center; }
.row-align-end     { align-items: flex-end; }
.row-justify-start { justify-content: flex-start; }
.row-justify-center { justify-content: center; }
.row-justify-end   { justify-content: flex-end; }
.row-justify-between { justify-content: space-between; }
.row-justify-around { justify-content: space-around; }

/* No gutters variant */
.row-no-gutters {
	margin-left: 0;
	margin-right: 0;
}

.row-no-gutters > [class*="col-"] {
	padding-left: 0;
	padding-right: 0;
}

/* ==========================================================================
   Flexbox Utilities
   ========================================================================== */

.ernesto-flex {
	display: flex;
	gap: var(--space-md, 1.5rem);
}

.ernesto-flex-center {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: var(--space-md, 1.5rem);
}

.ernesto-flex-between {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--space-md, 1.5rem);
}

.ernesto-flex-column {
	display: flex;
	flex-direction: column;
	gap: var(--space-md, 1.5rem);
}

@media (max-width: 768px) {
	.ernesto-flex {
		flex-direction: column;
	}
}

/* ==========================================================================
   Spacing Utilities
   ========================================================================== */

/* Padding */
.ernesto-p-xs { padding: var(--space-xs, 0.5rem); }
.ernesto-p-sm { padding: var(--space-sm, 1rem); }
.ernesto-p-md { padding: var(--space-md, 1.5rem); }
.ernesto-p-lg { padding: var(--space-lg, 2rem); }
.ernesto-p-xl { padding: var(--space-xl, 3rem); }

/* Padding Top */
.ernesto-pt-xs { padding-top: var(--space-xs, 0.5rem); }
.ernesto-pt-sm { padding-top: var(--space-sm, 1rem); }
.ernesto-pt-md { padding-top: var(--space-md, 1.5rem); }
.ernesto-pt-lg { padding-top: var(--space-lg, 2rem); }
.ernesto-pt-xl { padding-top: var(--space-xl, 3rem); }

/* Padding Bottom */
.ernesto-pb-xs { padding-bottom: var(--space-xs, 0.5rem); }
.ernesto-pb-sm { padding-bottom: var(--space-sm, 1rem); }
.ernesto-pb-md { padding-bottom: var(--space-md, 1.5rem); }
.ernesto-pb-lg { padding-bottom: var(--space-lg, 2rem); }
.ernesto-pb-xl { padding-bottom: var(--space-xl, 3rem); }

/* Margin */
.ernesto-m-xs { margin: var(--space-xs, 0.5rem); }
.ernesto-m-sm { margin: var(--space-sm, 1rem); }
.ernesto-m-md { margin: var(--space-md, 1.5rem); }
.ernesto-m-lg { margin: var(--space-lg, 2rem); }
.ernesto-m-xl { margin: var(--space-xl, 3rem); }

/* Margin Top */
.ernesto-mt-xs { margin-top: var(--space-xs, 0.5rem); }
.ernesto-mt-sm { margin-top: var(--space-sm, 1rem); }
.ernesto-mt-md { margin-top: var(--space-md, 1.5rem); }
.ernesto-mt-lg { margin-top: var(--space-lg, 2rem); }
.ernesto-mt-xl { margin-top: var(--space-xl, 3rem); }

/* Margin Bottom */
.ernesto-mb-xs { margin-bottom: var(--space-xs, 0.5rem); }
.ernesto-mb-sm { margin-bottom: var(--space-sm, 1rem); }
.ernesto-mb-md { margin-bottom: var(--space-md, 1.5rem); }
.ernesto-mb-lg { margin-bottom: var(--space-lg, 2rem); }
.ernesto-mb-xl { margin-bottom: var(--space-xl, 3rem); }

/* ==========================================================================
   Button Utilities
   ========================================================================== */

.ernesto-btn {
	display: inline-block;
	padding: 0.75rem 1.5rem;
	font-family: var(--font-body, 'Inter', sans-serif);
	font-weight: 600;
	text-decoration: none;
	border-radius: var(--button-border-radius, 9999px);
	border-width: var(--button-border-width, 0);
	border-style: solid;
	transition: all 0.3s ease;
	cursor: pointer;
	text-align: center;
}

.ernesto-btn-primary {
	background-color: var(--color-primary, #0066FF);
	color: #FFFFFF;
	border-color: var(--color-primary, #0066FF);
}

.ernesto-btn-primary:hover {
	background-color: var(--color-primary-light);
	border-color: var(--color-primary-dark);
}

.ernesto-btn-secondary {
	background-color: var(--color-secondary, #64748B);
	color: #FFFFFF;
	border-color: var(--color-secondary, #64748B);
}

.ernesto-btn-secondary:hover {
	background-color: var(--color-secondary-hover);
	border-color: var(--color-secondary-hover);
}

.ernesto-btn-accent {
	background-color: var(--color-accent, #FF3366);
	color: #FFFFFF;
	border-color: var(--color-accent, #FF3366);
}

.ernesto-btn-accent:hover {
	background-color: var(--color-accent-hover);
	border-color: var(--color-accent-hover);
}

/* ==========================================================================
   Card Components
   ========================================================================== */

.ernesto-card {
	background-color: var(--bg-surface);
	padding: var(--space-lg, 2rem);
	border-radius: var(--image-border-radius, 8px);
	border: var(--image-border-width, 0) solid var(--color-border);
	transition: all 0.3s ease;
}

.ernesto-card:hover {
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.ernesto-card-image {
	width: 100%;
	height: auto;
	border-radius: var(--image-border-radius, 8px);
	margin-bottom: var(--space-md, 1.5rem);
}

.ernesto-card-title {
	font-size: 1.5rem;
	font-weight: 700;
	margin-bottom: var(--space-sm, 1rem);
	color: var(--text-heading);
}

.ernesto-card-content {
	color: var(--text-main);
	line-height: 1.6;
	margin-bottom: var(--space-md, 1.5rem);
}

/* ==========================================================================
   Section Utilities
   ========================================================================== */

.ernesto-section {
	padding-top: var(--space-xl, 3rem);
	padding-bottom: var(--space-xl, 3rem);
}

.ernesto-section-hero {
	padding-top: calc(var(--space-xl, 3rem) * 2);
	padding-bottom: calc(var(--space-xl, 3rem) * 2);
	min-height: 60vh;
	display: flex;
	align-items: center;
}

.ernesto-section-bg-primary {
	background-color: var(--color-primary);
	color: #FFFFFF;
}

.ernesto-section-bg-secondary {
	background-color: var(--color-secondary);
	color: #FFFFFF;
}

.ernesto-section-bg-light {
	background-color: var(--bg-surface);
	color: var(--text-main);
}

/* ==========================================================================
   Typography Utilities
   ========================================================================== */

.ernesto-text-center {
	text-align: center;
}

.ernesto-text-left {
	text-align: left;
}

.ernesto-text-right {
	text-align: right;
}

.ernesto-heading {
	font-family: var(--font-heading);
	color: var(--text-heading);
	line-height: 1.2;
	margin-bottom: var(--space-md, 1.5rem);
}

.ernesto-heading-hero {
	font-family: var(--font-special);
	font-size: clamp(2.5rem, 6vw, 4rem);
	font-weight: 700;
	line-height: 1.1;
	margin-bottom: var(--space-lg, 2rem);
}

.ernesto-heading-1 {
	font-size: clamp(2rem, 5vw, 3rem);
	font-weight: 700;
}

.ernesto-heading-2 {
	font-size: clamp(1.75rem, 4vw, 2.5rem);
	font-weight: 700;
}

.ernesto-heading-3 {
	font-size: clamp(1.5rem, 3vw, 2rem);
	font-weight: 600;
}

.ernesto-lead {
	font-size: 1.25rem;
	line-height: 1.6;
	color: var(--text-main);
}

/* ==========================================================================
   Image Utilities
   ========================================================================== */

.ernesto-img-rounded {
	border-radius: var(--image-border-radius, 8px);
}

.ernesto-img-circle {
	border-radius: 50%;
}

.ernesto-img-cover {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ernesto-img-contain {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

/* Aspect Ratio Containers */
.ernesto-aspect-4-5,
.ernesto-aspect-1-1,
.ernesto-aspect-16-9,
.ernesto-aspect-32-9 {
	position: relative;
	width: 100%;
	overflow: hidden;
}

.ernesto-aspect-4-5 {
	aspect-ratio: 4 / 5;
}

.ernesto-aspect-1-1 {
	aspect-ratio: 1 / 1;
}

.ernesto-aspect-16-9 {
	aspect-ratio: 16 / 9;
}

.ernesto-aspect-32-9 {
	aspect-ratio: 32 / 9;
}

.ernesto-aspect-4-5 img,
.ernesto-aspect-1-1 img,
.ernesto-aspect-16-9 img,
.ernesto-aspect-32-9 img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* ==========================================================================
   Block Pattern Specific Styles
   ========================================================================== */

/* Hero Slider Section */
.ernesto-hero-slider-section {
	width: 100%;
	margin: 0;
	padding: 0;
}

/* Slider container: don't force aspect-ratio on the wrapper.
   At mid-widths (e.g. 1280px) the 32:9 height (~360px) is shorter than
   the title+description+button stack, so content is clipped by overflow:hidden.
   The slide's own min-height (60vh from hero-slider.css) drives the height instead.
   The background image fills via position:absolute regardless of container height. */
.ernesto-hero-slider-section .ernesto-hero-slider,
.ernesto-hero-slider-section .slider-viewport {
	width: 100%;
}

/* Ensure images fill container */
.ernesto-hero-slider-section .slide-image img,
.ernesto-hero-slider-section .slide-image picture {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Half Layout (50/50 Text/Image) */
.ernesto-half-layout .row {
	align-items: center;
}

/* Image-first ordering on mobile */
@media (max-width: 767px) {
	.ernesto-image-first {
		order: -1;
	}
}

/* Text Flow Layout (Magazine Style) */
.ernesto-text-image-flow {
	position: relative;
}

/* Desktop: Float image and let text wrap */
@media (min-width: 768px) {
	.ernesto-image-flow-right {
		float: right;
		margin-left: var(--space-lg, 2rem);
		margin-bottom: var(--space-md, 1.5rem);
	}

	.ernesto-image-flow-left {
		float: left;
		margin-right: var(--space-lg, 2rem);
		margin-bottom: var(--space-md, 1.5rem);
	}

	.ernesto-text-flow-col {
		width: 100%;
	}

	/* Clear float after text section */
	.ernesto-text-image-flow::after {
		content: "";
		display: table;
		clear: both;
	}
}

/* Mobile: Stack images on top */
@media (max-width: 767px) {
	.ernesto-image-flow-col {
		order: -1;
		margin-bottom: var(--space-md, 1.5rem);
	}

	.ernesto-image-flow-right,
	.ernesto-image-flow-left {
		float: none;
		margin: 0 0 var(--space-md, 1.5rem) 0;
	}
}

/* ==========================================================================
   Dark Mode Support
   ========================================================================== */

@media (prefers-color-scheme: dark) {
	/* Background handled by light-dark() via --bg-surface from customizer */
	.ernesto-card {
		background-color: var(--bg-surface);
		border-color: var(--border-color, #334155);
	}

	.ernesto-heading,
	.ernesto-heading-hero,
	.ernesto-card-title {
		color: var(--text-heading, #f8fafc);
	}

	.ernesto-card-content,
	.ernesto-lead {
		color: var(--text-main, #e2e8f0);
	}
}

/* ==========================================================================
   Accessibility
   ========================================================================== */

/* Focus states */
.ernesto-btn:focus-visible,
.ernesto-card:focus-visible {
	outline: 3px solid var(--color-primary);
	outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
	.ernesto-btn,
	.ernesto-card,
	* {
		transition: none !important;
		animation: none !important;
	}
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
	.ernesto-section-hero {
		min-height: auto;
		padding: 2rem 0;
	}

	.ernesto-btn {
		border: 1px solid #000;
		text-decoration: none;
	}

	.ernesto-grid-2,
	.ernesto-grid-3,
	.ernesto-grid-4 {
		display: block;
	}

	.ernesto-card {
		break-inside: avoid;
		margin-bottom: 1rem;
	}
}

/* ==========================================================================
   Visual Hero with Image — Button overrides
   Match slider button: same font-size, font-weight, border-radius (from customizer)
   ========================================================================== */

/* Style the actual button link — not the wrapper div */
.ernesto-hero-visual .wp-block-button__link,
.ernesto-hero-visual .wp-block-button__link.wp-element-button {
	border-radius: var(--button-border-radius, 9999px) !important;
	font-size: var(--font-size-lg, 1.125rem) !important;
	font-weight: var(--font-weight-semibold, 600) !important;
	padding: var(--space-md, 1rem) var(--space-2xl, 2.5rem) !important;
	background-color: var(--color-primary) !important;
	color: var(--text-on-brand, #ffffff) !important;
	border-color: var(--color-primary) !important;
	box-shadow: var(--shadow-md) !important;
	transition: all var(--transition-fast) !important;
	text-decoration: none !important;
}

.ernesto-hero-visual .wp-block-button__link:hover,
.ernesto-hero-visual .wp-block-button__link.wp-element-button:hover {
	background-color: var(--color-primary-hover) !important;
	border-color: var(--color-primary-hover) !important;
	transform: translateY(-2px) !important;
	box-shadow: var(--shadow-lg) !important;
}

/* Strip button appearance from the wrapper div (was causing double-button look) */
.ernesto-hero-visual .wp-block-button {
	background: none !important;
	border: none !important;
	padding: 0 !important;
	box-shadow: none !important;
}
