/*
Theme Name: Woodex Master
Theme URI: https://woodex.com.pk
Author: Woodex Interior
Author URI: https://woodex.com.pk
Description: Master (parent) theme for Woodex Interior — classic Elementor-compatible theme with a four-color cool monochrome design system, PHP fallback header/footer, menu registration, and a design-token :root block reused by every template. Use the Woodex Child theme for site-specific overrides.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: woodex-master
*/

/* ============================================================
   WOODEX MASTER — DESIGN TOKENS
   Four-color cool monochrome system.
   Mirror these into Elementor → Site Settings → Global Colors
   so every widget can reference them by name.
   ============================================================ */
:root {
	--woodex-black: #111111;      /* primary text, nav, dark sections, footer */
	--woodex-white: #FFFFFF;      /* primary surfaces, text on black */
	--woodex-gray:  #888888;      /* muted copy, labels, CTA band, accents */
	--woodex-light: #E6E6E6;      /* page surface, borders, soft alt sections */

	--woodex-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	--woodex-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

	--woodex-radius: 4px;
	--woodex-pill: 999px;
	--woodex-max: 1320px;
}

/* ============================================================
   BASE
   ============================================================ */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: var(--woodex-sans);
	color: var(--woodex-black);
	background: var(--woodex-white);
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4, h5, h6 { line-height: 1.1; font-weight: 400; }

/* ============================================================
   TYPOGRAPHY HELPERS
   ============================================================ */
.woodex-sheet .elementor-heading-title,
.woodex-eyebrow .elementor-heading-title {
	font-family: var(--woodex-mono);
	font-weight: 500;
	font-size: 12px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--woodex-gray);
}

.woodex-hero-head .elementor-heading-title { text-wrap: balance; }

/* Oversized outlined wordmark (e.g. "SPACES" under the hero) */
.woodex-wordmark .elementor-heading-title {
	font-size: clamp(96px, 24vw, 360px);
	font-weight: 500;
	letter-spacing: -0.04em;
	line-height: 0.8;
	color: transparent;
	-webkit-text-stroke: 1.4px rgba(255, 255, 255, 0.2);
	white-space: nowrap;
	user-select: none;
	pointer-events: none;
}

.woodex-big-num .elementor-heading-title { font-weight: 200; line-height: 1; }

/* ============================================================
   BUTTONS — pill with trailing arrow
   ============================================================ */
.woodex-pill .elementor-button {
	border-radius: var(--woodex-pill);
	transition: transform 0.2s ease;
}
.woodex-pill .elementor-button:hover { transform: translateY(-1px); }
.woodex-pill .elementor-button .elementor-button-text::after {
	content: "\2192";           /* → */
	display: inline-block;
	margin-left: 10px;
	transition: transform 0.2s ease;
}
.woodex-pill .elementor-button:hover .elementor-button-text::after {
	transform: translate(3px, -1px);
}

/* Ghost pill (transparent on dark) */
.woodex-ghost .elementor-button {
	border: 1px solid currentColor;
	background: transparent !important;
	border-radius: var(--woodex-pill);
}

/* ============================================================
   NAV (rendered by wp_nav_menu / [woodex_menu] shortcode)
   ============================================================ */
.woodex-nav {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	align-items: center;
	gap: 30px;
}
.woodex-nav li { margin: 0; }
.woodex-nav a {
	font-size: 14px;
	letter-spacing: 0.02em;
	color: #fff;
	opacity: 0.85;
	text-decoration: none;
	transition: opacity 0.2s ease;
}
.woodex-nav a:hover { opacity: 1; }
.woodex-nav .sub-menu { display: none; }

/* ============================================================
   IMAGERY — neutral treatment, hover crop
   ============================================================ */
.woodex-swatch img { width: 84px; height: 84px; object-fit: cover; border: 1px solid rgba(255,255,255,0.16); }

.woodex-about-img img,
.woodex-svc-img img,
.woodex-proj-img img,
.woodex-art-img img,
.woodex-showcase img,
.woodex-proj-card img {
	width: 100%;
	object-fit: cover;
	border-radius: var(--woodex-radius);
	filter: grayscale(100%);
	transition: filter 0.5s ease, transform 0.6s ease;
}
.woodex-about-img img { aspect-ratio: 4 / 5; }
.woodex-svc-img img { aspect-ratio: 4 / 3; }
.woodex-proj-img img { aspect-ratio: 4 / 5; }
.woodex-art-img img { aspect-ratio: 3 / 2; }
.woodex-showcase img { aspect-ratio: 16 / 9; }

.woodex-proj-card:hover img,
.woodex-art-img:hover img,
.woodex-proj-img:hover img {
	filter: grayscale(0%);
	transform: scale(1.04);
}

/* ============================================================
   PHP FALLBACK HEADER / FOOTER (used only when no XPRO
   Theme Builder header/footer is assigned)
   ============================================================ */
.woodex-fallback-header {
	position: relative;
	background: var(--woodex-black);
	color: var(--woodex-white);
	z-index: 1000;
}
.woodex-fallback-header__inner {
	max-width: var(--woodex-max);
	margin: 0 auto;
	padding: 18px clamp(20px, 5vw, 72px);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
}
.woodex-fallback-header .brand {
	font-weight: 500;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	font-size: 15px;
	color: var(--woodex-white);
}
.woodex-fallback-header .cta {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	background: var(--woodex-white);
	color: var(--woodex-black);
	padding: 12px 20px;
	border-radius: var(--woodex-pill);
	font-size: 14px;
	font-weight: 500;
}
.woodex-fallback-header .cta:hover { transform: translateY(-1px); }

.woodex-fallback-footer {
	background: var(--woodex-black);
	color: var(--woodex-white);
	padding: 90px clamp(20px, 5vw, 72px) 36px;
}
.woodex-fallback-footer__inner { max-width: var(--woodex-max); margin: 0 auto; }
.woodex-fallback-footer .foot-cta {
	font-size: clamp(34px, 6vw, 64px);
	font-weight: 300;
	letter-spacing: -0.03em;
	line-height: 1.0;
	max-width: 16ch;
	margin-bottom: 24px;
}
.woodex-fallback-footer .cols {
	display: grid;
	grid-template-columns: 2fr 1fr 1fr 1fr;
	gap: 36px;
	margin-top: 48px;
	padding-top: 40px;
	border-top: 1px solid rgba(255,255,255,0.16);
}
.woodex-fallback-footer h4 {
	font-family: var(--woodex-mono);
	font-size: 11px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--woodex-gray);
	margin: 0 0 16px;
}
.woodex-fallback-footer ul { list-style: none; margin: 0; padding: 0; }
.woodex-fallback-footer li { padding: 5px 0; font-size: 14px; opacity: 0.85; }
.woodex-fallback-footer a:hover { text-decoration: underline; }
.woodex-fallback-footer .legal {
	margin-top: 48px;
	padding-top: 22px;
	border-top: 1px solid rgba(255,255,255,0.16);
	display: flex;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px;
	font-size: 12px;
	color: var(--woodex-gray);
	font-family: var(--woodex-mono);
}

/* ============================================================
   WOODEX ANIMATED HERO WIDGET
   ============================================================ */
.woodex-hero-widget {
	position: relative;
	min-height: 100svh;
	background: linear-gradient(180deg, #161616 0%, #0f0f0f 62%, #0b0b0b 100%);
	color: var(--woodex-white);
	overflow: hidden;
	isolation: isolate;
	display: flex;
	align-items: center;
}
.woodex-hero-widget__grid {
	position: absolute;
	inset: 0;
	background-image:
		repeating-linear-gradient(90deg, transparent, transparent calc(20% - 1px), rgba(255,255,255,0.04) calc(20% - 1px), rgba(255,255,255,0.04) 20%);
	pointer-events: none;
	z-index: 0;
}
.woodex-hero-widget__plan {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	z-index: 1;
	pointer-events: none;
}
.woodex-hero-widget__plan .draw-line {
	fill: none;
	stroke: rgba(255,255,255,0.22);
	stroke-width: 1.4;
	stroke-dasharray: var(--len);
	stroke-dashoffset: var(--len);
	animation: woodexDraw 1.7s cubic-bezier(.2,.7,.2,1) forwards;
}
@keyframes woodexDraw {
	to { stroke-dashoffset: 0; }
}
.woodex-hero-widget__inner {
	position: relative;
	z-index: 3;
	width: 100%;
	max-width: var(--woodex-max);
	margin: 0 auto;
	padding: 120px clamp(20px, 5vw, 72px) 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 22px;
}
.woodex-hero-widget__eyebrow {
	font-family: var(--woodex-mono);
	font-size: 12px;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--woodex-gray);
	margin: 0;
	animation: woodexRise .9s cubic-bezier(.2,.7,.2,1) both;
}
.woodex-hero-widget__head {
	font-size: clamp(44px, 8.2vw, 112px);
	font-weight: 300;
	line-height: 0.98;
	letter-spacing: -0.03em;
	margin: 0;
	max-width: 15ch;
}
.woodex-hero-widget__head .ln { display: block; overflow: hidden; }
.woodex-hero-widget__head .ln > span {
	display: block;
	transform: translateY(104%);
	animation: woodexRise 0.9s cubic-bezier(.2,.7,.2,1) forwards;
}
.woodex-hero-widget__head .ln:nth-child(2) > span { animation-delay: 120ms; }
@keyframes woodexRise {
	to { transform: translateY(0); }
}
.woodex-hero-widget__copy {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 28px;
	margin-top: 16px;
	animation: woodexFade .7s ease .32s both;
}
@keyframes woodexFade {
	from { opacity: 0; transform: translateY(14px); }
	to { opacity: 1; transform: none; }
}
.woodex-hero-widget__cta {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	background: var(--woodex-white);
	color: var(--woodex-black);
	padding: 12px 20px;
	border-radius: var(--woodex-pill);
	font-size: 14px;
	font-weight: 500;
	text-decoration: none;
	transition: transform .2s ease;
}
.woodex-hero-widget__cta:hover { transform: translateY(-1px); }
.woodex-hero-widget__cta .arrow {
	width: 22px; height: 22px; border-radius: 50%;
	border: 1px solid var(--woodex-black);
	display: grid; place-items: center; font-size: 11px;
	transition: transform .2s ease;
}
.woodex-hero-widget__cta:hover .arrow { transform: translate(2px,-1px); }
.woodex-hero-widget__sub {
	max-width: 44ch;
	font-size: 17px;
	color: rgba(255,255,255,0.78);
	line-height: 1.55;
	margin: 0;
}
.woodex-hero-widget__word {
	position: absolute;
	left: clamp(20px, 5vw, 72px);
	right: clamp(20px, 5vw, 72px);
	bottom: -0.14em;
	z-index: 2;
	font-weight: 500;
	font-size: clamp(96px, 24vw, 360px);
	line-height: 0.8;
	letter-spacing: -0.04em;
	color: transparent;
	-webkit-text-stroke: 1.4px rgba(255,255,255,0.20);
	white-space: nowrap;
	overflow: hidden;
	user-select: none;
	pointer-events: none;
	animation: woodexFade 1.1s ease .4s both;
}
@media (prefers-reduced-motion: reduce) {
	.woodex-hero-widget__plan .draw-line,
	.woodex-hero-widget__head .ln > span,
	.woodex-hero-widget__eyebrow,
	.woodex-hero-widget__copy,
	.woodex-hero-widget__word { animation: none; transform: none; opacity: 1; stroke-dashoffset: 0; }
}

/* ============================================================
   BLOG SHORTCODE STYLES (single post / archive)
   ============================================================ */
.woodex-post-title { font-size: clamp(32px, 4.5vw, 54px); font-weight: 300; letter-spacing: -0.02em; margin: 0; }
.woodex-post-meta { font-family: var(--woodex-mono); font-size: 13px; letter-spacing: 0.02em; color: var(--woodex-gray); }
.woodex-post-featured { width: 100%; border-radius: var(--woodex-radius); filter: grayscale(100%); }
.woodex-blog-grid, .woodex-related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.woodex-blog-card, .woodex-related-card { display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: var(--woodex-black); }
.woodex-blog-img, .woodex-related-img { width: 100%; aspect-ratio: 3/2; object-fit: cover; border-radius: var(--woodex-radius); filter: grayscale(100%); transition: filter .5s ease, transform .6s ease; }
.woodex-blog-card:hover .woodex-blog-img, .woodex-related-card:hover .woodex-related-img { filter: grayscale(0%); transform: scale(1.04); }
.woodex-blog-cat { font-family: var(--woodex-mono); font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--woodex-gray); }
.woodex-blog-title, .woodex-related-title { font-size: 19px; font-weight: 400; line-height: 1.25; }
.woodex-blog-date { font-size: 13px; color: var(--woodex-gray); font-family: var(--woodex-mono); }
@media (max-width: 980px) { .woodex-blog-grid, .woodex-related-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .woodex-blog-grid, .woodex-related-grid { grid-template-columns: 1fr; } }

/* Inline WhatsApp button (shortcode / widget) */
.woodex-whatsapp {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	background: #25D366;
	color: #fff;
	text-decoration: none;
	font-size: 14px;
	font-weight: 600;
	padding: 12px 20px;
	border-radius: var(--woodex-pill);
	transition: transform .2s ease;
}
.woodex-whatsapp:hover { transform: translateY(-1px); color: #fff; }
.woodex-whatsapp svg { width: 20px; height: 20px; fill: #fff; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
	.woodex-nav { display: none; }
	.woodex-fallback-footer .cols { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
	.woodex-fallback-footer .cols { grid-template-columns: 1fr; }
	.woodex-wordmark .elementor-heading-title { -webkit-text-stroke-width: 1px; }
}

@media (prefers-reduced-motion: reduce) {
	.woodex-pill .elementor-button,
	.woodex-proj-card img,
	.woodex-art-img img,
	.woodex-proj-img img { transition: none; }
	.woodex-proj-card img,
	.woodex-art-img img,
	.woodex-proj-img img,
	.woodex-swatch img { filter: none; }
}
