/*
Theme Name: BAKEDROLL
Theme URI: https://bakedroll.pl
Author: BAKEDROLL
Description: Lekki motyw sklepu BAKEDROLL pod WooCommerce. Kolory marki, bramka 18+, gotowy pod produkty konopne, odzież i merch.
Version: 1.1.0
Requires at least: 6.4
Requires PHP: 8.0
Text Domain: bakedroll
WC requires at least: 8.0
*/

:root {
	--br-crust: #C8842E;
	--br-crust-dark: #A8641E;
	--br-brown: #1F3D1B;
	--br-ink: #10200E;
	--br-green: #3F8F2F;
	--br-green-dark: #2C6B20;
	--br-lime: #9BD14A;
	--br-cream: #E6F2D6;
	--br-bg: #F4F9EE;
	--br-deep: #13290F;
	--br-line: #C9DDB4;
	--br-muted: #4D6345;
	--br-radius: 14px;
	--br-max: 1200px;
	--br-display: 'Bowlby One', Impact, sans-serif;
	--br-body: 'Space Grotesk', system-ui, -apple-system, sans-serif;
}

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

body {
	margin: 0;
	background: var(--br-bg);
	color: var(--br-ink);
	font-family: var(--br-body);
	font-size: 17px;
	line-height: 1.6;
}

img { max-width: 100%; height: auto; }
a { color: var(--br-green); }
a:hover { color: var(--br-green-dark); }

h1, h2, h3 {
	font-family: var(--br-display);
	font-weight: 400;
	line-height: 1.1;
	color: var(--br-brown);
	letter-spacing: .5px;
}

.br-wrap { max-width: var(--br-max); margin: 0 auto; padding: 0 20px; }

.br-btn,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.wp-block-button__link {
	display: inline-block;
	background: var(--br-green);
	color: #fff;
	border: 0;
	border-radius: 999px;
	padding: 13px 26px;
	font-family: var(--br-body);
	font-weight: 700;
	font-size: 16px;
	text-decoration: none;
	cursor: pointer;
	transition: background .15s;
}
.br-btn:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover { background: var(--br-green-dark); color: #fff; }
.woocommerce a.button.alt,
.woocommerce button.button.alt { background: var(--br-crust); }
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover { background: var(--br-crust-dark); }
.br-btn--ghost { background: transparent; color: var(--br-brown); box-shadow: inset 0 0 0 2px var(--br-brown); }
.br-btn--ghost:hover { background: var(--br-brown); color: #fff; }

/* Pasek informacyjny */
.br-topbar { background: var(--br-brown); color: var(--br-cream); font-size: 14px; text-align: center; padding: 7px 16px; }

/* Nagłówek */
.br-header { background: var(--br-bg); border-bottom: 2px solid var(--br-line); position: sticky; top: 0; z-index: 50; }
.br-header__in { display: flex; align-items: center; gap: 24px; min-height: 76px; flex-wrap: wrap; }
.br-logo { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.br-logo svg { width: 58px; height: 47px; }
.br-logo__txt { font-family: var(--br-display); font-size: 28px; color: var(--br-brown); line-height: 1; }
.br-logo__txt span { color: var(--br-green); }
.br-nav { flex: 1; }
.br-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 22px; flex-wrap: wrap; }
.br-nav a { color: var(--br-ink); text-decoration: none; font-weight: 600; }
.br-nav a:hover, .br-nav .current-menu-item > a { color: var(--br-green); }
.br-cart { position: relative; display: inline-flex; align-items: center; gap: 6px; color: var(--br-brown); font-weight: 700; text-decoration: none; min-height: 44px; }
.br-cart__count { background: var(--br-crust); color: #fff; border-radius: 999px; font-size: 12px; min-width: 22px; height: 22px; display: inline-flex; align-items: center; justify-content: center; padding: 0 6px; }
.br-menu-toggle { display: none; background: none; border: 2px solid var(--br-brown); border-radius: 10px; min-width: 44px; min-height: 44px; color: var(--br-brown); font-weight: 700; cursor: pointer; }

@media (max-width: 860px) {
	.br-menu-toggle { display: inline-block; margin-left: auto; }
	.br-nav { order: 10; flex-basis: 100%; display: none; padding-bottom: 14px; }
	.br-nav.is-open { display: block; }
	.br-nav ul { flex-direction: column; gap: 12px; }
}

/* Strona główna */
.br-hero { padding: 64px 0 56px; }
.br-hero__in { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.br-hero h1 { font-size: clamp(44px, 7vw, 84px); margin: 0 0 12px; }
.br-hero h1 span { color: var(--br-green); }
.br-hero__lead { font-size: 20px; color: var(--br-muted); max-width: 30em; margin: 0 0 28px; }
.br-hero__cta { display: flex; gap: 12px; flex-wrap: wrap; }
.br-hero__art svg { width: 100%; height: auto; max-width: 460px; display: block; margin: 0 auto; }
@media (max-width: 860px) { .br-hero__in { grid-template-columns: 1fr; } .br-hero__art { order: -1; } .br-hero__art svg { max-width: 300px; } }

.br-section { padding: 56px 0; }
.br-section--cream { background: var(--br-cream); }
.br-section h2 { font-size: clamp(30px, 4vw, 44px); margin: 0 0 24px; }

.br-cats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.br-cat { background: #fff; border: 2px solid var(--br-line); border-radius: var(--br-radius); padding: 24px; text-decoration: none; color: var(--br-ink); transition: transform .15s, border-color .15s; }
.br-cat:hover { transform: translateY(-3px); border-color: var(--br-green); color: var(--br-ink); }
.br-cat h3 { margin: 0 0 6px; font-size: 22px; }
.br-cat p { margin: 0; color: var(--br-muted); font-size: 15px; }
@media (max-width: 860px) { .br-cats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .br-cats { grid-template-columns: 1fr; } }

.br-trust { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.br-trust div { border-top: 3px solid var(--br-crust); padding-top: 14px; }
.br-trust strong { display: block; font-size: 18px; color: var(--br-brown); }
@media (max-width: 760px) { .br-trust { grid-template-columns: 1fr; } }

/* Treść */
.br-main { padding: 40px 0 64px; min-height: 50vh; }
.br-content { max-width: 780px; }
.br-post { margin-bottom: 40px; }

/* WooCommerce */
.woocommerce ul.products { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; margin: 0; }
.woocommerce ul.products::before, .woocommerce ul.products::after { display: none; }
.woocommerce ul.products li.product { width: auto !important; margin: 0 !important; float: none !important; background: #fff; border: 2px solid var(--br-line); border-radius: var(--br-radius); padding: 14px; display: flex; flex-direction: column; }
.woocommerce ul.products li.product img { border-radius: 10px; }
.woocommerce ul.products li.product .woocommerce-loop-product__title { font-family: var(--br-body); font-weight: 700; font-size: 17px; color: var(--br-ink); }
.woocommerce ul.products li.product .price { color: var(--br-brown); font-weight: 700; font-size: 18px; }
.woocommerce ul.products li.product .button { margin-top: auto; text-align: center; }
@media (max-width: 960px) { .woocommerce ul.products { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 680px) { .woocommerce ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } }
.woocommerce span.onsale { background: var(--br-crust); border-radius: 999px; min-height: 0; line-height: 1; padding: 8px 12px; }
.woocommerce div.product p.price, .woocommerce div.product span.price { color: var(--br-brown); font-weight: 700; font-size: 26px; }
.woocommerce .woocommerce-message, .woocommerce .woocommerce-info { border-top-color: var(--br-green); }
.woocommerce .woocommerce-message::before, .woocommerce .woocommerce-info::before { color: var(--br-green); }
.br-coa { background: var(--br-cream); border-radius: var(--br-radius); padding: 14px 18px; margin: 16px 0; font-size: 15px; }

/* Stopka */
.br-footer { background: var(--br-ink); color: var(--br-cream); padding: 48px 0 24px; font-size: 15px; }
.br-footer a { color: var(--br-cream); }
.br-footer a:hover { color: #fff; }
.br-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.br-footer ul { list-style: none; margin: 0; padding: 0; }
.br-footer li { margin-bottom: 8px; }
.br-footer h3 { color: var(--br-cream); font-size: 20px; margin: 0 0 12px; }
.br-footer__legal { border-top: 1px solid #4A3020; margin-top: 32px; padding-top: 18px; color: #C9B596; font-size: 13px; }
@media (max-width: 760px) { .br-footer__grid { grid-template-columns: 1fr; } }

/* Bramka 18+ */
.br-age { position: fixed; inset: 0; z-index: 9999; background: rgba(43, 23, 9, .92); display: flex; align-items: center; justify-content: center; padding: 20px; }
.br-age[hidden] { display: none; }
.br-age__box { background: var(--br-bg); border-radius: 20px; max-width: 440px; width: 100%; padding: 32px 28px; text-align: center; }
.br-age__box svg { width: 140px; height: auto; }
.br-age__box h2 { font-size: 30px; margin: 8px 0; }
.br-age__box p { color: var(--br-muted); margin: 0 0 22px; }
.br-age__btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.br-age__no { font-size: 14px; margin-top: 14px; display: none; color: #9A2A1C; }

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

/* ===== Zielona wersja 1.1 ===== */
.br-topbar { background: var(--br-deep); color: var(--br-lime); }
.br-header { background: var(--br-brown); border-bottom-color: var(--br-deep); }
.br-logo__txt { color: #fff; }
.br-logo__txt span, .br-hero h1 span { color: var(--br-lime); }
.br-nav a { color: #E6F2D6; }
.br-nav a:hover, .br-nav .current-menu-item > a { color: var(--br-lime); }
.br-cart { color: #fff; }
.br-cart__count { background: var(--br-lime); color: var(--br-deep); }
.br-menu-toggle { border-color: var(--br-lime); color: var(--br-lime); }

.br-hero { position: relative; overflow: hidden; background: radial-gradient(120% 90% at 70% 40%, #2F6A24 0%, var(--br-brown) 55%, var(--br-deep) 100%); color: #E6F2D6; }
.br-hero .br-wrap { position: relative; z-index: 2; }
.br-hero h1 { color: #fff; }
.br-hero__lead { color: #CFE5B8; }
.br-hero .br-btn { background: var(--br-lime); color: var(--br-deep); }
.br-hero .br-btn:hover { background: #B5E36E; color: var(--br-deep); }
.br-hero .br-btn--ghost { background: transparent; color: #fff; box-shadow: inset 0 0 0 2px #fff; }
.br-hero .br-btn--ghost:hover { background: #fff; color: var(--br-deep); }
.br-hero__art svg { filter: drop-shadow(0 20px 30px rgba(0,0,0,.35)); animation: br-bob 5s ease-in-out infinite; }

/* Liście */
.br-leaves { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.br-leaf { position: absolute; top: -12%; color: var(--br-lime); opacity: .0; animation: br-fall linear infinite; }
.br-leaf svg { width: 100%; height: auto; display: block; animation: br-spin ease-in-out infinite alternate; animation-duration: inherit; }
.br-leaf:nth-child(1)  { left: 4%;  width: 46px; animation-duration: 14s; animation-delay: 0s; }
.br-leaf:nth-child(2)  { left: 14%; width: 30px; animation-duration: 11s; animation-delay: -3s; color: #6DB33F; }
.br-leaf:nth-child(3)  { left: 26%; width: 58px; animation-duration: 17s; animation-delay: -7s; }
.br-leaf:nth-child(4)  { left: 38%; width: 26px; animation-duration: 10s; animation-delay: -2s; color: #4E9A33; }
.br-leaf:nth-child(5)  { left: 50%; width: 40px; animation-duration: 15s; animation-delay: -9s; }
.br-leaf:nth-child(6)  { left: 61%; width: 34px; animation-duration: 12s; animation-delay: -5s; color: #6DB33F; }
.br-leaf:nth-child(7)  { left: 72%; width: 52px; animation-duration: 16s; animation-delay: -11s; }
.br-leaf:nth-child(8)  { left: 83%; width: 28px; animation-duration: 9s;  animation-delay: -4s; color: #4E9A33; }
.br-leaf:nth-child(9)  { left: 92%; width: 44px; animation-duration: 13s; animation-delay: -8s; }
.br-leaf:nth-child(10) { left: 8%;  width: 22px; animation-duration: 18s; animation-delay: -13s; color: #B5E36E; }
.br-leaf:nth-child(11) { left: 45%; width: 24px; animation-duration: 19s; animation-delay: -15s; color: #B5E36E; }
.br-leaf:nth-child(12) { left: 67%; width: 20px; animation-duration: 20s; animation-delay: -6s; color: #B5E36E; }

@keyframes br-fall {
	0%   { transform: translate3d(0, 0, 0); opacity: 0; }
	10%  { opacity: .55; }
	50%  { transform: translate3d(40px, 60vh, 0); }
	90%  { opacity: .45; }
	100% { transform: translate3d(-30px, 120vh, 0); opacity: 0; }
}
@keyframes br-spin { from { transform: rotate(-35deg); } to { transform: rotate(35deg); } }
@keyframes br-bob { 0%,100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-12px) rotate(2deg); } }

@media (prefers-reduced-motion: reduce) {
	.br-leaf, .br-leaf svg, .br-hero__art svg { animation: none; }
	.br-leaf { opacity: .3; top: auto; bottom: 8%; }
}

.br-section--cream { background: var(--br-cream); }
.br-cat:hover { border-color: var(--br-green); }
.br-trust div { border-top-color: var(--br-green); }
.br-footer { background: var(--br-deep); }
.br-footer__legal { border-top-color: #24451D; color: #A9C48F; }
.br-age { background: rgba(19, 41, 15, .94); }
.woocommerce span.onsale { background: var(--br-green); }
