@layer existing {
.sa-page { min-height: 100vh; margin: 0; color: var(--fg); background: var(--surface); font-family: Inter, -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif; }
.sa-page * { box-sizing: border-box; }
.sa-shell { width: min(1200px, 100% - 40px); margin: 0 auto; }
.sa-head { display: flex; align-items: center; gap: 32px; min-height: 72px; border-bottom: 1px solid var(--ln-hair); }
.sa-brand { display: flex; align-items: center; gap: 9px; color: var(--fg); text-decoration: none; white-space: nowrap; }
.sa-brand span { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; color: #fff; background: linear-gradient(135deg, var(--accent), #5e5ce6); font-size: 12px; font-weight: 800; }
.sa-brand b { font-size: 14px; }
.sa-head nav { display: flex; flex: 1; justify-content: center; gap: 26px; }
.sa-head nav a { color: var(--muted); font-size: 13px; text-decoration: none; }
.sa-head nav a:hover { color: var(--accent); }
.sa-head > button { width: 34px; height: 34px; border: 1px solid var(--ln-hair); border-radius: 50%; color: var(--fg); background: var(--surface-2); cursor: pointer; }
.sa-hero { padding: clamp(70px, 10vw, 128px) 0 66px; }
.sa-kicker, .sa-panel-head span:first-child, .sa-side-card > span, .sa-answer-head span { color: var(--accent); font-size: 10px; font-weight: 700; letter-spacing: .13em; }
.sa-hero h1 { margin: 14px 0 18px; font-size: clamp(46px, 7vw, 90px); line-height: 1.07; letter-spacing: -.065em; }
.sa-hero em { font-style: normal; color: var(--accent); }
.sa-hero p { margin: 0; color: var(--muted); font-size: clamp(15px, 2vw, 19px); }
.sa-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(260px, .85fr); gap: 18px; align-items: start; }
.sa-panel, .sa-side-card, .sa-answer { border: 1px solid var(--ln-hair); border-radius: 24px; background: var(--surface-2); box-shadow: var(--shadow-raised); }
.sa-panel { padding: clamp(22px, 4vw, 36px); }
.sa-panel-head, .sa-answer-head { display: flex; justify-content: space-between; gap: 16px; align-items: start; }
.sa-panel h2, .sa-answer h2 { margin: 7px 0 0; color: var(--fg); font-size: 25px; letter-spacing: -.035em; }
.sa-state { padding: 6px 9px; border-radius: 999px; color: var(--muted) ; background: var(--surface); font-size: 11px ; font-weight: 500 ; letter-spacing: 0 ; white-space: nowrap; }
.sa-state.ready { color: #248a3d ; background: color-mix(in srgb, #34c759 12%, transparent); }
.sa-context { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 24px; padding: 13px 14px; border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); border-radius: 13px; background: var(--accent-soft); }
.sa-context b { display: block; color: var(--fg); font-size: 12px; }
.sa-context small { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; }
.sa-context button { border: 0; color: var(--accent); background: transparent; cursor: pointer; }
.sa-modes { display: flex; gap: 6px; margin: 24px 0; padding: 4px; border-radius: 13px; background: var(--surface); }
.sa-modes button { flex: 1; min-height: 36px; border: 0; border-radius: 10px; color: var(--muted); background: transparent; font: inherit; font-size: 12px; cursor: pointer; }
.sa-modes button[aria-pressed="true"] { color: var(--fg); background: var(--surface-2); box-shadow: 0 2px 8px rgba(0,0,0,.1); }
.sa-label { display: block; margin-bottom: 9px; color: var(--fg); font-size: 12px; font-weight: 650; }
.sa-panel textarea { display: block; width: 100%; min-height: 170px; resize: vertical; padding: 16px; border: 1px solid var(--ln-hair); border-radius: 15px; outline: 0; color: var(--fg); background: var(--surface); font: inherit; font-size: 14px; line-height: 1.65; }
.sa-panel textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.sa-submit-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 12px; }
.sa-submit-row span { color: var(--muted); font-size: 11px; }
.sa-submit-row button { min-height: 42px; padding: 0 18px; border: 0; border-radius: 12px; color: #fff; background: var(--accent); font: inherit; font-size: 13px; font-weight: 650; cursor: pointer; }
.sa-submit-row button:disabled { opacity: .55; cursor: wait; }
.sa-notice { min-height: 20px; margin: 10px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.sa-side { display: grid; gap: 18px; }
.sa-side-card { padding: 24px; }
.sa-side-card h3 { margin: 8px 0 14px; font-size: 18px; }
.sa-side-card p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.sa-preset { display: flex; justify-content: space-between; align-items: center; width: 100%; padding: 12px 0; border: 0; border-top: 1px solid var(--ln-hair); color: var(--fg); background: transparent; font: inherit; font-size: 12px; text-align: left; cursor: pointer; }
.sa-preset i { color: var(--accent); font-style: normal; }
.sa-answer { margin-top: 18px; padding: clamp(22px, 4vw, 36px); }
.sa-answer-head button { padding: 7px 12px; border: 1px solid var(--ln-hair); border-radius: 9px; color: var(--fg); background: var(--surface); cursor: pointer; }
#saAnswerText { margin-top: 25px; color: var(--fg); font-size: 14px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.sa-foot { display: flex; justify-content: space-between; margin: 50px 0 25px; padding-top: 20px; border-top: 1px solid var(--ln-hair); color: var(--muted); font-size: 11px; }
.sa-foot a { color: var(--muted); text-decoration: none; }
@media (max-width: 760px) { .sa-shell { width: min(100% - 28px, 620px); } .sa-head nav { display: none; } .sa-head > button { margin-left: auto; } .sa-hero { padding: 58px 0 42px; } .sa-layout { grid-template-columns: 1fr; } .sa-side { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .sa-side { grid-template-columns: 1fr; } .sa-panel, .sa-side-card, .sa-answer { border-radius: 19px; } .sa-panel-head { flex-direction: column; } .sa-modes button { font-size: 11px; } }

}
