/*
Theme Name: Mizmor Productions
Theme URI: https://mvp-tv.co.il
Description: ערכת עיצוב מותאמת למזמור הפקות - אולפני טלוויזיה וניידות שידור.
Version: 1.4.0
Requires at least: 6.4
Requires PHP: 8.0
Text Domain: mizmor
*/

:root {
  --bg: #1b1b1b;
  --bg-dark: #0b0b0b;
  --text: #f2f2f2;
  --muted: #b9b9b9;
  --accent: #1e9bf0;
  --btn: #2a2150;
  --btn-hover: #3a2f6e;
  --cta: #2f4be0;
  --radius: 8px;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Assistant", "Heebo", Arial, sans-serif;
  font-size: 18px;
  line-height: 1.6;
  direction: rtl;
  text-align: right;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }
a:hover { color: #5cb8f5; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 .5em; }

.skip-link, .contact-form .hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.skip-link:focus { width: auto; height: auto; clip: auto; clip-path: none; right: 1rem; top: 1rem; background: #fff; color: #000; padding: .5rem 1rem; z-index: 1000; }
html, body { overflow-x: clip; }

/* ---------- Header ---------- */
.site-header {
  position: absolute; inset: 0 0 auto 0; z-index: 50;
  padding: 18px 4vw;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  background: linear-gradient(to bottom, rgba(0,0,0,.65), rgba(0,0,0,0));
}
body:not(.home) .site-header { position: relative; background: var(--bg-dark); }
.site-header .logo img { height: 46px; width: auto; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 26px; flex-wrap: wrap; }
.main-nav a { color: #fff; text-decoration: none; font-weight: 600; font-size: 17px; }
.main-nav a:hover, .main-nav .current-menu-item > a { color: var(--accent); }
.header-social { display: flex; gap: 16px; }
.header-social a { color: #fff; display: inline-flex; }
.header-social svg { width: 22px; height: 22px; fill: currentColor; }
.nav-toggle { display: none; background: none; border: 0; color: #fff; cursor: pointer; padding: 6px; }
.nav-toggle svg { width: 28px; height: 28px; fill: currentColor; }

/* ---------- Layout helpers used by page blocks ---------- */
.entry-content > * { max-width: var(--max); margin-left: auto; margin-right: auto; padding-left: 4vw; padding-right: 4vw; }
.entry-content > .alignfull { max-width: none; padding-left: 0; padding-right: 0; }
.entry-content p { margin: 0 0 1em; }
.section { padding-top: 56px !important; padding-bottom: 56px !important; }
.section-title { color: var(--accent); text-align: center; font-size: clamp(28px, 3.4vw, 40px); font-weight: 800; }
.section-sub { text-align: center; color: var(--muted); margin-top: -.4em; }
.center { text-align: center; }
.lead { font-size: clamp(19px, 1.8vw, 23px); text-align: center; }
.strong-line { font-weight: 800; font-size: clamp(21px, 2.1vw, 28px); text-align: center; }
.page-title-band { text-align: center; padding: 60px 4vw 20px !important; }
.page-title-band h1 { color: var(--accent); font-size: clamp(32px, 4vw, 48px); font-weight: 800; }

/* Hero (cover block) */
.hero.wp-block-cover { min-height: 92vh !important; align-items: flex-start !important; padding-top: 110px !important; }
.hero .wp-block-cover__inner-container { text-align: center; }
.hero .hero-brand { font-size: clamp(36px, 5vw, 64px); font-weight: 800; line-height: 1.15; margin-bottom: .15em; text-shadow: 0 2px 16px rgba(0,0,0,.6); color: #fff; }
.hero h1.hero-title { font-size: clamp(18px, 2vw, 24px); font-weight: 600; text-shadow: 0 2px 12px rgba(0,0,0,.7); color: #fff; }

/* Service cards */
.cards.wp-block-columns { gap: 28px; }
.card { text-align: center; }
.card h3 { font-size: clamp(22px, 2.2vw, 30px); font-weight: 800; margin-bottom: .1em; }
.card .card-sub { color: #ddd; margin-bottom: 14px; }
.card figure { margin: 0; position: relative; overflow: hidden; border-radius: 4px; }
.card figure img { width: 100%; aspect-ratio: 16 / 13; object-fit: cover; transition: transform .4s; }
.card:hover figure img { transform: scale(1.04); }
.card .wp-block-buttons { justify-content: center; margin-top: -64px; position: relative; z-index: 2; margin-bottom: 30px; }
.wp-block-button__link, .btn {
  background: var(--btn) !important; color: #fff !important;
  border-radius: var(--radius) !important; padding: 10px 34px !important;
  font-weight: 700; text-decoration: none; border: 0; display: inline-block;
}
.wp-block-button__link:hover, .btn:hover { background: var(--btn-hover) !important; }

/* Location cards (studios page) */
.locations figure img { aspect-ratio: 16 / 11; object-fit: cover; width: 100%; }
.locations figcaption { text-align: center; font-size: 20px; color: #eee; margin-top: 10px; }

/* Split media/text rows */
.split.wp-block-media-text { gap: 0; align-items: center; }
.split .wp-block-media-text__media img { width: 100%; height: 100%; object-fit: cover; }
.split .wp-block-media-text__content { padding: 40px 5% !important; }
.split h2 { color: var(--accent); font-size: clamp(26px, 2.8vw, 36px); font-weight: 800; }
.split ul { list-style: none; padding: 0; margin: 0; }
.split li { padding: 6px 0; }

/* Split rows built with columns (text column first = right side in RTL) */
.split-cols.wp-block-columns { align-items: center !important; gap: 48px; }
.split-cols h1, .split-cols h2 { color: var(--accent); font-weight: 800; font-size: clamp(26px, 2.8vw, 38px); text-align: right; }
.split-cols h1.section-title { text-align: right; }
.split-cols h3 { font-size: 22px; font-weight: 800; }
.split-cols .split-media figure { margin: 0; }
.split-cols .split-media img { width: 100%; max-height: 680px; object-fit: cover; border-radius: 4px; }
.split-cols ul { list-style: none; padding: 0; margin: 0; }
.split-cols li { padding: 7px 0; border-bottom: 1px solid #2a2a2a; }
.split-cols li::before { content: "•"; color: var(--accent); margin-left: 10px; }
.split-cols .clients-inline, .split-text .wp-block-image:last-child img { margin-top: 24px; }
.wp-block-image { margin: 0 0 1em; }

/* Clients strip */
.clients img { margin: 30px auto 0; max-width: 900px; width: 100%; }

/* ---------- Contact strip ---------- */
.contact-strip { background: var(--bg); border-top: 1px solid #262626; padding: 34px 4vw; }
.contact-strip .inner { max-width: var(--max); margin: 0 auto; display: flex; gap: 30px; align-items: flex-end; flex-wrap: wrap; justify-content: space-between; }
.contact-strip h2 { color: var(--accent); font-size: 26px; font-weight: 600; margin: 0; }
.contact-strip p { margin: 0; color: var(--muted); font-size: 15px; }
.contact-form { display: flex; gap: 14px; flex: 1 1 560px; align-items: flex-end; flex-wrap: wrap; }
.contact-form input[type=text], .contact-form input[type=tel], .contact-form input[type=email] {
  flex: 1 1 150px; background: transparent; border: 0; border-bottom: 1px solid #777;
  color: #fff; font: inherit; font-size: 16px; padding: 8px 4px;
}
.contact-form input:focus { outline: none; border-bottom-color: var(--accent); }
.contact-form button { background: var(--cta); color: #fff; border: 0; border-radius: 30px; padding: 10px 40px; font: inherit; font-weight: 700; cursor: pointer; }
.contact-form button:hover { filter: brightness(1.15); }
.form-msg { width: 100%; padding: 10px 14px; border-radius: 6px; margin-top: 10px; font-weight: 600; }
.form-msg.ok { background: #12391f; color: #9ff0b8; }
.form-msg.err { background: #3d1414; color: #ffb3b3; }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-dark); padding: 50px 4vw 30px; }
.site-footer .inner { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr) 1.4fr; gap: 30px; align-items: start; }
.site-footer h3 { color: var(--accent); font-size: 17px; font-weight: 700; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 10px; font-size: 15px; }
.site-footer a { color: #ccc; text-decoration: none; }
.site-footer a:hover { color: #fff; }
.site-footer .loc strong { display: block; color: #fff; font-size: 16px; }
.site-footer .loc span { color: #aaa; font-size: 14px; }
.site-footer .loc a.waze { color: var(--accent); font-size: 14px; display: inline-block; margin: 4px 0 14px; }
.site-footer .footer-logo { align-self: center; justify-self: start; }
.site-footer .footer-logo img { max-width: 260px; }
.site-footer .contact-list svg { width: 16px; height: 16px; fill: #aaa; vertical-align: -3px; margin-left: 8px; }
.copyright { text-align: center; color: #777; font-size: 13px; margin-top: 30px; }

/* ---------- Hero video ---------- */
.hero.wp-block-cover { background: #111 url(assets/img/hero-aerial.webp) center / cover no-repeat; }
.hero video.wp-block-cover__video-background { object-fit: cover; }

/* ---------- Gallery ---------- */
.mizmor-gallery.wp-block-gallery.has-nested-images { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px !important; }
.mizmor-gallery.wp-block-gallery.has-nested-images figure.wp-block-image { width: auto !important; margin: 0 !important; flex: none !important; }
.mizmor-gallery.wp-block-gallery.has-nested-images figure.wp-block-image img { width: 100% !important; height: auto !important; }
.mizmor-gallery.wp-block-gallery .wp-block-image img { aspect-ratio: 4 / 3; object-fit: cover; border-radius: 4px; transition: transform .3s, filter .3s; }
.mizmor-gallery.wp-block-gallery .wp-block-image:hover img { transform: scale(1.03); filter: brightness(1.1); }
.productions.wp-block-gallery.has-nested-images { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 18px !important; }
.productions.wp-block-gallery.has-nested-images figure.wp-block-image { width: auto !important; margin: 0 !important; }
.productions.wp-block-gallery .wp-block-image img { aspect-ratio: 16 / 10; object-fit: contain; background: #111; border-radius: 6px; padding: 6px; }
.floorplan img { max-width: 720px; margin: 0 auto; border-radius: 6px; }

.site-credit { text-align: center; color: #666; font-size: 13px; margin-top: 8px; }
.site-credit a { color: #999; }
.site-credit a:hover { color: #fff; }

/* ---------- Legal pages, form note ---------- */
.legal { max-width: 860px !important; }
.legal h3 { color: var(--accent); margin-top: 1.4em; }
.legal ul { padding-right: 1.2em; }
.form-note { width: 100%; margin: 6px 0 0; font-size: 13px; color: var(--muted); }
.form-note a { color: var(--muted); text-decoration: underline; }
.legal-links { text-align: center; margin-top: 26px; font-size: 14px; color: #666; }
.legal-links a { color: #aaa; text-decoration: none; margin: 0 8px; }
.legal-links a:hover { color: #fff; }

/* ---------- Floating buttons: accessibility (left) + WhatsApp (right) ---------- */
.wa-float, .a11y-toggle { position: fixed; bottom: 20px; z-index: 900; width: 56px; height: 56px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(0,0,0,.45); border: 0; cursor: pointer; }
.wa-float { right: 20px; background: #25d366; color: #fff; }
.wa-float svg { width: 30px; height: 30px; fill: #fff; }
.wa-float:hover { filter: brightness(1.08); }
.a11y-toggle { left: 20px; background: var(--cta); color: #fff; }
.a11y-toggle svg { width: 30px; height: 30px; fill: #fff; }
.a11y-panel { position: fixed; left: 20px; bottom: 86px; z-index: 901; width: 240px; background: #fff; color: #111; border-radius: 10px; box-shadow: 0 8px 28px rgba(0,0,0,.5); padding: 12px; display: flex; flex-direction: column; gap: 6px; font-size: 15px; }
.a11y-panel[hidden] { display: none; }
.a11y-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.a11y-panel button, .a11y-panel a { font: inherit; text-align: right; background: #f1f3f7; color: #111; border: 1px solid #d8dbe2; border-radius: 6px; padding: 8px 10px; cursor: pointer; text-decoration: none; }
.a11y-panel button[aria-pressed="true"] { background: var(--cta); color: #fff; border-color: var(--cta); }
.a11y-panel .a11y-close { background: none; border: 0; font-size: 22px; padding: 0 6px; }
.a11y-panel a { color: #1d3fc4; text-decoration: underline; }
*:focus-visible { outline: 3px solid #ffbf47 !important; outline-offset: 2px; }

/* Accessibility modes */
html.a11y-font-1 { font-size: 112%; } html.a11y-font-1 body { font-size: 20px; }
html.a11y-font-2 body { font-size: 22px; } html.a11y-font-3 body { font-size: 25px; }
html.a11y-contrast body, html.a11y-contrast .site-footer, html.a11y-contrast .contact-strip, html.a11y-contrast .site-header { background: #000 !important; color: #fff !important; }
html.a11y-contrast a, html.a11y-contrast .section-title, html.a11y-contrast h1, html.a11y-contrast h2, html.a11y-contrast h3 { color: #ffff00 !important; }
html.a11y-contrast .wp-block-cover__background { opacity: .7 !important; background: #000 !important; }
html.a11y-contrast .a11y-panel a { color: #1d3fc4 !important; }
html.a11y-links a { text-decoration: underline !important; outline: 2px dashed #ffbf47; outline-offset: 2px; }
html.a11y-readable body, html.a11y-readable body * { font-family: Arial, Helvetica, sans-serif !important; letter-spacing: .02em; }
html.a11y-noanim *, html.a11y-noanim *::before, html.a11y-noanim *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }

/* Admin bar offset for the transparent home header */
.admin-bar.home .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar.home .site-header { top: 46px; } }

/* ---------- Generic page (non-front, plain content) ---------- */
.site-main { min-height: 40vh; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }
  .main-nav { display: none; position: absolute; top: 100%; right: 0; left: 0; background: rgba(10,10,10,.97); padding: 20px 6vw; }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; gap: 16px; }
  .header-social { display: none; }
  .site-footer .inner { grid-template-columns: 1fr 1fr; }
  .site-footer .footer-logo { grid-column: 1 / -1; justify-self: center; }
  .card .wp-block-buttons { margin-top: -60px; }
  .split .wp-block-media-text__content { padding: 30px 6vw !important; }
}
@media (max-width: 560px) {
  .wa-float, .a11y-toggle { width: 50px; height: 50px; bottom: 14px; }
  .wa-float { right: 14px; } .a11y-toggle { left: 14px; }
  .a11y-panel { left: 14px; bottom: 74px; }
  body { font-size: 17px; }
  .site-footer .inner { grid-template-columns: 1fr; text-align: center; }
  .contact-strip .inner { flex-direction: column; align-items: stretch; }
  .contact-form button { width: 100%; }
}

/* ---------- 1.4.0: language switch, FAQ, CTA, English (LTR) ---------- */
.lang-switch { color: #fff; text-decoration: none; font-weight: 700; font-size: 14px; border: 1px solid rgba(255,255,255,.5); border-radius: 4px; padding: 2px 8px; align-self: center; }
.lang-switch:hover { color: var(--accent); border-color: var(--accent); }
.faq .wp-block-details { border-bottom: 1px solid #2a2a2a; padding: 4px 0; margin: 0; }
.faq summary { cursor: pointer; font-weight: 700; font-size: 20px; padding: 14px 0; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-size: 26px; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.faq details p { color: #ddd; padding-bottom: 10px; }
.cta-band { text-align: center; }
.cta-band .wp-block-buttons { justify-content: center; }
.related-links ul { list-style: none; padding: 0 !important; display: flex; flex-wrap: wrap; gap: 10px 26px; }
.related-links h3 { margin-top: 0; }
html[dir=ltr] body { direction: ltr; text-align: left; }
html[dir=ltr] .split-cols h1, html[dir=ltr] .split-cols h2, html[dir=ltr] .split-cols h1.section-title { text-align: left; }
html[dir=ltr] .split-cols li::before { margin-left: 0; margin-right: 10px; }
html[dir=ltr] .legal ul { padding-right: 0; padding-left: 1.2em; }
html[dir=ltr] .a11y-panel button, html[dir=ltr] .a11y-panel a { text-align: left; }
html[dir=ltr] .site-footer .contact-list svg { margin-left: 0; margin-right: 8px; }
html[dir=ltr] .skip-link:focus { right: auto; left: 1rem; }
