/* Survival After Separation: plain pages (contact, legal, login, members, downloads) + shared form styles.
   Owner: builder B. Loaded by sas_site_start() after sas.css; uses its tokens (with fallbacks).
   Everything is scoped under .sas-plain / .sas-sheet-in. Builder C: put funnel styles in sas-funnel.css. */

.sas-plain {
  --sp-plum: var(--plum, #2e1f3a); --sp-plum-2: var(--plum-2, #3b2749); --sp-plum-d: var(--plum-d, #24182e);
  --sp-or: var(--orange, #ef803b); --sp-or-h: var(--orange-h, #e66c20); --sp-or-d: var(--orange-d, #c9561a);
  --sp-or-soft: var(--orange-soft, #fde8da); --sp-cream: var(--cream, #fbf6f1); --sp-lav: var(--lav, #f1ebf5);
  --sp-ink: var(--ink, #2a1f30); --sp-text: var(--text, #404040); --sp-muted: var(--muted, #6b5f70); --sp-line: var(--line, #eadfe8);
  --sp-head: var(--head, 'Montserrat', Arial, sans-serif); --sp-body: var(--body, 'Roboto', Arial, sans-serif);
  --sp-r: var(--r, 18px); --sp-shadow: var(--shadow, 0 10px 30px rgba(46, 31, 58, .10));
}

/* ---------- Text inside the white sheet ---------- */
.sas-sheet-in > :first-child { margin-top: 0; }
.sas-sheet-in > :last-child { margin-bottom: 0; }
.sas-plain .sas-sheet-in h2 { font: 800 clamp(23px, 2.6vw, 28px)/1.3 var(--sp-head); color: var(--sp-ink); margin: 1.6em 0 .55em; }
.sas-plain .sas-sheet-in h3 { font: 700 20px/1.35 var(--sp-head); color: var(--sp-ink); margin: 1.5em 0 .45em; }
.sas-sheet-in p { margin: 0 0 1.05em; }
.sas-sheet-in ul, .sas-sheet-in ol { margin: 0 0 1.2em; padding-left: 1.3em; }
.sas-sheet-in li { margin: 0 0 .5em; }
.sas-sheet-in li::marker { color: var(--sp-or); }
.sas-sheet-in a:not([class]) { color: var(--sp-or-d); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.sas-sheet-in a:not([class]):hover { color: var(--sp-plum); }
.sas-plain .sp-lead { font-size: 20px; color: var(--sp-ink); }
.sas-plain .sp-small { font-size: 16px; color: var(--sp-muted); }
.sas-plain .sp-center { text-align: center; }
.sas-plain .sp-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.sas-plain .sp-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Legal pages ---------- */
.sp-legal .sas-sheet-in { overflow-wrap: anywhere; }
.sp-legal .sas-sheet-in h2 { padding-top: 1.1em; border-top: 1px solid var(--sp-line); }
.sp-legal .sas-sheet-in > h2:first-child { padding-top: 0; border-top: 0; }
.sp-legal .sas-sheet-in h2::before { content: ""; display: block; width: 38px; height: 4px; border-radius: 4px; background: var(--sp-or); margin: 0 0 14px; }
.sp-legal .sas-sheet-in h3 { color: var(--sp-plum-2); }
.sp-legal .sas-sheet-in ul { padding-left: 0; list-style: none; }
.sp-legal .sas-sheet-in ul li { position: relative; padding-left: 26px; }
.sp-legal .sas-sheet-in ul li::before { content: ""; position: absolute; left: 4px; top: .66em; width: 9px; height: 9px; border-radius: 50%; background: var(--sp-or); }
.sp-legal .sas-sheet-in li > p { margin: 0 0 .7em; }
.sp-legal .sas-sheet-in li > p:last-child { margin-bottom: 0; }

/* ---------- Two-column layout + cards ---------- */
.sp-split { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.sp-split-main, .sp-split-side { min-width: 0; }
.sp-split-side { display: grid; gap: 22px; }
.sp-pic { display: block; width: 100%; height: auto; border-radius: var(--sp-r); box-shadow: var(--sp-shadow); object-fit: cover; aspect-ratio: 3 / 2; }
.sas-plain .sp-card { background: var(--sp-cream); border: 1px solid var(--sp-line); border-radius: var(--sp-r); padding: 30px 32px; }
.sas-plain .sp-card + .sp-card { margin-top: 22px; }
.sas-plain .sp-card-soft { background: var(--sp-lav); border-style: dashed; border-color: #d9cbe2; }
.sas-plain .sp-card > :last-child { margin-bottom: 0; }
.sas-plain .sas-sheet-in .sp-card h2 { margin-top: 0; font-size: 24px; }
.sas-plain .sp-card-login { background: #fff; border-top: 5px solid var(--sp-or); box-shadow: var(--sp-shadow); }
.sas-plain .sp-note { background: #fff; box-shadow: var(--sp-shadow); border-left: 5px solid var(--sp-or); font-size: 17px; }
.sas-plain .sp-note p { margin: 0 0 .7em; }
.sas-plain .sp-note-h { font: 800 19px/1.3 var(--sp-head); color: var(--sp-ink); margin: 0 0 .45em; }
.sas-plain .sp-note p + .sp-note-h { margin-top: 1.1em; }

/* ---------- Forms (also used by the thanks + admin pages: .sas-field / .sp-field) ---------- */
.sas-plain .sp-field, .sas-plain .sas-field { margin: 0 0 18px; min-width: 0; }
.sas-plain form label { display: block; font: 700 16px/1.4 var(--sp-head); color: var(--sp-ink); margin: 0 0 7px; }
.sas-plain form input[type=text], .sas-plain form input[type=email], .sas-plain form input[type=password], .sas-plain form input[type=number],
.sas-plain form input[type=search], .sas-plain form select, .sas-plain form textarea {
  display: block; width: 100%; max-width: 100%; box-sizing: border-box; font: 400 18px/1.4 var(--sp-body); color: var(--sp-ink); background: #fff;
  border: 1.5px solid #ddd0e2; border-radius: 12px; padding: 13px 15px; transition: border-color .15s, box-shadow .15s; }
.sas-plain form textarea { min-height: 170px; resize: vertical; }
.sas-plain form select { appearance: none; -webkit-appearance: none; padding-right: 42px; cursor: pointer;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 9l6 6 6-6' fill='none' stroke='%23c9561a' stroke-width='2.5' stroke-linecap='round'/%3E%3C/svg%3E") right 14px center / 18px no-repeat; }
.sas-plain form ::placeholder { color: #9a8ea0; opacity: 1; }
.sas-plain form input:focus, .sas-plain form select:focus, .sas-plain form textarea:focus { outline: none; border-color: var(--sp-or); box-shadow: 0 0 0 4px rgba(239, 128, 59, .18); }
.sp-row2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 18px; }
.sp-inline { display: flex; gap: 12px; align-items: stretch; }
.sp-inline input { flex: 1 1 auto; min-width: 0; }
.sp-inline .sp-btn { flex: none; }
.sp-captcha { margin: 4px 0 22px; min-height: 78px; max-width: 100%; overflow: hidden; }
.sp-form .sp-btn + .sp-small { margin-top: 16px; }

/* ---------- Buttons (orange pill, same family as the kit's .sas-btn) ---------- */
.sas-plain .sp-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; max-width: 100%; box-sizing: border-box; text-align: center;
  background: linear-gradient(180deg, #f6964f 0%, var(--sp-or) 55%, var(--sp-or-h) 100%); color: #fff; text-decoration: none;
  font: 800 18px/1.2 var(--sp-head); padding: 15px 32px; border-radius: 60px; border: 0; cursor: pointer;
  box-shadow: 0 4px 0 var(--sp-or-d), 0 12px 26px rgba(239, 128, 59, .32); transition: transform .12s ease, box-shadow .12s ease; }
.sas-plain .sp-btn:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 6px 0 var(--sp-or-d), 0 16px 30px rgba(239, 128, 59, .38); }
.sas-plain .sp-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--sp-or-d), 0 6px 14px rgba(239, 128, 59, .3); }
.sas-plain .sp-btn:focus-visible { outline: 3px solid var(--sp-plum); outline-offset: 3px; }
.sas-plain .sp-btn-wide { display: flex; width: 100%; margin-top: 8px; }
.sas-plain .sp-btn-small { font-size: 16px; padding: 11px 22px; }
.sas-plain .sp-btn-ghost { background: #fff; color: var(--sp-or-d); box-shadow: inset 0 0 0 2px var(--sp-or); }
.sas-plain .sp-btn-ghost:hover { color: var(--sp-or-h); background: #fff; box-shadow: inset 0 0 0 2px var(--sp-or-h), 0 8px 18px rgba(239, 128, 59, .18); }

/* ---------- Alerts ---------- */
.sp-alert { border-radius: 14px; padding: 16px 20px; margin: 0 0 22px; border: 1px solid; }
.sas-sheet-in .sp-alert p { margin: 0; }
.sas-sheet-in .sp-alert p + p { margin-top: 4px; }
.sas-sheet-in .sp-alert-h { font: 800 19px/1.3 var(--sp-head); margin: 0 0 4px; }
.sp-ok { background: #eff9f2; border-color: #bfe3c9; color: #1d5b33; }
.sp-err { background: #fff2ec; border-color: #f4c3a6; color: #8a3410; }

/* ---------- Members bar (inside the plum band) ---------- */
.sp-mbar { display: inline-flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 10px; }
.sp-mbar-hi { font: 700 19px/1.3 var(--sp-head); color: #fff; margin-right: 6px; }
.sp-mbar a { color: #fff; text-decoration: none; font: 700 16px/1 var(--sp-head); padding: 10px 18px; border-radius: 40px;
  background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .26); transition: background .15s, border-color .15s; }
.sp-mbar a:hover { color: #fff; background: rgba(239, 128, 59, .35); border-color: var(--sp-or); }

/* ---------- Members home: access cards ---------- */
.sas-plain .sp-members .sp-lead, .sp-members .sp-lead { text-align: center; margin-bottom: .4em; }
.sp-access { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); gap: 28px; margin-top: 30px; }
.sp-access-card { display: flex; flex-direction: column; margin: 0; background: var(--sp-cream); border: 1px solid var(--sp-line); border-radius: 22px;
  overflow: hidden; color: inherit; text-decoration: none; transition: transform .15s, box-shadow .15s; }
a.sp-access-card:hover, .sp-access-card:focus-within { color: inherit; transform: translateY(-3px); box-shadow: var(--sp-shadow); }
.sp-access-pic { display: flex; align-items: center; justify-content: center; min-height: 270px; padding: 30px 20px 26px;
  background: radial-gradient(420px 220px at 50% 115%, rgba(239, 128, 59, .38), transparent 70%), linear-gradient(160deg, var(--sp-plum-2), var(--sp-plum-d)); }
.sp-access-pic-wide img { width: 100%; max-width: 360px; height: auto; filter: drop-shadow(0 14px 22px rgba(0, 0, 0, .35)); }
.sp-access-body { display: flex; flex-direction: column; flex: 1; padding: 26px 30px 30px; }
.sp-access-h { font: 800 23px/1.25 var(--sp-head); color: var(--sp-ink); margin: 0 0 12px; }
.sp-access-list { display: grid; gap: 8px; margin: 0 0 24px; flex: 1; }
.sp-access-list > span { position: relative; padding-left: 30px; }
.sp-access-list > span::before { content: ""; position: absolute; left: 0; top: .3em; width: 19px; height: 19px; border-radius: 50%;
  background: var(--sp-or) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 13px no-repeat; }
.sp-access-body .sp-btn { align-self: flex-start; }

/* Fanned covers */
.sp-fan { position: relative; display: flex; justify-content: center; align-items: flex-end; }
.sp-fan img { width: 120px; height: auto; filter: drop-shadow(0 14px 20px rgba(0, 0, 0, .35)); }
.sp-fan img:nth-child(1) { transform: rotate(-9deg) translate(30px, 10px); }
.sp-fan img:nth-child(2) { position: relative; z-index: 2; width: 146px; }
.sp-fan img:nth-child(3) { transform: rotate(9deg) translate(-30px, 10px); }

/* ---------- Downloads page ---------- */
.sp-product .sp-lead { max-width: 760px; margin-left: auto; margin-right: auto; }
.sp-dl-main { display: flex; align-items: center; gap: 38px; margin: 30px 0 10px; padding: 34px 40px; border-radius: 22px; color: #e9def0;
  background: radial-gradient(520px 260px at 12% 120%, rgba(239, 128, 59, .4), transparent 70%), linear-gradient(150deg, var(--sp-plum-2), var(--sp-plum-d)); }
.sp-dl-main img { width: 170px; height: auto; flex: none; filter: drop-shadow(0 18px 26px rgba(0, 0, 0, .4)); }
.sp-dl-body { min-width: 0; }
.sas-plain .sas-sheet-in .sp-dl-main .sp-dl-h { color: #fff; font-size: clamp(25px, 3vw, 32px); margin: 0 0 .3em; }
.sp-dl-main p { margin: 0 0 1.1em; }
.sas-plain .sp-dl-tag { display: inline-block; margin: 0 0 10px; padding: 3px 13px; border-radius: 30px; background: var(--sp-or-soft); color: var(--sp-or-d); font: 800 16px/1.5 var(--sp-head); }
.sp-dl-main .sp-dl-tag { background: var(--sp-or); color: #fff; }
.sas-plain .sas-sheet-in .sp-dl-sec { text-align: center; font-size: clamp(21px, 2.3vw, 25px); margin: 1.7em auto .9em; max-width: 720px; }
.sp-dl-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.sp-dl { display: flex; flex-direction: column; align-items: center; text-align: center; background: var(--sp-cream); border: 1px solid var(--sp-line); border-radius: var(--sp-r); padding: 24px 18px 22px; transition: transform .15s, box-shadow .15s; }
.sp-dl:hover { transform: translateY(-3px); box-shadow: var(--sp-shadow); }
.sp-dl-pic { height: 190px; display: flex; align-items: flex-end; justify-content: center; margin-bottom: 18px; }
.sp-dl-pic img { max-height: 190px; width: auto; max-width: 140px; filter: drop-shadow(0 12px 18px rgba(46, 31, 58, .25)); }
.sas-plain .sas-sheet-in .sp-dl-h { font: 700 18px/1.35 var(--sp-head); color: var(--sp-ink); margin: 0 0 18px; flex: 1; }
.sp-back { margin-top: 30px; }

/* ---------- Phone / tablet ---------- */
@media (max-width: 960px) {
  .sp-dl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .sp-split { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .sp-split-side { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; }
}
@media (max-width: 760px) {
  .sp-row2 { grid-template-columns: minmax(0, 1fr); }
  .sas-plain .sp-card { padding: 22px 18px; }
  .sp-inline { flex-direction: column; }
  .sp-split-side { grid-template-columns: minmax(0, 1fr); }
  .sp-dl-main { flex-direction: column; text-align: center; gap: 18px; padding: 28px 20px; }
  .sp-dl-main img { width: 140px; }
  .sp-access-body { padding: 22px 20px 24px; }
  .sp-access-body .sp-btn { align-self: stretch; }
  .sp-mbar-hi { flex-basis: 100%; text-align: center; margin: 0 0 4px; }
  .sp-mbar a { padding: 9px 14px; }
  .sas-plain .sp-lead { font-size: 18px; }
}
@media (max-width: 520px) {
  .sp-dl-grid { grid-template-columns: minmax(0, 1fr); }
  .sp-fan img { width: 96px; }
  .sp-fan img:nth-child(2) { width: 118px; }
  .sp-fan img:nth-child(1) { transform: rotate(-9deg) translate(24px, 8px); }
  .sp-fan img:nth-child(3) { transform: rotate(9deg) translate(-24px, 8px); }
  .sp-access-pic { min-height: 210px; }
  .sp-captcha { transform-origin: 0 0; }
}
@media (max-width: 430px) {
  .sp-captcha .g-recaptcha { transform: scale(.9); transform-origin: 0 0; }
}
@media (max-width: 360px) {
  .sp-captcha .g-recaptcha { transform: scale(.8); }
}
