/* ==========================================================================
   Herbs By Rachu — Header & Hero
   Palette drawn from logo: deep forest green / olive / leaf green / cream
   Fonts:   Fraunces (headings) + Jost (body)
   ========================================================================== */

:root {
	--hbr-forest:      #16351b;
	--hbr-forest-soft: rgba(22, 53, 27, 0.08);
	--hbr-olive:       #5c7a29;
	--hbr-leaf:        #8fbf4d;
	--hbr-leaf-light:  #c3e08a;
	--hbr-cream:       #f8f6ee;
	--hbr-white:       #ffffff;
	--hbr-ink:         #1c2b16;
	--hbr-ink-muted:   #4c5a45;
	--hbr-border:      rgba(22, 53, 27, 0.12);
	--hbr-shadow:      0 10px 30px rgba(22, 53, 27, 0.14);
	--hbr-shadow-lg:   0 20px 50px rgba(22, 53, 27, 0.20);
	--hbr-radius:      16px;
	--hbr-ease:        cubic-bezier(0.16, 1, 0.3, 1);
	--hbr-header-h:    88px;
}

body {
	font-family: 'Jost', 'Segoe UI', sans-serif;
	color: var(--hbr-ink);
}

.hero__title,
.hero__product-title {
	font-family: 'Fraunces', Georgia, serif;
}

/* ==========================================================================
   HEADER — always solid (logo is green, needs a light ground)
   ========================================================================== */

.site-header {
	position: sticky;
	top: 0;
	left: 0;
	right: 0;
	z-index: 999;
	background: var(--hbr-cream);
	border-bottom: 1px solid var(--hbr-border);
	transition: box-shadow 0.35s var(--hbr-ease);
}

.site-header.is-scrolled {
	box-shadow: var(--hbr-shadow);
}

.site-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	max-width: 1320px;
	margin: 0 auto;
	padding: 22px 32px;
	min-height: var(--hbr-header-h);
}

/* Nav — left */
.main-navigation {
	display: flex;
	align-items: center;
	flex: 1;
}

.main-navigation ul {
	display: flex;
	align-items: center;
	gap: 32px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.main-navigation ul ul {
	display: none;
}

.main-navigation a {
	font-size: 0.95rem;
	font-weight: 500;
	letter-spacing: 0.01em;
	color: var(--hbr-ink);
	text-decoration: none;
	transition: color 0.25s var(--hbr-ease);
}

.main-navigation a:hover,
.main-navigation a:focus {
	color: var(--hbr-olive);
}

.menu-toggle {
	display: none;
	background: transparent;
	border: 0;
	cursor: pointer;
	padding: 8px;
}

.menu-toggle__bars {
	display: flex;
	flex-direction: column;
	gap: 5px;
}

.menu-toggle__bars span {
	display: block;
	width: 22px;
	height: 2px;
	background: var(--hbr-ink);
}

/* Branding — centre */
.site-branding {
	flex: 0 0 auto;
	text-align: center;
}

.site-branding .custom-logo-link img {
	max-height: 52px;
	width: auto;
	transition: filter 0.25s var(--hbr-ease);
}

.site-branding .site-title {
	margin: 0;
	font-family: 'Fraunces', Georgia, serif;
	font-size: 1.6rem;
	font-weight: 600;
	letter-spacing: 0.01em;
	text-transform: lowercase;
}

.site-branding .site-title a {
	color: var(--hbr-forest);
	text-decoration: none;
}

/* Actions — right */
.header-actions {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 20px;
	flex: 1;
}

.header-actions__icon {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: transparent;
	border: 0;
	color: var(--hbr-ink);
	cursor: pointer;
	position: relative;
	text-decoration: none;
	font-size: 0.92rem;
	font-weight: 500;
	transition: color 0.25s var(--hbr-ease);
}

.header-actions__icon:hover,
.header-actions__icon:focus {
	color: var(--hbr-olive);
}

.header-actions__label {
	display: inline-block;
}

.cart-count {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 20px;
	height: 20px;
	padding: 0 5px;
	border-radius: 999px;
	background: var(--hbr-leaf);
	color: var(--hbr-forest);
	font-size: 0.72rem;
	font-weight: 700;
}

/* Search flyout */
.header-search {
	max-height: 0;
	overflow: hidden;
	background: var(--hbr-white);
	transition: max-height 0.35s var(--hbr-ease);
}

.header-search.is-open {
	max-height: 90px;
}

.header-search__form {
	display: flex;
	align-items: center;
	gap: 12px;
	max-width: 1320px;
	margin: 0 auto;
	padding: 18px 32px;
	border-top: 1px solid var(--hbr-border);
}

.header-search__field {
	flex: 1;
	border: 0;
	background: transparent;
	font-family: 'Jost', sans-serif;
	font-size: 1rem;
	color: var(--hbr-ink);
	outline: none;
}

.header-search__submit {
	display: inline-flex;
	background: var(--hbr-forest);
	color: var(--hbr-white);
	border: 0;
	border-radius: 999px;
	width: 38px;
	height: 38px;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

/* ==========================================================================
   HERO
   ========================================================================== */

.hero {
	position: relative;
	min-height: 92vh;
	display: flex;
	align-items: center;
	overflow: hidden;
	background: var(--hbr-forest);
}

.hero__media {
	position: absolute;
	inset: 0;
	background-image: var(--hero-image);
	background-size: cover;
	background-position: center;
}

.hero__overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, rgba(0, 0, 0, 0.1) 35%, rgba(0, 0, 0, 0.45) 100%);
}

.hero__content {
	position: relative;
	z-index: 2;
	max-width: 1320px;
	width: 100%;
	margin: 0 auto;
	padding: 0 32px;
	color: var(--hbr-white);
}

.hero__eyebrow {
	display: inline-flex;
	align-items: center;
	padding: 8px 18px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.14);
	backdrop-filter: blur(6px);
	font-size: 0.85rem;
	font-weight: 500;
	letter-spacing: 0.03em;
	margin-bottom: 28px;
}

.hero__title {
	margin: 0 0 22px;
	font-size: clamp(2.4rem, 5vw, 4rem);
	line-height: 1.1;
	font-weight: 500;
	max-width: 14ch;
}

.hero__subtitle {
	margin: 0 0 36px;
	max-width: 46ch;
	font-size: 1.05rem;
	line-height: 1.6;
	color: rgba(255, 255, 255, 0.88);
}

.hero__cta-row {
	display: flex;
	gap: 16px;
}

.btn-primary {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 15px 28px;
	border-radius: 999px;
	background: var(--hbr-forest);
	color: var(--hbr-white);
	font-weight: 600;
	font-size: 0.95rem;
	text-decoration: none;
	border: 1px solid rgba(255, 255, 255, 0.18);
	transition: background 0.25s var(--hbr-ease), transform 0.25s var(--hbr-ease);
}

.btn-primary:hover,
.btn-primary:focus {
	background: var(--hbr-olive);
	transform: translateY(-2px);
	color: var(--hbr-white);
}

/* Floating product card */
.hero__product-card {
	position: absolute;
	z-index: 2;
	right: 48px;
	bottom: 48px;
	width: min(360px, calc(100% - 64px));
	background: var(--hbr-cream);
	border-radius: var(--hbr-radius);
	box-shadow: var(--hbr-shadow-lg);
	padding: 24px 26px;
}

.hero__product-brand {
	display: block;
	font-size: 0.8rem;
	font-weight: 600;
	color: var(--hbr-olive);
	text-transform: lowercase;
	margin-bottom: 6px;
}

.hero__product-title {
	margin: 0 0 10px;
	font-size: 1.2rem;
	font-weight: 600;
	color: var(--hbr-forest);
}

.hero__product-desc {
	margin: 0 0 16px;
	font-size: 0.9rem;
	line-height: 1.5;
	color: var(--hbr-ink-muted);
}

.hero__product-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--hbr-forest);
	text-decoration: none;
}

.hero__product-link:hover,
.hero__product-link:focus {
	color: var(--hbr-olive);
}

/* ==========================================================================
   NEW ARRIVALS
   ========================================================================== */

.new-in {
	background: var(--hbr-cream);
	padding: 100px 32px;
}

.new-in__header {
	max-width: 640px;
	margin: 0 auto 56px;
	text-align: center;
}

.new-in__eyebrow {
	display: inline-flex;
	align-items: center;
	padding: 7px 16px;
	border-radius: 999px;
	background: var(--hbr-forest-soft);
	color: var(--hbr-forest);
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	margin-bottom: 20px;
}

.new-in__title {
	margin: 0;
	font-size: clamp(1.9rem, 3.4vw, 2.6rem);
	line-height: 1.25;
	font-weight: 500;
	color: var(--hbr-forest);
}

.new-in__grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 32px;
	max-width: 1160px;
	margin: 0 auto;
}

.product-card {
	display: flex;
	align-items: center;
	gap: 24px;
	background: transparent;
}

.product-card__media {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 160px;
	height: 160px;
	border-radius: var(--hbr-radius);
	background: linear-gradient(160deg, var(--hbr-leaf-light) 0%, var(--hbr-white) 100%);
	overflow: hidden;
}

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

.product-card__media-placeholder {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	border-radius: 50%;
	background: var(--hbr-white);
	color: var(--hbr-olive);
}

.product-card__body {
	display: flex;
	flex-direction: column;
	flex: 1;
	min-width: 0;
}

.product-card__eyebrow {
	font-size: 0.78rem;
	font-weight: 500;
	color: var(--hbr-olive);
	text-transform: lowercase;
	margin-bottom: 6px;
}

.product-card__title {
	margin: 0 0 8px;
	font-size: 1.15rem;
	font-weight: 600;
	line-height: 1.3;
}

.product-card__title a {
	color: var(--hbr-forest);
	text-decoration: none;
}

.product-card__title a:hover {
	color: var(--hbr-olive);
}

.product-card__desc {
	margin: 0 0 20px;
	font-size: 0.9rem;
	line-height: 1.6;
	color: var(--hbr-ink-muted);
}

.product-card__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

.product-card__price {
	font-size: 1rem;
	font-weight: 600;
	color: var(--hbr-forest);
}

.product-card__actions {
	display: inline-flex;
	align-items: center;
	gap: 10px;
}

.product-card__cta {
	display: inline-flex;
	align-items: center;
	padding: 10px 20px;
	border-radius: 999px;
	border: 1px solid var(--hbr-border);
	font-size: 0.85rem;
	font-weight: 600;
	color: var(--hbr-forest);
	text-decoration: none;
	transition: background 0.25s var(--hbr-ease), color 0.25s var(--hbr-ease), border-color 0.25s var(--hbr-ease);
}

.product-card__cta:hover {
	background: var(--hbr-forest);
	border-color: var(--hbr-forest);
	color: var(--hbr-white);
}

.product-card__cta-arrow {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	flex: 0 0 auto;
	border-radius: 50%;
	border: 1px solid var(--hbr-border);
	color: var(--hbr-forest);
	transition: background 0.25s var(--hbr-ease), border-color 0.25s var(--hbr-ease), color 0.25s var(--hbr-ease), transform 0.25s var(--hbr-ease);
}

.product-card:hover .product-card__cta-arrow {
	background: var(--hbr-forest);
	border-color: var(--hbr-forest);
	color: var(--hbr-white);
	transform: translateX(2px);
}

/* ==========================================================================
   CATEGORIES
   ========================================================================== */

.categories {
	background: var(--hbr-white);
	padding: 100px 32px;
}

.categories__header {
	max-width: 1320px;
	margin: 0 auto 40px;
}

.categories__eyebrow {
	display: inline-flex;
	align-items: center;
	padding: 7px 16px;
	border-radius: 999px;
	background: var(--hbr-forest-soft);
	color: var(--hbr-forest);
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	margin-bottom: 20px;
}

.categories__title {
	margin: 0;
	max-width: 16ch;
	font-size: clamp(1.9rem, 3.4vw, 2.6rem);
	line-height: 1.2;
	font-weight: 500;
	color: var(--hbr-forest);
}

.categories__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 20px;
	max-width: 1320px;
	margin: 0 auto;
}

.category-card {
	--category-image: none;
	position: relative;
	display: flex;
	align-items: flex-end;
	aspect-ratio: 3 / 4;
	border-radius: var(--hbr-radius);
	overflow: hidden;
	text-decoration: none;
	isolation: isolate;
}

.category-card__media {
	position: absolute;
	inset: 0;
	background-image: var(--category-image);
	background-color: var(--hbr-forest);
	background-size: cover;
	background-position: center;
	transition: transform 0.5s var(--hbr-ease);
}

.category-card:hover .category-card__media {
	transform: scale(1.06);
}

.category-card__overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(22, 53, 27, 0.05) 0%, rgba(22, 53, 27, 0.35) 55%, rgba(22, 53, 27, 0.85) 100%);
}

.category-card__content {
	position: relative;
	z-index: 1;
	padding: 24px 22px;
	color: var(--hbr-white);
}

.category-card__title {
	display: block;
	font-family: 'Fraunces', Georgia, serif;
	font-size: 1.4rem;
	font-weight: 500;
	margin-bottom: 8px;
}

.category-card__desc {
	display: block;
	font-size: 0.88rem;
	line-height: 1.5;
	color: rgba(255, 255, 255, 0.85);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 1100px) {
	.categories__grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 560px) {
	.categories {
		padding: 64px 20px;
	}

	.categories__grid {
		grid-template-columns: 1fr;
	}

	.category-card {
		aspect-ratio: 4 / 3;
	}
}

@media (max-width: 900px) {
	.new-in__grid {
		grid-template-columns: 1fr;
		max-width: 480px;
	}
}

@media (max-width: 560px) {
	.new-in {
		padding: 64px 20px;
	}

	.product-card {
		flex-direction: column;
		align-items: flex-start;
		text-align: left;
	}

	.product-card__media {
		width: 100%;
		height: 220px;
	}
}

@media (max-width: 900px) {
	.site-header__inner {
		padding: 18px 20px;
	}

	.main-navigation {
		position: fixed;
		top: var(--hbr-header-h);
		left: 0;
		right: 0;
		bottom: 0;
		background: var(--hbr-cream);
		flex-direction: column;
		align-items: flex-start;
		padding: 32px 24px;
		transform: translateX(-100%);
		transition: transform 0.35s var(--hbr-ease);
		flex: none;
	}

	.main-navigation.is-open {
		transform: translateX(0);
	}

	.main-navigation ul {
		flex-direction: column;
		align-items: flex-start;
		gap: 20px;
		width: 100%;
	}

	.main-navigation a {
		color: var(--hbr-ink);
		font-size: 1.1rem;
	}

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

	.header-actions__label {
		display: none;
	}

	.hero__product-card {
		left: 20px;
		right: 20px;
		bottom: 24px;
		width: auto;
	}

	.hero__title {
		max-width: none;
	}
}
