/*
 * Vinolibano — the look of the whole site: colours, type, buttons, header, footer, pages and
 * the blog. WooCommerce pages (shop, product, basket, checkout, account): woocommerce.css.
 */

/* ------------------------------------------------------------------ tokens */

:root {
	--vl-wine: #5a0e14;        /* buttons, footer */
	--vl-wine-text: #6a1b1b;   /* links, menu */
	--vl-wine-dark: #3f090e;   /* hover */
	--vl-gold: #c6a571;        /* lines and accents */
	--vl-gold-text: #86643a;   /* small gold text on cream (readable) */
	--vl-cream: #f4efe7;       /* page background */
	--vl-sand: #e6ddd0;        /* panels */
	--vl-heading: #6a1b1b;     /* headings (the old theme's heading colour) */
	--vl-ink: #333;            /* strong text, prices, fields */
	--vl-text: #666;           /* body text */
	--vl-link: #5a0e14;        /* links */
	--vl-line: rgba(90, 14, 20, .16);
	--vl-footer-title: #fdf3e1;
	--vl-serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
	--vl-sans: Raleway, "Helvetica Neue", Arial, sans-serif;
	--vl-label: Raleway, "Helvetica Neue", Arial, sans-serif;
	--vl-max: 1160px;
	--vl-narrow: 760px;
	--vl-gutter: clamp(20px, 4vw, 40px);
}

/* -------------------------------------------------------------------- base */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	overflow-x: clip;
}

body {
	margin: 0;
	background: var(--vl-cream);
	color: var(--vl-text);
	font: 300 16px/1.8 var(--vl-sans);
	-webkit-font-smoothing: antialiased;
}

img,
svg,
video {
	max-width: 100%;
	height: auto;
}

h1,
h2,
h3,
h4,
h5,
h6 {
	margin: 0 0 .5em;
	color: var(--vl-heading);
	font-family: var(--vl-serif);
	font-weight: 300;
	line-height: 1;
	letter-spacing: 0;
}

/* Words to stress inside a heading: <em> (e.g. "Ein Herz für <em>libanesische Weine</em>"). */
:is(h1, h2, h3, h4, h5, h6) em {
	font-style: italic;
}

h1 { font-size: clamp(38px, 5vw, 56px); }
h2 { font-size: clamp(30px, 3.6vw, 40px); }
h3 { font-size: clamp(24px, 2.6vw, 30px); }
h4 { font-size: 22px; }
h5,
h6 { font-size: 18px; }

p,
ul,
ol,
dl,
blockquote,
figure,
table {
	margin: 0 0 1.25em;
}

a {
	color: var(--vl-link);
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
}

a:hover {
	color: var(--vl-wine-dark);
}

:focus-visible {
	outline: 2px solid var(--vl-wine);
	outline-offset: 3px;
}

strong,
b {
	color: var(--vl-ink);
	font-weight: 700;
}

hr {
	margin: 2.5em 0;
	border: 0;
	border-top: 1px solid var(--vl-line);
}

blockquote {
	padding: .2em 0 .2em 1.2em;
	border-left: 2px solid var(--vl-gold);
	color: var(--vl-ink);
	font: italic 400 24px/1.5 var(--vl-serif);
}

table {
	width: 100%;
	border-collapse: collapse;
}

th,
td {
	padding: 10px 12px;
	border-bottom: 1px solid var(--vl-line);
	text-align: left;
}

figcaption,
.wp-caption-text {
	margin-top: 8px;
	color: var(--vl-text);
	font-size: 14px;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.vl-skip-link:focus {
	z-index: 1000;
	top: 8px;
	left: 8px;
	width: auto;
	height: auto;
	margin: 0;
	padding: 12px 18px;
	clip: auto;
	background: #fff;
	color: var(--vl-wine);
	font-weight: 700;
}

/* ------------------------------------------------------- layout and labels */

.vl-container {
	width: min(100% - 2 * var(--vl-gutter), var(--vl-max));
	margin-inline: auto;
}

.vl-container--narrow {
	width: min(100% - 2 * var(--vl-gutter), var(--vl-narrow));
}

.vl-section {
	padding-block: clamp(40px, 7vw, 90px);
}

/* Small gold capitals above a heading: "— Unsere Geschichte". */
.vl-eyebrow {
	margin: 0 0 12px;
	color: var(--vl-gold-text);
	font: 700 14px/1.4 var(--vl-label);
	letter-spacing: .08em;
	text-transform: uppercase;
}

.vl-eyebrow::before {
	content: "— ";
}

/* ----------------------------------------------------------------- buttons */

.vl-button,
.wp-block-button__link,
.wp-element-button,
input[type="submit"],
button[type="submit"] {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 48px;
	padding: 14px 26px;
	border: 1px solid var(--vl-wine);
	border-radius: 0;
	background: var(--vl-wine);
	color: #fff;
	font: 700 13px/1.4 var(--vl-sans);
	letter-spacing: .15em;
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	cursor: pointer;
	transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.vl-button:hover,
.wp-block-button__link:hover,
.wp-element-button:hover,
input[type="submit"]:hover,
button[type="submit"]:hover {
	border-color: var(--vl-wine-dark);
	background: var(--vl-wine-dark);
	color: #fff;
}

.vl-button--outline,
.is-style-outline > .wp-block-button__link {
	background: transparent;
	color: var(--vl-wine-text);
}

.vl-button--outline:hover,
.is-style-outline > .wp-block-button__link:hover {
	background: var(--vl-wine);
	color: #fff;
}

.vl-button--small {
	min-height: 40px;
	padding: 9px 20px;
	font-size: 11px;
}

.vl-buttons {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.vl-text-link {
	color: var(--vl-wine-text);
	font: 700 12px/1.4 var(--vl-sans);
	letter-spacing: .14em;
	text-decoration: none;
	text-transform: uppercase;
}

.vl-text-link:hover {
	text-decoration: underline;
	text-decoration-color: var(--vl-gold);
}

/* ------------------------------------------------------------------- forms */

input[type="text"],
input[type="email"],
input[type="search"],
input[type="password"],
input[type="tel"],
input[type="url"],
input[type="number"],
input[type="date"],
textarea,
select {
	max-width: 100%;
	min-height: 46px;
	padding: 10px 12px;
	border: 1px solid #d3c7b8;
	border-radius: 0;
	background: #fff;
	color: var(--vl-ink);
	font: 400 16px/1.4 var(--vl-sans);
}

textarea {
	min-height: 140px;
}

input:focus,
textarea:focus,
select:focus {
	border-color: var(--vl-wine);
	outline: 1px solid var(--vl-wine);
	outline-offset: 0;
}

label {
	color: var(--vl-ink);
}

.vl-search-form {
	display: flex;
	gap: 10px;
	max-width: 640px;
}

.vl-search-form input[type="search"] {
	flex: 1;
	min-width: 0;
}

/* ------------------------------------------------------------------ header */

.vl-header {
	position: relative;
	z-index: 50;
	background: var(--vl-cream);
}

.vl-header-bar {
	display: flex;
	align-items: center;
	gap: 28px;
	min-height: 96px;
}

.vl-logo {
	flex: 0 0 auto;
	display: block;
	line-height: 0;
}

.vl-logo img {
	width: 140px;
	height: auto;
}

.vl-nav {
	flex: 1 1 auto;
	min-width: 0;
}

.vl-menu {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 22px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.vl-menu li {
	position: relative;
}

.vl-menu a {
	display: block;
	padding: 10px 0;
	color: var(--vl-wine-text);
	font: 400 12px/1.3 var(--vl-sans);
	letter-spacing: .06em;
	text-decoration: none;
	text-transform: uppercase;
}

.vl-menu a:hover,
.vl-menu .current-menu-item > a,
.vl-menu .current-menu-ancestor > a,
.vl-menu .current_page_item > a {
	color: var(--vl-wine);
	text-decoration: underline;
	text-decoration-color: var(--vl-gold);
	text-underline-offset: 6px;
}

/* Dropdowns (a second menu level) on wide screens. */
.vl-menu .sub-menu {
	position: absolute;
	top: 100%;
	left: -18px;
	z-index: 10;
	display: none;
	min-width: 220px;
	margin: 0;
	padding: 10px 18px;
	list-style: none;
	background: var(--vl-cream);
	box-shadow: 0 14px 30px -14px rgba(63, 9, 14, .35);
}

.vl-menu li:hover > .sub-menu,
.vl-menu li:focus-within > .sub-menu,
.vl-menu li.is-open > .sub-menu {
	display: block;
}

.vl-menu .sub-menu a {
	padding: 9px 0;
	white-space: nowrap;
}

.vl-menu > .menu-item-has-children {
	display: flex;
	align-items: center;
}

/* The ▾ after an entry with a dropdown (opens it by tap or keyboard). */
.vl-submenu-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 36px;
	margin-left: 2px;
	padding: 0;
	border: 0;
	background: none;
	color: var(--vl-wine-text);
	cursor: pointer;
}

.vl-submenu-toggle::before {
	content: "";
	width: 6px;
	height: 6px;
	margin-top: -3px;
	border-right: 1.5px solid currentColor;
	border-bottom: 1.5px solid currentColor;
	transform: rotate(45deg);
	transition: transform .2s ease;
}

.vl-submenu-toggle[aria-expanded="true"]::before {
	margin-top: 3px;
	transform: rotate(-135deg);
}

.vl-tools {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 14px;
	margin-left: auto;
}

.vl-icon {
	display: block;
	width: 20px;
	height: 20px;
}

.vl-icon-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	min-height: 44px;
	padding: 0;
	border: 0;
	background: none;
	color: var(--vl-wine-text);
	cursor: pointer;
}

.vl-icon-button:hover {
	color: var(--vl-wine);
}

.vl-cart-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	color: var(--vl-wine);
	font-size: 12px;
	text-decoration: none;
	white-space: nowrap;
}

.vl-cart-link:hover .vl-cart-count {
	text-decoration: underline;
}

/* The number isn't known yet for this visitor (see vinolibano_cart_link_script()): keep its place, show nothing. */
.vl-cart-link.is-pending .vl-cart-count {
	visibility: hidden;
}

.vl-langs {
	display: flex;
	gap: 6px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.vl-langs a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	min-height: 40px;
	color: var(--vl-wine-text);
	font-size: 12px;
	letter-spacing: .06em;
	text-decoration: none;
}

.vl-langs a:hover {
	color: var(--vl-wine);
	text-decoration: underline;
	text-decoration-color: var(--vl-gold);
}

.vl-langs a[aria-current] {
	color: var(--vl-wine);
	font-weight: 700;
	text-decoration: underline;
	text-decoration-color: var(--vl-gold);
	text-underline-offset: 6px;
}

.vl-langs--bar {
	margin-left: 18px;
}

.vl-langs--menu,
.vl-menu-toggle,
.vl-menu-toggle .vl-icon--close,
.vl-menu-toggle[aria-expanded="true"] .vl-icon--menu {
	display: none;
}

.vl-menu-toggle[aria-expanded="true"] .vl-icon--close {
	display: block;
}

/* Without JavaScript there is nothing to open the search with. */
.vl-no-js .vl-search-toggle {
	display: none;
}

.vl-search-panel {
	padding: 20px 0;
	border-top: 1px solid var(--vl-line);
	background: var(--vl-cream);
}

.vl-search-panel .vl-search-form {
	max-width: 760px;
}

/* Phones and tablets: menu behind the ☰ button, with the language switch inside it. */
@media (max-width: 980px) {
	.vl-header-bar {
		gap: 8px;
		min-height: 68px;
	}

	.vl-logo img {
		width: 104px;
	}

	.vl-tools {
		gap: 2px;
	}

	.vl-menu-toggle {
		display: inline-flex;
	}

	.vl-langs--bar {
		display: none;
	}

	.vl-nav {
		position: absolute;
		top: 100%;
		right: 0;
		left: 0;
		display: none;
		max-height: calc(100vh - 68px);
		overflow-y: auto;
		padding: 6px var(--vl-gutter) 26px;
		border-top: 1px solid var(--vl-line);
		background: var(--vl-cream);
		box-shadow: 0 18px 30px -18px rgba(63, 9, 14, .35);
	}

	.vl-nav.is-open {
		display: block;
	}

	.vl-menu {
		flex-direction: column;
		gap: 0;
	}

	.vl-menu a {
		padding: 14px 0;
		border-bottom: 1px solid var(--vl-line);
		font-size: 14px;
	}

	.vl-menu .sub-menu {
		position: static;
		display: block;
		min-width: 0;
		padding: 0 0 0 18px;
		box-shadow: none;
	}

	/* In the ☰ menu the sub-entries are always shown, indented. */
	.vl-menu > .menu-item-has-children {
		display: block;
	}

	.vl-submenu-toggle {
		display: none;
	}

	.vl-langs--menu {
		display: flex;
		padding-top: 14px;
	}

	.vl-langs--menu a {
		font-size: 14px;
	}

	/* No JavaScript: show the menu as a plain row under the logo. */
	.vl-no-js .vl-header-bar {
		flex-wrap: wrap;
	}

	.vl-no-js .vl-nav {
		position: static;
		display: block;
		order: 3;
		width: 100%;
		padding: 0 0 12px;
		border: 0;
		box-shadow: none;
	}

	.vl-no-js .vl-menu-toggle {
		display: none;
	}
}

@media (max-width: 480px) {
	.vl-cart-count {
		font-size: 11px;
	}

	.vl-logo img {
		width: 92px;
	}
}

/* ------------------------------------------------------------------ footer */

.vl-footer {
	padding-top: 58px;
	background: var(--vl-wine);
	color: #fff;
}

.vl-footer a {
	color: #fff;
	text-decoration: none;
}

.vl-footer a:hover {
	text-decoration: underline;
	text-decoration-color: var(--vl-gold);
}

.vl-footer :focus-visible {
	outline-color: #fff;
}

.vl-footer-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 40px 32px;
	align-items: start;
	text-align: center;
}

.vl-footer-brand {
	text-align: left;
}

.vl-footer-brand img {
	width: 180px;
}

.vl-footer-title {
	margin: 0 0 18px;
	color: var(--vl-footer-title);
	font: 300 clamp(32px, 2.8vw, 40px)/1.2 var(--vl-serif);
	text-wrap: balance;
}

.vl-footer-menu {
	display: grid;
	gap: 12px;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 16px;
	line-height: 1.5;
}

.vl-footer-menu--caps a {
	text-transform: uppercase;
}

.vl-footer-menu--light {
	font-family: var(--vl-label);
	font-weight: 300;
}

.vl-footer-menu--light a {
	overflow-wrap: anywhere;
}

.vl-footer-copy {
	margin-block: 0;
	padding: 60px 0;
	font-size: 15px;
	text-align: center;
}

/* Phones: two columns (links | social), then contact and policies across the width, left-aligned. */
@media (max-width: 760px) {
	.vl-footer {
		padding-top: 44px;
	}

	.vl-footer-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 32px 24px;
		text-align: left;
	}

	.vl-footer-brand,
	.vl-footer-col--contact,
	.vl-footer-col--legal {
		grid-column: 1 / -1;
	}

	.vl-footer-brand img {
		width: 150px;
	}

	.vl-footer-col--social {
		order: 1;
	}

	.vl-footer-col--contact {
		order: 2;
	}

	.vl-footer-col--legal {
		order: 3;
	}

	.vl-footer-title {
		margin-bottom: 10px;
		font-size: 27px;
	}

	.vl-footer-menu {
		gap: 9px;
		font-size: 15px;
	}

	.vl-footer-copy {
		margin-top: 36px;
		padding: 22px 0 28px;
		border-top: 1px solid rgba(253, 243, 225, .18);
		font-size: 13px;
		text-align: left;
	}
}

/* ------------------------------------------------------- pages and content */

.vl-page-header {
	padding-top: clamp(36px, 6vw, 80px);
}

.vl-section > .vl-page-header:first-child {
	padding-top: 0;
}

.vl-page-title {
	margin-bottom: .4em;
}

.vl-page-intro {
	max-width: var(--vl-narrow);
	font-size: 18px;
}

.vl-page-intro--italic {
	font-style: italic;
}

.vl-page-content {
	padding-bottom: clamp(40px, 7vw, 90px);
}

/* No title above (the home page): keep the content off the header. */
.vl-page-content:first-child {
	padding-top: clamp(40px, 7vw, 90px);
}

.vl-entry > :last-child {
	margin-bottom: 0;
}

.vl-entry ul,
.vl-entry ol {
	padding-left: 1.3em;
}

.vl-entry li + li {
	margin-top: .3em;
}

.vl-entry img {
	display: block;
}

.vl-entry .alignleft {
	float: left;
	margin: .3em 1.6em 1em 0;
}

.vl-entry .alignright {
	float: right;
	margin: .3em 0 1em 1.6em;
}

.vl-entry .aligncenter {
	margin-inline: auto;
}

.vl-entry .alignfull {
	width: 100vw;
	max-width: 100vw;
	margin-inline: calc(50% - 50vw);
}

.vl-entry--full .alignwide,
.vl-entry--full > :not(.alignfull) {
	width: min(100% - 2 * var(--vl-gutter), var(--vl-max));
	margin-inline: auto;
}

.vl-entry--full .alignfull {
	width: 100%;
	margin-inline: 0;
}

.vl-empty {
	font-size: 18px;
}

/* Section titles on the terms, privacy and returns pages (inc/pages.php). */
.vl-entry .vl-legal-heading {
	max-width: 32em;
	margin: 1.9em 0 .6em;
	padding-top: .9em;
	border-top: 1px solid var(--vl-line);
	font-size: clamp(24px, 2.6vw, 30px);
	line-height: 1.15;
	text-wrap: balance;
}

.vl-entry h3.vl-legal-heading {
	padding-top: 0;
	border-top: 0;
	font-size: clamp(20px, 2vw, 24px);
}

.vl-entry > .vl-legal-heading:first-child {
	margin-top: 0;
	padding-top: 0;
	border-top: 0;
}

/* ---------------------------------------------------------------- the blog */

.vl-card-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 48px 32px;
	margin-top: 24px;
}

.vl-card {
	display: flex;
	flex-direction: column;
}

.vl-card-media {
	display: block;
	margin-bottom: 18px;
	overflow: hidden;
	background: var(--vl-sand);
	aspect-ratio: 3 / 2;
}

.vl-card-media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .5s ease;
}

.vl-card:hover .vl-card-media img {
	transform: scale(1.04);
}

.vl-card-body {
	display: flex;
	flex: 1;
	flex-direction: column;
	align-items: flex-start;
}

.vl-card-body .vl-eyebrow {
	margin-bottom: 8px;
	font-size: 12px;
}

.vl-card-title {
	margin-bottom: 10px;
	font-size: 28px;
}

.vl-card-title a {
	color: var(--vl-ink);
	text-decoration: none;
}

.vl-card-title a:hover {
	color: var(--vl-wine);
}

.vl-card-excerpt p {
	margin-bottom: 14px;
}

.vl-card .vl-text-link {
	margin-top: auto;
}

.vl-post-image {
	margin-block: 10px 40px;
}

.vl-post-image img {
	display: block;
	width: 100%;
	max-height: 620px;
	object-fit: cover;
}

.vl-post-footer {
	padding-block: 40px;
}

/* "Das könnte Sie auch interessieren": three other posts under a post. */
.vl-related {
	padding-block: clamp(40px, 6vw, 72px);
	border-top: 1px solid var(--vl-line);
}

.vl-related-title {
	margin-bottom: 8px;
	text-align: center;
}

.vl-related .vl-card-title {
	font-size: clamp(22px, 2.2vw, 26px);
}

.vl-post-comments,
.vl-related:last-child {
	padding-bottom: clamp(40px, 7vw, 90px);
}

.vl-tags {
	font-size: 14px;
}

.post-navigation .nav-links,
.pagination .nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 12px 20px;
	justify-content: space-between;
	padding-top: 24px;
	border-top: 1px solid var(--vl-line);
}

.pagination .nav-links {
	justify-content: center;
	margin-top: 56px;
}

.page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	min-height: 44px;
	padding: 0 10px;
	color: var(--vl-wine-text);
	text-decoration: none;
}

.page-numbers.current {
	background: var(--vl-wine);
	color: #fff;
}

.vl-comments {
	margin-top: 48px;
}

.vl-comment-list,
.vl-comment-list .children {
	margin: 0 0 32px;
	padding: 0;
	list-style: none;
}

.vl-comment-list .children {
	margin: 20px 0 0 32px;
}

.vl-comment-list .comment-body {
	padding: 20px 0;
	border-bottom: 1px solid var(--vl-line);
}

.vl-comment-list .avatar {
	float: left;
	margin-right: 14px;
	border-radius: 50%;
}

.vl-comment-list .comment-metadata {
	font-size: 13px;
}

.comment-form p {
	margin-bottom: 16px;
}

.comment-form label {
	display: block;
	margin-bottom: 4px;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
}

.vl-404 {
	text-align: center;
}

.vl-404 .vl-buttons {
	justify-content: center;
	margin-top: 32px;
}

@media (max-width: 980px) {
	.vl-card-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 600px) {
	.vl-card-grid {
		grid-template-columns: 1fr;
	}
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		transition: none !important;
		animation: none !important;
	}
}

/* The old event popup a code snippet still adds (#eventPopup): replaced by the home page's own promotion popup. */
#eventPopup {
	display: none !important;
}
