/* Tichy CartViper-style shop. Colours taken from the old CartViper site. */
:root {
	--tichy-maroon: #864343;
	--tichy-maroon-dark: #642c2c;
	--tichy-maroon-btn: #6e3636;
	--tichy-red: #ff0000;
	--tichy-panel: #ececec;
	--tichy-text: #333;
	--tichy-line: #cfcfcf;
}

/* ---------- layout ---------- */
.tichy-layout { display: flex; gap: 22px; align-items: flex-start; max-width: 1200px; margin: 20px auto; padding: 0 16px; font-family: Verdana, Arial, Helvetica, sans-serif; color: var(--tichy-text); font-size: 13px; }
.tichy-side { flex: 0 0 230px; }
.tichy-main { flex: 1 1 auto; min-width: 0; }
.tichy-bar { background: linear-gradient(#444, #000); color: #fff; font-size: 17px; padding: 8px 12px; border-radius: 6px 6px 0 0; }
.tichy-bar--side { border-radius: 6px 6px 0 0; }
.tichy-panel { background: var(--tichy-panel); padding: 14px 18px 20px; border: 1px solid var(--tichy-line); border-top: 0; }
.tichy-box { margin-bottom: 18px; }
.tichy-box-body { background: linear-gradient(#fff, #e4e4e4); border: 1px solid var(--tichy-line); border-top: 0; padding: 10px; border-radius: 0 0 6px 6px; }
.tichy-location { margin: 0 0 12px; }
.tichy-location a { color: var(--tichy-maroon); }

/* ---------- catalog menu ---------- */
.tichy-menu, .tichy-sub { list-style: none; margin: 0; padding: 0; }
.tichy-menu > li > a { display: block; font-weight: bold; padding: 5px 8px; border: 1px solid #ccc; background: #fff; color: #222; text-decoration: none; }
.tichy-sub { margin: 6px 0 0 14px; }
.tichy-sub li { margin-bottom: 5px; }
.tichy-sub a { display: block; padding: 6px 8px; background: #e2e2e2; border: 1px solid #cfcfcf; color: #222; font-size: 12px; text-decoration: none; }
.tichy-sub a:hover, .tichy-menu a.is-current { background: var(--tichy-maroon); color: #fff; border-color: var(--tichy-maroon-dark); }
.tichy-sub .tichy-sub { margin-left: 10px; }
.tichy-compare-link { color: var(--tichy-maroon); font-weight: bold; }

/* ---------- toolbar ---------- */
.tichy-toolbar { display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; margin-bottom: 8px; padding-bottom: 10px; border-bottom: 1px solid var(--tichy-line); }
.tichy-search { display: flex; gap: 8px; align-items: center; flex: 1 1 320px; margin: 0; }
.tichy-search input[type=search] { flex: 1; min-width: 0; padding: 5px 8px; border: 1px solid #999; background: #fff; }
.tichy-sort-label { font-size: 12px; margin-left: auto; }
.woocommerce-ordering { margin: 0 !important; float: none !important; }
.woocommerce-ordering select { padding: 4px; border: 1px solid #999; background: #fff; font-size: 12px; }

/* ---------- product grid ---------- */
.tichy-main ul.products { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px 26px; margin: 18px 0; padding: 0; list-style: none; }
/* WooCommerce's clearfix pseudo-elements would otherwise take up grid cells (empty first slot) */
.tichy-main ul.products::before, .tichy-main ul.products::after,
.woocommerce .tichy-main ul.products::before, .woocommerce .tichy-main ul.products::after { content: none !important; display: none !important; }
.tichy-main ul.products li.product { width: auto !important; margin: 0 !important; float: none !important; padding: 0 0 14px; border-bottom: 1px dotted #bbb; text-align: left; background: transparent; }
.tichy-name { margin: 0 0 8px; font-size: 14px; line-height: 1.3; text-transform: uppercase; font-weight: bold; }
.tichy-name a { color: var(--tichy-maroon); text-decoration: none; }
.tichy-thumb { display: flex; align-items: center; justify-content: center; height: 170px; overflow: hidden; background: #fff; text-align: center; margin-bottom: 8px; }
.tichy-main ul.products li.product .tichy-thumb img { width: auto !important; max-width: 100% !important; height: auto !important; max-height: 100% !important; object-fit: contain; display: block; margin: 0 auto; }
.tichy-main ul.products li.product { display: flex; flex-direction: column; }
.tichy-main ul.products li.product .tichy-cart { margin-top: auto; }
.tichy-field { margin: 4px 0; }
.tichy-price, .tichy-price .amount, .tichy-price bdi { color: var(--tichy-red); font-size: 15px; margin: 8px 0; }
.tichy-price del, .tichy-price del .amount { color: #777; font-size: 12px; }
.tichy-price ins { text-decoration: none; }
.tichy-more, .tichy-main a.tichy-cmp-toggle, .tichy-single-meta a { color: #333; text-decoration: underline; }
.tichy-cmp-toggle.is-on { color: var(--tichy-maroon) !important; font-weight: bold; }
.tichy-cart { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
.tichy-cart input[type=number], .woocommerce div.product form.cart .qty { width: 54px; padding: 4px; border: 1px solid #999; background: #fff; }
.tichy-btn, .woocommerce div.product form.cart .single_add_to_cart_button { display: inline-block; background: linear-gradient(var(--tichy-maroon), var(--tichy-maroon-dark)) !important; color: #fff !important; border: 1px solid #4b1f1f !important; border-radius: 4px !important; padding: 7px 14px !important; font-family: Verdana, Arial, sans-serif; font-size: 12px !important; cursor: pointer; text-decoration: none; line-height: 1.2; }
.tichy-btn:hover, .woocommerce div.product form.cart .single_add_to_cart_button:hover { background: var(--tichy-maroon-btn) !important; }
.tichy-btn--light { background: linear-gradient(#fff, #ddd) !important; color: #222 !important; border-color: #aaa !important; }
.tichy-oos { color: #a00; font-weight: bold; }
.tichy-summary { margin: 4px 0; }
.tichy-stars .star-rating { margin: 0; }
.star-rating span::before { color: #f5b301; }

/* pagination */
.tichy-main .woocommerce-pagination { margin: 14px 0; }
.tichy-main .woocommerce-pagination ul { display: flex; flex-wrap: wrap; gap: 4px; list-style: none; padding: 0; border: 0; }
.tichy-main .woocommerce-pagination li { border: 0; }
.tichy-main .woocommerce-pagination a, .tichy-main .woocommerce-pagination span { display: block; padding: 5px 10px; background: #fff; border: 1px solid #aaa; color: #333; text-decoration: none; }
.tichy-main .woocommerce-pagination .current { background: var(--tichy-maroon); color: #fff; border-color: var(--tichy-maroon-dark); }

/* ---------- single product ---------- */
.tichy-main div.product { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
.tichy-main div.product .woocommerce-product-gallery { width: 100% !important; float: none !important; margin: 0; background: #fff; }
.tichy-main div.product .summary { width: 100% !important; float: none !important; margin: 0; }
.tichy-main div.product .woocommerce-tabs { grid-column: 1 / -1; }
.tichy-main div.product .product_title { color: var(--tichy-maroon); text-transform: uppercase; font-size: 20px; margin: 0 0 12px; }
/* Gallery: show every image in full. The slider otherwise locks its height to the first (shortest) image. */
.tichy-main div.product .flex-viewport { height: auto !important; }
.tichy-main div.product .woocommerce-product-gallery__image { display: flex !important; align-items: center; justify-content: center; min-height: 320px; background: #fff; }
.tichy-main div.product .woocommerce-product-gallery__image a { display: flex; align-items: center; justify-content: center; width: 100%; }
.tichy-main div.product .woocommerce-product-gallery__image img:not(.zoomImg) { width: auto !important; max-width: 100% !important; height: auto !important; max-height: 460px; object-fit: contain; margin: 0 auto; }
.tichy-main div.product .flex-control-thumbs { display: grid !important; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 10px 0 0 !important; padding: 0; list-style: none; overflow: visible !important; height: auto !important; }
.tichy-main div.product .flex-control-thumbs li { width: auto !important; float: none !important; margin: 0 !important; background: #fff; border: 1px solid var(--tichy-line); }
.tichy-main div.product .flex-control-thumbs img { width: 100% !important; height: 80px !important; object-fit: contain; opacity: .6; cursor: pointer; }
.tichy-main div.product .flex-control-thumbs img.flex-active, .tichy-main div.product .flex-control-thumbs img:hover { opacity: 1; }
.tichy-single-meta p { margin: 4px 0; }
.tichy-single-desc { margin: 12px 0; }
.tichy-main div.product p.price, .tichy-main div.product .price .amount { color: var(--tichy-red); font-size: 18px; }
.tichy-label { color: var(--tichy-maroon); }
.tichy-avg { display: flex; gap: 6px; align-items: center; margin: 8px 0; }
.tichy-main div.product form.cart { display: flex; gap: 8px; align-items: center; margin: 12px 0; }
.tichy-main .woocommerce-tabs ul.tabs { padding: 0; margin: 0 0 0 0; list-style: none; display: flex; }
.tichy-main .woocommerce-tabs ul.tabs::before { display: none; }
.tichy-main .woocommerce-tabs ul.tabs li { background: #fff; border: 1px solid var(--tichy-line); border-bottom: 0; padding: 8px 14px; margin: 0; border-radius: 0; }
.tichy-main .woocommerce-tabs ul.tabs li a { color: #000; text-decoration: none; }
.tichy-main .woocommerce-tabs .panel { background: #fff; border: 1px solid var(--tichy-line); padding: 14px 18px; margin: 0; }

/* ---------- compare ---------- */
.tichy-compare-scroll { overflow-x: auto; }
.tichy-compare-table { width: 100%; border-collapse: collapse; background: #fff; font-size: 13px; }
.tichy-compare-table th, .tichy-compare-table td { border: 1px solid var(--tichy-line); padding: 8px 10px; vertical-align: top; text-align: left; min-width: 150px; }
.tichy-compare-table th { background: var(--tichy-maroon); color: #fff; width: 120px; min-width: 100px; }
.tichy-compare-table img { max-width: 140px; height: auto; }
.tichy-compare-page { font-family: Verdana, Arial, sans-serif; max-width: 1200px; margin: 20px auto; padding: 0 16px; }
#tichy-cmp-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 9999; display: flex; gap: 14px; justify-content: center; align-items: center; padding: 10px 14px; background: #222; color: #fff; font-family: Verdana, Arial, sans-serif; font-size: 13px; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
	.tichy-layout { flex-direction: column; align-items: stretch; }
	.tichy-side { flex: none; width: 100%; }
	.tichy-main ul.products { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
	.tichy-main ul.products { grid-template-columns: 1fr; }
	.tichy-main div.product { grid-template-columns: 1fr; }
	.tichy-sort-label { margin-left: 0; }
}
