/*
Theme Name: sage classic
Description: The current sageelectronics.com look (black header, grey product bands, Poppins), rebuilt as a block theme without Elementor.
Version: 0.1.0
Requires at least: 6.5
Requires PHP: 7.4
Text Domain: sage-classic
*/

/* ---------- base ---------- */
strong, b { font-weight: 600; }
img { max-width: 100%; height: auto; }
.wp-site-blocks { padding-top: 0; padding-bottom: 0; }
.wp-site-blocks > * { margin-block-start: 0; }
:where(.site-main) { padding-block: 40px 64px; }
.site-main.is-home { padding: 0; }
.page-title { margin-bottom: 24px; }
.post-meta { color: var(--wp--preset--color--muted); font-size: 14px; }
.post-list { list-style: none; padding: 0; }
.post-list > li { padding-block: 24px; border-bottom: 1px solid #e5e5e5; }
.post-list h2 { font-size: 24px; margin: 0 0 4px; }

/* ---------- header ---------- */
.site-header { background: #000; color: #fff; padding-block: 14px; }
.site-header__bar { gap: 32px; }
.site-header__right { gap: 28px; }
.site-header__logo img { width: 100px; height: auto; }
.site-nav { font-size: 14px; font-weight: 500; text-transform: uppercase; letter-spacing: .02em; }
.site-nav a, .site-nav .wp-block-navigation-item__content { color: #fff; }
.site-nav .wp-block-navigation__container { gap: 32px; }
.site-nav .wp-block-navigation-item > a:hover { color: #9cc6f0; text-decoration: none; }
.site-nav .current-menu-item > a { box-shadow: inset 0 -3px 0 #4A92DA; padding-bottom: 8px; }
.site-nav .wp-block-navigation__submenu-container { background: #000 !important; color: #fff; border: 0 !important; padding: 8px 0; min-width: 240px !important; }
.site-nav .wp-block-navigation__submenu-container a { text-transform: none; padding: 8px 18px !important; }
.site-nav .wp-block-navigation__responsive-container.is-menu-open { background: #000; color: #fff; }
.site-header .wp-block-navigation__responsive-container-open svg,
.site-header .wp-block-navigation__responsive-container-close svg { fill: #fff; }
.wp-block-button.is-style-outline-blue .wp-block-button__link {
	background: transparent !important; color: #4A92DA !important; border: 1.5px solid #4A92DA !important;
	border-radius: 30px !important; padding: 8px 24px !important; text-transform: uppercase; font-size: 14px; font-weight: 400;
}
.wp-block-button.is-style-outline-blue .wp-block-button__link:hover { background: #4A92DA !important; color: #fff !important; text-decoration: none; }
.site-header__cart { color: #fff; }
.site-header__cart .wc-block-mini-cart__button { color: #fff; }

/* ---------- footer ---------- */
.site-footer { background: #000; color: #fff; padding-block: 18px; }
.site-footer p { margin: 0; }
.site-footer__tag { text-transform: uppercase; font-size: 14px; letter-spacing: .02em; }
.site-footer__credit { font-size: 11px; margin-top: 4px !important; }

/* ---------- home: product bands ---------- */
.sage-products.is-variant-bands { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; margin: 0; }
.sage-band { text-align: center; padding: 16px 24px 32px; background: #F6F6F6; display: flex; flex-direction: column; align-items: center; }
.sage-band:nth-child(1), .sage-band:nth-child(2) { grid-column: 1 / -1; }
.sage-band:nth-child(2) { background: #EFEFEF; }
.sage-band:nth-child(4), .sage-band:nth-child(5) { background: #E3E4E5; }
.sage-band__title { margin: 0; font-size: clamp(26px, 3vw, 36px); font-weight: 500; text-transform: uppercase; line-height: 1.15; }
.sage-band__title a { color: #000; }
.sage-band__title a:hover { text-decoration: none; }
.sage-band__sub { margin: 0; font-size: 15px; color: #000; }
.sage-band__links { display: flex; gap: 40px; justify-content: center; margin: 8px 0 16px; font-size: 14px; }
.sage-band__links a::before { content: "›"; margin-right: 6px; font-weight: 600; }
.sage-band__img { display: block; margin-top: auto; }
.sage-band__img img { max-height: 340px; width: auto; object-fit: contain; margin-inline: auto; transition: transform .35s cubic-bezier(.2,.7,.2,1); }
.sage-band:hover .sage-band__img img { transform: scale(1.03); }

/* ---------- single product ---------- */
.product-main { padding-top: 0; }
.product-bar { background: #fff; border-bottom: 1px solid #ddd; padding-block: 10px; position: sticky; top: 0; z-index: 20; }
.product-bar__inner { gap: 16px; }
.product-bar__name { gap: 14px; align-items: center; }
.product-bar__title { font-size: 15px !important; font-weight: 600; text-transform: uppercase; margin: 0; }
.product-bar__sub p { margin: 0; font-size: 13px; color: var(--wp--preset--color--muted); line-height: 1.2; max-width: 14ch; }
.product-bar__price { font-size: 14px; font-weight: 600; color: #000; }
.product-top { margin-top: 32px !important; gap: 48px; }
.product-buy { padding-top: 24px; }
.product-tax-note { font-size: 13px; color: var(--wp--preset--color--muted); text-align: right; }
.product-buy__price { font-size: 18px; font-weight: 500; color: #000; }
.product-buy .single_add_to_cart_button, .product-buy button.wp-element-button {
	background: #4A3DC9; color: #fff; border: 0; border-radius: 3px; padding: 10px 28px; font-weight: 500;
}
.product-buy .quantity input { width: 72px; padding: 8px; border: 1px solid #ccc; }
.product-buy table.variations td, .product-buy table.variations th { padding: 4px 8px 4px 0; text-align: left; }
.product-links { list-style: none; padding: 0; margin: 24px 0 0; font-size: 14px; }
.product-links li { padding: 6px 0; }
.product-links a::before { content: "›"; margin-right: 8px; font-weight: 600; }
.sage-manual { display: inline-block; margin-top: 8px; font-size: 14px; }
.sage-manual::before { content: "↓ "; }
.product-details { margin-top: 48px !important; gap: 48px; }
.section-label, .sage-field__heading {
	font-size: 18px !important; font-weight: 300; text-transform: uppercase; letter-spacing: .08em;
	color: #bbb !important; text-align: center; border-bottom: 1px solid #e5e5e5; padding-bottom: 6px; margin: 0 0 16px;
}
.product-description { font-size: 14px; color: #555; }
.product-description h5 { font-size: 15px; font-weight: 500; color: #000; text-align: left !important; margin: 0 0 8px; }
.product-description ul { padding-left: 1.2em; }
.sage-field { font-size: 14px; color: #555; margin-bottom: 32px; }
.sage-field table { width: 100%; border-collapse: collapse; }
.sage-field td { border: 1px solid #e5e5e5; padding: 8px 12px; }
.sage-field tr:nth-child(odd) td { background: #F6F6F6; }
.product-audio { margin-top: 48px !important; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; }
.product-audio .sage-field__heading { text-align: left; color: #000 !important; font-size: 24px !important; font-weight: 500; text-transform: none; letter-spacing: 0; border: 0; }
.product-audio iframe { width: 100%; min-height: 360px; border: 0; }

/* testimonial cards */
.sage-testimonials { margin-top: 56px !important; }
.sage-testimonials__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.sage-t { display: flex; gap: 16px; padding: 18px 20px; border-radius: 14px; background: #fff; box-shadow: 0 4px 18px rgba(0,0,0,.08); font-size: 13px; }
.sage-t__photo { width: 64px; height: 64px !important; border-radius: 50%; object-fit: cover; flex: none; align-self: flex-start; }
.sage-t__body { display: flex; flex-direction: column; min-width: 0; }
.sage-t__title { font-size: 16px; font-weight: 500; margin: 0; }
.sage-t__title a { color: #000; }
.sage-t__who { margin: 2px 0 8px; color: var(--wp--preset--color--muted); display: flex; flex-direction: column; line-height: 1.4; }
.sage-t__who b { font-weight: 500; color: #333; }
.sage-t__quote { margin: 0; color: #555; }
.sage-t__more { align-self: flex-end; margin-top: 8px; }
.sage-t__more::after { content: " ›"; }

/* ---------- pages without a title (products, testimonials, contact) ---------- */
.site-main.is-no-title { background: #F6F6F6; }
.page-title { text-align: center; text-transform: none !important; }
.site-nav .site-nav__contact { display: none; }
.section-heading { font-size: 18px !important; font-weight: 400; margin: 56px 0 24px !important; }

/* product icon row */
.sage-products.is-variant-icons { list-style: none; padding: 0; margin: 8px 0 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
.sage-icon { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; color: #000; font-size: 12px; font-weight: 500; text-transform: uppercase; line-height: 1.1; }
.sage-icon:hover { text-decoration: none; color: var(--wp--preset--color--link); }
.sage-icon img { width: 90px; height: 90px; object-fit: contain; transition: transform .35s cubic-bezier(.2,.7,.2,1); }
.sage-icon:hover img { transform: scale(1.06); }
.sage-icon__name { max-width: 12ch; }

/* testimonial carousel (photo cards) */
.sage-tl.is-carousel { position: relative; }
.sage-tl.is-carousel .sage-tl__list { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 40px) / 3); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 4px 2px 24px; }
.sage-tl.is-carousel .sage-tl__list::-webkit-scrollbar { display: none; }
.sage-tl.is-carousel .sage-tl__list:focus-visible { outline: 2px solid var(--wp--preset--color--link); outline-offset: 4px; }
.sage-tc { scroll-snap-align: start; display: flex; flex-direction: column; background: #fff; border-radius: 40px; overflow: hidden; box-shadow: 0 6px 18px rgba(0,0,0,.08); font-size: 14px; }
.sage-tc__top { display: flex; gap: 16px; padding: 28px 22px 0 10px; }
.sage-tc__prod { width: 70px; height: 40px !important; object-fit: contain; flex: none; }
.sage-tc__who { margin: 0 0 6px; display: flex; flex-direction: column; color: #bbb; font-size: 13px; font-weight: 500; text-transform: uppercase; line-height: 1.6; }
.sage-tc__title { font-size: 17px !important; font-weight: 400; margin: 0; }
.sage-tc__title a { color: #000; }
.sage-tc__quote { margin: 40px 22px 0; color: #707070; line-height: 1.5; }
.sage-tc__more { align-self: flex-end; margin: 6px 24px 16px; margin-top: auto; padding-top: 8px; }
.sage-tc__more::after, .sage-t__more::after { content: " ›"; font-weight: 600; }
.sage-tc__photo { display: block; width: 100%; aspect-ratio: 367 / 300; height: auto !important; object-fit: cover; }
.sage-tl__nav { position: absolute; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; background: transparent; cursor: pointer; color: #333; font-size: 0; }
.sage-tl__nav::before { content: ""; display: block; width: 12px; height: 12px; margin: auto; border: solid currentColor; border-width: 0 0 2px 2px; }
.sage-tl__nav.is-prev { left: -48px; }
.sage-tl__nav.is-prev::before { transform: rotate(45deg); }
.sage-tl__nav.is-next { right: -48px; }
.sage-tl__nav.is-next::before { transform: rotate(-135deg); }
.sage-tl__nav:hover, .sage-tl__nav:focus-visible { color: var(--wp--preset--color--link); }

/* testimonial grid (no photo) */
.sage-tl.is-grid { margin-top: 32px; }
.sage-tl.is-grid .sage-tl__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.sage-tl.is-grid .sage-t { border-radius: 40px; padding: 28px 24px; }
.sage-tl.is-grid .sage-t__title { font-size: 18px; color: #707070; }
.sage-tl.is-grid .sage-t__title a { color: #707070; }
.sage-t__photo.is-product { width: 100px; height: 100px !important; border-radius: 0; object-fit: contain; }

/* contact */
.contact-cols { gap: 48px; margin-top: 40px !important; }
.contact-info { color: #707070; }
.contact-info strong { color: #707070; }
.contact-info .wp-block-social-links { gap: 6px; }
.contact-info .wp-social-link { border-radius: 3px !important; }
.contact-info .wp-social-link a { padding: 12px; }
.sage-form label { display: block; font-size: 15px; color: #707070; }
.sage-form__req { color: #e02b27; }
.sage-form__field { margin: 0 0 10px; }
.sage-form input[type=text], .sage-form input[type=email], .sage-form textarea { width: 100%; box-sizing: border-box; padding: 16px 20px; border: 1px solid #69727d; border-radius: 3px; font: inherit; font-size: 15px; background: #fff; }
.sage-form input:focus, .sage-form textarea:focus { outline: 2px solid var(--wp--preset--color--link); outline-offset: 0; }
.sage-form button { width: 100%; padding: 12px; border: 0; border-radius: 3px; cursor: pointer; font-weight: 600; background: var(--wp--preset--color--link); color: #fff; }
.sage-form button:hover, .sage-form button:focus-visible { background: #1f5f9f; }
.sage-form__hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.sage-form__notice { padding: 12px 16px; border-radius: 3px; margin: 0 0 16px; }
.sage-form__notice.is-success { background: #e6f4ea; color: #1e4620; }
.sage-form__notice.is-error { background: #fdecea; color: #611a15; }

/* sage customers */
.customer-list { font-size: 15px; color: #707070; line-height: 2; }

/* ---------- mobile ---------- */
@media (max-width: 1100px) {
	.sage-tl__nav.is-prev { left: -8px; }
	.sage-tl__nav.is-next { right: -8px; }
	.sage-tl.is-carousel .sage-tl__list { grid-auto-columns: calc((100% - 20px) / 2); }
}
@media (max-width: 781px) {
	.site-nav .site-nav__contact { display: block; }
	.sage-products.is-variant-icons { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 24px; }
	.sage-tl.is-carousel .sage-tl__list { grid-auto-columns: 85%; }
	.sage-tl__nav { display: none; }
	.sage-tl.is-grid .sage-tl__list { grid-template-columns: minmax(0, 1fr); }
	.sage-tl.is-grid .sage-t { padding: 20px; }
	.sage-t__photo.is-product { width: 64px; height: 64px !important; }
	.site-header__contact { display: none !important; }
	.sage-products.is-variant-bands { grid-template-columns: minmax(0, 1fr); }
	.sage-band { grid-column: 1 / -1; }
	.sage-band:nth-child(n) { background: #F6F6F6; }
	.sage-band:nth-child(even) { background: #EFEFEF; }
	.product-bar__sub { display: none; }
	.product-tax-note { text-align: left; }
	.product-audio, .sage-testimonials__list { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
