/*
Theme Name: BTWN Trading
Theme URI: https://github.com/EHeroGit/btwn-trading-site
Author: Edmilson
Description: Institutional and commercial theme for BTWN Trading - Amazonian Robusta specialty coffee export. Multilingual (Polylang), RTL-ready, responsive.
Version: 0.3.1
Requires at least: 6.5
Requires PHP: 8.1
License: GPL-2.0-or-later
Text Domain: btwn
*/

/* ---------- Fonts (self-hosted, SIL OFL; no requests to Google) ---------- */
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("assets/fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("assets/fonts/inter-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("assets/fonts/eb-garamond-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: normal; font-weight: 600; font-display: swap; src: url("assets/fonts/eb-garamond-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: italic; font-weight: 500; font-display: swap; src: url("assets/fonts/eb-garamond-latin-500-italic.woff2") format("woff2"); }

/* ---------- Tokens ---------- */
:root {
	/* Brand palette: forest #062819, gold #D6A443, ivory #FCFAF5.
	   Variable names kept from the first version: --coffee = forest (dark), --cherry = gold for text on light. */
	--ink: #0f1f18;
	--coffee: #062819;
	--coffee-2: #0c3a25;
	--gold: #D6A443;
	--gold-2: #c8953a;
	--cherry: #7d5a14;   /* gold, darkened for text on light backgrounds (contrast 6:1 on ivory) */
	--cherry-2: #5f430c;
	--forest: #1d5a3a;
	--error: #9b1c1c;
	--cream: #FCFAF5;
	--sand: #F3EEE2;
	--line: #E3DAC6;
	--muted: #5f625b;
	--white: #ffffff;

	--font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
	--font-display: "EB Garamond", "Iowan Old Style", Georgia, "Noto Serif", serif;

	--wrap: 1180px;
	--gutter: clamp(16px, 4vw, 40px);
	--radius: 6px;
	--section: clamp(56px, 9vw, 112px);
}

/* Scripts the display face does not cover fall back to system fonts. */
/* The Latin fonts come first: they only contain Latin glyphs, so brand names and numbers stay in the
   site fonts and the browser falls back to the system CJK/Arabic font for everything else. */
:lang(zh) { --font-display: "EB Garamond", "Noto Serif SC", "Songti SC", serif; --font-body: "Inter", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif; }
:lang(ar) { --font-display: "EB Garamond", "Noto Naskh Arabic", "Geeza Pro", serif; --font-body: "Inter", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif; }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
	margin: 0;
	background: var(--cream);
	color: var(--ink);
	font-family: var(--font-body);
	font-size: 17px;
	line-height: 1.65;
	text-rendering: optimizeLegibility;
	-webkit-font-smoothing: antialiased;
}
img, video, iframe { max-width: 100%; height: auto; display: block; }
a { color: var(--cherry); text-underline-offset: 3px; }
a:hover { color: var(--cherry-2); }
h1, h2, h3, h4 {
	font-family: var(--font-display);
	font-weight: 600;
	line-height: 1.12;
	color: var(--coffee);
	margin: 0 0 .5em;
	letter-spacing: -.01em;
}
h1 { font-size: clamp(2.4rem, 5.5vw, 4.4rem); }
.hero:not(.hero--page) h1 { font-size: clamp(2.4rem, 4.4vw, 3.9rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
h3 { font-size: clamp(1.35rem, 2vw, 1.6rem); }
p { margin: 0 0 1.1em; }
:focus-visible { outline: 3px solid var(--cherry-2); outline-offset: 2px; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }
.skip-link:focus { position: fixed; inset-block-start: 8px; inset-inline-start: 8px; z-index: 1000; width: auto; height: auto; clip: auto; background: var(--white); padding: 10px 16px; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.eyebrow {
	display: inline-block;
	font-size: .78rem;
	font-weight: 600;
	letter-spacing: .16em;
	text-transform: uppercase;
	color: var(--cherry);
	margin-block-end: 14px;
}

/* ---------- Buttons ---------- */
.btn, .wp-block-button__link, .btwn-form button {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	min-height: 48px; padding: 12px 26px;
	border-radius: var(--radius); border: 1.5px solid var(--gold);
	background: var(--gold); color: var(--coffee);
	font: 600 .95rem/1.2 var(--font-body); letter-spacing: .02em;
	text-decoration: none; cursor: pointer;
	transition: background .2s, color .2s, border-color .2s;
}
.btn:hover, .wp-block-button__link:hover, .btwn-form button:hover { background: var(--gold-2); border-color: var(--gold-2); color: var(--coffee); }
.btn--ghost, .is-style-outline .wp-block-button__link { background: transparent; color: var(--coffee); border-color: var(--cherry); }
.btn--ghost:hover, .is-style-outline .wp-block-button__link:hover { background: var(--coffee); border-color: var(--coffee); color: var(--white); }
.btn--light { background: var(--white); border-color: var(--white); color: var(--coffee); }
.btn--light:hover { background: transparent; color: var(--white); border-color: var(--white); }
.wp-block-buttons { display: flex; flex-wrap: wrap; gap: 12px; margin-block: 8px 0; }

/* ---------- Header ---------- */
.site-header {
	position: sticky; inset-block-start: 0; z-index: 50;
	background: var(--cream); /* opaque: a backdrop blur made header text look soft on Windows */
	border-block-end: 1px solid var(--line);
}
.admin-bar .site-header { inset-block-start: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { inset-block-start: 0; } }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--coffee); }
.brand img { max-height: 48px; width: auto; }
.brand__name { font-family: var(--font-display); font-weight: 600; font-size: 1.55rem; letter-spacing: .04em; line-height: 1; }
.brand__tag { display: block; font-family: var(--font-body); font-size: .62rem; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); margin-block-start: 4px; }

.primary-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.primary-nav a {
	display: block; padding: 10px 12px; border-radius: var(--radius);
	color: var(--coffee); text-decoration: none; font-size: .92rem; font-weight: 600;
}
.primary-nav a:hover, .primary-nav .current-menu-item > a, .primary-nav .current_page_item > a, .primary-nav a[aria-current="page"] { color: var(--cherry); background: var(--sand); }

.header-tools { display: flex; align-items: center; gap: 8px; }
.lang-switch { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.lang-switch a, .lang-switch span {
	display: block; min-width: 40px; padding: 8px; text-align: center;
	font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
	text-decoration: none; color: var(--muted); border-radius: var(--radius);
}
.lang-switch a:hover { color: var(--cherry); background: var(--sand); }
.lang-switch .is-current span { color: var(--white); background: var(--coffee); }

/* Header language menu (8 languages) */
.lang-menu { position: relative; }
.lang-menu summary {
	display: flex; align-items: center; gap: 6px; min-height: 48px; padding: 0 12px;
	border: 1px solid var(--line); border-radius: var(--radius); background: var(--white);
	color: var(--coffee); font-size: .8rem; font-weight: 600; letter-spacing: .08em;
	cursor: pointer; list-style: none;
}
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary svg { width: 18px; height: 18px; }
.lang-menu[open] summary { border-color: var(--cherry); }
.lang-menu ul {
	position: absolute; inset-block-start: calc(100% + 6px); inset-inline-end: 0; z-index: 60;
	min-width: 200px; margin: 0; padding: 6px; list-style: none;
	background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
	box-shadow: 0 18px 40px rgba(4, 24, 15, .14);
}
.lang-menu a, .lang-menu li > span {
	display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius);
	color: var(--ink); text-decoration: none; font-size: .95rem;
}
.lang-menu b { min-width: 24px; font-size: .72rem; letter-spacing: .08em; color: var(--muted); }
.lang-menu a:hover { background: var(--sand); color: var(--cherry); }
.lang-menu .is-current > span { background: var(--coffee); color: var(--white); }
.lang-menu .is-current b { color: var(--gold); }

/* Phone numbers and emails stay left-to-right inside RTL text */
.ltr { direction: ltr; unicode-bidi: isolate; }

.nav-toggle {
	display: none; align-items: center; justify-content: center;
	width: 48px; height: 48px; border: 1px solid var(--line); border-radius: var(--radius);
	background: var(--white); color: var(--coffee); cursor: pointer;
}
.nav-toggle svg { width: 22px; height: 22px; }

@media (max-width: 1080px) {
	.nav-toggle { display: inline-flex; }
	.primary-nav {
		position: fixed; inset: 72px 0 auto 0; max-height: calc(100vh - 72px); overflow-y: auto;
		background: var(--cream); border-block-end: 1px solid var(--line);
		box-shadow: 0 18px 40px rgba(4, 24, 15, .12);
		display: none;
	}
	.admin-bar .primary-nav { inset-block-start: 104px; }
	.primary-nav.is-open { display: block; }
	.primary-nav ul { flex-direction: column; padding: 12px var(--gutter) 20px; }
	.primary-nav a { padding: 14px 12px; font-size: 1.05rem; border-block-end: 1px solid var(--line); border-radius: 0; }
}
@media (max-width: 480px) {
	.brand__tag { display: none; }
	.lang-switch a, .lang-switch span { min-width: 34px; padding: 8px 4px; }
}

/* ---------- Hero ----------
   Text on forest green beside a framed photo. The client's photos are 500-1000 px wide,
   so they are never stretched to full screen width (that made them blurry). */
.hero {
	position: relative;
	color: var(--white);
	background: var(--coffee);
	overflow: hidden;
}
.hero__grid {
	display: grid; gap: 32px; align-items: center;
	padding-block: clamp(40px, 7vw, 88px);
}
@media (min-width: 900px) {
	.hero__grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(40px, 5vw, 72px); }
	.hero__grid--text { grid-template-columns: minmax(0, 1fr); }
}
.hero__media { margin: 0; max-width: 600px; width: 100%; justify-self: center; }
.hero__media img {
	width: 100%; aspect-ratio: 4 / 3; object-fit: cover;
	border-radius: var(--radius); border: 1px solid rgba(214, 164, 67, .45);
	box-shadow: 0 18px 40px rgba(0, 0, 0, .28);
}
.hero--page .hero__media img { aspect-ratio: 3 / 2; }
.hero__content { max-width: 680px; }
.hero h1 { color: var(--white); margin-block-end: .3em; }
.hero--page h1 { font-size: clamp(2.2rem, 4.4vw, 3.5rem); }
.hero .eyebrow { color: var(--gold); }
.hero__lead { font-size: clamp(1.05rem, 1.6vw, 1.2rem); max-width: 620px; color: rgba(255, 253, 249, .92); margin-block-end: 28px; }
.hero--page .hero__lead { margin-block-end: 0; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Page content (block editor output) ---------- */
.content { padding-block: var(--section); }
.content > .wrap > * { max-width: 760px; }
.content > .wrap > .alignwide, .content > .wrap > .wp-block-columns, .content > .wrap > .wp-block-group, .content > .wrap > .btwn-grid { max-width: none; }
.content h2 { margin-block-start: 1.6em; }
.content h2:first-child { margin-block-start: 0; }
.content ul, .content ol { padding-inline-start: 1.2em; margin: 0 0 1.2em; }
.content li { margin-block-end: .35em; }
.content blockquote, .wp-block-quote {
	margin: 1.6em 0; padding: 4px 0; padding-inline-start: 22px;
	border-inline-start: 3px solid var(--cherry);
	font-family: var(--font-display); font-size: 1.45rem; line-height: 1.35; color: var(--coffee);
}
.wp-block-image { margin: 0 0 1.4em; }
.wp-block-image img { border-radius: var(--radius); }
.wp-block-image figcaption, .wp-element-caption { font-size: .85rem; color: var(--muted); margin-block-start: 8px; }

.wp-block-columns { display: flex; flex-wrap: wrap; gap: clamp(24px, 4vw, 56px); margin-block: 0 1.6em; align-items: flex-start; }
.wp-block-columns.are-vertically-aligned-center, .wp-block-columns.is-vertically-centered { align-items: center; }
.wp-block-column { flex: 1 1 280px; min-width: 0; }

/* Full-bleed bands inside page content */
.btwn-band { position: relative; padding-block: var(--section); margin-block: var(--section); }
.btwn-band::before { content: ""; position: absolute; inset: 0 calc(50% - 50vw); z-index: -1; background: var(--sand); }
.btwn-band--dark { color: var(--cream); }
.btwn-band--dark::before { background: var(--coffee); }
.btwn-band--dark h2, .btwn-band--dark h3 { color: var(--white); }
.btwn-band--dark .eyebrow { color: var(--gold); }
.btwn-band--dark a:not(.wp-block-button__link):not(.btn) { color: var(--gold); }
/* Classic themes get an extra wrapper inside group blocks; let grids see the real children. */
.wp-block-group__inner-container { display: contents; }
.btwn-band + .btwn-band { margin-block-start: calc(var(--section) * -1); }
.content p.eyebrow { margin-block-end: 10px; }
.content .eyebrow + h2, .content .eyebrow + h3 { margin-block-start: 0; }
.wp-block-column .wp-block-image img { width: 100%; max-height: 560px; object-fit: cover; }
.content > .wrap > .btwn-band:first-child { margin-block-start: calc(var(--section) * -1); }
.content > .wrap > .btwn-band:last-child { margin-block-end: calc(var(--section) * -1); }
body { overflow-x: clip; }

/* Cards / stats */
.btwn-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; margin-block: 28px; }
.btwn-card {
	background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
	padding: 26px 24px; margin: 0;
}
.btwn-band--dark .btwn-card { background: var(--coffee-2); border-color: rgba(255,255,255,.12); }
.btwn-card h3 { margin-block-end: .35em; }
.btwn-card p:last-child { margin-block-end: 0; }
.btwn-stat { font-family: var(--font-display); font-size: clamp(2.6rem, 5vw, 3.6rem); line-height: 1; color: var(--cherry); margin-block-end: 8px !important; font-weight: 600; }
.btwn-band--dark .btwn-stat { color: var(--gold); }
.btwn-source { font-size: .82rem; color: var(--muted); }
.btwn-band--dark .btwn-source { color: rgba(247, 242, 234, .7); }

.btwn-specs { list-style: none; padding: 0 !important; margin: 0 0 1.4em; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 28px; }
.btwn-specs li { padding: 12px 0; border-block-end: 1px solid var(--line); margin: 0 !important; }

/* ---------- Home sections ---------- */
.section { padding-block: var(--section); }
.section--sand { background: var(--sand); }
.section--dark { background: var(--coffee); color: var(--cream); }
.section--dark h2 { color: var(--white); }
.section__head { max-width: 720px; margin-block-end: 36px; }

/* ---------- News ---------- */
.post-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.post-card { display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.post-card__img { aspect-ratio: 16 / 10; background: var(--sand); }
.post-card__img img { width: 100%; height: 100%; object-fit: cover; }
.post-card__body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.post-card h3 a { color: var(--coffee); text-decoration: none; }
.post-card h3 a:hover { color: var(--cherry); }
.post-meta { font-size: .8rem; color: var(--muted); margin-block-end: 10px; letter-spacing: .02em; }
.post-card__more { margin-block-start: auto; font-weight: 600; font-size: .92rem; }
.source-box { margin-block-start: 32px; padding: 20px 22px; background: var(--sand); border-radius: var(--radius); border-inline-start: 3px solid var(--cherry); }
.source-box p { margin: 0 0 10px; font-size: .92rem; color: var(--muted); }
.pagination { margin-block-start: 40px; display: flex; gap: 8px; flex-wrap: wrap; }
.pagination .page-numbers { padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; }
.pagination .current { background: var(--coffee); color: var(--white); border-color: var(--coffee); }

/* ---------- Video (privacy-friendly facade) ---------- */
.btwn-video { margin: 0 0 1.6em; }
.btwn-video__frame {
	position: relative; aspect-ratio: 16 / 9; width: 100%;
	background: #000; border-radius: var(--radius); overflow: hidden;
}
.btwn-video__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.btwn-video__play {
	position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; cursor: pointer;
	background: #000 center / cover no-repeat;
}
.btwn-video__play::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.05), rgba(0,0,0,.45)); }
.btwn-video__icon {
	position: absolute; inset-block-start: 50%; inset-inline-start: 50%; transform: translate(-50%, -50%);
	width: 76px; height: 76px; border-radius: 50%; background: var(--gold);
	display: grid; place-items: center; box-shadow: 0 8px 30px rgba(0,0,0,.35); transition: transform .2s, background .2s;
}
[dir="rtl"] .btwn-video__icon { transform: translate(50%, -50%); }
.btwn-video__play:hover .btwn-video__icon { background: var(--gold-2); }
.btwn-video__icon svg { width: 30px; height: 30px; fill: var(--coffee); margin-inline-start: 4px; }
.btwn-video__caption { font-size: .9rem; color: var(--muted); margin-block-start: 10px; }
.section--dark .btwn-video__caption, .btwn-band--dark .btwn-video__caption { color: rgba(247, 242, 234, .75); }
.btwn-video__note { font-size: .75rem; color: var(--muted); margin-block-start: 4px; }
.btwn-video-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 28px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: clamp(28px, 5vw, 64px); }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-list { list-style: none; padding: 0 !important; margin: 0 0 24px; }
.contact-list li { display: flex; flex-direction: column; padding: 14px 0; border-block-end: 1px solid var(--line); margin: 0 !important; }
.contact-list .label { font-size: .74rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.contact-list a { font-weight: 600; word-break: break-word; align-self: flex-start; }
.is-placeholder { color: var(--muted); font-style: italic; }

.btwn-form { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 4vw, 36px); }
.btwn-form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .btwn-form .row { grid-template-columns: 1fr; } }
.btwn-form label { display: block; font-size: .85rem; font-weight: 600; margin-block-end: 6px; color: var(--coffee); }
.btwn-form .field { margin-block-end: 18px; }
.btwn-form input, .btwn-form select, .btwn-form textarea {
	width: 100%; min-height: 48px; padding: 12px 14px;
	border: 1px solid var(--line); border-radius: var(--radius); background: var(--cream);
	font: 400 1rem/1.4 var(--font-body); color: var(--ink);
}
.btwn-form textarea { min-height: 150px; resize: vertical; }
.btwn-form input:focus, .btwn-form select:focus, .btwn-form textarea:focus { outline: 2px solid var(--cherry); outline-offset: 0; border-color: var(--cherry); background: var(--white); }
.btwn-form .hp { position: absolute; inset-inline-start: -9999px; width: 1px; height: 1px; overflow: hidden; }
.btwn-form .consent { display: flex; gap: 10px; align-items: flex-start; font-size: .85rem; color: var(--muted); font-weight: 400; }
.btwn-form .consent input { width: 20px; min-height: 20px; height: 20px; margin-block-start: 2px; flex: none; accent-color: var(--cherry); }
.notice { padding: 14px 18px; border-radius: var(--radius); margin-block-end: 20px; font-weight: 600; }
.notice--ok { background: #e3eee4; color: var(--forest); }
.notice--err { background: #f6e0e0; color: var(--error); }

/* ---------- CTA strip ---------- */
.cta-strip { background: var(--coffee); color: var(--white); padding-block: clamp(44px, 6vw, 72px); }
.cta-strip__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.cta-strip h2 { color: var(--white); margin: 0 0 6px; }
.cta-strip p { margin: 0; color: rgba(255, 253, 249, .88); max-width: 620px; }

/* ---------- Footer ---------- */
.site-footer { background: #041a10; color: rgba(247, 242, 234, .78); padding-block: 64px 28px; font-size: .92rem; }
.site-footer a { color: rgba(247, 242, 234, .9); text-decoration: none; }
.site-footer a:hover { color: var(--gold); text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { font-family: var(--font-body); font-size: .74rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); margin-block-end: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-block-end: 8px; }
.site-footer .brand__name { color: var(--white); }
.footer-bottom { margin-block-start: 48px; padding-block-start: 22px; border-block-start: 1px solid rgba(255,255,255,.12); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; font-size: .8rem; }
.photo-credits { margin-block-start: 14px; font-size: .72rem; line-height: 1.6; color: rgba(247, 242, 234, .55); }
.photo-credits a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.site-footer .lang-switch a { color: rgba(247, 242, 234, .75); }
.site-footer .lang-switch .is-current span { background: rgba(255,255,255,.14); }

/* Brand line on the About page, coffee steps */
.btwn-tagline { font-size: .8rem; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--cherry); }
.btwn-steps .btwn-card { border-block-start: 3px solid var(--gold); }
.cta-strip .btn--light { background: var(--gold); border-color: var(--gold); color: var(--coffee); }
.cta-strip .btn--light:hover { background: var(--gold-2); border-color: var(--gold-2); }

/* ---------- 404 / misc ---------- */
.empty-state { padding-block: var(--section); text-align: center; }

/* =====================================================================
   Motion and detail (v0.3)
   Brand-led touches: gold hairlines, the logo's square frame, a coffee leaf.
   Every animation is disabled under prefers-reduced-motion (end of file).
   ===================================================================== */
:root {
	--ease: cubic-bezier(.2, .7, .2, 1);
	--glow: radial-gradient(60% 80% at 85% 20%, rgba(214, 164, 67, .16), transparent 60%),
	        radial-gradient(50% 70% at 0% 100%, rgba(29, 90, 58, .55), transparent 70%);
}
::selection { background: var(--gold); color: var(--coffee); }

/* Eyebrow: gold hairline before the label */
.eyebrow { display: inline-flex; align-items: center; gap: 12px; }
.eyebrow::before { content: ""; width: 28px; height: 1px; background: currentColor; opacity: .8; flex: none; }

/* Header: shadow + compact after scrolling; gold reading-progress line */
.site-header { transition: box-shadow .3s var(--ease); }
.site-header.is-scrolled { box-shadow: 0 10px 30px rgba(4, 24, 15, .08); }
.site-header__inner { transition: min-height .3s var(--ease); }
.site-header.is-scrolled .site-header__inner { min-height: 62px; }
.scroll-progress {
	position: absolute; inset-inline: 0; inset-block-end: -1px; height: 2px;
	background: linear-gradient(90deg, var(--gold-2), var(--gold));
	transform: scaleX(var(--progress, 0)); transform-origin: left; pointer-events: none;
}
[dir="rtl"] .scroll-progress { transform-origin: right; }

/* Nav: animated gold underline instead of a filled box */
.primary-nav a { position: relative; background: none !important; transition: color .2s; }
@media (min-width: 1081px) {
	.primary-nav a::after {
		content: ""; position: absolute; inset-inline: 12px; inset-block-end: 4px; height: 1.5px;
		background: var(--gold); transform: scaleX(0); transition: transform .3s var(--ease);
	}
	.primary-nav a:hover::after, .primary-nav .current-menu-item > a::after, .primary-nav a[aria-current="page"]::after { transform: scaleX(1); }
}
.lang-menu ul { animation: menu-in .18s var(--ease); }
@keyframes menu-in { from { opacity: 0; transform: translateY(-6px); } }

/* Buttons: lift + soft shine */
.btn, .wp-block-button__link, .btwn-form button { position: relative; overflow: hidden; transition: background .25s, color .25s, border-color .25s, transform .25s var(--ease), box-shadow .25s; }
.btn:hover, .wp-block-button__link:hover, .btwn-form button:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(4, 24, 15, .18); }
.btn::after, .wp-block-button__link::after, .btwn-form button::after {
	content: ""; position: absolute; inset-block: 0; inset-inline-start: -60%; width: 40%;
	background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .45), transparent);
	transform: skewX(-20deg); transition: inset-inline-start .6s var(--ease); pointer-events: none;
}
.btn:hover::after, .wp-block-button__link:hover::after, .btwn-form button:hover::after { inset-inline-start: 130%; }

/* Hero: gold glow, leaf watermark, framed photo with slow zoom */
.hero { background: var(--glow), var(--coffee); }
.hero__media { position: relative; }
.hero__media::before {
	content: ""; position: absolute; inset: 18px -18px -18px 18px; z-index: 0;
	border: 1px solid rgba(214, 164, 67, .6); border-radius: var(--radius);
}
[dir="rtl"] .hero__media::before { inset: 18px 18px -18px -18px; }
.hero__photo { position: relative; z-index: 1; overflow: hidden; border-radius: var(--radius); box-shadow: 0 24px 60px rgba(0, 0, 0, .35); }
.hero__media img { border: 0; box-shadow: none; border-radius: 0; animation: slow-zoom 22s ease-in-out infinite alternate; }
@keyframes slow-zoom { from { transform: scale(1); } to { transform: scale(1.08); } }
.hero__grid { position: relative; z-index: 1; }
.leaf-mark {
	position: absolute; z-index: 0; width: clamp(220px, 26vw, 380px); height: auto;
	inset-block-end: -60px; inset-inline-start: -70px; transform: rotate(-28deg);
	fill: none; stroke: var(--gold); stroke-width: 1.2; opacity: .12; pointer-events: none;
	animation: sway 9s ease-in-out infinite alternate;
}
@keyframes sway { from { rotate: -3deg; } to { rotate: 3deg; } }
.hero__content > * { animation: rise .9s var(--ease) both; }
.hero__content > :nth-child(2) { animation-delay: .08s; }
.hero__content > :nth-child(3) { animation-delay: .16s; }
.hero__content > :nth-child(4) { animation-delay: .24s; }
.hero__media { animation: rise 1s .2s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(26px); } }
@media (max-width: 899px) {
	.hero__media::before { inset: 12px -12px -12px 12px; }
	[dir="rtl"] .hero__media::before { inset: 12px 12px -12px -12px; }
	.hero__media { width: auto; justify-self: stretch; margin-inline-end: 12px; }
}

/* Brand ticker under the home banner */
.ticker { background: var(--gold); color: var(--coffee); overflow: hidden; border-block: 1px solid rgba(6, 40, 25, .15); }
.ticker__track { display: flex; width: max-content; animation: ticker 38s linear infinite; }
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__row { display: flex; align-items: center; gap: 28px; padding-block: 14px; padding-inline-end: 28px; }
.ticker span { font-family: var(--font-body); font-size: .8rem; font-weight: 600; letter-spacing: .28em; text-transform: uppercase; white-space: nowrap; }
.ticker svg { width: 11px; height: 15px; fill: var(--coffee); flex: none; }
.ticker svg path { fill: none; stroke: var(--gold); stroke-width: 2.4; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* Images in content: offset gold frame, gentle zoom on hover */
.wp-block-column .wp-block-image { position: relative; isolation: isolate; }
.wp-block-column .wp-block-image::before {
	content: ""; position: absolute; inset: 16px -16px -16px 16px; border: 1px solid var(--gold); border-radius: var(--radius); z-index: -1;
}
[dir="rtl"] .wp-block-column .wp-block-image::before { inset: 16px 16px -16px -16px; }
.wp-block-column .wp-block-image img { transition: transform .8s var(--ease); box-shadow: 0 20px 50px rgba(4, 24, 15, .16); }
.wp-block-column .wp-block-image:hover img { transform: scale(1.02); }

/* Cards: numbered, lift on hover, gold line grows */
.content { counter-reset: card; }
.btwn-card { position: relative; transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s; }
.btwn-card::before {
	content: ""; position: absolute; inset-inline: -1px; inset-block-start: -1px; height: 3px;
	background: var(--gold); border-radius: var(--radius) var(--radius) 0 0;
	transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease);
}
[dir="rtl"] .btwn-card::before { transform-origin: right; }
.btwn-card:hover { transform: translateY(-6px); box-shadow: 0 22px 44px rgba(4, 24, 15, .12); }
.btwn-card:hover::before, .btwn-steps .btwn-card::before { transform: scaleX(1); }
.btwn-steps .btwn-card { border-block-start: 1px solid var(--line); }
.btwn-band:not(.btwn-band--dark) .btwn-grid:not(.btwn-steps) .btwn-card { counter-increment: card; padding-block-start: 64px; }
.btwn-band:not(.btwn-band--dark) .btwn-grid:not(.btwn-steps) .btwn-card::after {
	content: "0" counter(card); position: absolute; inset-block-start: 20px; inset-inline-start: 24px;
	font-family: var(--font-display); font-size: 1.6rem; line-height: 1; color: var(--cherry);
}

/* Dark band: glow + glassy stat cards */
.btwn-band--dark::before { background: var(--glow), var(--coffee); }
.btwn-band--dark .btwn-card { background: rgba(255, 255, 255, .04); border-color: rgba(214, 164, 67, .25); }
.btwn-band--dark .btwn-card:hover { box-shadow: 0 22px 44px rgba(0, 0, 0, .3); border-color: rgba(214, 164, 67, .55); }
.btwn-stat { font-variant-numeric: tabular-nums; }

/* Video: pulsing ring */
.btwn-video__frame { box-shadow: 0 24px 60px rgba(4, 24, 15, .22); }
.btwn-video__icon::before {
	content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 2px solid var(--gold);
	animation: pulse 2.2s var(--ease) infinite;
}
@keyframes pulse { from { opacity: .9; transform: scale(.85); } to { opacity: 0; transform: scale(1.35); } }
.btwn-video__play:hover .btwn-video__icon { transform: translate(-50%, -50%) scale(1.08); }
[dir="rtl"] .btwn-video__play:hover .btwn-video__icon { transform: translate(50%, -50%) scale(1.08); }
.btwn-video__play { transition: filter .4s; }
.btwn-video__play:hover { filter: brightness(1.08); }

/* News cards */
.post-card { transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.post-card:hover { transform: translateY(-6px); box-shadow: 0 22px 44px rgba(4, 24, 15, .12); }
.post-card__img { overflow: hidden; }
.post-card__img img { transition: transform .8s var(--ease); }
.post-card:hover .post-card__img img { transform: scale(1.06); }
.post-card__more { display: inline-flex; gap: 6px; transition: gap .25s var(--ease); }
.post-card:hover .post-card__more { gap: 12px; }

/* Specs list: gold diamond markers */
.btwn-specs li { display: flex; align-items: center; gap: 12px; transition: padding-inline-start .3s var(--ease), color .3s; }
.btwn-specs li::before { content: ""; width: 7px; height: 7px; background: var(--gold); transform: rotate(45deg); flex: none; }
.btwn-specs li:hover { padding-inline-start: 6px; color: var(--cherry); }

/* Contact */
.btwn-form { box-shadow: 0 24px 60px rgba(4, 24, 15, .08); }
.btwn-form input, .btwn-form select, .btwn-form textarea { transition: border-color .2s, background .2s, box-shadow .2s; }
.btwn-form input:focus, .btwn-form select:focus, .btwn-form textarea:focus { outline: 0; box-shadow: 0 0 0 3px rgba(214, 164, 67, .35); }

/* CTA strip: glow + leaf */
.cta-strip { position: relative; overflow: hidden; background: var(--glow), var(--coffee); border-block-start: 1px solid rgba(214, 164, 67, .25); }
.cta-strip__inner { position: relative; z-index: 1; }
.leaf-mark--cta { inset-block: -90px auto; inset-inline: auto 4%; width: clamp(180px, 20vw, 280px); transform: rotate(32deg); opacity: .14; }

/* Footer: gold hairline */
.site-footer { position: relative; }
.site-footer::before { content: ""; position: absolute; inset-inline: 0; inset-block-start: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--gold), transparent); opacity: .5; }

/* Phone numbers never break across lines */
a[href^="tel:"], a[href*="wa.me"] { white-space: nowrap; }
@media (max-width: 599px) {
	.wp-block-column .wp-block-image::before { inset: 10px -10px -10px 10px; }
	[dir="rtl"] .wp-block-column .wp-block-image::before { inset: 10px 10px -10px -10px; }
	.wp-block-column .wp-block-image { margin-inline-end: 10px; }
}

/* Back to top */
.to-top {
	position: fixed; inset-block-end: 22px; inset-inline-end: 22px; z-index: 40;
	width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%;
	background: var(--gold); color: var(--coffee); box-shadow: 0 10px 26px rgba(4, 24, 15, .25);
	opacity: 0; transform: translateY(16px); pointer-events: none; transition: opacity .3s, transform .3s var(--ease), background .2s;
}
.to-top svg { width: 22px; height: 22px; }
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--gold-2); color: var(--coffee); }

/* Reveal on scroll (only when JS runs; content is never hidden without JS) */
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s); }
.js .reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { animation: none !important; transition: none !important; }
	.js .reveal { opacity: 1; transform: none; }
}
