/* Language home as a landing page. Loaded only by homes that carry pages.home.lp, after style.css (common + b).
   Uses the theme variables and logical properties only, so ar/ur mirror without separate rules. */
.lp { --lp-pad: clamp(2rem, 1.4rem + 2vw, 3.1rem); }
.lp h2 { margin: 0 0 1.1rem; font-size: clamp(1.45rem, 1.1rem + 1.3vw, 1.9rem); font-weight: 800; line-height: 1.35; color: var(--navy); }
/* a gold bar, then axis ticks: the one mark every section heading shares */
.lp h2::after { content: ""; display: block; inline-size: 128px; block-size: 4px; margin-block-start: .55rem; background: linear-gradient(var(--gold), var(--gold)) 0 0 / 48px 4px no-repeat, repeating-linear-gradient(90deg, #e6c777 0 2px, transparent 2px 8px) 60px 0 / 68px 4px no-repeat; border-radius: 4px; }
[dir="rtl"] .lp h2::after { background-position: 100% 0, 0 0; }
:where(.lp) p { margin: 0; }
:where(.lp) :is(ul, ol) { margin: 0; padding: 0; list-style: none; }
.lp a { overflow-wrap: anywhere; }

/* hero: small. Text and two buttons first, a modest picture beside (desktop) or under (phone) */
.lp-hero { background: radial-gradient(700px 300px at 85% 0%, rgba(242, 193, 78, .2), transparent 70%),
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 200' preserveAspectRatio='none'%3E%3Cpolyline fill='none' stroke='%23f2c14e' stroke-opacity='.34' stroke-width='2' vector-effect='non-scaling-stroke' points='0,100 80,120 150,90 230,130 310,80 400,120 480,95 560,135 650,85 740,125 830,90 920,120 1010,100 1100,115 1200,95'/%3E%3C/svg%3E") 0 100% / 100% 52px no-repeat,
  linear-gradient(rgba(255, 255, 255, .035) 1px, transparent 1px) 0 0 / 44px 44px,
  linear-gradient(90deg, rgba(255, 255, 255, .035) 1px, transparent 1px) 0 0 / 44px 44px, #0a2150; color: #fff; }
.lp-hero__in { display: grid; gap: 18px; align-items: center; padding-block: 22px 26px; }
.lp-hero h1 { margin: 0; font-size: clamp(1.7rem, 1.2rem + 2.2vw, 2.7rem); font-weight: 800; line-height: 1.28; text-wrap: balance; }
.lp-hero__sub { margin-block-start: .8rem; max-inline-size: 40em; font-size: 1.02rem; line-height: 1.7; color: #dbe5f8; }
.lp-hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-block-start: 1.3rem; }
.lp-btn { display: inline-flex; align-items: center; justify-content: center; min-block-size: 52px; padding-inline: 1.6rem; border-radius: 999px; font-weight: 800; line-height: 1.3; text-align: center; text-decoration: none; transition: transform .18s ease, filter .18s ease; }
.lp-btn::after { content: "\2192"; margin-inline-start: .55rem; }
[dir="rtl"] .lp-btn::after { content: "\2190"; }
.lp-btn--primary { background: var(--gold); color: var(--on-gold); box-shadow: 0 6px 16px rgba(0, 0, 0, .28); }
.lp-btn--ghost { border: 2px solid rgba(255, 255, 255, .7); color: #fff; }
.lp-btn:hover { transform: translateY(-1px); filter: brightness(1.06); }
.lp-hero :focus-visible { outline-color: var(--gold); }
.lp-hero__fig { position: relative; z-index: 2; margin: 0; overflow: hidden; border-radius: 12px; box-shadow: 0 0 0 2px var(--gold), 0 14px 34px rgba(0, 0, 0, .35); }
.lp-hero__img { display: block; inline-size: 100%; aspect-ratio: 1200 / 340; object-fit: cover; object-position: center 30%; filter: brightness(1.12) contrast(1.04); }
[dir="rtl"] .lp-hero__img { transform: scaleX(-1); }
@media (min-width: 45em) {
  .lp-hero__in { grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 36px; padding-block: 26px 28px; }
  .lp-hero--solo .lp-hero__in { grid-template-columns: minmax(0, 1fr); }
  .lp-hero__img { aspect-ratio: 1200 / 700; object-position: right center; }
  .lp-hero__fig { align-self: end; margin-block-end: -52px; }
  .lp-hero__in { padding-block-end: 22px; }
  .lp-notice p { max-inline-size: calc(100% - 40%); }
}

/* the one-line notice */
.lp-notice { background: #fff6e0; border-block: 1px solid #e6c777; color: #4a3500; }
.lp-notice .wrap { padding-block: 12px; }
.lp-notice p { font-size: .94rem; line-height: 1.65; }
.lp-notice a { color: #4a3500; font-weight: 700; }

.lp-intro { padding-block: 0 .4rem; }
.lp-intro .talk { margin-block: 1rem 0; }
.lp-intro .balloon__body p { padding: .7rem 1rem; font-size: .96rem; line-height: 1.6; }
@media (min-width: 64em) { .lp-intro .talk { flex-direction: row; align-items: flex-start; gap: 24px; } .lp-intro .balloon { flex: 1 1 0; inline-size: auto; } .lp-intro .balloon--kocchan { margin-inline-start: 0; } }

/* sections */
.lp-sec { padding-block: var(--lp-pad); }
.lp-sec--paths { padding-block-start: 1.6rem; padding-block-end: 1.4rem; }
.lp-sec--steps { padding-block-start: calc(var(--lp-pad) * .6); }
.lp-sec--tint { background: rgba(255, 255, 255, .62); border-block: 1px solid rgba(5, 25, 62, .08); }
.lp-sec--dark { background: #0a2150; color: #fff; }
.lp-sec--dark h2 { color: #fff; }
.lp-sec--dark :focus-visible { outline-color: var(--gold); }
.lp-more { margin-block-start: 1.2rem; }
/* links stay block/inline-block (not flex) so the space before an isolated Latin term survives */
.lp-more a, .lp-note + .lp-more a { display: inline-block; padding-block: .72rem; font-weight: 700; }
.lp-note { max-inline-size: 62ch; margin-block-start: 1.2rem; color: var(--muted); font-size: .96rem; line-height: 1.75; }

/* entry tiles: the whole tile is the link (stretched), the link text is the short label only */
.lp-paths { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
@media (min-width: 36em) { .lp-paths { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64em) { .lp-paths { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; } }
.lp-path { position: relative; padding: 18px 20px 20px; background: var(--card-bg); border: 1px solid var(--card-line); border-block-start: 4px solid var(--gold); border-radius: 12px; box-shadow: var(--card-shadow); transition: transform .18s ease, box-shadow .18s ease; }
.lp-path:hover { transform: translateY(-2px); box-shadow: 0 18px 40px rgba(5, 25, 62, .2); }
.lp-path:focus-within { outline: 3px solid var(--focus); outline-offset: 3px; }
.lp-path__link { display: block; padding-block: .6rem .1rem; font-size: 1.12rem; font-weight: 800; line-height: 1.35; color: var(--navy); text-decoration: none; }
.lp-path__link::before { content: ""; position: absolute; inset: 0; }
.lp-path__link::after { content: "\2192"; margin-inline-start: .5rem; color: var(--accent-ink); }
[dir="rtl"] .lp-path__link::after { content: "\2190"; }
.lp-path__link:focus-visible { outline: none; }
.lp-path p { margin-block-start: .15rem; font-size: .93rem; line-height: 1.65; color: var(--muted); }
/* a picture on the tile (the mascot in a different pose): full width across the top, never mirrored in RTL */
.lp-path:has(> .lp-path__img) { overflow: hidden; padding-block-start: 0; }
.lp-path__img { display: block; inline-size: calc(100% + 40px); block-size: auto; aspect-ratio: 4 / 3; max-inline-size: none; margin-inline: -20px; margin-block-end: .5rem; object-fit: cover; background: #0a1a3a; transition: transform .35s ease; }
.lp-path:hover .lp-path__img { transform: scale(1.04); }

/* three steps */
.lp-steps { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; counter-reset: none; }
@media (min-width: 56.25em) { .lp-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; } }
.lp-step { position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: start; padding: 18px; background: var(--card-bg); border: 1px solid var(--card-line); border-radius: 12px; box-shadow: var(--card-shadow); }
.lp-step__n { display: grid; place-items: center; inline-size: 44px; block-size: 44px; border-radius: 50%; background: var(--navy); color: var(--gold); font-weight: 800; font-size: 1.15rem; }
.lp-step p { font-size: 1rem; line-height: 1.7; }
.lp-step__n { box-shadow: 0 0 0 3px var(--gold); }
.lp-step:not(:last-child)::after { content: ""; position: absolute; z-index: 1; inset-inline-start: 38px; inset-block: 62px -32px; inline-size: 4px; border-radius: 4px; background: var(--gold); }
@media (min-width: 56.25em) {
  .lp-steps { position: relative; padding-block-start: 22px; }
  .lp-steps::before { content: ""; position: absolute; z-index: 1; inset-block-start: 20px; inset-inline-start: 40px; inline-size: calc(66.667% + 19px); block-size: 4px; border-radius: 4px; background: var(--gold); }
  .lp-step { grid-template-columns: minmax(0, 1fr); padding-block-start: 38px; }
  .lp-step__n { position: absolute; z-index: 2; inset-block-start: -22px; inset-inline-start: 18px; }
  .lp-step:not(:last-child)::after { content: none; }
}

/* the rebate figure above the steps: an order of events, drawn (decoration; the words are in the cards below) */
.lp-flow { margin-block: .2rem 1.1rem; }
.lp-flow__svg { display: block; inline-size: 100%; block-size: auto; overflow: visible; }
.lp-flow__svg--wide { display: none; }
@media (min-width: 56.25em) { .lp-flow__svg--wide { display: block; } .lp-flow__svg--narrow { display: none; } }
.lp-flow__disc { fill: var(--navy); stroke: var(--gold); stroke-width: 3; }
.lp-flow__ink { fill: #fff; }
.lp-flow__gold { fill: var(--gold); }
.lp-flow__link { fill: none; stroke: #fff; stroke-width: 6; }
.lp-flow__link--gold { stroke: var(--gold); }
.lp-flow__line { fill: none; stroke: var(--navy); stroke-opacity: .55; stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 2 9; }
.lp-flow__line--fee { stroke: #c99a1d; stroke-opacity: .9; }
.lp-flow__line--back { stroke: #c99a1d; stroke-opacity: .9; stroke-dasharray: 8 9; stroke-width: 3; }
.lp-flow__head { fill: var(--navy); fill-opacity: .7; }
.lp-flow__dot { fill: var(--gold); stroke: #a87c10; stroke-width: 1.5; }
@media (prefers-reduced-motion: no-preference) {
  .lp-flow__line { animation: lp-flow-run 2.4s linear infinite; }
  .lp-flow__line--back { animation: lp-flow-run-back 3.2s linear infinite; }
}
@keyframes lp-flow-run { to { stroke-dashoffset: -22; } }
@keyframes lp-flow-run-back { to { stroke-dashoffset: -34; } }

/* brokers and prop firms: every tile has the same size and weight */
.lp-kind + .lp-kind { margin-block-start: 2rem; }
.lp-kind__h { margin: 0 0 .9rem; font-size: 1.05rem; line-height: 1.5; color: var(--navy); }
.lp-brokers { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
@media (min-width: 36em) { .lp-brokers { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64em) {
  .lp-brokers { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lp-kind--prop { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 16px; align-items: start; }
  .lp-kind--prop .lp-kind__h { margin: 0; padding-block: .2rem; padding-inline-end: 1rem; border-inline-start: 4px solid var(--gold); padding-inline-start: 1rem; font-size: 1.12rem; }
  .lp-kind--prop .lp-brokers { grid-column: 2 / -1; grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.lp-broker { display: flex; flex-direction: column; padding: 18px 20px; background: var(--card-bg); border: 1px solid var(--card-line); border-radius: 12px; box-shadow: var(--card-shadow); }
.lp-broker__name { margin: 0 0 .35rem; font-size: 1.25rem; font-weight: 800; line-height: 1.3; color: var(--navy); }
.lp-broker > p { font-size: .93rem; line-height: 1.65; color: var(--muted); }
.lp-broker__links { margin-block-start: .8rem; border-block-start: 1px solid rgba(5, 25, 62, .1); }
.lp-broker__links li + li { border-block-start: 1px solid rgba(5, 25, 62, .07); }
.lp-broker__date::before { content: ""; display: inline-block; inline-size: 7px; block-size: 7px; margin-inline-end: .45rem; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 2px #e6c777; vertical-align: .05em; }
.lp-broker__date { align-self: flex-start; margin-block-start: auto; padding: .2rem .75rem; border: 1px solid #e6c777; border-radius: 999px; background: #fff6e0; color: #4a3500; font-size: .78rem; font-weight: 700; line-height: 1.5; }
.lp-broker__links { margin-block-end: .9rem; }
.lp-broker__links a { display: block; padding-block: .72rem; font-size: .95rem; font-weight: 600; line-height: 1.4; }

/* calculator: the lot_calc markup and the existing calculator styles */
.lp-sec--calc .lot-calc { max-inline-size: 980px; margin-block-start: 0; }
@media (min-width: 64em) {
  .lp-sec--calc .lot-calc [id$="-result"] > div[hidden] { display: block; opacity: .86; }
  .lp-sec--calc .lot-calc [id$="-result"] > div:has(bdi:not(:empty)) { opacity: 1; }
  .lp-sec--calc .lot-calc [id$="-result"] bdi:empty::before { content: "\2014"; }
  .lp-sec--calc .lot-calc { max-inline-size: none; grid-template-columns: repeat(2, minmax(0, 1fr)) minmax(0, .95fr); column-gap: 24px; padding: 1.8rem; }
  .lp-sec--calc .lot-calc > .lot-calc__field { grid-column: auto; margin-block-end: .6rem; }
  .lp-sec--calc .lot-calc > button { grid-column: 1 / span 2; margin-block-start: .4rem; }
  .lp-sec--calc .lot-calc > [id$="-result"] { grid-column: 3; grid-row: 1 / span 3; }
}

/* learning order */
.lp-learn { display: grid; gap: 12px; max-inline-size: 760px; }
.lp-learn__item { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 14px; align-items: start; padding: 12px 16px; background: var(--card-bg); border: 1px solid var(--card-line); border-radius: 12px; }
@media (min-width: 56.25em) {
  .lp-learn { max-inline-size: none; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 18px; }
  .lp-learn__item:last-child:nth-child(odd) { grid-column: 1 / -1; }
}
.lp-learn__n { display: grid; place-items: center; inline-size: 40px; block-size: 40px; border-radius: 50%; background: var(--navy); color: #fff; font-weight: 800; }
.lp-learn__item a { display: inline-block; padding-block: .42rem; font-size: 1.05rem; font-weight: 700; }
.lp-learn__item p { font-size: .9rem; line-height: 1.6; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* trust band (dark) and the two lead paragraphs */
.lp-trust { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
@media (min-width: 56.25em) { .lp-trust { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; } }
.lp-trust li { padding: 16px 18px; border-inline-start: 4px solid var(--gold); background: rgba(255, 255, 255, .07); border-radius: 6px; line-height: 1.7; color: #fff; }
.lp-lead { max-inline-size: 760px; margin-block-start: 1.8rem; }
.lp-lead p { color: #dbe5f8; line-height: 1.8; }
.lp-lead p + p { margin-block-start: .9rem; }
@media (min-width: 56.25em) { .lp-lead { max-inline-size: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; } .lp-lead p + p { margin-block-start: 0; } }

/* FAQ: question and answer both visible */
@media (min-width: 56.25em) { .lp-faqs { column-count: 2; column-gap: 18px; } .lp-faqs .lp-faq { max-inline-size: none; break-inside: avoid; } }
.lp-faq { margin-block-end: 14px; padding: .55rem 1.4rem .8rem; background: var(--card-bg); border: 1px solid var(--card-line); border-block-start: 3px solid var(--gold); border-radius: 12px; box-shadow: var(--card-shadow); max-inline-size: 860px; }
.lp-faq summary { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-block-size: 44px; cursor: pointer; list-style: none; }
.lp-faq summary::-webkit-details-marker { display: none; }
.lp-faq summary::after { content: ""; flex: none; inline-size: 9px; block-size: 9px; margin-inline-end: 4px; border-inline-end: 2px solid var(--navy); border-block-end: 2px solid var(--navy); transform: rotate(45deg); transition: transform .18s ease; }
.lp-faq[open] > summary::after { transform: rotate(-135deg); }
.lp-faq summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; border-radius: 6px; }
.lp-faq[open] > summary { margin-block-end: .4rem; }
.lp-faq h3 { margin: 0; font-size: 1.08rem; line-height: 1.5; color: var(--navy); }
.lp-faq__a > :last-child { margin-block-end: 0; }
.lp-faq__a p, .lp-faq__a li { max-inline-size: 68ch; line-height: 1.8; }
.lp-faq__a p + p, .lp-faq__a ul, .lp-faq__a ol { margin-block-start: .7rem; }
.lp-faq__a ul, .lp-faq__a ol { list-style: revert; padding-inline-start: 1.4rem; }
.lp-faq__a table { display: block; max-inline-size: 100%; overflow-x: auto; border-collapse: collapse; font-size: .92rem; }
.lp-faq__a th, .lp-faq__a td { padding: .5rem .7rem; border: 1px solid var(--line); text-align: start; vertical-align: top; }

/* every page, as text links: wide screens set the broker guides in two columns beside the other lists */
.lp-all { display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.lp-all summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-block-size: 44px; border-block-end: 2px solid var(--gold); cursor: pointer; list-style: none; }
.lp-all summary::-webkit-details-marker { display: none; }
.lp-all summary::after { content: ""; flex: none; inline-size: 9px; block-size: 9px; margin-inline-end: 6px; border-inline-end: 2px solid var(--navy); border-block-end: 2px solid var(--navy); transform: rotate(45deg); transition: transform .18s ease; }
.lp-all details[open] > summary::after { transform: rotate(-135deg); }
[dir="rtl"] .lp-all summary::after, [dir="rtl"] .lp-faq summary::after { transform: rotate(-45deg); }
[dir="rtl"] .lp-all details[open] > summary::after, [dir="rtl"] .lp-faq[open] > summary::after { transform: rotate(135deg); }
.lp-all summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.lp-all h3 { margin: 0; font-size: 1.05rem; color: var(--navy); }
.lp-all h4 { margin: 0 0 0; font-size: .9rem; color: var(--muted); }
.lp-all__group { margin-block-end: 1.2rem; }
.lp-all__broker { margin-block-start: .8rem; }
.lp-all a { display: block; padding-block: .56rem; font-size: .96rem; line-height: 1.4; }
@media (min-width: 64em) {
  .lp-all { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); column-gap: 48px; align-items: start; }
  .lp-all__group--guide { grid-row: 1 / span 3; }
  .lp-all__cols { column-count: 2; column-gap: 48px; }
  .lp-all__broker { break-inside: avoid; padding-block-end: .2rem; }
  .lp-all a { padding-block: .36rem; }
}

@media (max-width: 36em) {
  .lp { --lp-pad: 1.7rem; }
  .lp-hero__cta .lp-btn { flex: 1 1 100%; }
  .lp-hero__fig { margin-block-start: 4px; }
  .lp-sec--paths { padding-block-start: 1.1rem; }
  .lp-path { padding: 14px 16px 16px; }
  .lp-path:has(> .lp-path__img) { display: grid; grid-template-columns: 112px minmax(0, 1fr); column-gap: 14px; align-items: center; padding: 0 14px 0 0; }
  [dir="rtl"] .lp-path:has(> .lp-path__img) { padding: 0 0 0 14px; }
  .lp-path__img { grid-row: 1 / span 2; inline-size: 112px; block-size: 100%; min-block-size: 96px; margin: 0; aspect-ratio: auto; }
  .lp-path:has(> .lp-path__img) .lp-path__link { padding-block-start: .7rem; }
  .lp-path:has(> .lp-path__img) p { padding-block-end: .8rem; }
  .lp-broker { padding: 16px; }
  .lp-faq { padding: .3rem 1.1rem .5rem; }
}

@media (prefers-reduced-motion: reduce) { .lp-path__img { transition: none; } .lp-path:hover .lp-path__img { transform: none; } .lp-path, .lp-btn { transition: none; } .lp-path:hover, .lp-btn:hover { transform: none; } .lp-all summary::after, .lp-faq summary::after { transition: none; } }
