:root {
  color-scheme: light;
  --ink: #172820;
  --muted: #52625a;
  --green: #16523f;
  --line: #dce4db;
  --pale: #eaf2e8;
  --paper: #f6f8f2;
  --white: #fff;
  font-family: 'Segoe UI', system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, textarea, input, select { font: inherit; }
button { color: inherit; cursor: pointer; }
button:disabled { cursor: default; }
button, a, textarea { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, [tabindex]:focus-visible, label:has(input:focus-visible) span { outline: 2px solid #317961; outline-offset: 3px; }
[hidden] { display: none !important; }
svg { display: inline-block; width: 19px; height: 19px; vertical-align: middle; flex: none; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; }
.shell { max-width: 1256px; width: calc(100% - 96px); margin: 0 auto; }
.topbar { background: #fcfdf9; border-bottom: 1px solid #e2e8dd; }
.brandbar { display: flex; justify-content: space-between; align-items: center; min-height: 66px; gap: 20px; }
.brand { display: inline-flex; gap: 10px; align-items: center; text-decoration: none; color: var(--ink); font-size: 23px; font-weight: 750; letter-spacing: -.065em; }
.brand-icon { display: grid; place-content: center; grid-auto-flow: column; width: 34px; height: 34px; border-radius: 9px; background: var(--green); color: white; font: bold 22px Georgia, serif; }
.brand-icon span, .brand-dot { color: #578239; }
.brand-icon span { color: #d7ea9d; }
.brand-dot { margin-left: -10px; }
.top-note { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 13px; }
.top-note svg { width: 15px; height: 15px; }
.intro { padding: 32px 0 26px; }
.eyebrow { display: flex; align-items: center; gap: 9px; color: var(--green); font-size: 11px; letter-spacing: .17em; font-weight: 750; }
.eyebrow span { width: 8px; height: 8px; border-radius: 50%; background: #71a459; }
h1 { font: 400 clamp(38px, 4.7vw, 66px)/1.04 Georgia, serif; margin: 10px 0 9px; letter-spacing: -.054em; }
h1 em { color: var(--green); font-weight: 400; }
.intro p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.55; }
.workspace { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; align-items: stretch; }
.panel { background: var(--white); min-width: 0; border: 1px solid var(--line); border-radius: 17px; box-shadow: 0 4px 12px #2a432407; display: flex; flex-direction: column; overflow: hidden; }
.panel-top { min-height: 67px; padding: 12px 18px; display: flex; justify-content: space-between; align-items: center; gap: 12px; border-bottom: 1px solid var(--line); }
.panel-heading { display: flex; align-items: center; gap: 10px; }
.panel-heading h2 { font-size: 17px; font-weight: 690; margin: 0; line-height: 1.2; letter-spacing: -.025em; }
.panel-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: var(--pale); color: var(--green); flex: none; }
.panel-icon svg { width: 17px; height: 17px; }
.text-button { border: 0; background: transparent; color: var(--green); padding: 7px 2px; display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 650; }
.text-button:hover span { text-decoration: underline; }
.text-button svg { width: 15px; height: 15px; }
.toolbar { position: relative; padding: 8px 10px; background: #fcfdfb; border-bottom: 1px solid #e8ede6; display: flex; flex-wrap: wrap; align-items: center; gap: 3px 5px; }
.tool-group { display: flex; flex: 0 0 auto; align-items: center; gap: 1px; }
.tool-group + .tool-group { border-inline-start: 1px solid var(--line); padding-inline-start: 5px; }
.tool { background: transparent; border: 0; border-radius: 7px; width: 32px; height: 36px; padding: 0; display: inline-grid; place-items: center; color: #33453b; font-size: 17px; }
.tool:hover:not(:disabled), .tool[aria-pressed=true] { background: var(--pale); color: var(--green); }
.tool:disabled { color: #939e95; }
.tool.bold { font-weight: 750; }
.tool.underline { text-decoration: underline; text-underline-offset: 3px; }
.tool.strike { text-decoration: line-through; }
.tool svg { width: 17px; height: 17px; }
.history-tools { margin-inline-start: auto; }
.tool-menu > summary { list-style: none; cursor: pointer; }
.tool-menu > summary::-webkit-details-marker { display: none; }
.tool-menu[open] > summary, .tool-menu > summary:hover { background: var(--pale); color: var(--green); }
.tool-menu > summary:focus-visible { outline: 2px solid #317961; outline-offset: -2px; }
.case-tool { display: inline-flex; justify-content: center; align-items: center; gap: 2px; width: 40px; font-size: 14px; }
.case-tool span { font-size: 10px; }
.hash-tool { font-size: 21px; }
.tool-popover { position: absolute; z-index: 2; inset-block-start: calc(100% - 3px); inset-inline-start: 12px; width: max-content; max-width: calc(100% - 24px); display: grid; padding: 4px; background: var(--white); border: 1px solid var(--line); border-radius: 9px; box-shadow: 0 6px 17px #233f2e22; }
.tool-menu:not([open]) > .tool-popover { display: none; }
.tool-popover button { border: 0; border-radius: 5px; background: transparent; text-align: left; padding: 8px 10px; font-size: 13px; }
.tool-popover button:hover:not(:disabled), .tool-popover button[aria-pressed=true] { background: var(--pale); }
.tool-popover button:disabled { color: var(--muted); opacity: .65; }
.tool-popover button:focus-visible { outline-offset: -2px; }
.tool-popover hr { width: calc(100% - 12px); margin: 3px auto; border: 0; border-top: 1px solid var(--line); }
.tool-popover .typeface-option { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 4px 14px; }
.typeface-sample { color: var(--green); font: 16px/1.25 Arial, 'Segoe UI Symbol', sans-serif; }
.hashtag-suggestions { display: grid; margin-top: 3px; border-top: 1px solid var(--line); }
.hashtag-suggestions button { color: var(--green); overflow-wrap: anywhere; }
.emoji-grid { grid-template-columns: repeat(5, 1fr); gap: 2px; }
.emoji-grid button { font-size: 19px; text-align: center; width: 38px; height: 38px; padding: 0; }
#draft { display: block; width: 100%; height: 256px; min-height: 210px; flex: 1 1 auto; border: 0; padding: 20px; overflow: auto; overflow-wrap: anywhere; white-space: pre-wrap; background: white; color: var(--ink); font-family: 'Segoe UI', 'Segoe UI Emoji', 'Apple Color Emoji', system-ui, sans-serif; font-size: 15px; line-height: 1.55; }
#draft:focus-visible { outline: 2px solid #6c9e84; outline-offset: -2px; }
#draft:empty::before { content: attr(aria-placeholder); color: #6b7870; pointer-events: none; }
.draft-bold, .draft-serif { font-weight: 750; }
.draft-italic { font-style: italic; }
.draft-underline { text-decoration-line: underline; }
.draft-strike { text-decoration-line: line-through; }
.draft-underline.draft-strike { text-decoration-line: underline line-through; }
.draft-serif { font-family: Georgia, serif; }
.draft-mono { font-family: Consolas, monospace; }
.draft-script { font-family: 'Segoe Script', 'Brush Script MT', cursive; }
.editor-foot { min-height: 59px; border-top: 1px solid #e8ede6; padding: 12px 18px; display: flex; justify-content: space-between; align-items: center; gap: 12px; color: var(--muted); font-size: 12px; }
.source-tag { border: 1px solid var(--line); border-radius: 99px; padding: 3px 8px; font-size: 11px; }
.view-toggle { display: flex; padding: 3px; gap: 2px; background: #eef2eb; border-radius: 8px; }
.view-tool { width: 34px; height: 29px; display: grid; place-items: center; border: 0; padding: 0; border-radius: 6px; color: #52645a; background: transparent; }
.view-tool[aria-pressed=true] { background: #fff; color: var(--green); box-shadow: 0 1px 3px #25322122; }
.view-tool svg { width: 16px; height: 16px; }
.preview-stage { display: flex; justify-content: center; align-items: flex-start; padding: 19px; background: #edf2e9; flex: 1 1 auto; min-height: 310px; }
.post { width: 100%; min-width: 0; min-height: 242px; padding: 15px 16px; background: white; border: 1px solid #dce5da; border-radius: 11px; box-shadow: 0 3px 10px #2b3e2910; }
.preview-stage[data-view=mobile] .post { max-width: 332px; }
.post-header { display: flex; align-items: center; gap: 9px; margin-bottom: 14px; }
.avatar { width: 38px; height: 38px; display: grid; flex: none; place-content: center; border-radius: 50%; color: #32634d; background: #e1efe3; }
.post-header strong { display: block; font-size: 13px; color: #17271e; }
.post-header div > span { font-size: 11px; color: #57645b; display: flex; gap: 3px; align-items: center; }
.post-header div > span svg { width: 11px; height: 11px; }
.post-dots { margin-left: auto; font-weight: bold; letter-spacing: 2px; font-size: 22px; align-self: flex-start; line-height: 1; }
.post-body { color: #181b18; font: 14px/1.48 Arial, 'Segoe UI Emoji', 'Apple Color Emoji', sans-serif; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 245px; overflow: auto; scrollbar-width: thin; }
.post-text-area { position: relative; }
.preview-measure { position: absolute; inset: 0 0 auto; max-height: none; overflow: visible; visibility: hidden; pointer-events: none; }
.preview-more { display: inline-block; vertical-align: baseline; white-space: nowrap; margin-inline-start: .3em; border: 0; padding: 0; background: transparent; color: var(--green); font-weight: 700; }
button.preview-more:hover { text-decoration: underline; }
.preview-cut { width: fit-content; margin: 9px 0 0; color: var(--muted); font-size: 11px; line-height: 1.35; }
.empty-preview { color: #6b7870; font-size: 14px; margin: 0; }
.preview-foot { min-height: 59px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; padding: 10px 18px; gap: 10px; }
.count-block { display: flex; flex-direction: column; color: var(--muted); font-size: 11px; line-height: 1.25; }
.count { color: var(--ink); font-size: 13px; font-weight: 680; font-variant-numeric: tabular-nums; }
.count.over, .count.over + span { color: #9b3923; }
.copy-button { display: inline-flex; gap: 8px; align-items: center; justify-content: center; background: var(--green); color: white; padding: 10px 15px; min-height: 40px; border: 1px solid transparent; border-radius: 8px; font-size: 13px; font-weight: 650; white-space: nowrap; }
.copy-button:hover:not(:disabled) { background: #0d4332; }
.copy-button:disabled { opacity: .5; }
.copy-button svg { width: 16px; height: 16px; }
.compatibility { margin-top: 10px; }
.compat-summary { display: inline-flex; align-items: center; gap: 7px; list-style: none; cursor: pointer; padding: 7px 9px; border-radius: 7px; color: var(--green); font-size: 12px; font-weight: 660; }
.compat-summary::-webkit-details-marker { display: none; }
.compat-summary:hover, .compatibility[open] > .compat-summary { background: var(--pale); }
.compat-summary:focus-visible { outline: 2px solid #317961; outline-offset: 2px; }
.compat-summary svg { width: 15px; height: 15px; }
.compat-summary::after { content: ''; width: 5px; height: 5px; border: solid currentColor; border-width: 0 1px 1px 0; transform: rotate(45deg); margin: -3px 2px 0; }
.compatibility[open] > .compat-summary::after { transform: rotate(225deg); margin-top: 3px; }
.mode-label { padding: 2px 7px; border: 1px solid var(--line); border-radius: 99px; background: var(--white); color: var(--muted); font-size: 11px; font-weight: 580; }
.compat-content { margin-top: 5px; padding: 11px 13px; border: 1px solid #d8e4d7; background: #edf3e9; border-radius: 10px; }
.mode-switch { min-width: 0; width: fit-content; max-width: 100%; margin: 0; padding: 3px; border: 1px solid #dbe5d9; border-radius: 8px; display: flex; flex-wrap: wrap; gap: 2px; background: #e5eee2; }
.mode-switch label { position: relative; display: inline-flex; cursor: pointer; }
.mode-switch input { position: absolute; inset: 0; margin: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.mode-switch span { display: block; padding: 6px 9px; color: #4e5f53; border-radius: 5px; font-size: 12px; font-weight: 630; }
.mode-switch input:checked + span { color: var(--green); background: #fff; box-shadow: 0 1px 3px #2532211c; }
.compatibility p { color: #485a4e; line-height: 1.45; font-size: 13px; margin: 7px 0 0; }
.page-foot { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 6px 18px; padding: 15px 1px 18px; color: var(--muted); font-size: 12px; }
.page-foot a { color: var(--green); text-underline-offset: 2px; }
.page-foot svg { width: 12px; height: 12px; }
.toast { position: fixed; inset: auto 18px 18px auto; z-index: 2; pointer-events: none; max-width: calc(100% - 36px); }
.toast:not(:empty) { padding: 10px 15px; border-radius: 8px; background: #173a2d; color: white; box-shadow: 0 3px 15px #183a2e3b; font-size: 13px; }
dialog { width: min(480px, calc(100% - 30px)); padding: 20px; border: 1px solid var(--line); border-radius: 15px; color: var(--ink); }
dialog::backdrop { background: #13261b70; }
dialog h2 { margin: 0; font-size: 18px; }
dialog p { color: var(--muted); font-size: 14px; }
dialog textarea { display: block; width: 100%; min-height: 130px; margin: 0 0 12px; padding: 8px; border: 1px solid var(--line); border-radius: 7px; }
.manual-rich { min-height: 90px; margin: 0 0 12px; padding: 8px; border: 1px solid var(--line); border-radius: 7px; }
@media (max-width: 850px) { .shell { width: calc(100% - 44px); } }
@media (max-width: 670px) {
  .shell { width: calc(100% - 28px); }
  .intro { padding: 25px 0 19px; }
  .workspace { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .top-note { font-size: 11px; }
  .brandbar { min-height: 57px; }
  .panel-top { min-height: 55px; }
  .toolbar { padding-inline: 8px; }
  .tool { width: 32px; }
  .case-tool { width: 38px; }
  #draft { height: 225px; }
  .preview-stage { min-height: 235px; padding: 13px; }
  .post { min-height: 205px; }
  .page-foot { font-size: 11px; }
}
@media (max-width: 390px) { .top-note { max-width: 145px; } .mode-switch span { padding-inline: 7px; } }
