/*
Theme Name: New Tech Metals
Author: New Tech Metals Manufacturing
Description: Product-catalog theme (RTL) for New Tech Metals Manufacturing – copper AC pipes, auto-feeding metal parts and metal works.
Version: 1.0.1
Requires PHP: 7.4
Text Domain: newtech
*/

:root {
	--slate: #2c3e50;
	--slate-dark: #1f2d3a;
	--slate-2: #3b5166;
	--red: #e3342f;
	--red-dark: #c4231f;
	--copper: #b87333;
	--text: #2a323b;
	--muted: #66707b;
	--line: #e3e7eb;
	--bg: #ffffff;
	--bg-soft: #f3f5f7;
	--radius: 12px;
	--shadow: 0 10px 30px rgba(31, 45, 58, .10);
	--wrap: 1200px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: "Tajawal", "Segoe UI", Tahoma, sans-serif;
	font-size: 17.5px;
	line-height: 1.85;
	color: var(--text);
	background: var(--bg);
	-webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); text-decoration: none; }
a:hover { color: var(--red-dark); }

h1, h2, h3, h4 { color: var(--slate-dark); line-height: 1.4; margin: 0 0 .55em; font-weight: 800; }
h1 { font-size: clamp(1.9rem, 4vw, 3rem); }
h2 { font-size: clamp(1.5rem, 2.7vw, 2.15rem); }
h3 { font-size: 1.18rem; font-weight: 700; }
p { margin: 0 0 1em; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.ltr { direction: ltr; unicode-bidi: embed; display: inline-block; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: #fff; box-shadow: 0 1px 0 var(--line); }
.site-header::before { content: ""; display: block; height: 4px; background: linear-gradient(90deg, var(--red) 0 25%, var(--slate) 25% 100%); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 84px; }
.brand img { height: 58px; width: auto; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; }
.main-nav a { display: block; padding: 8px 14px; color: var(--slate-dark); font-weight: 700; font-size: 16px; border-bottom: 2px solid transparent; white-space: nowrap; }
.main-nav a:hover,
.main-nav .current-menu-item > a { color: var(--red); border-bottom-color: var(--red); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: 10px; width: 46px; height: 46px; cursor: pointer; }
.nav-toggle span { display: block; width: 20px; height: 2px; background: var(--slate); margin: 4px auto; }

/* ---------- Buttons ---------- */
.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	padding: 12px 26px; border-radius: 8px; font-weight: 700; font-size: 16px;
	border: 2px solid transparent; transition: transform .15s ease, background .15s ease, color .15s ease;
	white-space: nowrap; line-height: 1.6;
}
.btn:hover { transform: translateY(-1px); }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-dark); color: #fff; }
.btn-slate { background: var(--slate); color: #fff; }
.btn-slate:hover { background: var(--slate-dark); color: #fff; }
.btn-line { border-color: var(--slate); color: var(--slate); background: transparent; }
.btn-line:hover { background: var(--slate); color: #fff; }
.btn-white { background: #fff; color: var(--slate-dark); }
.btn-white:hover { background: var(--slate-dark); color: #fff; }

/* ---------- Hero (split with product collage) ---------- */
.hero { background: linear-gradient(180deg, var(--bg-soft) 0%, #fff 100%); position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset-inline-end: -160px; top: -160px; width: 520px; height: 520px; border-radius: 50%; border: 70px solid rgba(44, 62, 80, .05); }
.hero .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; padding-top: 72px; padding-bottom: 84px; position: relative; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.badge { background: #fff; border: 1px solid var(--line); color: var(--slate); font-weight: 700; font-size: 14px; padding: 4px 14px; border-radius: 999px; }
.badge.red { background: var(--red); border-color: var(--red); color: #fff; }
.hero h1 span { color: var(--red); }
.hero .lead { font-size: 1.12rem; color: var(--muted); max-width: 580px; margin-bottom: 28px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-collage { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.hero-collage a { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; box-shadow: var(--shadow); transition: transform .2s ease; }
.hero-collage a:hover { transform: translateY(-4px); }
.hero-collage a:nth-child(2) { margin-top: 36px; }
.hero-collage a:nth-child(3) { margin-top: -36px; }
.hero-collage img { width: 100%; aspect-ratio: 1; object-fit: contain; }

/* ---------- Sections ---------- */
.section { padding: 92px 0; }
.section-soft { background: var(--bg-soft); }
.section-slate { background: var(--slate-dark); color: rgba(255, 255, 255, .8); }
.section-slate h2, .section-slate h3 { color: #fff; }
.section-head { max-width: 720px; margin-bottom: 42px; }
.section-head.center { text-align: center; margin-inline: auto; }
.kicker { display: inline-flex; align-items: center; gap: 10px; color: var(--red); font-weight: 800; font-size: 15px; margin-bottom: 6px; }
.kicker::before { content: ""; width: 10px; height: 10px; background: var(--red); transform: rotate(45deg); }
.section-head p { color: var(--muted); font-size: 1.05rem; }
.section-slate .section-head p { color: rgba(255, 255, 255, .7); }

/* Category tiles */
.cats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.cat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .2s ease, transform .2s ease; }
.cat:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.cat-img { background: var(--bg-soft); padding: 18px; display: block; }
.cat-img img { width: 100%; aspect-ratio: 4 / 3; object-fit: contain; mix-blend-mode: multiply; }
.cat-body { padding: 18px 20px 22px; border-top: 3px solid var(--slate); flex: 1; display: flex; flex-direction: column; }
.cat:hover .cat-body { border-top-color: var(--red); }
.cat-body h3 { font-size: 1.08rem; margin-bottom: 6px; }
.cat-body h3 a { color: var(--slate-dark); }
.cat-body p { color: var(--muted); font-size: 15px; line-height: 1.75; flex: 1; margin-bottom: 10px; }
.more { font-weight: 800; font-size: 15px; display: inline-flex; gap: 6px; align-items: center; }
.more::after { content: "←"; transition: transform .2s ease; }
.cat:hover .more::after, .post-card:hover .more::after { transform: translateX(-4px); }

/* Spec split */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.spec-img { background: #fff; border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.spec-img img { width: 100%; aspect-ratio: 5 / 4; object-fit: contain; }
.spec-list { list-style: none; padding: 0; margin: 0 0 1.4em; display: grid; gap: 10px; }
.spec-list li { display: flex; gap: 12px; align-items: flex-start; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; }
.spec-list li::before { content: ""; flex: none; width: 8px; height: 8px; margin-top: 11px; background: var(--copper); border-radius: 2px; transform: rotate(45deg); }
.capacity { display: inline-flex; align-items: baseline; gap: 10px; background: var(--slate); color: #fff; padding: 10px 20px; border-radius: 10px; margin-bottom: 18px; font-weight: 700; }
.capacity b { font-size: 1.6rem; color: #fff; }

/* Industries strip */
.industries { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.industry { border: 1px solid rgba(255, 255, 255, .12); border-radius: var(--radius); padding: 26px 22px; background: rgba(255, 255, 255, .03); }
.industry .ic { width: 50px; height: 50px; border-radius: 12px; background: rgba(227, 52, 47, .15); display: grid; place-items: center; margin-bottom: 14px; }
.industry .ic svg { width: 26px; height: 26px; fill: none; stroke: #ff6b66; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.industry p { margin: 0; font-size: 15px; color: rgba(255, 255, 255, .7); }

/* Product gallery */
.gallery-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.gallery-grid a { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 10px; transition: box-shadow .2s ease, border-color .2s ease; }
.gallery-grid a:hover { box-shadow: var(--shadow); border-color: var(--red); }
.gallery-grid img { width: 100%; aspect-ratio: 1; object-fit: contain; }

/* Post cards */
.posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.post-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .2s ease; }
.post-card:hover { box-shadow: var(--shadow); }
.post-card .thumb { background: var(--bg-soft); display: block; padding: 14px; }
.post-card .thumb img { width: 100%; aspect-ratio: 16 / 10; object-fit: contain; mix-blend-mode: multiply; }
.post-card .body { padding: 18px 20px 22px; flex: 1; display: flex; flex-direction: column; }
.post-card .meta { font-size: 13.5px; color: var(--muted); margin-bottom: 4px; }
.post-card h3 { font-size: 1.05rem; }
.post-card h3 a { color: var(--slate-dark); }
.post-card h3 a:hover { color: var(--red); }
.post-card p { color: var(--muted); font-size: 15px; line-height: 1.75; flex: 1; }

/* CTA */
.cta { background: var(--slate); border-radius: 18px; padding: 46px 50px; color: rgba(255, 255, 255, .85); display: flex; justify-content: space-between; align-items: center; gap: 26px; flex-wrap: wrap; position: relative; overflow: hidden; }
.cta::after { content: ""; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 8px; background: var(--red); }
.cta h2 { color: #fff; margin-bottom: 4px; }
.cta p { margin: 0; }

/* ---------- Inner pages ---------- */
.page-head { background: var(--slate-dark); color: #fff; padding: 60px 0 52px; position: relative; overflow: hidden; }
.page-head::after { content: ""; position: absolute; inset-inline-end: 0; bottom: 0; width: 35%; height: 4px; background: var(--red); }
.page-head h1 { color: #fff; margin: 0; max-width: 900px; }
.crumbs { font-size: 14px; color: rgba(255, 255, 255, .6); margin-bottom: 8px; }
.crumbs a { color: rgba(255, 255, 255, .85); }
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 46px; padding-block: 60px 86px; }
.entry-featured { background: var(--bg-soft); border-radius: var(--radius); padding: 20px; margin-bottom: 26px; }
.entry-featured img { margin: 0 auto; max-height: 520px; width: auto; }
.entry-content h1 { font-size: 1.8rem; }
.entry-content h2 { font-size: 1.5rem; margin-top: 1.6em; }
.entry-content h2::after { content: ""; display: block; width: 50px; height: 3px; background: var(--red); margin-top: 8px; }
.entry-content ul, .entry-content ol { padding-inline-start: 1.4em; }
.entry-content img { border-radius: 8px; }
.entry-content .gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 1.5em 0; }
.entry-content .gallery br { display: none; }
.entry-content .gallery-item { margin: 0; width: auto !important; background: var(--bg-soft); border-radius: 8px; padding: 8px; }
.entry-content .gallery-item img { aspect-ratio: 1; object-fit: contain; width: 100%; border: 0 !important; }
.entry-content .wp-caption, .entry-content figure { max-width: 100%; margin: 1.5em auto; }
.entry-content .aligncenter { margin-inline: auto; }
.entry-content table { width: 100%; border-collapse: collapse; margin: 1.5em 0; }
.entry-content th, .entry-content td { border: 1px solid var(--line); padding: 10px 14px; text-align: start; }
.tags { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 8px; }
.tags a { background: var(--bg-soft); color: var(--text); padding: 3px 14px; border-radius: 999px; font-size: 14px; }
.tags a:hover { background: var(--red); color: #fff; }
.side .box { border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-bottom: 22px; }
.side .box h3 { font-size: 1.05rem; padding-bottom: 10px; border-bottom: 2px solid var(--line); margin-bottom: 14px; }
.side .box-cta { background: var(--slate); border: 0; color: rgba(255, 255, 255, .8); }
.side .box-cta h3 { color: #fff; border-color: rgba(255, 255, 255, .15); }
.side .box-cta .btn { width: 100%; }
.side-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.side-list a { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: center; color: var(--slate-dark); font-weight: 700; font-size: 14.5px; line-height: 1.55; }
.side-list a:hover { color: var(--red); }
.side-list img { width: 64px; height: 64px; object-fit: contain; background: var(--bg-soft); border-radius: 8px; padding: 4px; }
.sticky { position: sticky; top: 110px; }
.pagination { margin-top: 36px; display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.pagination .page-numbers { padding: 6px 16px; border: 1px solid var(--line); border-radius: 8px; color: var(--slate-dark); }
.pagination .current { background: var(--red); border-color: var(--red); color: #fff; }

/* ---------- Footer ---------- */
.site-footer { background: var(--slate-dark); color: rgba(255, 255, 255, .65); padding: 66px 0 24px; font-size: 15.5px; }
.site-footer h4 { color: #fff; font-size: 1.05rem; margin-bottom: 14px; }
.site-footer a { color: rgba(255, 255, 255, .82); }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 42px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.footer-logo { display: inline-block; background: #fff; padding: 10px 14px; border-radius: 10px; margin-bottom: 14px; }
.footer-logo img { height: 46px; width: auto; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); margin-top: 40px; padding-top: 18px; font-size: 14px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
	.cats, .industries { grid-template-columns: repeat(2, 1fr); }
	.gallery-grid { grid-template-columns: repeat(4, 1fr); }
	.layout { grid-template-columns: 1fr; }
	.sticky { position: static; }
}
@media (max-width: 960px) {
	.nav-toggle { display: block; }
	.header-wa { display: none; }
	.main-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); padding: 8px 20px 16px; }
	.main-nav.open { display: block; }
	.main-nav ul { flex-direction: column; }
	.hero .wrap, .split, .posts, .footer-grid { grid-template-columns: 1fr; }
	.hero .wrap { gap: 40px; padding-top: 52px; }
	.section { padding: 70px 0; }
	.cta { padding: 34px 28px; }
}
@media (max-width: 600px) {
	body { font-size: 16.5px; }
	.cats, .industries { grid-template-columns: 1fr; }
	.gallery-grid { grid-template-columns: repeat(3, 1fr); }
	.brand img { height: 46px; }
	.hero-collage a:nth-child(2), .hero-collage a:nth-child(3) { margin-top: 0; }
	.entry-content .gallery { grid-template-columns: repeat(2, 1fr); }
}
