/* ===== s14 ===== */
@scope (.s14) {
:scope{
  --navy:#0e0d2c;
  --ink:#1d1d1b;
  --gold-bd:#ab8444;
  --font-body:"Assistant","Heebo",system-ui,sans-serif;
  --font-head:"Heebo","Assistant",sans-serif;
  --canvas-w:1920px;
  --h:383;
}
*,*::before,*::after{box-sizing:border-box;}
html,body{margin:0;padding:0;}
html{direction:rtl;}
body{direction:rtl;font-family:var(--font-body);color:var(--ink);background:#fff;-webkit-font-smoothing:antialiased;overflow-x:clip;}
h2,p{margin:0;padding:0;}

/* Scaled-stage helper (copied from base.css) */
.scaled{position:relative;width:100%;overflow:hidden;height:calc(100vw * var(--h) / 1920);}
.scaled > .stage{position:absolute;top:0;right:0;width:var(--canvas-w);height:calc(var(--h) * 1px);transform-origin:top right;transform:scale(calc(100vw / var(--canvas-w)));}

/* ===== Section ===== */
.yd514{background:#fff;}
.yd514 .yd-inner{position:absolute;top:0;left:312px;width:1299px;height:383px;}

.yd514__title{
  position:absolute;top:0;left:0;width:1299px;
  font-family:var(--font-head);font-weight:400;font-size:50px;line-height:60px;
  text-align:center;color:var(--navy);
}
.yd514__title b{font-weight:900;}

.yd514__lead{
  position:absolute;top:149px;left:245px;width:806px;
  font-family:var(--font-body);font-weight:400;font-size:20px;line-height:30px;
  text-align:center;color:var(--ink);
}

.yd514__cards{position:absolute;top:246px;left:0;width:1299px;height:137px;}
.yd514__card{
  position:absolute;top:0;width:302px;height:137px;
  /* Figma: horizontal gradient #f8f4ed (right) -> #fff (left); 2px gold rule on the RIGHT edge only */
  background:linear-gradient(to left,#f8f4ed 0%,#ffffff 100%);
  border:0;border-right:2px solid var(--gold-bd);
  display:flex;align-items:center;justify-content:flex-start;
  padding:14px 19px 14px 21px;
}
.yd514__card:nth-child(1){left:0;}
.yd514__card:nth-child(2){left:331px;}
.yd514__card:nth-child(3){left:663px;}
.yd514__card:nth-child(4){left:997px;}
.yd514__card p{
  font-family:var(--font-body);font-weight:400;font-size:19px;line-height:28px;
  text-align:right;color:var(--ink);width:100%;
}
.yd514__card p b{font-weight:700;}

/* ===== Tablet ===== */

/* ===== RESPONSIVE — tablet ≤1199 / mobile ≤767 (Figma mobile) ===== */
@media (max-width:1199px){
  .yd514.scaled{height:auto;overflow:visible}
  .yd514.scaled > .stage{position:static;width:100%;height:auto;transform:none}
  .yd514 .yd-inner{position:static;width:100%;max-width:720px;height:auto;margin:0 auto;padding:0 24px}
  .yd514__title{position:static;width:100%;font-size:34px;line-height:44px}
  .yd514__lead{position:static;width:100%;max-width:640px;margin:16px auto 0;font-size:18px;line-height:28px}
  /* Figma order = ירשתם ▸ שותף ▸ פרידה ▸ השקעה  (reverse of the desktop L→R order) */
  .yd514__cards{position:static;width:100%;height:auto;margin-top:26px;
    display:flex;flex-direction:column-reverse;gap:12px}
  .yd514__card{position:static;left:auto!important;width:100%;height:auto;min-height:0;
    padding:14px 18px;border:0;border-right:3px solid var(--gold-bd);
    background:linear-gradient(to left,#f6f0e5 0%,#ffffff 62%)}
  .yd514__card p{font-size:17px;line-height:27px}
}

/* tablet: two per row, keeping the Figma reading order */
@media (min-width:768px) and (max-width:1199px){
  .yd514__cards{display:grid;grid-template-columns:1fr 1fr;gap:14px}
  .yd514__card:nth-child(1){order:4}
  .yd514__card:nth-child(2){order:3}
  .yd514__card:nth-child(3){order:2}
  .yd514__card:nth-child(4){order:1}
}

@media (max-width:767px){
  .yd514 .yd-inner{padding:0 15px}
  .yd514__title{font-size:28px;line-height:38px}
  .yd514__lead{font-size:16px;line-height:28px;margin-top:14px}
  .yd514__cards{margin-top:24px;gap:12px}
  .yd514__card{padding:13px 16px}
  .yd514__card p{font-size:16px;line-height:28px}
}

/* ===== Figma mobile 5647:20493 — corrected type scale ===== */
@media (max-width:767px){
  .yd514__title{font-size:32px;line-height:38px;}
  .yd514__lead{font-size:18px;line-height:28px;}
  .yd514__card p{font-size:19px;line-height:28px;}
}
}
