/* Ohmania Hero — replaces the Slider Revolution "Cover" slide.
   Measurements taken from the original slide: 1425x650 canvas, text column
   starting ~90px from the left, vertically centred, layers stacked
   kicker / title / strapline / button. Entrance: fade-in, kicker at 450ms,
   title and strapline at 500ms, 300ms each; button visible immediately. */

.ohm-hero {
	--ohm-hero-ratio: 1425 / 650;
	--ohm-hero-min-h: 420px;
	--ohm-hero-kicker: #e6d3a3;
	--ohm-hero-text: #ffffff;
	--ohm-hero-overlay: transparent;
	--ohm-hero-pad-x: clamp(20px, 6.3vw, 90px);

	position: relative;
	width: 100%;
	aspect-ratio: var(--ohm-hero-ratio);
	min-height: var(--ohm-hero-min-h);
	overflow: hidden;
	background: #262626;
	color: var(--ohm-hero-text);
	isolation: isolate;
	/* grid so the inner column is centred against the section's real height,
	   including when that height comes from min-height rather than aspect-ratio */
	display: grid;
	align-items: center;
}

.ohm-hero__media,
.ohm-hero__media img,
.ohm-hero__overlay {
	position: absolute;
	inset: 0;
}

.ohm-hero__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center center;
	display: block;
	max-width: none;
}

.ohm-hero__overlay {
	background: var(--ohm-hero-overlay);
}

/* Content column matches the theme header (#menu_wrapper): 1170px centred from
   1100px up, 960px between 960 and 1099px, full width with the header's 30px /
   20px side padding below that. So the text lines up with the logo and nav. */
.ohm-hero__inner {
	position: relative;
	z-index: 1;
	align-self: center;
	width: 100%;
	max-width: var(--ohm-hero-max-w, 1170px);
	margin: 0 auto;
	padding: 0;
	box-sizing: border-box;
	display: flex;
	align-items: center;
}

@media (min-width: 960px) and (max-width: 1099px) {
	.ohm-hero__inner {
		max-width: 960px;
	}
}

@media (min-width: 768px) and (max-width: 959px) {
	.ohm-hero__inner {
		max-width: none;
		padding-left: 30px;
		padding-right: 30px;
	}
}

@media (max-width: 767px) {
	.ohm-hero__inner {
		max-width: none;
		padding-left: 20px;
		padding-right: 20px;
	}
}

.ohm-hero--center .ohm-hero__inner {
	justify-content: center;
	text-align: center;
}

.ohm-hero__content {
	max-width: 1046px;
}

.ohm-hero__kicker,
.ohm-hero__title,
.ohm-hero__subtitle {
	margin: 0;
	padding: 0;
	text-shadow: none;
	color: var(--ohm-hero-text);
}

/* "Welcome to" — Alegreya 700 italic, 70px / 50px, gold */
.ohm-hero__kicker {
	font-family: Alegreya, Georgia, serif;
	font-weight: 700;
	font-style: italic;
	font-size: clamp(38px, 4.9vw, 70px);
	line-height: 0.72;
	color: var(--ohm-hero-kicker);
	margin-bottom: 0.32em;
	text-transform: none;
	letter-spacing: 0;
}

/* "The Gables Restaurant" — Lato 300, 65px, -3px tracking; "The Gables" bold */
.ohm-hero__title {
	font-family: Lato, "Helvetica Neue", Arial, sans-serif;
	font-weight: 300;
	font-size: clamp(34px, 4.56vw, 65px);
	line-height: 1.1;
	letter-spacing: -0.046em;
	text-transform: none;
	margin-bottom: 0.3em;
}

.ohm-hero__title strong {
	font-weight: 700;
}

/* "A local dining experience like no other" — Lato 20px / 24px */
.ohm-hero__subtitle {
	font-family: Lato, "Helvetica Neue", Arial, sans-serif;
	font-weight: 400;
	font-size: clamp(16px, 1.4vw, 20px);
	line-height: 1.2;
	letter-spacing: 0;
	margin-bottom: 2.1em;
}

/* BOOK NOW — Jost 600 11px, 1px tracking, 12px 35px padding, 2px white border, transparent */
.ohm-hero__button,
.ohm-hero__button:visited {
	display: inline-block;
	font-family: Jost, Lato, Arial, sans-serif;
	font-weight: 600;
	font-size: 11px;
	line-height: 17px;
	letter-spacing: 1px;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--ohm-hero-text);
	background: transparent;
	border: 2px solid var(--ohm-hero-text);
	border-radius: 0;
	padding: 12px 35px;
	box-sizing: border-box;
	cursor: pointer;
	transition: border-radius 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.ohm-hero__button:hover,
.ohm-hero__button:focus-visible {
	color: var(--ohm-hero-text);
	border-radius: 3px;
	/* the original hover thickened the border to 3px; a shadow does that without a layout shift */
	box-shadow: 0 0 0 1px var(--ohm-hero-text);
	background: rgba(255, 255, 255, 0.06);
	outline: none;
}

/* Entrance animation (mirrors the slider timeline) */
@keyframes ohm-hero-in {
	from { opacity: 0; transform: translateY(6px); }
	to   { opacity: 1; transform: none; }
}

.ohm-hero__kicker,
.ohm-hero__title,
.ohm-hero__subtitle {
	opacity: 0;
	animation: ohm-hero-in 0.3s ease-out forwards;
}

.ohm-hero__kicker   { animation-delay: 0.45s; }
.ohm-hero__title    { animation-delay: 0.5s; }
.ohm-hero__subtitle { animation-delay: 0.5s; }

@media (prefers-reduced-motion: reduce) {
	.ohm-hero__kicker,
	.ohm-hero__title,
	.ohm-hero__subtitle {
		animation: none;
		opacity: 1;
	}
}

/* The theme's header is transparent and sits on top of the hero. Below 1024px the
   1425/650 ratio gets too short for the header (top bar + logo row) plus the text,
   so switch to a min-height and push the content below the header. */
@media (max-width: 1024px) {
	.ohm-hero {
		aspect-ratio: auto;
		min-height: max(var(--ohm-hero-min-h), 62vw);
	}

	/* The header (top bar + logo row, about 150px) overlays the top of the hero.
	   Reserve that band so the text centres in the visible part of the photo. */
	.ohm-hero__inner {
		padding-top: 150px;
		padding-bottom: 30px;
	}
}

/* Phones: the old slide switched to a 480x720 portrait canvas and hid the
   text layers, leaving photo + button. Default here keeps the text, scaled.
   Add hide_text_mobile="yes" to reproduce the original behaviour. */
@media (max-width: 767px) {
	.ohm-hero {
		min-height: max(var(--ohm-hero-min-h), 72vh);
	}

	.ohm-hero__inner {
		padding-top: 100px; /* phone header: top bar 30px + logo row ~70px */
		padding-bottom: 30px;
	}

	.ohm-hero--hide-text-mobile .ohm-hero__kicker,
	.ohm-hero--hide-text-mobile .ohm-hero__title,
	.ohm-hero--hide-text-mobile .ohm-hero__subtitle {
		display: none;
	}
}

/* Neutralise theme wrappers when the shortcode sits inside a page-builder text block.
   Give the builder block the slug "ohm-hero-cover" (or anything starting "ohm-hero"):
   Grand Restaurant forces 20-30px padding on .one.withsmallpadding at tablet/phone widths. */
.ppb_text_fullwidth .ohm-hero,
.ppb_text .ohm-hero {
	margin: 0;
}

.one.withsmallpadding[id^="ohm-hero"],
.one.withpadding[id^="ohm-hero"] {
	padding: 0 !important;
}
