:root {
  --primary-color: #004a7c; /* Deep, trustworthy navy blue */
  --secondary-color: #f1f7fc; /* A very light, clean blue-grey */
  --accent-color: #00a896; /* A vibrant, positive teal */
  --text-color: #212529;
  --light-text-color: #ffffff;
  --grey-color: #5a646e;
  --bg-color: #ffffff;
}

/* --- Global Styles & Typography --- */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  scroll-behavior: smooth;
}
body {
  font-family: "Assistant", "Arial", sans-serif;
  line-height: 1.7;
  color: var(--text-color);
  background-color: var(--bg-color);
  text-align: right;
}

/* Specific override for #contact */
#contact {
  text-align: left; /* this section aligns left */
}

#contact2 {
  text-align: left; /* this section aligns left */
}

.container {
  max-width: 1140px;
  margin: auto;
  padding: 0 20px;
}
h1,
h2,
h3 {
  line-height: 1.3;
  margin-bottom: 20px;
  font-weight: 700;
}
h1 {
  font-size: 3rem;
  color: var(--primary-color);
}
h2 {
  font-size: 2.5rem;
  color: var(--primary-color);
  text-align: center;
}
h3 {
  font-size: 1.4rem;
  color: var(--primary-color);
}
p {
  margin-bottom: 15px;
  color: var(--grey-color);
}
.section {
  padding: 100px 0;
}
.section-subtitle {
  text-align: center;
  max-width: 700px;
  margin: -10px auto 60px auto;
  font-size: 1.1rem;
}

/* --- Header & Navigation --- */
.main-header {
  background: var(--bg-color);
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
}
.main-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.logo {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--primary-color);
  text-decoration: none;
}
.main-nav a {
  font-weight: 600;
  color: var(--text-color);
  text-decoration: none;
  margin-right: 30px;
  transition: color 0.3s;
}
.main-nav a:hover {
  color: var(--accent-color);
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 50px;
  font-weight: 700;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  letter-spacing: 0.5px;
  text-decoration: none;
}
.btn-primary {
  background: var(--accent-color);
  color: var(--light-text-color);
  border-color: var(--accent-color);
}
.btn-primary:hover {
  background: transparent;
  color: var(--accent-color);
}

/* --- 1. HERO SECTION (The Hook) --- */
.hero {
  padding: 60px 0;
  background: var(--secondary-color);
}
.hero-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}
.hero-text {
  flex: 1.2;
}
.hero-text .sub-headline {
  font-size: 1.2rem;
  margin-bottom: 30px;
  color: var(--text-color);
}
.hero-image {
  flex: 1;
  text-align: center;
}
.hero-image img {
  max-width: 100%;
  height: auto;
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0, 74, 124, 0.2);
}

/* --- STEP 2: ELEVATED TRUST & SOCIAL PROOF --- */
#trust-bar {
  padding: 40px 0;
  background-color: var(--bg-color);
}
.trust-container {
  text-align: center;
}
.trust-container h3 {
  font-size: 1.1rem;
  color: var(--grey-color);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 25px;
}
.trust-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 50px;
  filter: grayscale(1);
  opacity: 0.7;
}
.trust-logos i {
  font-size: 2rem;
  color: var(--primary-color);
}
.trust-logos span {
  font-weight: 600;
}

/* --- 2. SPECIALIZATIONS SECTION (The Proof) --- */
/* --- Base & Mobile Styles (Mostly Unchanged) --- */
.specializations-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* --- From your modern-style.css or similar --- */

/* The container that defines the final size in your layout */
.video-box {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: 10px;
  overflow: hidden; /* This is crucial to hide the oversized iframe */
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  background-color: #e0f0ff;
  margin-bottom: 20px;
}

/* This new wrapper does the scaling trick */
.iframe-scaler {
  width: 200%;
  height: 200%;
  transform: scale(0.5);
  transform-origin: top left;
}

.iframe-scaler iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* --- Desktop Layout (The Fix) --- */
@media (min-width: 1024px) {
  .video-box {
    /* These rules remain from your original code */
    margin-left: 140px;
    width: 300px;
    aspect-ratio: 9/16;
    margin-bottom: 0;
    position: sticky;
    top: 20px;
  }

  /* The rest of your desktop styles remain the same... */
}

/* Mobile: Flip the order */
@media (max-width: 1024px) {
  .navbar-nav {
    flex-direction: column-reverse; /* reverse order */
  }
}

.icon-svg {
  width: auto; /* הגודל של האייקון */
  height: 41px; /* שומר על פרופורציות */
  display: block;
  text-align: left; /* מרכז את האייקון ומוסיף רווח מתחת */
}

.video-box iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Swiper styles for mobile */
.swiper {
  width: 100%;
  padding-top: 10px;
  padding-bottom: 40px; /* Make space for pagination */
  overflow: hidden; /* Keep this for mobile */
}

.spec-card {
  background: var(--bg-color, #fff);
  border-radius: 10px;
  border: 1px solid #e0f0ff;
  padding: 20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  width: 80%; /* Width for the mobile slider view */
  box-sizing: border-box;
}

/* Style for the active slide on mobile ONLY */
.swiper-slide-active {
  transform: scale(1.05);
  box-shadow: 0 15px 35px rgba(0, 74, 124, 0.15);
}

.swiper-pagination {
  position: static;
  margin-top: 20px;
}

.swiper-pagination-bullet {
  background: #ccc;
  opacity: 1;
}

.swiper-pagination-bullet-active {
  background: var(--accent-color, #004a7c);
}

/* --- Desktop Layout (The Fix) --- */
@media (min-width: 1024px) {
  .specializations-wrapper {
    display: grid;
    /* First column for video, second for the cards */
    grid-template-columns: minmax(400px, 1fr) 1fr;
    align-items: flex-start; /* Aligns items to the top of their cell */
    gap: 40px;
  }

  .video-box {
    width: 100%;
    margin-left: 140px;
    width: 300px;
    aspect-ratio: 9/16;
    margin-bottom: 0; /* Remove mobile margin */
    position: sticky; /* Optional: Makes video stick while scrolling */
    top: 20px;
  }

  /* Reset Swiper container styles for the grid */
  .swiper {
    margin-left: auto;
    padding: 0;
    overflow: visible; /* Allows hover shadows to be seen */
  }

  /* This is key: Turn the swiper-wrapper into a CSS Grid */
  .swiper-wrapper {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  /* Reset individual card styles for desktop */
  .spec-card,
  .swiper-slide {
    width: 100% !important; /* Ensure card fills the grid cell */
    transform: none !important; /* Remove any leftover transform from Swiper */
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08); /* A consistent, subtle shadow */
  }

  /* Add a clean hover effect for desktop */
  .spec-card:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 10px 25px rgba(0, 74, 124, 0.15) !important;
  }

  /* Hide mobile-only pagination on desktop */
  .swiper-pagination {
    display: none;
  }
}

/* --- Card Content (Unchanged) --- */
.spec-card i {
  font-size: 2.5rem;
  color: var(--accent-color, #004a7c);
  margin-bottom: 20px;
}
.spec-card ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.spec-card ul li {
  padding-right: 20px;
  position: relative;
  margin-bottom: 8px;
  font-size: 0.95rem;
}
.spec-card ul li::before {
  content: "\f00c";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  color: var(--accent-color, #004a7c);
  position: absolute;
  right: 0;
  top: 2px;
}

/* --- 3. THE "YOUR JOURNEY" SECTION (Builds Trust & Reduces Anxiety) --- */
.journey-section {
  background: var(--secondary-color);
}
.journey-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
}
.journey-step {
  text-align: center;
}
.step-number {
  font-size: 3rem;
  font-weight: 700;
  color: var(--accent-color);
  opacity: 0.3;
  line-height: 1;
}
.journey-step h3 {
  margin-top: -10px;
}

/* --- 4. ABOUT SECTION (Personal Connection) --- */
.about-wrapper {
  display: flex;
  align-items: center;
  gap: 60px;
}
.about-image img {
  width: 100%;
  border-radius: 10px;
}
.about-text .highlight {
  color: var(--primary-color);
  font-weight: 700;
}

/* --- 5. TESTIMONIALS SECTION (Social Proof) --- */
.testimonials-section {
  background: var(--secondary-color);
}
.testimonial-card {
  background: var(--bg-color);
  padding: 40px;
  border-radius: 10px;
  border-right: 5px solid var(--accent-color);
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.05);
}
.testimonial-card blockquote {
  font-size: 1.1rem;
  font-style: italic;
  border: none;
  padding: 0;
  margin-bottom: 20px;
}
.author-info {
  display: flex;
  align-items: center;
}
.author-info img {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  margin-left: 15px;
}
.author-name {
  font-weight: 700;
}

/* --- 6. FINAL CTA SECTION (The Ultimate Action) --- */
.final-cta {
  background: var(--primary-color);
  color: var(--light-text-color);
  padding: 80px 40px;
  border-radius: 20px;
  text-align: center;
}
.final-cta h2 {
  color: var(--light-text-color);
}
.final-cta p {
  color: #cde4f5;
  max-width: 600px;
  margin: 0 auto 30px auto;
}
.final-cta .btn {
  background: #fff;
  color: var(--primary-color);
  border-color: #fff;
}
.final-cta .btn:hover {
  background: transparent;
  color: #fff;
}

/* --- 7. FOOTER SECTION (Clear Navigation) --- */
.main-footer {
  padding: 60px 0 20px 0;
  background-color: #1a3a53;
  color: #a9b4c2;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 30px;
  margin-bottom: 40px;
}
.footer-col h4 {
  color: var(--light-text-color);
}
.footer-col ul {
  list-style: none;
}
.footer-col a {
  color: #a9b4c2;
  text-decoration: none;
  transition: color 0.3s;
}
.footer-col a:hover {
  color: var(--light-text-color);
}
.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid #3a5772;
}

/* --- Responsive Design --- */
@media (max-width: 992px) {
  .about-wrapper {
    flex-direction: column;
  }
}
@media (max-width: 768px) {
  h1 {
    font-size: 2.4rem;
  }
  h2 {
    font-size: 2rem;
  }
  .section {
    padding: 60px 0;
  }
  .trust-logos {
    flex-wrap: wrap;
    gap: 30px;
  }
  .main-header .container {
    flex-direction: column;
    gap: 15px;
  }
  .hero-wrapper {
    flex-direction: column-reverse;
    text-align: center;
  }
  .hero-text {
    margin-top: 30px;
  }
}

/* This goes in the Custom CSS area of the HTML block */

@media screen and (min-width: 768px) {
  .yt-wrapper {
    overflow: hidden;
    max-width: 100%;
  }

  .yt-frame-container {
    position: relative;
    padding-bottom: 56.25%;
    padding-top: 25px;
    width: 300%;
    left: -100%;
  }

  .yt-frame-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
  }
}

@media screen and (max-width: 767px) {
  .yt-frame-container iframe {
    aspect-ratio: 16/9;
    pointer-events: none;
  }
}
