/* The studio shares atlas typography; reading stays narrow, controls wrap. */
.shenlun-space[data-sl-view="writing"] .workspace { grid-template-columns: minmax(0, 1fr); }
.shenlun-space[data-sl-view="writing"] .sidebar,
.shenlun-space[data-sl-view="writing"] .detail { display: none; }
.shenlun-space[data-sl-view="writing"] .stage { min-width: 0; }
.shenlun-space[data-sl-view="writing"] #stageContent { padding: clamp(14px, 3vw, 32px); }
.ws-studio { max-width: 1120px; margin: 0 auto; color: #26382f; min-width: 0; overflow-wrap: anywhere; line-height: 1.8; }
.ws-studio *, .ws-studio *::before, .ws-studio *::after { box-sizing: border-box; }
.ws-studio [hidden] { display: none !important; }
.ws-mobile-intro { display: none; }
.ws-card > .ws-template-actions { margin: 10px 0 16px; gap: 8px; }
.ws-mobile-route { display: none; }
.ws-studio h2, .ws-studio h3, .ws-studio p { margin: 0 0 12px; }
.ws-studio h2 { font-size: 22px; line-height: 1.5; }
.ws-studio h3 { font-size: 16px; line-height: 1.65; }
.ws-studio ul, .ws-studio ol { padding-left: 1.5em; }
.ws-studio li { margin: 8px 0; }
.ws-studio a { color: #245a46; text-decoration: underline; text-underline-offset: 3px; }
.ws-studio button, .ws-studio select, .ws-studio textarea { font: inherit; }
.ws-studio button:focus-visible, .ws-studio a:focus-visible, .ws-studio summary:focus-visible, .ws-studio select:focus-visible, .ws-studio textarea:focus-visible { outline: 3px solid #a76c32; outline-offset: 3px; }
.ws-intro { padding-bottom: 18px; border-bottom: 1px solid #d5dbd2; }
.ws-intro h2 { font-size: clamp(23px, 3vw, 31px); letter-spacing: -.02em; }
.ws-kicker { display: block; color: #587362; font-size: 12px; font-weight: 700; letter-spacing: .06em; margin-bottom: 9px; }
.ws-tabs, .ws-actions, .ws-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 20px 0; min-width: 0; }
.ws-button { display: inline-flex; justify-content: center; align-items: center; min-height: 44px; max-width: 100%; padding: 8px 15px; border: 1px solid #bfcfc2; border-radius: 10px; background: #fffef9; color: #284d3b; cursor: pointer; white-space: normal; line-height: 1.5; text-align: center; }
.ws-button:hover { background: #edf3e9; }
.ws-primary, .ws-tabs .is-active { background: #2f5945; color: #fffef8; border-color: #2f5945; }
.ws-primary:hover, .ws-tabs .is-active:hover { background: #244937; }
.ws-filters { align-items: end; padding: 16px; border-radius: 12px; background: #edf1e9; }
.ws-filters label { display: flex; flex: 1 1 170px; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 600; min-width: 0; }
.ws-filters select { width: 100%; min-width: 0; min-height: 44px; padding: 8px; background: #fffef9; border: 1px solid #bfcdc0; border-radius: 7px; color: #26382f; font-size: 16px; }
.ws-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.ws-card { min-width: 0; padding: clamp(18px, 2.4vw, 27px); border: 1px solid #d5dbd2; border-radius: 15px; background: #fffdf7; }
.ws-card > .ws-button { margin-top: 8px; }
.ws-card h2 { font-size: 21px; }
.ws-muted, .ws-count, .ws-footer { color: #5d6c61; font-size: 13px; }
.ws-theme { font-weight: 600; }
.ws-section-intro { max-width: 760px; font-size: 16px; }
.ws-reading { max-width: 760px; margin: 0 auto; font-size: 16px; }
.ws-reading > .ws-button:first-child { margin-bottom: 26px; }
.ws-title { font-size: clamp(25px, 3vw, 34px) !important; }
.ws-title, .ws-intro h2 { scroll-margin-top: 64px; }
.ws-lead { font-size: 17px; }
.ws-field { margin: 18px 0; }
.ws-field h3 { margin-bottom: 6px; color: #52694f; }
.ws-field p:last-child { margin-bottom: 0; }
.ws-boundary, .ws-notice, .ws-bad { padding: 15px 18px; background: #f5eee2; border-left: 3px solid #a98350; border-radius: 0 9px 9px 0; }
.ws-good, .ws-emphasis { padding: 15px 18px; background: #ecf2e8; border-left: 3px solid #638565; border-radius: 0 9px 9px 0; }
.ws-point { padding: 22px 0; border-top: 1px solid #d5dbd2; }
.ws-point > h3 { font-size: 20px; }
.ws-point .ws-field { margin: 12px 0; }
.ws-reading > section { margin: 30px 0; }
.ws-disclosure { margin: 18px 0; padding: 12px 15px; border: 1px solid #d5dbd2; border-radius: 10px; background: #fafaf3; }
.ws-disclosure summary { cursor: pointer; min-height: 32px; font-weight: 600; }
.ws-disclosure[open] summary { margin-bottom: 16px; }
.ws-references { display: grid; gap: 12px; font-size: 13px; }
.ws-essay-body { margin-top: 28px; font-size: 18px; line-height: 2; }
.ws-essay-paragraph { margin: 0 0 24px; }
.ws-essay-paragraph > p { text-indent: 2em; }
.ws-annotation { padding: 15px 18px; background: #edf3e8; border-radius: 10px; font-size: 14px; line-height: 1.8; }
.ws-annotation p { margin: 6px 0 0; }
.ws-review { padding: 20px; background: #f2eee4; border-radius: 12px; }
.ws-draft { border-top: 2px solid #728b72; padding-top: 26px; }
.ws-draft-fields { display: grid; gap: 16px; }
.ws-draft-fields + .ws-draft-fields { margin-top: 18px; }
.ws-writing-focus > .ws-intro, .ws-writing-focus > .ws-tabs { display: none; }
.ws-content-view > .ws-intro { display: none; }
.ws-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.ws-writing-focus .ws-title { font-size: 22px !important; line-height: 1.5; }
.ws-writing-focus .ws-status { font-size: 13px; line-height: 1.6; padding: 9px 12px; }
.ws-draft-focused { border-top: 0; padding-top: 0; }
.ws-draft-focused > h2 { font-size: 20px; }
.ws-draft-focused textarea[data-draft-field="body"] { min-height: 38vh; }
.ws-draft-outline .ws-draft-fields { margin-top: 14px; }
.ws-self-review li { margin-bottom: 12px; }
.ws-material-links { display: grid; gap: 10px; }
.ws-practice-evidence { font-size: 14px; }
.ws-writing-focus .ws-reading > .ws-button:first-child { margin-bottom: 14px; }
.ws-draft-fields label, .ws-copy-fallback { display: flex; flex-direction: column; gap: 7px; font-weight: 600; }
.ws-studio textarea { display: block; resize: vertical; min-height: 80px; width: 100%; min-width: 0; max-width: 100%; padding: 12px; background: #fffefb; color: #26382f; border: 1px solid #b8c8b9; border-radius: 9px; font-size: 16px; font-weight: 400; line-height: 1.8; }
.ws-status { padding: 12px 15px; background: #edf3e8; border-radius: 9px; font-size: 14px; }
.ws-warning { background: #f6e8d5; color: #704318; }
.ws-empty { padding: 32px 15px; text-align: center; }
.ws-saved-drafts { margin: 10px 0; }
.ws-saved-drafts > summary { min-height: 44px; display: flex; align-items: center; }
.ws-saved-list { display: grid; gap: 9px; }
.ws-resume { display: grid; gap: 4px; text-align: left; width: 100%; min-width: 0; white-space: normal; overflow-wrap: anywhere; }
.ws-resume small { font-size: 12px; font-weight: 400; color: #5d6c61; }
.ws-footer { border-top: 1px solid #d5dbd2; padding: 20px 0 8px; margin-top: 35px; }
@media (max-width: 700px) {
  /* Keep the full learning route available without consuming the first screen. */
  .ws-studio > .ws-intro { display: none; }
  .ws-mobile-route { display: block; padding: 4px 0 10px; font-size: 14px; }
  .ws-intro > .ws-kicker, .ws-intro > h2, .ws-intro > .ws-intro-description { display: none; }
  .ws-mobile-intro { display: block; }
  .ws-template-actions .ws-button { padding: 8px 10px; font-size: 14px; }
  .shenlun-space[data-sl-view="writing"] .stage-head { min-height: 0; padding: 8px 14px 0; }
  .shenlun-space[data-sl-view="writing"] #stageEyebrow { display: none; }
  .shenlun-space[data-sl-view="writing"] .stage-head h1 { margin: 0; font-size: 18px; line-height: 1.5; }
  .ws-material-kinds { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin: 12px 0; }
  .ws-material-kinds .ws-button { padding: 8px 4px; font-size: 14px; }
  .ws-grid { grid-template-columns: minmax(0, 1fr); gap: 15px; }
  .ws-card h2 { font-size: 18px; line-height: 1.5; }
  .ws-tabs { gap: 7px; }
  .ws-tabs .ws-button { flex: 1 1 100px; padding: 8px 10px; font-size: 14px; }
  .ws-essay-body { font-size: 17px; }
  .ws-notice { font-size: 14px; }
}

/* Mobile starts with learning content, while all navigation stays available. */
.ws-filter-disclosure{margin:16px 0;border:1px solid #d5dbd2;border-radius:10px;padding:0 12px}.ws-filter-disclosure>summary{min-height:44px;display:flex;align-items:center;cursor:pointer;font-weight:600;font-size:14px}.ws-filter-disclosure>summary::before{content:"＋";margin-right:8px}.ws-filter-disclosure[open]>summary::before{content:"−"}.ws-filter-disclosure .ws-filters{margin:0 0 12px}.ws-study-route{margin:10px 0 0}
@media(max-width:700px){.ws-intro{padding-bottom:10px}.ws-intro h2{font-size:23px;line-height:1.35}.ws-intro-description{font-size:14px;line-height:1.6}.ws-tabs{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;margin:12px 0}.ws-tabs .ws-button{padding:7px 3px;font-size:12px;line-height:1.4;min-height:44px}.ws-filters{padding:10px}.ws-filters label{flex-basis:100px}.ws-study-route{padding:6px 10px;font-size:13px}.ws-filter-disclosure{margin:10px 0}.ws-count{margin-bottom:10px}}

/* Compact phone navigation: see .agents/notes/implemented/feature/2026-09-27-essay-studio.md */
.ws-section-picker{display:none}
.ws-writing-focus>.ws-section-picker{display:none}
.ws-template-fit{margin:12px 0 0;padding:0 10px}
.ws-template-fit>summary{min-height:44px;display:flex;align-items:center;gap:6px;cursor:pointer}
.ws-template-fit>summary::before{content:'＋'}
.ws-template-fit[open]>summary::before{content:'−'}
@media(max-width:700px){
 .shenlun-space[data-sl-view="writing"] .stage-head{position:absolute!important;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);padding:0!important;min-height:0!important}
 .ws-tabs{display:none}
 .ws-section-picker{display:flex;align-items:center;gap:12px;margin:0 0 10px}
 .ws-section-picker>span{font-size:15px;font-weight:700;white-space:nowrap}
 .ws-section-picker select{flex:1;min-width:0;width:100%;min-height:44px;padding:8px;border:1px solid #bfcfc2;border-radius:10px;background:#fffef9;color:#284d3b;font-size:16px}
 .ws-card{padding:16px}
 .ws-count{font-size:12px}
 .ws-template-fit{font-size:14px}
}
