/* ===========================================================================
   Edim marketing site — shared styles
   Palette: navy #1e3a5f · gold #c4a052 · white
   Type:    Cormorant Garamond (display) · Source Sans 3 (body)
   =========================================================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Source Sans 3', sans-serif;
  background: #1e3a5f;
  color: white;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; }

/* ---- Top navigation ------------------------------------------------------ */
.site-nav {
  width: 100%;
  border-bottom: 1px solid rgba(196, 160, 82, 0.18);
}

.nav-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 18px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-logo {
  display: flex;
  align-items: baseline;
  gap: 10px;
  text-decoration: none;
}

.nav-logo-en {
  font-family: 'Cormorant Garamond', serif;
  font-size: 26px;
  font-weight: 500;
  letter-spacing: 4px;
  color: white;
}

.nav-logo-he {
  font-family: 'Times New Roman', serif;
  font-size: 15px;
  color: #c4a052;
  direction: rtl;
}

.nav-links {
  display: flex;
  gap: 28px;
}

.nav-links a {
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
  text-decoration: none;
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.nav-links a:hover { color: rgba(255, 255, 255, 0.95); }

.nav-links a.active {
  color: #c4a052;
  border-bottom-color: rgba(196, 160, 82, 0.6);
}

/* ---- Main layout --------------------------------------------------------- */
.page-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 56px 20px 40px;
}

.container {
  width: 100%;
  max-width: 900px;
  text-align: center;
}

.page-heading {
  font-family: 'Cormorant Garamond', serif;
  font-size: 34px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 8px;
}

.page-subtitle {
  font-size: 15px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 40px;
}

.divider {
  width: 60px;
  height: 1px;
  background: #c4a052;
  margin: 0 auto 32px auto;
}

/* ---- Home hero ----------------------------------------------------------- */
.logo {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 16px;
  margin-bottom: 24px;
}

.logo-english {
  font-family: 'Cormorant Garamond', serif;
  font-size: 72px;
  font-weight: 500;
  letter-spacing: 8px;
  color: white;
}

.logo-hebrew {
  font-family: 'Times New Roman', serif;
  font-size: 36px;
  color: #c4a052;
  direction: rtl;
}

.tagline {
  font-family: 'Cormorant Garamond', serif;
  font-size: 26px;
  font-style: italic;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.6;
  margin-bottom: 28px;
}

.subtitle {
  font-size: 15px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.55);
  letter-spacing: 1px;
  margin-bottom: 28px;
}

.badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 300;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #c4a052;
  border: 1px solid rgba(196, 160, 82, 0.4);
  border-radius: 999px;
  padding: 6px 18px;
  margin-bottom: 40px;
}

.contact {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.6);
}

.contact a { color: #c4a052; text-decoration: none; }
.contact a:hover { text-decoration: underline; }

/* ---- Video --------------------------------------------------------------- */
/* Break out of the 900px content column so the video can be larger/readable. */
.video-section {
  width: min(1140px, 90vw);
  margin: 24px 0;
  margin-left: 50%;
  transform: translateX(-50%);
}

.video-frame {
  position: relative;
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(196, 160, 82, 0.3);
  background: rgba(0, 0, 0, 0.25);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.preview-video { width: 100%; height: 100%; object-fit: cover; display: block; }

.video-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  color: rgba(255, 255, 255, 0.5);
}

.video-play {
  width: 56px; height: 56px;
  border: 1px solid #c4a052;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}

.video-play svg { width: 20px; height: 20px; fill: #c4a052; margin-left: 3px; }

.video-placeholder span {
  font-size: 12px; font-weight: 300; letter-spacing: 2px; text-transform: uppercase;
}

/* ---- Home doorways (entry points to deeper pages) ------------------------ */
.doorways {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 8px;
}

.doorway {
  display: block;
  text-align: left;
  text-decoration: none;
  padding: 26px 28px;
  border: 1px solid rgba(196, 160, 82, 0.25);
  background: rgba(0, 0, 0, 0.12);
  transition: border-color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.doorway:hover {
  border-color: rgba(196, 160, 82, 0.7);
  background: rgba(0, 0, 0, 0.22);
  transform: translateY(-2px);
}

.doorway-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 22px;
  color: rgba(255, 255, 255, 0.92);
  margin-bottom: 6px;
}

.doorway-desc {
  font-size: 13px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.5;
}

.doorway-more {
  display: inline-block;
  margin-top: 14px;
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #c4a052;
}

/* ---- Gallery ------------------------------------------------------------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.gallery-item { display: flex; flex-direction: column; cursor: pointer; }

.gallery-thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid rgba(196, 160, 82, 0.2);
  transition: border-color 0.3s ease;
}

.gallery-item:hover .gallery-thumb { border-color: rgba(196, 160, 82, 0.7); }

.gallery-thumb img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
  transition: transform 0.4s ease, opacity 0.3s ease;
  opacity: 0.85;
}

.gallery-item:hover .gallery-thumb img { transform: scale(1.04); opacity: 1; }

.gallery-thumb .overlay {
  position: absolute; inset: 0;
  background: rgba(30, 58, 95, 0.3);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity 0.3s ease; pointer-events: none;
}

.gallery-item:hover .overlay { opacity: 1; }

.overlay-icon {
  width: 36px; height: 36px;
  border: 1px solid #c4a052; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}

.overlay-icon svg { width: 16px; height: 16px; fill: #c4a052; }

.gallery-caption {
  font-size: 12px; font-weight: 300;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  text-align: center; padding: 8px 4px 0;
  transition: color 0.3s ease;
}

.gallery-item:hover .gallery-caption { color: rgba(196, 160, 82, 0.8); }

/* ---- PDF cards (For Educators) ------------------------------------------- */
.pdf-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  text-align: left;
}

.pdf-card {
  display: block;
  text-decoration: none;
  transition: transform 0.25s ease;
}

.pdf-card:hover { transform: translateY(-3px); }

.pdf-thumb {
  position: relative;
  aspect-ratio: 8.5 / 11;
  overflow: hidden;
  border: 1px solid rgba(196, 160, 82, 0.25);
  background: #fff;
  transition: border-color 0.3s ease;
}

.pdf-card:hover .pdf-thumb { border-color: rgba(196, 160, 82, 0.75); }

.pdf-thumb img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top; display: block;
}

.pdf-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 21px;
  color: rgba(255, 255, 255, 0.92);
  margin: 16px 0 6px;
}

.pdf-desc {
  font-size: 13px;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.5;
}

.pdf-link {
  display: block;
  margin-top: 14px;
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #c4a052;
}

.pdf-card:hover .pdf-link { text-decoration: underline; }

/* ---- Signup form --------------------------------------------------------- */
.form-section { margin-top: 64px; width: 100%; }

.form-section h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 24px; font-weight: 400;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 8px;
}

.form-section p {
  font-size: 14px; color: rgba(255, 255, 255, 0.5);
  margin-bottom: 24px;
}

/* ---- Footer -------------------------------------------------------------- */
.site-footer {
  width: 100%;
  border-top: 1px solid rgba(196, 160, 82, 0.18);
  margin-top: 40px;
}

.footer-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-brand {
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px; letter-spacing: 3px; color: rgba(255, 255, 255, 0.8);
}

.footer-note {
  font-size: 12px; font-weight: 300; letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.4);
}

.footer-inner .contact { font-size: 13px; }

/* ---- Lightbox ------------------------------------------------------------ */
.lightbox {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(10, 22, 40, 0.96);
  align-items: center; justify-content: center; padding: 20px;
}
.lightbox.active { display: flex; }

.lightbox-inner {
  max-width: 1100px; width: 100%;
  display: flex; flex-direction: column; align-items: center; gap: 16px;
}

.lightbox-img-wrap { width: 100%; display: flex; align-items: center; justify-content: center; }

.lightbox img {
  max-width: 100%; max-height: 75vh; object-fit: contain; display: block;
  border: 1px solid rgba(196, 160, 82, 0.25);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);
}

.lightbox-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px; font-weight: 400; color: rgba(255, 255, 255, 0.75); letter-spacing: 1px;
}

.lightbox-nav { display: flex; align-items: center; gap: 24px; }

.lightbox-btn {
  background: none; border: 1px solid rgba(196, 160, 82, 0.4); color: #c4a052;
  width: 40px; height: 40px; border-radius: 50%; font-size: 18px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: border-color 0.2s, background 0.2s;
}
.lightbox-btn:hover { border-color: #c4a052; background: rgba(196, 160, 82, 0.1); }

.lightbox-counter {
  font-size: 13px; font-weight: 300; color: rgba(255, 255, 255, 0.4);
  letter-spacing: 2px; min-width: 60px; text-align: center;
}

.lightbox-close {
  position: fixed; top: 20px; right: 24px;
  background: none; border: 1px solid rgba(196, 160, 82, 0.4); color: #c4a052;
  width: 40px; height: 40px; border-radius: 50%; font-size: 20px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: border-color 0.2s, background 0.2s;
}
.lightbox-close:hover { border-color: #c4a052; background: rgba(196, 160, 82, 0.1); }

/* ---- PDF lightbox (centered modal, rendered with PDF.js) ----------------- */
.pdf-lightbox {
  display: none;
  position: fixed; inset: 0; z-index: 1100;
  background: rgba(10, 22, 40, 0.96);
  align-items: center; justify-content: center;
  padding: 24px;
}
.pdf-lightbox.active { display: flex; }

.pdf-lb-dialog {
  width: 100%; max-width: 860px; max-height: 88vh;
  display: flex; flex-direction: column;
  background: #16283d;
  border: 1px solid rgba(196, 160, 82, 0.25);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.65);
}

.pdf-lb-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(196, 160, 82, 0.2);
}

.pdf-lb-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px; color: rgba(255, 255, 255, 0.85); letter-spacing: 1px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.pdf-lb-actions { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }

.pdf-lb-download {
  font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase;
  color: #c4a052; text-decoration: none;
  border: 1px solid rgba(196, 160, 82, 0.4);
  padding: 7px 15px; border-radius: 999px;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.pdf-lb-download:hover { background: rgba(196, 160, 82, 0.1); border-color: #c4a052; }

.pdf-lb-close {
  background: none; border: 1px solid rgba(196, 160, 82, 0.4); color: #c4a052;
  width: 36px; height: 36px; border-radius: 50%; font-size: 19px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.pdf-lb-close:hover { background: rgba(196, 160, 82, 0.1); border-color: #c4a052; }

.pdf-lb-scroll {
  flex: 1; overflow-y: auto;
  padding: 20px; background: rgba(0, 0, 0, 0.28);
  scrollbar-width: thin;                                  /* Firefox */
  scrollbar-color: rgba(196, 160, 82, 0.4) transparent;  /* Firefox: thumb / track */
}
.pdf-lb-scroll::-webkit-scrollbar { width: 8px; }
.pdf-lb-scroll::-webkit-scrollbar-track { background: transparent; }
.pdf-lb-scroll::-webkit-scrollbar-thumb {
  background: rgba(196, 160, 82, 0.35);
  border-radius: 999px;
}
.pdf-lb-scroll::-webkit-scrollbar-thumb:hover { background: rgba(196, 160, 82, 0.6); }

.pdf-lb-pages { display: flex; flex-direction: column; align-items: center; gap: 16px; }

.pdf-lb-page {
  width: 100%; max-width: 780px; height: auto; display: block;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
  background: #fff;
}

.pdf-lb-status {
  padding: 28px 12px; text-align: center;
  font-size: 14px; font-weight: 300; letter-spacing: 0.5px; line-height: 1.5;
  color: rgba(255, 255, 255, 0.7);
}

/* ---- Responsive ---------------------------------------------------------- */
@media (max-width: 760px) {
  .nav-inner { flex-direction: column; gap: 14px; padding: 16px 20px; }
  .nav-links { gap: 20px; }
  .logo-english { font-size: 48px; letter-spacing: 4px; }
  .logo-hebrew  { font-size: 24px; }
  .tagline      { font-size: 21px; }
  .doorways     { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .pdf-grid     { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .footer-inner { flex-direction: column; text-align: center; }
  .pdf-lb-bar   { padding: 12px 16px; }
  .pdf-lb-title { font-size: 16px; }
  .pdf-lb-download { padding: 6px 12px; }
}

@media (max-width: 400px) {
  .gallery-grid { grid-template-columns: 1fr; }
  .pdf-grid     { grid-template-columns: 1fr; max-width: 320px; margin: 0 auto; }
}
