/*
Theme Name: Studio Wood
Description: תבנית האתר של סטודיו ווד.
Author: Studio Wood
Version: 1.0.4
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: studio-wood
*/

:root {
	--sw-text: #515254;
	--sw-dark: #1d1d1f;
	--sw-muted: #8a8b8d;
	--sw-light: #f4f4f4;
	--sw-box: #dedede;
	--sw-line: #cfcfcf;
	--sw-white: #fff;
	--sw-max: 1110px;
	--sw-header: 64px;
}

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

html { scroll-behavior: smooth; }

body {
	margin: 0;
	font-family: "Heebo", Arial, sans-serif;
	font-size: 17px;
	font-weight: 400;
	line-height: 1.6;
	color: var(--sw-text);
	background: var(--sw-white);
	direction: rtl;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--sw-dark); }
h1, h2, h3, h4, h5, h6 { font-weight: 500; line-height: 1.25; margin: 0 0 .5em; color: var(--sw-text); }
p { margin: 0 0 1em; }

.sw-container { width: 100%; max-width: var(--sw-max); margin: 0 auto; padding: 0 16px; }
.sw-narrow { max-width: 860px; }
.sw-section { padding: 64px 0; }
.sw-gray { background: var(--sw-light); }
.sw-center { text-align: center; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); }

/* ---------- Header ---------- */
.sw-header {
	position: fixed;
	top: 0; right: 0; left: 0;
	height: var(--sw-header);
	z-index: 50;
	background: var(--sw-white);
	box-shadow: 0 1px 0 rgba(0,0,0,.06);
	transition: background .3s, box-shadow .3s;
}
.admin-bar .sw-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .sw-header { top: 46px; } }

.sw-header__inner {
	height: 100%;
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	align-items: center;
	padding: 0 24px;
}
.sw-header__start { justify-self: start; }
.sw-header__end { justify-self: end; display: flex; gap: 18px; align-items: center; }
.sw-logo img { height: 34px; width: auto; }
.sw-logo .sw-logo--light { display: none; }

.has-hero .sw-header:not(.is-scrolled) { background: transparent; box-shadow: none; }
.has-hero .sw-header:not(.is-scrolled) .sw-logo--light { display: block; }
.has-hero .sw-header:not(.is-scrolled) .sw-logo--dark { display: none; }
.has-hero .sw-header:not(.is-scrolled) .sw-menu-btn,
.has-hero .sw-header:not(.is-scrolled) .sw-icon-btn { color: var(--sw-white); }
.has-hero .sw-header:not(.is-scrolled) .sw-logo img { height: 52px; }

.sw-menu-btn {
	display: inline-flex; align-items: center; gap: 10px;
	background: none; border: 0; cursor: pointer;
	font: inherit; font-size: 14px; color: var(--sw-dark); padding: 6px 0;
}
.sw-burger { width: 18px; display: grid; gap: 4px; }
.sw-burger span { display: block; height: 2px; background: currentColor; border-radius: 1px; }

.sw-icon-btn {
	display: inline-flex; align-items: center; justify-content: center;
	width: 28px; height: 28px; color: var(--sw-dark);
	background: none; border: 0; padding: 0; cursor: pointer;
}
.sw-icon-btn svg { width: 15px; height: 15px; fill: currentColor; }

.sw-search {
	position: absolute; top: 100%; left: 0; right: 0;
	background: var(--sw-white);
	padding: 14px 24px;
	box-shadow: 0 6px 18px rgba(0,0,0,.08);
	display: none;
}
.sw-search.is-open { display: block; }
.sw-search form { max-width: 560px; margin: 0 auto; display: flex; gap: 8px; }
.sw-search input[type="search"] { flex: 1; }

.sw-main { padding-top: var(--sw-header); }
.has-hero .sw-main { padding-top: 0; }

/* ---------- Side menu ---------- */
.sw-drawer {
	position: fixed; top: 0; bottom: 0; right: 0;
	width: min(380px, 88vw);
	background: var(--sw-white);
	z-index: 60;
	transform: translateX(100%);
	transition: transform .35s ease;
	display: flex; flex-direction: column;
	padding: 24px 40px 32px;
	overflow-y: auto;
	box-shadow: -8px 0 30px rgba(0,0,0,.08);
}
.admin-bar .sw-drawer { top: 32px; }
.sw-drawer.is-open { transform: none; }
.sw-overlay {
	position: fixed; inset: 0; background: rgba(0,0,0,.25);
	z-index: 55; opacity: 0; pointer-events: none; transition: opacity .3s;
}
.sw-overlay.is-open { opacity: 1; pointer-events: auto; }
.sw-drawer__close {
	align-self: flex-start;
	background: none; border: 0; cursor: pointer; font: inherit; font-size: 14px;
	display: inline-flex; gap: 8px; align-items: center; color: var(--sw-dark);
}
.sw-drawer__close svg { width: 14px; height: 14px; fill: currentColor; }
.sw-drawer nav { margin-top: 72px; }
.sw-drawer ul { list-style: none; margin: 0; padding: 0; }
.sw-nav-main > li > a { display: block; font-size: 20px; font-weight: 500; color: var(--sw-dark); padding: 6px 0; }
.sw-nav-main .sub-menu { padding: 2px 0 8px; }
.sw-nav-main .sub-menu a,
.sw-nav-main li.sub-cat > a { font-size: 14px; font-weight: 400; color: var(--sw-text); padding: 4px 0; }
.sw-nav-main li.sub-cat > a::before,
.sw-nav-main .sub-menu a::before { content: "– "; color: var(--sw-muted); }
.sw-nav-secondary { margin-top: 40px; }
.sw-nav-secondary a { display: block; font-size: 14px; color: var(--sw-muted); padding: 2px 0; }
.sw-drawer .sw-socials { margin-top: auto; padding-top: 40px; justify-content: space-between; }

/* ---------- Socials ---------- */
.sw-socials { display: flex; gap: 22px; align-items: center; list-style: none; margin: 0; padding: 0; }
.sw-socials img { width: 16px; height: 16px; object-fit: contain; opacity: .6; transition: opacity .2s; }
.sw-socials a:hover img { opacity: 1; }

/* ---------- Hero ---------- */
.sw-hero {
	position: relative;
	height: 72vh; min-height: 360px; max-height: 760px;
	background: #ddd center / cover no-repeat;
	overflow: hidden;
}
.sw-hero::after {
	content: ""; position: absolute; inset: 0 0 auto 0; height: 160px;
	background: linear-gradient(rgba(0,0,0,.35), rgba(0,0,0,0));
	pointer-events: none;
}
.sw-hero--short { height: 56vh; }
.sw-slides { position: absolute; inset: 0; }
.sw-slide { position: absolute; inset: 0; background: center / cover no-repeat; opacity: 0; transition: opacity 1.2s ease; }
.sw-slide.is-active { opacity: 1; }

.sw-hero-box {
	position: relative;
	z-index: 2;
	margin: -112px auto 0;
	max-width: 420px;
	background: var(--sw-box);
	padding: 28px 32px;
	text-align: center;
}
.sw-hero-box h1 { font-size: 22px; font-weight: 700; color: var(--sw-dark); margin-bottom: 8px; }
.sw-hero-box p { font-size: 15px; margin: 0; }

.sw-page-title { text-align: center; font-size: 26px; font-weight: 400; margin: 24px 0 0; }
.sw-divider { width: 1px; height: 28px; background: var(--sw-dark); margin: 40px auto; }

/* ---------- Home ---------- */
.sw-tagline { text-align: center; padding: 40px 16px; }
.sw-tagline h2, .sw-tagline p { font-size: 28px; font-weight: 400; margin: 0; }

.sw-cat-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 40px 24px;
	justify-content: center;
}
.sw-cat-grid--center { display: flex; flex-wrap: wrap; justify-content: center; }
.sw-cat-grid--center > * { flex: 0 1 calc((100% - 48px) / 3); }
.sw-cat { text-align: center; }
.sw-cat__img { aspect-ratio: 4 / 3; display: flex; align-items: flex-end; justify-content: center; }
.sw-cat__img img { max-height: 100%; width: auto; object-fit: contain; transition: transform .4s ease; }
.sw-cat:hover .sw-cat__img img { transform: scale(1.04); }
.sw-cat__name { margin-top: 18px; font-size: 20px; font-weight: 400; }

.sw-about-band { height: 380px; background: center / cover no-repeat; }
.sw-about-card {
	max-width: 760px; margin: -64px auto 0; position: relative; z-index: 2;
	background: var(--sw-box); padding: 40px 56px 36px; font-size: 15px;
}
.sw-about-card p:empty, .sw-about-card p:has(> br:only-child) { display: none; }
@media (max-width: 640px) { .sw-about-card { padding: 28px 22px 30px; margin-top: -40px; } }
.sw-about-card h2, .sw-about-card h3 { color: var(--sw-dark); }
.sw-about-card h2 { font-size: 24px; font-weight: 500; }
.sw-about-card h3, .sw-about-card h4 { font-size: 17px; text-align: center; }
.sw-more { display: inline-flex; gap: 6px; align-items: center; font-size: 14px; color: var(--sw-dark); margin-top: 8px; }
.sw-more::after { content: "‹"; font-size: 18px; line-height: 1; }

.sw-blog-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 18px; }
.sw-blog-head h2 { font-size: 18px; margin: 0; color: var(--sw-dark); }
.sw-blog-head a { font-size: 13px; }
.sw-zigzag { display: grid; grid-template-columns: 1fr 1fr; }
.sw-zigzag__img { aspect-ratio: 2 / 1; overflow: hidden; }
.sw-zigzag__img img { width: 100%; height: 100%; object-fit: cover; }
.sw-zigzag__text { padding: 24px 32px; display: flex; flex-direction: column; justify-content: center; }
.sw-zigzag__text h3 { font-size: 21px; color: var(--sw-dark); }
.sw-zigzag__text p { font-size: 14px; color: var(--sw-muted); margin: 0; }
.sw-zigzag:nth-child(even) .sw-zigzag__img { order: 2; }

/* ---------- Product archive ---------- */
.sw-term-intro { text-align: center; max-width: 860px; margin: 0 auto 48px; }
.sw-term-intro h1 { font-size: 30px; font-weight: 400; }
.sw-term-intro p { font-size: 15px; }
.sw-products { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px 24px; }
.sw-product-card { text-align: center; display: block; }
.sw-product-card__img { aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; }
.sw-product-card__img img { max-height: 100%; width: auto; object-fit: contain; transition: transform .4s ease; }
.sw-product-card:hover .sw-product-card__img img { transform: scale(1.04); }
.sw-product-card__en { margin-top: 18px; font-size: 20px; font-weight: 700; color: var(--sw-text); }
.sw-product-card__he { margin-top: 10px; font-size: 19px; font-weight: 400; padding: 0 24px; }

/* ---------- Single product ---------- */
.sw-product-title { text-align: center; font-size: 24px; font-weight: 400; margin: 24px 0 0; }
.sw-gallery { max-width: 560px; margin: 0 auto; position: relative; }
.sw-gallery__track { position: relative; height: min(560px, 110vw); }
.sw-gallery__item { position: absolute; inset: 0; opacity: 0; transition: opacity .5s; display: flex; align-items: center; justify-content: center; }
.sw-gallery__item.is-active { opacity: 1; }
.sw-gallery__item img { max-height: 100%; width: auto; object-fit: contain; }
.sw-gallery__nav { display: flex; justify-content: center; align-items: center; gap: 14px; margin-top: 14px; font-size: 13px; }
.sw-gallery__nav button { background: none; border: 0; cursor: pointer; font-size: 18px; color: var(--sw-text); padding: 0 4px; }
.sw-about-product { margin-top: 48px; }
.sw-about-product > h2 { text-align: center; font-size: 17px; color: var(--sw-dark); margin-bottom: 24px; }
.sw-product-meta { display: grid; grid-template-columns: 1fr 1.4fr; gap: 48px; }
.sw-specs h3, .sw-enquiry h3 { font-size: 14px; font-weight: 700; color: var(--sw-dark); margin-bottom: 14px; }
.sw-specs dl { margin: 0; font-size: 13px; }
.sw-specs dt { display: inline; font-weight: 700; color: var(--sw-dark); }
.sw-specs dd { display: inline; margin: 0; }
.sw-specs dd::after { content: ""; display: block; margin-bottom: 8px; }
.sw-badge { display: flex; gap: 8px; align-items: center; border-top: 1px solid var(--sw-line); border-bottom: 1px solid var(--sw-line); padding: 12px 0; margin-top: 12px; font-size: 13px; }
.sw-badge svg { width: 22px; height: 22px; stroke: var(--sw-muted); fill: none; }
.sw-share { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; font-size: 13px; background: none; border: 0; cursor: pointer; color: var(--sw-dark); padding: 0; font-family: inherit; }
.sw-share svg { width: 13px; height: 13px; fill: currentColor; }
.sw-related { border-top: 1px solid var(--sw-line); margin-top: 64px; padding-top: 18px; }
.sw-related > h2 { font-size: 14px; color: var(--sw-dark); margin-bottom: 18px; }
.sw-related .sw-product-card__he { font-size: 13px; color: var(--sw-muted); }

/* ---------- Contact page ---------- */
.sw-contact { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.sw-contact__box { background: var(--sw-box); padding: 72px 40px; text-align: center; font-size: 14px; min-height: 320px; display: flex; flex-direction: column; justify-content: center; }
.sw-contact__line { margin: 0; color: var(--sw-dark); }
@media (max-width: 767px) { .sw-contact { grid-template-columns: 1fr; gap: 32px; } .sw-contact__box { padding: 40px 24px; min-height: 0; } }

/* ---------- Forms (Contact Form 7) ---------- */
.wpcf7 .hidden, .wpcf7 .prod-name { display: none !important; }
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 textarea,
.sw-search input[type="search"] {
	width: 100%;
	border: 0; border-bottom: 1px solid var(--sw-dark);
	background: transparent; font: inherit; font-size: 15px;
	padding: 8px 2px; color: var(--sw-dark); border-radius: 0;
}
.wpcf7 textarea { height: 90px; resize: vertical; }
.wpcf7 input:focus, .wpcf7 textarea:focus, .sw-search input:focus { outline: none; border-bottom-color: #000; }
.wpcf7 input[type="submit"], .sw-btn {
	background: #000; color: #fff; border: 0; cursor: pointer;
	font: inherit; font-size: 15px; padding: 7px 48px;
}
.wpcf7 input[type="submit"]:hover, .sw-btn:hover { background: #333; color: #fff; }
.wpcf7 p { margin-bottom: 18px; }

/* ---------- About page ---------- */
.sw-anchors { display: flex; justify-content: center; gap: 72px; margin: 28px 0 0; font-size: 14px; }
.sw-anchors a { color: var(--sw-muted); }
.sw-anchors a:hover { color: var(--sw-dark); }
.sw-about-section { padding: 48px 0; scroll-margin-top: calc(var(--sw-header) + 16px); }
.sw-about-section:nth-child(even) { background: var(--sw-light); }
.sw-about-section h2 { font-size: 21px; font-weight: 700; color: var(--sw-dark); }
.sw-about-section .sw-narrow { font-size: 15px; }

/* ---------- Content (posts, generic pages) ---------- */
.sw-content { font-size: 17px; }
.sw-content h2 { font-size: 26px; margin-top: 1.4em; }
.sw-content h3 { font-size: 21px; margin-top: 1.2em; }
.sw-content a { text-decoration: underline; }
.sw-content ul, .sw-content ol { padding-right: 1.2em; padding-left: 0; }
.sw-post-meta { text-align: center; font-size: 13px; color: var(--sw-muted); margin-top: 6px; }
.sw-posts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px 24px; }
.sw-post-card__img { aspect-ratio: 3 / 2; overflow: hidden; background: var(--sw-light); }
.sw-post-card__img img { width: 100%; height: 100%; object-fit: cover; }
.sw-post-card h2 { font-size: 19px; margin: 14px 0 6px; color: var(--sw-dark); }
.sw-post-card p { font-size: 14px; color: var(--sw-muted); }
.sw-pagination { margin-top: 48px; text-align: center; }
.sw-pagination .page-numbers { display: inline-block; padding: 4px 10px; }
.sw-pagination .current { color: var(--sw-dark); font-weight: 700; }

/* ---------- Social template ---------- */
.sw-social-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.sw-social-item { background: var(--sw-white); }
.sw-social-item img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.sw-social-item__body { padding: 16px; font-size: 14px; }
.sw-social-item__meta { font-size: 12px; color: var(--sw-muted); }

/* ---------- Footer ---------- */
.sw-footer { background: var(--sw-box); padding: 18px 0 22px; font-size: 13px; }
.sw-footer__contact { border-bottom: 1px solid var(--sw-dark); padding-bottom: 8px; margin: 0 0 14px; }
.sw-footer__contact .sep { margin: 0 10px; }
.sw-footer__row { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.sw-footer-menu { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; font-size: 11px; }
.sw-footer-menu li:not(:last-child)::after { content: "|"; margin: 0 6px; color: var(--sw-muted); }
.sw-footer-legal { font-size: 13px; margin-top: 10px; }
.sw-footer-legal a:not(:last-child)::after { content: " | "; }

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
	.sw-cat-grid, .sw-products, .sw-posts, .sw-social-grid { grid-template-columns: repeat(2, 1fr); }
	.sw-cat-grid--center > * { flex-basis: calc((100% - 24px) / 2); }
	.sw-product-meta { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
	body { font-size: 16px; }
	.sw-header__inner { padding: 0 16px; }
	.sw-header__end .sw-hide-sm { display: none; }
	.sw-menu-btn .sw-menu-label { display: none; }
	.sw-cat-grid, .sw-products, .sw-posts, .sw-social-grid { grid-template-columns: 1fr; }
	.sw-cat-grid--center > * { flex-basis: 100%; }
	.sw-zigzag { grid-template-columns: 1fr; }
	.sw-zigzag:nth-child(even) .sw-zigzag__img { order: 0; }
	.sw-hero { height: 52vh; }
	.sw-anchors { gap: 24px; flex-wrap: wrap; }
	.sw-section { padding: 44px 0; }
	.sw-tagline h2, .sw-tagline p { font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) {
	* { transition: none !important; scroll-behavior: auto !important; }
}
