/*
Theme Name: 1882 Homestead
Theme URI: https://1882homestead.monarchwave.com
Description: Brand child theme for 1882 Homestead LLC — a firearms, ammo & outdoor gear shop. Built on the GreenShift block theme with WooCommerce. Carries brand colors (navy, barn red, gold), fonts, sticky header with announcement bar, and reusable block patterns so the storefront stays easy to edit in the Site Editor.
Author: Monarch Wave
Template: greenshift
Version: 1.0.0
Requires at least: 6.5
Tested up to: 6.8
Requires PHP: 8.0
Text Domain: homestead1882
*/

/* -------------------------------------------------------------------------
   Most styling lives in theme.json (colors, fonts, spacing) so it stays
   editable in Appearance → Editor → Styles. The rules below cover behavior
   theme.json can't express — sticky header, announcement bar, marquee,
   and a few WooCommerce polish tweaks.
   ------------------------------------------------------------------------- */

/* Sticky site header --------------------------------------------------- */
.site-header-sticky {
	position: -webkit-sticky;
	position: sticky;
	top: 0;
	z-index: 999;
	box-shadow: 0 2px 10px rgba(31, 45, 61, 0.12);
}

/* Slim top announcement / deals bar ------------------------------------ */
.homestead-announcement {
	font-size: 0.85rem;
	letter-spacing: 0.02em;
}
.homestead-announcement a {
	color: var(--wp--preset--color--gold);
	text-decoration: underline;
	font-weight: 600;
}

/* Scrolling "midweek deals" marquee ------------------------------------ */
.homestead-marquee {
	overflow: hidden;
	white-space: nowrap;
}
.homestead-marquee > * {
	display: inline-block;
	padding-left: 100%;
	animation: homestead-scroll 22s linear infinite;
}
.homestead-marquee:hover > * {
	animation-play-state: paused;
}
@keyframes homestead-scroll {
	0%   { transform: translateX(0); }
	100% { transform: translateX(-100%); }
}

/* Product cards: tighten the look so items read fast (Primary Arms vibe) */
.woocommerce ul.products li.product,
.wc-block-grid__product,
.wp-block-woocommerce-product-template li {
	text-align: left;
}
.wp-block-woocommerce-product-template .wp-block-woocommerce-product-image img {
	aspect-ratio: 1 / 1;
	object-fit: contain;
	background: #ffffff;
}

/* Sale badge in brand red --------------------------------------------- */
.wc-block-components-product-sale-badge,
.onsale {
	background: var(--wp--preset--color--red) !important;
	color: #ffffff !important;
	border: none !important;
}

/* Buttons: solid, confident, no rounded "bubbly" AI look --------------- */
.wp-element-button,
.wc-block-components-button,
.woocommerce a.button,
.woocommerce button.button {
	border-radius: 3px;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}

/* Hero slider readability --------------------------------------------- */
.homestead-hero .wp-block-cover__inner-container {
	max-width: 1200px;
	margin-inline: auto;
	width: 100%;
}

/* Make the single-product layout feel like PSA/Bud's: price column tidy */
.single-product .wp-block-woocommerce-product-price,
.single-product .price {
	color: var(--wp--preset--color--navy);
	font-weight: 700;
}

/* Category tiles on the homepage -------------------------------------- */
.homestead-cat-grid.wp-block-columns { gap: 1rem !important; }
.homestead-cat-grid .wp-block-column {
	gap: 1rem;
	display: flex;
	flex-direction: column;
}
.homestead-cat-tile {
	overflow: hidden;
	border-radius: 6px;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.homestead-cat-tile:hover { transform: translateY(-3px); box-shadow: 0 8px 22px rgba(31,45,61,0.25); }
.homestead-cat-tile h3 { margin: 0; }
.homestead-cat-tile h3 a { color: #fff; text-decoration: none; }
.homestead-cat-tile h3 a:hover { color: var(--wp--preset--color--gold); }

/* Header search — Super Speedy Search, fitted into the white nav bar ---- */
.homestead-search { flex: 1 1 320px; min-width: 200px; max-width: 560px; }
.homestead-search .super-speedy-search-form,
.homestead-search .super-speedy-searchform,
.homestead-search .ssswrapper,
.homestead-search .sssinputwrapper { width: 100%; margin: 0; }
.homestead-search .ssstext,
.homestead-search input.ssstext,
.homestead-search input[type="text"] {
	width: 100%;
	padding: 0.6rem 0.9rem;
	border: 1px solid #cbd2da;
	border-radius: 4px;
	font-size: 0.95rem;
	line-height: 1.3;
	background: #fff;
	box-sizing: border-box;
}
.homestead-search input.ssstext:focus,
.homestead-search input[type="text"]:focus {
	outline: 2px solid var(--wp--preset--color--gold);
	border-color: var(--wp--preset--color--gold);
}
.homestead-search .sss-suggestions,
.homestead-search .sss-suggestions-container { z-index: 1000; text-align: left; }

/* Breadcrumbs: force left alignment on category / shop archives -------- */
.woocommerce-breadcrumb,
.wc-block-breadcrumbs,
.wp-block-breadcrumbs,
.wp-block-woocommerce-breadcrumbs {
	text-align: left !important;
	justify-content: flex-start !important;
}

/* Footer logo (white knockout for the dark footer) -------------------- */
.homestead-footer-logo img { max-width: 200px; height: auto; }

/* Shop / category: filter sidebar + results ---------------------------- */
.homestead-shop-layout .homestead-filters {
	border: 1px solid #e5e7eb;
	border-radius: 6px;
	padding: 1.25rem;
	align-self: flex-start;
	background: #fff;
}
.homestead-shop-layout .homestead-filters h2 {
	border-bottom: 2px solid var(--wp--preset--color--gold);
	padding-bottom: 0.5rem;
}
.homestead-shop-layout .ssfilterwrapper,
.homestead-shop-layout .ssf-widget { margin-bottom: 1rem; }
@media (max-width: 781px) {
	/* Stack filters above products on mobile */
	.homestead-shop-layout { flex-wrap: wrap; }
	.homestead-shop-layout .homestead-filters { flex-basis: 100% !important; }
}
