/*
Theme Name: Thai Huy Electric
Theme URI: https://thaihuyelectric.com
Author: Thai Huy Electric
Description: Theme bán hàng thiết bị điện, điện mặt trời, đèn năng lượng mặt trời và thi công màn hình LED. Tương thích WooCommerce.
Version: 1.0.0
Requires at least: 6.4
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: thaihuy
*/

:root {
	--th-navy: #0b2545;
	--th-navy-2: #13315c;
	--th-blue: #1d5fd1;
	--th-amber: #f5b700;
	--th-amber-dark: #d99a00;
	--th-ink: #1b2430;
	--th-muted: #5b6676;
	--th-line: #e3e8ef;
	--th-soft: #f4f7fb;
	--th-radius: 14px;
	--th-shadow: 0 6px 24px rgba(11, 37, 69, .08);
}

body { background: #fff; color: var(--th-ink); }
a { color: var(--th-blue); }
img { max-width: 100%; height: auto; }

/* ---------- Top bar & header ---------- */
.th-topbar { background: var(--th-navy); color: #cfd8e6; font-size: 14px; padding: 8px 16px !important; }
.th-topbar p { margin: 0; text-align: center; }
.th-topbar a { color: var(--th-amber); text-decoration: none; font-weight: 600; }

.th-header { background: #fff; border-bottom: 1px solid var(--th-line); position: sticky; top: 0; z-index: 50; padding: 12px 16px !important; }
.admin-bar .th-header { top: 32px; }
.th-header-inner { max-width: 1240px; margin: 0 auto !important; gap: 20px; }
.th-logo { margin: 0; font-weight: 800; font-size: 22px; letter-spacing: -.3px; line-height: 1; white-space: nowrap; }
.th-logo a { color: var(--th-navy); text-decoration: none; }
.th-logo span { color: var(--th-amber-dark); }
.th-nav { font-weight: 600; font-size: 15px; }
.th-nav a { color: var(--th-ink); text-decoration: none; }
.th-nav a:hover { color: var(--th-blue); }
.th-header-actions { gap: 6px; }

/* ---------- Generic sections ---------- */
.th-section { padding: 72px 16px !important; }
.th-section.is-soft { background: var(--th-soft); }
.th-section-head { text-align: center; max-width: 720px; margin: 0 auto 36px !important; }
.th-section-head h2 { font-size: clamp(26px, 3.2vw, 36px); margin: 0 0 10px; color: var(--th-navy); }
.th-section-head p { color: var(--th-muted); margin: 0; }
.th-eyebrow { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--th-amber-dark); margin: 0 0 12px; }

/* ---------- Buttons ---------- */
.wp-block-button.th-btn-primary .wp-block-button__link { background: var(--th-amber); color: var(--th-navy); font-weight: 700; border-radius: 999px; padding: 14px 28px; }
.wp-block-button.th-btn-primary .wp-block-button__link:hover { background: var(--th-amber-dark); }
.wp-block-button.th-btn-ghost .wp-block-button__link { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.6); font-weight: 700; border-radius: 999px; padding: 12px 26px; }
.wp-block-button.th-btn-ghost .wp-block-button__link:hover { border-color: #fff; background: rgba(255,255,255,.08); }
.wp-block-button.th-btn-dark .wp-block-button__link { background: var(--th-navy); color: #fff; font-weight: 700; border-radius: 999px; padding: 14px 28px; }

/* ---------- Hero ---------- */
.th-hero { background: radial-gradient(1200px 500px at 85% 20%, rgba(245,183,0,.22), transparent 60%), linear-gradient(135deg, var(--th-navy) 0%, var(--th-navy-2) 60%, #1a4480 100%); color: #fff; padding: 80px 16px 90px !important; overflow: hidden; }
.th-hero h1 { color: #fff; font-size: clamp(32px, 5vw, 54px); line-height: 1.12; margin: 0 0 18px; letter-spacing: -.5px; }
.th-hero .th-lead { color: #d6e0ee; font-size: 18px; max-width: 560px; }
.th-hero-cols { max-width: 1240px; margin: 0 auto !important; align-items: center !important; gap: 40px; }
.th-hero-art svg { width: 100%; height: auto; display: block; }
.th-badges { margin-top: 28px !important; gap: 10px 22px; }
.th-badges p { margin: 0; color: #e8eef7; font-size: 15px; font-weight: 600; }
.th-badges p::before { content: "✓"; color: var(--th-amber); margin-right: 8px; font-weight: 800; }

/* ---------- Cards ---------- */
.th-grid { max-width: 1240px; margin: 0 auto !important; gap: 22px !important; }
.th-card { background: #fff; border: 1px solid var(--th-line); border-radius: var(--th-radius); padding: 26px !important; height: 100%; box-shadow: var(--th-shadow); transition: transform .2s, box-shadow .2s; }
.th-card:hover { transform: translateY(-4px); box-shadow: 0 14px 34px rgba(11,37,69,.14); }
.th-card h3 { font-size: 20px; margin: 14px 0 8px; color: var(--th-navy); }
.th-card h3 a { color: inherit; text-decoration: none; }
.th-card p { color: var(--th-muted); font-size: 15px; margin: 0 0 10px; }
.th-card .th-more a { font-weight: 700; color: var(--th-blue); text-decoration: none; }
.th-icon { width: 56px; height: 56px; border-radius: 14px; display: grid; place-items: center; background: #fff6d6; }
.th-icon svg { width: 30px; height: 30px; }
.th-card.is-dark { background: var(--th-navy); border-color: var(--th-navy); }
.th-card.is-dark h3 { color: #fff; }
.th-card.is-dark p { color: #c6d2e3; }
.th-card.is-dark .th-icon { background: rgba(245,183,0,.15); }

/* ---------- LED service band ---------- */
.th-led { background: #0a1a30; color: #fff; }
.th-led .th-section-head h2 { color: #fff; }
.th-led .th-section-head p { color: #b6c3d6; }

/* ---------- Steps ---------- */
.th-step { text-align: center; }
.th-step-num { width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 50%; background: var(--th-amber); color: var(--th-navy); display: grid; place-items: center; font-weight: 800; font-size: 20px; }
.th-step h3 { font-size: 18px; color: var(--th-navy); margin: 0 0 6px; }
.th-step p { color: var(--th-muted); font-size: 15px; margin: 0; }

/* ---------- Products (WooCommerce shortcode lists) ---------- */
.th-products { max-width: 1240px; margin: 0 auto !important; }
.th-products-head { max-width: 1240px; margin: 0 auto 18px !important; align-items: flex-end; }
.th-products-head h2 { margin: 0; color: var(--th-navy); font-size: clamp(22px, 2.6vw, 30px); }
.th-products-head p { margin: 0; }
.th-products-head a { font-weight: 700; text-decoration: none; }
.woocommerce ul.products li.product, .woocommerce-page ul.products li.product {
	background: #fff; border: 1px solid var(--th-line); border-radius: var(--th-radius); padding: 14px !important; box-shadow: var(--th-shadow); text-align: left;
}
.woocommerce ul.products li.product img { border-radius: 10px; margin-bottom: 12px !important; aspect-ratio: 1 / 1; object-fit: cover; background: var(--th-soft); }
.woocommerce ul.products li.product .woocommerce-loop-product__title { font-size: 15px !important; font-weight: 600; color: var(--th-ink); min-height: 2.8em; }
.woocommerce ul.products li.product .price { color: #d0312d !important; font-weight: 800; font-size: 17px !important; }
.woocommerce ul.products li.product .button, .woocommerce a.button, .woocommerce button.button {
	background: var(--th-navy) !important; color: #fff !important; border-radius: 999px !important; font-weight: 700 !important; padding: 10px 18px !important;
}
.woocommerce ul.products li.product .button:hover, .woocommerce a.button:hover, .woocommerce button.button:hover { background: var(--th-blue) !important; }
.woocommerce span.onsale { background: #d0312d; border-radius: 999px; min-height: auto; min-width: auto; padding: 4px 10px; line-height: 1.4; }

/* ---------- Contact CTA ---------- */
.th-cta { background: linear-gradient(120deg, var(--th-amber) 0%, #ffd34d 100%); padding: 64px 16px !important; }
.th-cta-inner { max-width: 1240px; margin: 0 auto !important; gap: 32px; align-items: center !important; }
.th-cta h2 { color: var(--th-navy); font-size: clamp(26px, 3.4vw, 38px); margin: 0 0 10px; }
.th-cta p { color: #3b2f00; margin: 0 0 6px; font-size: 17px; }
.th-cta a:not(.wp-block-button__link) { color: var(--th-navy); font-weight: 700; }

/* ---------- Footer ---------- */
.th-footer { background: var(--th-navy); color: #b9c6d8; padding: 56px 16px 24px !important; font-size: 15px; }
.th-footer h3 { color: #fff; font-size: 17px; margin: 0 0 14px; }
.th-footer a { color: #e6edf7; text-decoration: none; }
.th-footer a:hover { color: var(--th-amber); }
.th-footer ul { list-style: none; padding: 0; margin: 0; }
.th-footer li { margin-bottom: 8px; }
.th-footer .th-logo a { color: #fff; }
.th-footer-cols { max-width: 1240px; margin: 0 auto !important; gap: 32px; }
.th-copy { max-width: 1240px; margin: 36px auto 0 !important; border-top: 1px solid rgba(255,255,255,.12); padding-top: 18px; font-size: 14px; text-align: center; }

/* ---------- Page / content ---------- */
.th-main { padding: 40px 16px 72px !important; }
.th-main .wp-block-post-title { color: var(--th-navy); }

/* ---------- Floating contact buttons ---------- */
.th-float { position: fixed; right: 16px; bottom: 20px; z-index: 999; display: flex; flex-direction: column; gap: 12px; }
.th-float a { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; box-shadow: 0 8px 20px rgba(0,0,0,.25); color: #fff; font-weight: 800; font-size: 13px; text-decoration: none; }
.th-float .th-float-call { background: #d0312d; animation: th-pulse 2s infinite; }
.th-float .th-float-zalo { background: #0068ff; }
.th-float svg { width: 26px; height: 26px; fill: #fff; }
@keyframes th-pulse { 0% { box-shadow: 0 0 0 0 rgba(208,49,45,.55); } 70% { box-shadow: 0 0 0 16px rgba(208,49,45,0); } 100% { box-shadow: 0 0 0 0 rgba(208,49,45,0); } }

/* ---------- Responsive ---------- */
@media (max-width: 781px) {
	.th-hero { padding: 48px 16px 56px !important; }
	.th-hero-art { display: none; }
	.th-section { padding: 52px 16px !important; }
	.th-topbar .th-hide-sm { display: none; }
	.th-logo { font-size: 19px; }
	.admin-bar .th-header { top: 0; }
}
