/* ShipLayout, AddressCard, AddAddressButton, ShipContinueFooter and AddressFormSheet. */
main:has(> .sa-page) { padding: 0; background: #0c0b1c; }
.sa-page {
  --sa-edge: #ffffff18; --sa-fg: #fafafa; --sa-dim: #b5b2c6;
  display: flex; flex-direction: column; gap: 0; width: 100%; max-width: 640px;
  min-height: calc(100dvh - 76px); margin: 0 auto; padding: 0 20px;
  color: var(--sa-fg); background: #0c0b1c; font-family: Manrope,sans-serif;
}
.sa-page [hidden] { display: none !important; }
.sa-header { display: grid; position: relative; grid-template-columns: 44px 1fr 44px; align-items: center; gap: 8px; padding-top: 12px; }
.sa-header h1,.sa-header h2 { margin: 0; text-align: center; color: #fafafa; font-size: 22px; line-height: 30px; font-weight: 700; }
.sa-back,.sa-close { display: grid; place-items: center; width: 44px; height: 44px; color: #fafafa; background: transparent; border: 0; text-decoration: none; }
.sa-back { font-size: 33px; }
.sa-steps { display: flex; grid-column: 1/-1; gap: 8px; margin: 8px 0 18px; }
.sa-steps i { flex: 1; height: 3px; border-radius: 3px; background: #ffffff25; }
.sa-steps i:first-child { background: #9693fa; }
.sa-list { flex: 1; min-width: 0; }
.sa-group { display: grid; gap: 12px; }
.sa-card { display: grid; position: relative; border: 1px solid var(--sa-edge); border-radius: 16px; background: #18172f; }
.sa-card:has(input:checked) { border-color: #9693fa; }
.sa-select { display: grid; grid-template-columns: 32px minmax(0,1fr) 24px; align-items: start; gap: 12px;
  padding: 20px; min-height: 108px; cursor: pointer; }
.sa-select strong { font-size: 16px; line-height: 22px; padding-right: 36px; }
.sa-select input { width: 20px; height: 20px; margin: 22px 0 0; accent-color: #9693fa; cursor: pointer; }
.sa-home { position: relative; width: 15px; height: 14px; margin: 32px auto 0; border: 1.7px solid #ddd9ea; border-top: 0; border-radius: 2px; }
.sa-home::before { content: ''; position: absolute; top: -6px; left: 0; width: 11px; height: 11px; border: solid #ddd9ea; border-width: 1.7px 0 0 1.7px; transform: rotate(45deg); }
.sa-lines { position: relative; margin: -64px 88px 10px 64px; min-width: 0; pointer-events: none; }
.sa-masked { display: block; color: #b0adbd; font-size: 14px; line-height: 20px; overflow-wrap: anywhere; }
.sa-reveal,.sa-text-action,.sa-source-link { color: var(--sa-dim); font: 600 13px/20px Manrope,sans-serif; text-decoration: underline; }
.sa-reveal,.sa-text-action { border: 0; background: transparent; padding: 6px 0; cursor: pointer; }
.sa-reveal { display: inline-flex; align-items: center; gap: 6px; pointer-events: auto; }
.sa-reveal::before { content: ''; width: 12px; height: 8px; border: 1px solid currentColor; border-radius: 70% 20%; transform: rotate(32deg); }
.sa-edit { position: absolute; right: 48px; top: calc(50% - 22px); width: 40px; height: 44px; }
.sa-edit::before { content: ''; position: absolute; left: 12px; top: 19px; width: 15px; height: 5px; border: 1.5px solid #c4c1d6; border-radius: 1px 3px 3px 1px; transform: rotate(-45deg); }
.sa-add,.sa-footer .button,.sa-editor .actions .button { display: grid; place-items: center; width: 100%; text-align: center; text-decoration: none; }
.sa-add { display: flex; justify-content: center; gap: 8px; align-items: center; margin-top: 12px; min-height: 44px; background: linear-gradient(160deg,#342f56,#24213b); color: #fafafa; border: 1px solid #ffffff24; border-radius: 12px; font-weight: 600; }
.sa-add::before { content: '+'; font-size: 20px; font-weight: 400; }
.sa-hint,.sa-recovery { font-size: 14px; line-height: 20px; color: var(--sa-dim); }
.sa-list > .sa-hint { margin: 12px 0; }
.sa-source-link { display: inline-block; margin: 8px 16px 8px 0; }
.sa-footer { position: sticky; bottom: 0; z-index: 1; margin-top: 24px; padding: 15px 0 max(16px,env(safe-area-inset-bottom)); background: linear-gradient(transparent,#0c0b1c 12px); }
.sa-page .model-form,.sa-page .controls,.sa-page .actions { border: 0; box-shadow: none; border-radius: 0; margin: 0; padding: 0; background: transparent; min-width: 0; }
.sa-page .form-status:empty { display: none; }
.sa-footer .actions { display: block; }
.sa-footer .button,.sa-editor .actions .button { min-height: 50px; color: #171527; background: #f0eef9; border-radius: 999px; border: 0; font-size: 16px; font-weight: 700; }
.sa-footer .button:disabled { opacity: .42; }
.sa-page .sa-editor { --sa-dim: #b5b2c6; width: min(100%,460px); max-width: 100%; max-height: 90dvh; padding: 0; border: 1px solid #ffffff1f;
  border-radius: 24px; background: #171732; color: #fafafa; inset: 0; margin: auto; overflow: hidden; }
.sa-editor[open] { display: flex; flex-direction: column; }
.sa-editor::backdrop { background: #060510a8; backdrop-filter: blur(4px); }
.sa-form-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 12px 6px 20px; }
.sa-form-head h1 { font-size: 22px; line-height: 31px; font-weight: 600; margin: 0; }
.sa-editor .model-form { display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain; }
.sa-editor .controls { display: flex; flex-direction: column; }
.sa-fields,.sa-confirm { padding: 8px 20px 18px; display: grid; gap: 14px; }
.sa-fields .field { display: grid; gap: 5px; margin: 0; font: 500 14px/20px Manrope,sans-serif; color: #c2bfd1; }
.sa-fields input { width: 100%; height: 52px; border-radius: 8px; background: #1b1a30; color: #fafafa; border: 1px solid #ffffff22; padding: 0 14px; font-size: 16px; }
.sa-editor .actions { position: sticky; bottom: 0; display: flex; flex-direction: column; gap: 8px; padding: 12px 20px max(16px,env(safe-area-inset-bottom)); background: #171732; }
.sa-editor .actions .secondary { color: #d5d2e0; background: transparent; }
.sa-editor .form-status:not(:empty) { padding: 6px 20px 16px; }
.sa-confirm h2 { margin: 8px 0 0; font-size: 18px; }
.sa-confirm p { margin: 0; font-size: 15px; line-height: 1.5; }
.sa-text-action { justify-self: start; }
.sa-page :is(input,button,a):focus-visible { outline: 2px solid #b4a8ff; outline-offset: 2px; }
@media (max-width: 760px) {
  .sa-page { min-height: calc(100dvh - 138px - env(safe-area-inset-bottom)); }
  .sa-footer { bottom: calc(62px + env(safe-area-inset-bottom)); }
  .sa-page .sa-editor { inset: auto 0 var(--sa-keyboard-inset,0px); margin: 0 auto; border-radius: 24px 24px 0 0; max-height: min(90dvh, var(--sa-visible-height,90dvh)); }
}
