/*
Theme Name: Java St
Author: Local Starter Themes
Author URI: https://localstarterthemes.com
Description: A bright, welcoming block theme for coffee shops, espresso bars, bakery-cafés, and brunch spots. Warm cream surfaces, an espresso-brown accent, butter-yellow stripes, and headlines that switch into an elegant italic serif give your site the feel of a sunny neighborhood café. Starter patterns cover the hero, a striped welcome band, menu category cards, a price board, a journal, and a visit section with opening hours. Built 100% on native blocks — no page builder, no dependencies.
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 7.4
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: java-st
Tags: one-column, custom-colors, custom-menu, custom-logo, editor-style, featured-images, full-site-editing, block-patterns, wide-blocks, block-styles, food-and-drink
*/

html {
	scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}
}

/* Keep anchored sections clear of the sticky header. */
main [id] {
	scroll-margin-top: 5rem;
}

/* Italic words in a heading switch to the serif accent face. */
:where(h1, h2, h3, h4, .wp-block-heading, .wp-block-post-title) em {
	font-family: var(--wp--preset--font-family--accent);
	font-style: italic;
	font-weight: 400;
	letter-spacing: -0.01em;
}

.java-st-header {
	z-index: 20;
}

.java-st-header .wp-block-site-title,
.java-st-header .wp-block-button__link {
	white-space: nowrap;
}

/* Collapse the header menu into the overlay below 960px (core only does it below 600px). */
@media screen and (min-width: 600px) and (max-width: 959px) {
	.java-st-header .wp-block-navigation__responsive-container-open:not(.always-shown) {
		display: flex;
	}

	.java-st-header .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) {
		display: none;
	}
}

@media screen and (max-width: 959px) {
	.java-st-header .java-st-header-cta {
		display: none;
	}

	.wp-block-navigation__responsive-container.is-menu-open {
		padding: 2rem !important;
	}

	.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content,
	.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content ul.wp-block-navigation__container {
		align-items: center !important;
	}

	.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container {
		gap: var(--wp--preset--spacing--40) !important;
	}

	.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
		font-size: 1.25rem;
	}
}

.wp-block-navigation__responsive-container.is-menu-open {
	background-color: var(--wp--preset--color--surface, #fbf8f2) !important;
	color: var(--wp--preset--color--on-surface, #2b201a) !important;
}

.is-style-no-wrap {
	white-space: nowrap;
}

/* Small pill label ("Open today", "New"). */
.is-style-java-pill {
	display: inline-block;
	padding: 0.3em 0.9em;
	border: 1px solid currentColor;
	border-radius: 999px;
	font-size: var(--wp--preset--font-size--label);
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

/* Hero: keep the copy on the same wide grid as the sections below. */
.wp-block-cover.java-st-hero .wp-block-cover__inner-container {
	width: 100%;
	max-width: var(--wp--style--global--wide-size, 1200px);
	margin-left: auto;
	margin-right: auto;
}

/* Menu category cards: whole card is clickable, arrow badge in the corner. */
.java-st-card {
	position: relative;
	overflow: hidden;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.java-st-card:hover,
.java-st-card:focus-within {
	transform: translateY(-3px);
	box-shadow: 0 14px 30px -18px rgba(43, 32, 26, 0.45);
}

.java-st-card .wp-block-image {
	margin: 0;
}

.java-st-card .wp-block-image img {
	border-radius: 0;
	transition: transform 0.5s ease;
}

.java-st-card:hover .wp-block-image img {
	transform: scale(1.04);
}

.java-st-card::after {
	content: "\2197";
	position: absolute;
	top: 0.75rem;
	right: 0.75rem;
	display: grid;
	place-items: center;
	width: 2rem;
	height: 2rem;
	border-radius: 999px;
	background: var(--wp--preset--color--on-surface, #2b201a);
	color: var(--wp--preset--color--surface, #fbf8f2);
	font-size: 0.875rem;
	line-height: 1;
	pointer-events: none;
}

.java-st-card .java-st-card-label a {
	text-decoration: none;
}

/* Stretch the label link over the whole card. */
.java-st-card .java-st-card-label a::before {
	content: "";
	position: absolute;
	inset: 0;
}

@media (prefers-reduced-motion: reduce) {
	.java-st-card,
	.java-st-card .wp-block-image img {
		transition: none;
	}

	.java-st-card:hover,
	.java-st-card:hover .wp-block-image img {
		transform: none;
	}
}

/* Price board rows: name on the left, dotted leader, price on the right. */
.java-st-price-row > :first-child {
	min-width: 0;
}

.java-st-price-row > .java-st-leader {
	flex: 1 1 auto;
	width: auto !important;
	min-width: 1.5rem;
	margin: 0 !important;
	align-self: center;
	border: 0;
	border-bottom: 2px dotted var(--wp--preset--color--outline, #a08b78);
	background: none !important;
	opacity: 1;
	transform: translateY(0.3em);
}

.java-st-price-row > :last-child {
	flex-shrink: 0;
}

/* Price board: the intro column follows the long list on wide screens. */
@media screen and (min-width: 782px) {
	.java-st-sticky {
		position: sticky;
		top: 6rem;
		align-self: flex-start;
	}
}

/* Small text links ("See all prices →"). */
.java-st-link a {
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 0.3em;
}

/* Opening hours: day on the left, time on the right. */
.java-st-hours-row {
	border-bottom: 1px solid rgba(242, 236, 225, 0.18);
}

/* Buttons on dark sections (hero, visit) flip to light on hover. */
.java-st-hero .wp-element-button:hover,
.java-st-hero .wp-element-button:focus,
.has-inverse-surface-background-color .wp-element-button:hover,
.has-inverse-surface-background-color .wp-element-button:focus {
	background-color: var(--wp--preset--color--surface-lowest, #ffffff) !important;
	color: var(--wp--preset--color--on-surface, #2b201a) !important;
}

/* Comment form fields. */
.wp-block-post-comments-form input:not([type="submit"]):not([type="checkbox"]),
.wp-block-post-comments-form textarea {
	background-color: var(--wp--preset--color--surface-lowest, #ffffff);
	color: var(--wp--preset--color--on-surface, #2b201a);
	border: 1px solid var(--wp--preset--color--outline-variant, #e6ddcd);
	border-radius: 6px;
	padding: 0.75rem 1rem;
}

.wp-block-post-comments-form input:not([type="submit"]):not([type="checkbox"]):focus,
.wp-block-post-comments-form textarea:focus {
	outline: 2px solid var(--wp--preset--color--secondary, #9c5a2b);
	outline-offset: 1px;
}

@media screen and (max-width: 781px) {
	.java-st-hero {
		min-height: 80vh !important;
	}

	.java-st-sketch {
		display: none;
	}
}

@media screen and (max-width: 600px) {
	.java-st-header {
		padding-left: var(--wp--preset--spacing--40) !important;
		padding-right: var(--wp--preset--spacing--40) !important;
	}
}
