/*
 Theme Name:   Woodmart Child
 Description:  Woodmart Child Theme
 Author:       XTemos
 Author URI:   http://xtemos.com
 Template:     woodmart
 Version:      1.0.0
 Text Domain:  woodmart
*/

/* ==========================================================================
   G. Ioannou catalog: variable-product spec table
   (replaces WooCommerce's size dropdown + Add to Cart on variable products)
   Brand tokens from the active Novamira design (g-ioannou-industrial-navy)
   ========================================================================== */

.gi-spec-table-wrap {
	margin: 24px 0;
	background: #FFFFFF;
	padding: 0;
}

.gi-spec-table-code {
	margin: 0 0 12px;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 13px;
	color: #737980;
}

.gi-spec-table-code strong {
	color: #1A1D21;
}

.gi-spec-table-scroll {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
}

.gi-spec-table {
	width: 100%;
	border-collapse: collapse;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 13px;
}

.gi-spec-table thead th {
	background: #1F4E79;
	color: #FFFFFF;
	font-weight: 600;
	text-align: left;
	letter-spacing: 0.02em;
	padding: 10px 14px;
	white-space: nowrap;
}

.gi-spec-table .gi-spec-table-unit {
	font-weight: 400;
	opacity: 0.75;
	font-size: 11px;
}

.gi-spec-table tbody td {
	padding: 8px 14px;
	color: #1A1D21;
	border-bottom: 1px solid #E4E4E0;
	white-space: nowrap;
}

.gi-spec-table tbody tr:last-child td {
	border-bottom: none;
}

.gi-spec-table tbody tr:hover td {
	background: rgba(31, 78, 121, 0.05);
}

.gi-spec-table td.gi-spec-table-size {
	font-weight: 600;
	color: #1F4E79;
}

.gi-spec-table-note {
	margin: 12px 0 0;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 12px;
	color: #737980;
}

/* Mega menu: Our Products dropdown */
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu {
	border-top: 3px solid #1F4E79;
	box-shadow: 0 12px 28px rgba(26, 29, 33, 0.08);

	/* Never let the panel exceed the viewport width, however many columns
	   it ends up with (extra columns wrap to a new row — wd-grid-f-inline
	   already has flex-wrap: wrap). */
	max-width: calc(100vw - 40px);
}

/* Size the panel to fit exactly how many category columns it has.
   "max-content" is unreliable here — in this nested flex layout the
   browser under-measures it and the last column's border overflows the
   box — so the width is computed explicitly instead:
   n columns × 200px basis + (n-1) × 20px gap + 64px (32px padding each side). */
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu:has(.wd-grid-f-inline > li.wd-col:nth-child(1):last-child) {
	--wd-dropdown-width: 264px;
}
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu:has(.wd-grid-f-inline > li.wd-col:nth-child(2):last-child) {
	--wd-dropdown-width: 484px;
}
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu:has(.wd-grid-f-inline > li.wd-col:nth-child(3):last-child) {
	--wd-dropdown-width: 704px;
}
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu:has(.wd-grid-f-inline > li.wd-col:nth-child(4):last-child) {
	--wd-dropdown-width: 924px;
}
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu:has(.wd-grid-f-inline > li.wd-col:nth-child(5):last-child) {
	--wd-dropdown-width: 1144px;
}
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu:has(.wd-grid-f-inline > li.wd-col:nth-child(6):last-child) {
	--wd-dropdown-width: 1364px;
}
#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu:has(.wd-grid-f-inline > li.wd-col:nth-child(7)) {
	--wd-dropdown-width: 1500px;
}

#menu-item-2847.menu-mega-dropdown > .wd-dropdown-menu > .container {
	max-width: 100%;
}

#menu-item-2847 .wd-sub-menu.wd-grid-f-inline {
	max-width: 100%;
}

#menu-item-2847 .wd-sub-menu.wd-grid-f-inline > li.wd-col {
	border-right: 1px solid #E4E4E0;
}

#menu-item-2847 .wd-sub-menu.wd-grid-f-inline > li.wd-col:last-child {
	border-right: none;
}

#menu-item-2847 .wd-sub-menu.wd-grid-f-inline > li.wd-col > a.woodmart-nav-link {
	font-family: Arial, Helvetica, sans-serif;
	font-weight: 700;
	font-size: 13px;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: #1F4E79;
	padding-bottom: 12px;
	margin-bottom: 10px;
	border-bottom: 1px solid #E4E4E0;
	display: block;
}

#menu-item-2847 .sub-sub-menu > li > a.woodmart-nav-link {
	font-family: Arial, Helvetica, sans-serif;
	font-weight: 400;
	font-size: 13px;
	color: #4A4F54;
	padding: 7px 0;
	display: block;
	transition: color 0.12s ease;
}

#menu-item-2847 .sub-sub-menu > li > a.woodmart-nav-link:hover {
	color: #1F4E79;
}

/* Spec table: shape badge + "other shapes in this series" navigator */
.gi-spec-table-code {
	display: flex;
	flex-wrap: wrap;
	gap: 4px 20px;
	align-items: center;
}

.gi-spec-table-shape a {
	color: #1F4E79;
	font-weight: 600;
	text-decoration: none;
	border-bottom: 1px solid #1F4E79;
}

.gi-spec-table-shape a:hover {
	color: #163b5c;
}

.gi-shape-nav {
	margin: 20px 0 0;
	padding-top: 16px;
	padding-bottom: 24px;
	border-top: 1px solid #E4E4E0;
}

.gi-shape-nav-label {
	margin: 0 0 10px;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #737980;
}

.gi-shape-nav-list {
	margin: 0;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 14px;
	color: #1A1D21;
	line-height: 1.8;
}

.gi-shape-link {
	color: #1A1D21;
	text-decoration: none;
	border-bottom: 1px solid #C7CBCF;
}

.gi-shape-link:hover {
	color: #1F4E79;
	border-color: #1F4E79;
}

.gi-shape-link-current {
	color: #1F4E79;
	font-weight: 700;
	border-color: #1F4E79;
}

/* [gi_series_products] shortcode: uses WoodMart's own native product-loop
   card markup (wc_get_template_part('content','product')), so no custom
   card styling is needed here — it inherits the shop grid's look exactly. */
.gi-series-products {
	margin: 20px 0 0;
	padding-top: 16px;
	border-top: 1px solid #E4E4E0;
	position: relative;
}

.gi-series-products.gi-loading .gi-series-products-grid {
	opacity: 0.4;
	pointer-events: none;
	transition: opacity 0.15s ease;
}

.gi-series-pagination-numbers {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	justify-content: center;
	margin: 24px 0 0;
}

.gi-series-page-link {
	min-width: 34px;
	height: 34px;
	padding: 0 8px;
	border: 1px solid #E4E4E0;
	background: #FFFFFF;
	color: #1A1D21;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 13px;
	cursor: pointer;
	border-radius: 3px;
	transition: border-color 0.12s ease, color 0.12s ease, background 0.12s ease;
}

.gi-series-page-link:hover {
	border-color: #1F4E79;
	color: #1F4E79;
}

.gi-series-page-current {
	background: #1F4E79;
	border-color: #1F4E79;
	color: #FFFFFF;
	font-weight: 600;
	cursor: default;
}


/* [gi_parent_categories] shortcode -- responsive top-level category grid */
.gi-parent-categories {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	gap: 24px;
	margin: 24px 0;
}

.gi-parent-cat-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	text-decoration: none;
	color: #1A1D21;
}

.gi-parent-cat-thumb {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	margin-bottom: 16px;
}

.gi-parent-cat-thumb img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	display: block;
}

.gi-parent-cat-name {
	font-family: Arial, Helvetica, sans-serif;
	font-weight: 700;
	font-size: 16px;
	line-height: 1.3;
	color: #1A1D21;
	margin-bottom: 6px;
	transition: color 0.15s ease;
}

.gi-parent-cat-card:hover .gi-parent-cat-name {
	color: #1F4E79;
}

.gi-parent-cat-count {
	font-family: Arial, Helvetica, sans-serif;
	font-size: 13px;
	color: #737980;
}

@media (max-width: 1024px) {
	.gi-parent-categories {
		grid-template-columns: repeat(3, 1fr);
		gap: 16px;
	}
}

@media (max-width: 600px) {
	.gi-parent-categories {
		grid-template-columns: repeat(2, 1fr);
		gap: 12px;
	}

	.gi-parent-cat-name {
		font-size: 14px;
	}
}
