/*
Theme Name: Zibu Tech
Theme URI: https://zibutech.co.za
Author: Zibu Tech (Pty) Ltd
Description: Custom theme for Zibu Tech — agency, tech store and design studio. Dark obsidian design with WooCommerce store, service pages with quote pop-ups, and a one-click setup under Appearance → Zibu Tech setup.
Version: 1.1.0
Requires at least: 6.3
Requires PHP: 7.4
Text Domain: zibutech
WC requires at least: 8.0
*/

:root { --zb-bg: #07080B; --zb-surface: #0D0F14; --zb-line: #1C1F29; --zb-line2: #2A2F3C; --zb-text: #F2F4F8; --zb-soft: #C9CEDA; --zb-muted: #9AA1B2; --zb-blue: #1C61E7; --zb-blue-l: #6E9BFF; }
html { background: var(--zb-bg); }
body { margin: 0; background: var(--zb-bg); color: var(--zb-text); font-family: Inter, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
*, *::before, *::after { box-sizing: border-box; }
a { color: var(--zb-text); text-decoration: none; }
a:hover { color: #fff; }
img { max-width: 100%; height: auto; }
:focus-visible { outline: 2px solid var(--zb-blue-l); outline-offset: 2px; }
.admin-bar .zb-pre { top: 32px; }

/* Shell for WooCommerce + plain pages */
.zb-shell { font-family: Inter, system-ui, sans-serif; color: var(--zb-text); background: var(--zb-bg); min-height: 100vh; display: flex; flex-direction: column; }
.zb-main { flex: 1; }
.zb-mono { font-family: 'JetBrains Mono', monospace; font-size: 12px; letter-spacing: 1.2px; color: var(--zb-blue-l); margin: 0 0 14px; }
.zb-page { max-width: 1100px; margin: 0 auto; padding: 72px 32px 100px; }
.zb-page--wc { max-width: 1360px; }
.zb-page__title { margin: 0 0 32px; font-family: 'Inter Tight', sans-serif; font-weight: 800; font-size: clamp(40px, 5vw, 72px); line-height: .95; letter-spacing: -.04em; }
.zb-content { font-size: 17px; line-height: 1.7; color: var(--zb-soft); }
.zb-content a { color: var(--zb-blue-l); text-decoration: underline; }
.zb-btn { display: inline-flex; min-height: 52px; align-items: center; padding: 0 26px; border-radius: 999px; background: #fff; color: #07080B !important; font-weight: 600; }
.zb-btn--ghost { background: transparent; color: var(--zb-text) !important; border: 1px solid #343947; }
.zb-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* Shop section inside the Store design */
.zb-shop { padding: 32px 32px 100px; font-family: Inter, system-ui, sans-serif; }
.zb-shop__inner { max-width: 1360px; margin: 0 auto; }
.zb-tools { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; margin-bottom: 18px; padding: 14px; background: var(--zb-surface); border: 1px solid var(--zb-line); border-radius: 18px; }
.zb-tools-h { margin: 0 auto 10px 6px; flex: 1 1 200px; font-family: 'Inter Tight', sans-serif; font-weight: 700; font-size: 20px; letter-spacing: -.01em; }
.zb-tools-h span { color: #7C8496; font-weight: 500; }
.zb-dd { flex: 1 1 190px; min-width: 0; display: flex; flex-direction: column; gap: 4px; margin: 0; }
.zb-dd > span { font-family: 'JetBrains Mono', monospace; font-size: 10px; letter-spacing: 1.2px; color: #7C8496; padding-left: 4px; }
.zb-dd select, .zb-dd .woocommerce-ordering select { height: 46px !important; width: 100%; border-radius: 12px; border: 1px solid var(--zb-line2); background-color: var(--zb-bg); color: var(--zb-text); padding: 0 36px 0 14px; font: inherit; font-size: 15px; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%239AA1B2' stroke-width='1.8'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; cursor: pointer; }
.zb-dd .woocommerce-ordering { margin: 0 !important; float: none !important; }
.zb-tools-clear { height: 46px; display: inline-flex; align-items: center; padding: 0 16px; border-radius: 12px; border: 1px solid #343947; font-size: 14px; }
.zb-shop__side { position: sticky; top: 24px; align-self: start; }
.zb-shop__side .zb-mono { color: #7C8496; margin-top: 8px; }
.zb-filter { list-style: none; margin: 0 0 28px; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.zb-filter a { display: flex; justify-content: space-between; align-items: center; min-height: 40px; padding: 0 12px; border-radius: 10px; color: var(--zb-soft); font-size: 15px; }
.zb-filter a span { font-family: 'JetBrains Mono', monospace; font-size: 12px; color: #7C8496; }
.zb-filter a:hover { background: var(--zb-surface); }
.zb-filter a.is-on { background: #fff; color: #07080B; }
.zb-filter a.is-on span { color: #4B5160; }
.zb-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.zb-chips a { min-height: 36px; padding: 0 12px; display: inline-flex; align-items: center; border-radius: 999px; border: 1px solid var(--zb-line2); color: var(--zb-soft); font-size: 13px; }
.zb-chips a.is-on, .zb-chips a:hover { background: #fff; border-color: #fff; color: #07080B; }
.zb-help { padding: 18px; border-radius: 16px; background: var(--zb-surface); border: 1px solid var(--zb-line); font-size: 14px; line-height: 1.5; color: var(--zb-soft); }
.zb-help p { margin: 0 0 10px; }
.zb-help a { color: var(--zb-blue-l); font-weight: 600; }
.zb-shop__bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 24px; }
.zb-shop__bar h2 { margin: 0; font-family: 'Inter Tight', sans-serif; font-weight: 800; font-size: 36px; letter-spacing: -.03em; }
.zb-shop__bar p { margin: 6px 0 0; color: var(--zb-muted); font-size: 14px; }
.zb-shop .woocommerce-ordering { margin: 0; }
.zb-shop .woocommerce-ordering select, .zb-shell select { height: 44px; border-radius: 12px; border: 1px solid var(--zb-line2); background: var(--zb-bg); color: var(--zb-text); padding: 0 12px; font: inherit; font-size: 14px; }
.zb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.zb-card { padding: 12px 12px 18px; border-radius: 22px; background: var(--zb-surface); border: 1px solid var(--zb-line); display: flex; flex-direction: column; transition: border-color .2s; }
.zb-card:hover { border-color: #343947; }
.zb-card__img { position: relative; aspect-ratio: 1 / 1; border-radius: 16px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.zb-card__img img { width: 86%; height: 86%; object-fit: contain; }
.zb-card__badge { position: absolute; left: 10px; top: 10px; padding: 4px 9px; border-radius: 999px; background: rgba(7,8,11,.8); color: #fff; font-family: 'JetBrains Mono', monospace; font-size: 11px; letter-spacing: 1px; }
.zb-card__label { margin: 16px 6px 0; font-family: 'JetBrains Mono', monospace; font-size: 11px; letter-spacing: 1px; color: var(--zb-blue-l); text-transform: uppercase; }
.zb-card__name { margin: 8px 6px 0; font-size: 16px; font-weight: 600; line-height: 1.35; }
.zb-card__stock { margin: 8px 6px 0; font-size: 13px; color: #4ADE80; }
.zb-card__foot { margin: auto 6px 0; padding-top: 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.zb-card__price { font-family: 'Inter Tight', sans-serif; font-weight: 800; font-size: 20px; }
.zb-card__price del { opacity: .5; font-size: 14px; font-weight: 500; margin-right: 6px; }
.zb-card__price ins { text-decoration: none; }
.zb-card__add, .zb-shop a.button.zb-card__add { width: 44px; height: 44px; min-height: 0; padding: 0 !important; border-radius: 999px !important; background: #fff !important; color: #07080B !important; display: inline-flex !important; align-items: center; justify-content: center; font-size: 22px !important; font-weight: 600; line-height: 1; border: 0; }
.zb-card__add.loading { opacity: .5; }
.zb-card__add.added { background: var(--zb-blue) !important; color: #fff !important; }
.zb-card .added_to_cart, .zb-card a.added_to_cart.wc-forward { display: none !important; }
.zb-card__add::after, .zb-card__add.added::after, .zb-card__add.loading::after { display: none !important; content: none !important; }
.zb-card__add.added { font-size: 0 !important; }
.zb-card__add.added::before { content: '✓'; font-size: 18px; }
.zb-pages { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.zb-pages .page-numbers { min-width: 44px; height: 44px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; border: 1px solid var(--zb-line2); color: var(--zb-soft); }
.zb-pages .page-numbers.current, .zb-pages a.page-numbers:hover { background: #fff; color: #07080B; border-color: #fff; }
.zb-empty { padding: 48px; border-radius: 22px; border: 1px dashed var(--zb-line2); text-align: center; color: var(--zb-soft); }
.zb-empty a { color: var(--zb-blue-l); font-weight: 600; }

/* Single product */
.zb-product { max-width: 1360px; margin: 0 auto; padding: 40px 32px 100px; }
.zb-crumbs { font-size: 14px; color: var(--zb-muted); margin-bottom: 28px; }
.zb-crumbs a { color: var(--zb-soft); }
.zb-product__grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 48px; align-items: start; }
.zb-product__gallery { border-radius: 24px; background: #FFFFFF; padding: 24px; }
.zb-product__gallery .woocommerce-product-gallery { width: 100% !important; float: none !important; margin: 0 !important; }
.zb-product__gallery img { border-radius: 12px; }
.zb-product__title { margin: 0; font-family: 'Inter Tight', sans-serif; font-weight: 800; font-size: clamp(32px, 3.6vw, 52px); line-height: 1.02; letter-spacing: -.03em; }
.zb-product__price { margin: 18px 0 0; font-family: 'Inter Tight', sans-serif; font-weight: 800; font-size: 32px; }
.zb-product__short { margin-top: 16px; color: var(--zb-soft); font-size: 16px; line-height: 1.6; }
.zb-product__buy { margin-top: 24px; }
.zb-product__buy form.cart { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.zb-product__perks { margin: 28px 0 0; padding: 20px 22px; list-style: none; border-radius: 18px; background: var(--zb-surface); border: 1px solid var(--zb-line); display: flex; flex-direction: column; gap: 10px; font-size: 14px; color: var(--zb-soft); }
.zb-product__perks li::before { content: '✓'; color: var(--zb-blue-l); font-weight: 700; margin-right: 10px; }
.zb-product__desc { margin-top: 56px; max-width: 820px; }
.zb-product__related { margin: 72px 0 24px; font-family: 'Inter Tight', sans-serif; font-weight: 800; font-size: 32px; letter-spacing: -.03em; }

/* WooCommerce dark styling (classic + block cart/checkout) */
.zb-shell .woocommerce, .zb-shell .wc-block-components-sidebar-layout, .zb-shell .wp-block-woocommerce-cart, .zb-shell .wp-block-woocommerce-checkout { color: var(--zb-text); }
.zb-shell .quantity input.qty, .zb-shell input[type=text], .zb-shell input[type=email], .zb-shell input[type=tel], .zb-shell input[type=password], .zb-shell input[type=number], .zb-shell textarea, .zb-shell .select2-selection { min-height: 48px; border-radius: 12px; border: 1px solid var(--zb-line2) !important; background: var(--zb-bg) !important; color: var(--zb-text) !important; padding: 0 14px; font: inherit; font-size: 16px; }
.zb-shell textarea { padding: 12px 14px; }
.zb-shell .quantity input.qty { width: 80px; text-align: center; }
.zb-shell .button, .zb-shell button.button, .zb-shell .single_add_to_cart_button, .zb-shell .checkout-button, .zb-shell #place_order, .zb-shell .wc-block-components-button:not(.is-link) { min-height: 52px; padding: 0 28px !important; border-radius: 999px !important; background: #fff !important; color: #07080B !important; border: 0 !important; font-family: Inter, system-ui, sans-serif !important; font-weight: 600 !important; font-size: 16px !important; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.zb-shell .button:hover, .zb-shell .single_add_to_cart_button:hover { background: #E3EBFF !important; }
.zb-shell table.shop_table, .zb-shell .wc-block-cart-items { border: 1px solid var(--zb-line) !important; border-radius: 18px; border-collapse: separate; overflow: hidden; background: var(--zb-surface); }
.zb-shell table.shop_table th, .zb-shell table.shop_table td { border-color: var(--zb-line) !important; padding: 16px !important; }
.zb-shell .cart_totals, .zb-shell .woocommerce-checkout-review-order, .zb-shell .wc-block-components-sidebar { background: var(--zb-surface); border: 1px solid var(--zb-line); border-radius: 18px; padding: 24px; }
.zb-shell .woocommerce-message, .zb-shell .woocommerce-info, .zb-shell .woocommerce-error, .zb-shell .wc-block-components-notice-banner { background: var(--zb-surface) !important; color: var(--zb-text) !important; border: 1px solid var(--zb-line2) !important; border-left: 4px solid var(--zb-blue) !important; border-radius: 14px; padding: 16px 20px !important; list-style: none; }
.zb-shell .woocommerce-message a.button, .zb-shell .woocommerce-info a.button { min-height: 40px; float: right; }
.zb-shell .wc-block-components-text-input input, .zb-shell .wc-block-components-combobox input, .zb-shell .wc-blocks-components-select select { background: var(--zb-bg) !important; color: var(--zb-text) !important; border-color: var(--zb-line2) !important; }
.zb-shell .wc-block-components-text-input label, .zb-shell .wc-block-components-checkbox__label, .zb-shell .wc-block-components-totals-item, .zb-shell .wc-block-components-product-name { color: var(--zb-soft) !important; }
.zb-shell .woocommerce-MyAccount-navigation ul { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.zb-shell .woocommerce-MyAccount-navigation a { display: block; padding: 10px 14px; border-radius: 10px; color: var(--zb-soft); }
.zb-shell .woocommerce-MyAccount-navigation .is-active a { background: #fff; color: #07080B; }
.zb-shell a.remove { color: #FF8A8A !important; }
.zb-shell .woocommerce-product-gallery__trigger { background: #fff; border-radius: 999px; }
.zb-shell .flex-control-thumbs { display: flex; gap: 8px; margin-top: 12px !important; }
.zb-shell .flex-control-thumbs li { width: 72px !important; }

@media (max-width: 900px) {
	.zb-product__grid { grid-template-columns: 1fr; }
	.zb-tools-h { flex-basis: 100%; margin-bottom: 4px; }
	.zb-dd { flex: 1 1 calc(50% - 5px); }
	.zb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.zb-card { padding: 8px 8px 14px; border-radius: 18px; }
	.zb-card__name { font-size: 14px; }
	.zb-card__price { font-size: 16px; }
	.zb-card__add, .zb-shop a.button.zb-card__add { width: 38px; height: 38px; font-size: 20px !important; }
	.zb-shop, .zb-product, .zb-page { padding-left: 20px; padding-right: 20px; }
}
