:root {
  --ink: #111111;
  --text: #333333;
  --muted: #444444;
  --line: #EBEBEB;
  --light: #F6F6F4;
  --field: #7A7A75;   /* input borders – 4.3:1 on white (WCAG 1.4.11 needs 3:1) */
  --accent: #E8890C; /* sun orange – decorative only (icons/logo), not for text */
  --focus: #B35F00;  /* darker orange for focus rings – ≥4:1 on white, light gray and ink */
  --whatsapp: #1F8F4E; /* darker WhatsApp green – white icon 4.1:1 (brand #25D366 is only 2:1) */
  --radius: 16px;
  --btn-radius: 10px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
main:focus { outline: none; }

.skip-link {
  position: absolute; inset-inline-start: 16px; top: -100px; z-index: 100;
  background: var(--ink); color: #FFFFFF; padding: 12px 20px; border-radius: var(--btn-radius);
  font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 12px; color: #FFFFFF; }
body {
  margin: 0;
  font-family: 'Heebo', Arial, sans-serif;
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--ink);
  background: #FFFFFF;
}
img { max-width: 100%; display: block; }
a { color: var(--ink); }
a:hover { color: var(--muted); }
h1, h2, h3, p { margin: 0; }

.container { max-width: 1120px; margin: 0 auto; padding-inline: 32px; }
.muted { color: var(--muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 54px; padding: 12px 28px;
  border-radius: var(--btn-radius); border: 2px solid var(--ink);
  font-family: inherit; font-size: 1.125rem;
  text-decoration: none; cursor: pointer;
}
.btn-dark { background: var(--ink); color: #FFFFFF; }
.btn-dark:hover { background: #333333; color: #FFFFFF; }
.btn-outline { background: #FFFFFF; color: var(--ink); }
.btn-outline:hover { background: var(--light); color: var(--ink); }
.btn-light { background: #FFFFFF; color: var(--ink); border-color: #FFFFFF; }
.btn-sm { min-height: 48px; padding: 10px 20px; font-size: 1.0625rem; }
.btn-xs { min-height: 48px; padding: 0 16px; font-size: 1rem; border-width: 1.5px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); }
.header-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; padding-block: 16px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.sun { color: var(--accent); flex: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-name { font-size: 1.375rem; font-weight: 800; }
.brand-name .suffix { font-weight: 400; font-size: 0.7em; } /* "בע״מ" thinner, like the logo */
.brand-sub { font-size: 0.875rem; color: #555555; }

/* Hero */
.hero { display: flex; flex-wrap: wrap; align-items: center; gap: 40px; padding-block: 56px 40px; }
.hero-text { flex: 1 1 420px; display: flex; flex-direction: column; gap: 22px; }
.hero h1 { font-size: 3.25rem; line-height: 1.12; font-weight: 800; letter-spacing: -0.5px; }
.lead { font-size: 1.25rem; color: var(--text); max-width: 460px; }
.hero-media { flex: 1 1 440px; display: flex; justify-content: center; }
.hero-media img { width: 100%; max-width: 500px; height: auto; aspect-ratio: 6 / 5; object-fit: contain; }

/* Benefits */
.benefits { display: flex; flex-wrap: wrap; gap: 32px; padding-block: 40px 72px; border-top: 1px solid var(--line); }
.benefits-wrap { padding-top: 16px; }
.benefit { flex: 1 1 240px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; }
.benefit .icon { color: var(--accent); }
.benefit h2 { font-size: 1.3125rem; font-weight: 700; }
.benefit p { color: var(--muted); }

/* Sections */
.section { display: flex; flex-direction: column; gap: 36px; padding-block: 72px; }
.section-head { display: flex; flex-direction: column; gap: 10px; max-width: 680px; }
.section-title { font-size: 2.375rem; font-weight: 800; line-height: 1.2; }
.section-sub { font-size: 1.1875rem; color: var(--text); }
.band-light { background: var(--light); }
.band-dark { background: var(--ink); color: #FFFFFF; }

/* Product cards */
.cards { display: flex; flex-wrap: wrap; gap: 24px; }
.card { flex: 1 1 300px; background: #FFFFFF; border-radius: var(--radius); padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.card img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: contain; }
.card h3 { font-size: 1.5rem; font-weight: 800; }
.card p { color: var(--muted); }
.sizes { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.sizes-label { font-size: 1rem; font-weight: 500; color: #555555; }
/* the number boxes stay together: if the row is too narrow, the whole group moves under the label */
.size-list { display: flex; gap: 8px; }
.size { font-size: 1.1875rem; font-weight: 800; border: 1.5px solid var(--ink); border-radius: var(--btn-radius); min-width: 52px; padding: 4px 12px; text-align: center; }

/* Branding figures */
.figures { display: flex; flex-wrap: wrap; gap: 24px; }
.figures figure { flex: 1 1 380px; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.figure-frame { background: var(--light); border-radius: var(--radius); padding: 24px; }
.figure-frame img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: contain; }
.figures figcaption { display: flex; flex-direction: column; gap: 2px; }
/* Flip gallery (gallery.js) – one photo at a time; swipe on phones, arrows everywhere; never moves by itself */
.gallery { position: relative; }
.gallery-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.gallery-track::-webkit-scrollbar { display: none; }
.gallery-track:focus-visible { outline-offset: 6px; }
.gallery-track img { flex: 0 0 100%; scroll-snap-align: start; min-width: 0; }
.gallery-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 48px; height: 48px; border-radius: 999px; border: 2px solid var(--ink);
  background: #FFFFFF; color: var(--ink); cursor: pointer; padding: 0;
  display: flex; align-items: center; justify-content: center;
}
.gallery-arrow:hover { background: var(--light); }
.gallery-prev { right: 10px; }  /* RTL: back = right, forward = left */
.gallery-next { left: 10px; }
.gallery-dots { position: absolute; bottom: 12px; left: 0; right: 0; display: flex; justify-content: center; gap: 8px; }
.gallery-dots span { width: 10px; height: 10px; border-radius: 999px; border: 1.5px solid var(--ink); background: #FFFFFF; }
.gallery-dots span.on { background: var(--ink); }
.figures figcaption strong { font-size: 1.3125rem; }
.figures figcaption span { color: var(--muted); }
/* Color buttons (products section) – each button is filled with its own color; colors.js swaps the card photos.
   Fills match the "mid" colors in tools/recolor.py. Labels: white ≥5:1 on black/blue/green, ink 6.7:1 on gray. */
/* white box under the product cards: colors first, then custom sizes (owner's order) */
.extras { background: #FFFFFF; border-radius: var(--radius); padding: 22px 24px; display: flex; flex-direction: column; gap: 12px; }
.color-picker { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.color-label { font-size: 1.1875rem; font-weight: 700; }
.color-buttons { display: flex; flex-wrap: wrap; gap: 12px; }
.color-btn {
  font-family: inherit; font-size: 1.0625rem; font-weight: 700;
  min-height: 48px; padding: 8px 20px; border-radius: var(--btn-radius);
  border: 2px solid var(--ink); color: #FFFFFF; cursor: pointer;
}
.color-btn[data-color="black"] { background: #1A1A1A; }
.color-btn[data-color="gray"]  { background: #9A9A9A; color: var(--ink); }
.color-btn[data-color="blue"]  { background: #2F5DA8; }
.color-btn[data-color="green"] { background: #2F7A43; }
.color-btn[aria-pressed="true"] { box-shadow: 0 0 0 3px #FFFFFF, 0 0 0 6px var(--ink); }
.color-btn:focus-visible { outline-offset: 8px; }
.color-note { color: var(--muted); }
.custom-size { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 4px; font-size: 1.1875rem; }
.custom-size a { font-weight: 700; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Bulk band */
.bulk { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding-block: 56px; }
.bulk h2 { font-size: 2.125rem; font-weight: 800; }
.bulk p { font-size: 1.25rem; color: #DDDDDD; margin-top: 6px; }

/* About */
.about-wrap { padding-top: 72px; }
.about { display: flex; flex-wrap: wrap; align-items: center; gap: 20px 32px; padding-bottom: 56px; border-bottom: 1px solid var(--line); }
.about p { flex: 1 1 500px; font-size: 1.25rem; line-height: 1.7; color: var(--text); }

/* Contact */
.contact { display: flex; flex-wrap: wrap; gap: 48px; padding-block: 72px 88px; }
.contact-info { flex: 1 1 380px; display: flex; flex-direction: column; gap: 20px; }
.person { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; border: 1.5px solid var(--line); border-radius: 14px; padding: 16px 20px; }
.person-text { display: flex; flex-direction: column; line-height: 1.3; }
.person-name { font-size: 1.125rem; font-weight: 700; }
.person-phone { font-size: 1.5rem; font-weight: 700; text-align: right; }
.person-actions { display: flex; gap: 8px; }

.lead-form { flex: 1 1 420px; background: var(--light); border-radius: var(--radius); padding: 32px; display: flex; flex-direction: column; gap: 18px; align-self: flex-start; }
.lead-form label { display: flex; flex-direction: column; gap: 6px; font-size: 1.0625rem; font-weight: 500; }
.lead-form .optional { font-weight: 400; color: var(--muted); }
.contact-info, .lead-form { min-width: 0; }
.lead-form select { width: 100%; min-width: 0; text-overflow: ellipsis; }
.lead-form input, .lead-form select {
  font-family: inherit; font-size: 1.125rem;
  min-height: 52px; padding: 12px 14px;
  border: 1.5px solid var(--field); border-radius: var(--btn-radius); background: #FFFFFF; color: var(--ink);
}
.lead-form input:focus, .lead-form select:focus { outline: 3px solid var(--focus); outline-offset: 2px; }
.lead-form .btn { min-height: 56px; font-size: 1.1875rem; align-self: flex-start; }
.lead-form input:is([type="tel"], [type="email"]) { text-align: right; }
.lead-form input[aria-invalid="true"] { border-color: #B42318; }
.field-error { color: #B42318; font-size: 1.0625rem; font-weight: 500; }
.field-error:empty { display: none; }
.form-status { gap: 12px; }
.form-status h3 { font-size: 1.625rem; font-weight: 800; }
.form-status p { font-size: 1.1875rem; }
.form-status a { font-weight: 700; white-space: nowrap; }
.form-status a.btn { color: #FFFFFF; }
.form-status-body { display: flex; flex-direction: column; gap: 12px; }
.lead-form .btn:disabled { opacity: 1; background: #444444; border-color: #444444; cursor: progress; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; padding: 0; }
.form-status:focus { outline: none; }
.contact-info a[href^="mailto"] { display: inline-block; padding-block: 10px; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding-block: 28px; font-size: 1.0625rem; color: var(--muted); }
.footer-row a { color: var(--ink); font-weight: 500; display: inline-block; padding-block: 12px; }

/* Floating buttons – stay in the bottom corners while scrolling.
   WhatsApp on the RIGHT, accessibility menu on the LEFT (physical sides, as the owner asked). */
.wa-float, .a11y-toggle {
  position: fixed; z-index: 50;
  bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  width: 64px; height: 64px; border-radius: 999px; border: 0; padding: 0; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}
.wa-float { right: 20px; background: var(--whatsapp); }
.wa-float:hover { background: #18773F; color: #FFFFFF; }
.a11y-toggle { left: 20px; background: var(--ink); }
.a11y-toggle:hover { background: #333333; }
@media print { .wa-float, .a11y-toggle, .a11y-panel, .skip-link { display: none; } }

/* Accessibility panel (a11y.js) */
.a11y-panel {
  position: fixed; z-index: 60; left: 20px; bottom: calc(96px + env(safe-area-inset-bottom, 0px));
  width: min(320px, calc(100vw - 40px)); max-height: calc(100vh - 120px); overflow-y: auto;
  background: #FFFFFF; color: var(--ink); border: 1.5px solid var(--ink); border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  padding: 20px; display: flex; flex-direction: column; align-items: flex-start; gap: 12px;
  font-size: 1.125rem;
}
.a11y-head { align-self: stretch; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.a11y-head h2 { font-size: 1.5rem; font-weight: 800; }
.a11y-head h2:focus { outline: none; }
.a11y-group { display: flex; flex-direction: column; gap: 8px; padding-bottom: 4px; }
.a11y-buttons { display: flex; gap: 8px; }
.a11y-btn, .a11y-close {
  font-family: inherit; font-size: 1.0625rem;
  min-height: 48px; padding: 10px 18px; border-radius: var(--btn-radius);
  border: 2px solid var(--ink); background: #FFFFFF; color: var(--ink); cursor: pointer;
}
.a11y-btn[aria-pressed="true"] { background: var(--ink); color: #FFFFFF; }
.a11y-btn:disabled { border-color: #8A8A85; color: #6B6B66; cursor: default; }
.a11y-close { border-width: 1.5px; }
.a11y-statement { font-weight: 500; display: inline-block; padding-block: 10px; }

/* Text size levels – every font-size is in rem, so scaling the root enlarges all text and it re-wraps */
html[data-a11y-text="1"] { font-size: 115%; }
html[data-a11y-text="2"] { font-size: 130%; }
html:is([data-a11y-text="1"], [data-a11y-text="2"]) .header-row { flex-wrap: wrap; }

/* High contrast – pure black on white, every box outlined */
.a11y-contrast { --text: #000000; --muted: #000000; --line: #000000; --light: #FFFFFF; --field: #000000; }
.a11y-contrast body, .a11y-contrast .brand-sub, .a11y-contrast .sizes-label { color: #000000; }
.a11y-contrast .bulk p { color: #FFFFFF; }
.a11y-contrast :is(.card, .lead-form, .figure-frame, .extras) { border: 2px solid #000000; }

/* Highlight links – underline and outline every link and button-link */
.a11y-links main a, .a11y-links .site-header a, .a11y-links .site-footer a {
  text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px;
  outline: 2px solid var(--focus); outline-offset: 2px;
}

/* Simple text page (accessibility statement) */
.doc { max-width: 760px; padding-block: 56px 88px; display: flex; flex-direction: column; gap: 18px; }
.doc h1 { font-size: 2.5rem; font-weight: 800; line-height: 1.2; }
.doc h2 { font-size: 1.625rem; font-weight: 800; margin-top: 18px; }
.doc p, .doc li { color: var(--text); }
.doc ul { margin: 0; padding-inline-start: 24px; display: flex; flex-direction: column; gap: 6px; }
.doc .updated { color: var(--muted); font-size: 1.0625rem; }

/* Phones */
@media (max-width: 640px) {
  .container { padding-inline: 20px; }
  .hero { padding-block: 32px 24px; gap: 24px; }
  .hero h1 { font-size: 2.375rem; }
  .lead { font-size: 1.125rem; }
  .section-title { font-size: 1.875rem; }
  .bulk h2 { font-size: 1.75rem; }
  .lead-form { padding: 22px; }
  /* keep logo + phone button on one row */
  .header-row { flex-wrap: nowrap; gap: 10px; padding-block: 12px; }
  .brand { gap: 8px; }
  .brand .sun { width: 32px; height: 32px; }
  .brand-name { font-size: 1.25rem; }
  .header-row .btn-sm { padding: 8px 14px; font-size: 1rem; gap: 6px; white-space: nowrap; }
  /* hero buttons side by side (owner request) – slimmer padding so both fit from 360px wide;
     narrower screens or the larger accessibility text sizes wrap back to stacked */
  .hero .btn-row { gap: 8px; }
  .hero .btn-row .btn { padding-inline: 14px; font-size: 1.0625rem; gap: 6px; }
  .hero .btn-row .btn svg { width: 18px; height: 18px; }
  /* room under the footer so the floating WhatsApp button never hides its text */
  .site-footer { padding-bottom: 84px; }
  .doc h1 { font-size: 2rem; }
  .brand-name, .brand-sub { white-space: nowrap; }
  /* gallery: arrows move under the photo (beside the dots) so they don't cover the box on a narrow screen */
  .gallery { padding-bottom: 72px; }
  .gallery-arrow { top: auto; bottom: 14px; transform: none; }
  .gallery-prev { right: 16px; }
  .gallery-next { left: 16px; }
  .gallery-dots { bottom: 33px; }
  /* all four color buttons on one row from ~360px wide */
  .color-buttons { gap: 8px; }
  .color-btn { padding-inline: 14px; }
}
/* 360–374px phones (common Android): tighten the header so "תבואות שמש בע״מ" + phone button stay on one row */
@media (max-width: 374px) {
  .header-row { gap: 8px; }
  .brand { gap: 6px; }
  .brand .sun { width: 28px; height: 28px; }
  .brand-name { font-size: 1.125rem; }
  .header-row .btn-sm { padding-inline: 10px; gap: 4px; }
  .header-row .btn-sm svg { width: 16px; height: 16px; }
}
/* very narrow phones (≤ 370px): if it still doesn't fit, let the phone button drop below the logo */
@media (max-width: 370px) {
  .header-row { flex-wrap: wrap; }
}
