:root {
  color-scheme: dark;
  font-family: 'Segoe UI', Arial, sans-serif;
  color: #eff2e9;
  background: #151815;
  font-synthesis: none;
  --accent: #d0f36f;
  --surface: #20251f;
  --line: #394037;
  --muted: #b9c1b4;
}

* { box-sizing: border-box; }
body { margin: 0; }
main { width: min(1088px, calc(100% - 48px)); margin: auto; padding-bottom: 64px; }
header { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 88px; border-bottom: 1px solid var(--line); }
a { color: inherit; text-decoration: none; }
.brand { font-size: 1.2rem; font-weight: 800; letter-spacing: -.03em; }
.telegram { border: 1px solid var(--line); border-radius: 100px; padding: 9px 15px; font-size: .91rem; }
.telegram span, h1 span { color: var(--accent); }
.intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; padding: 64px 0 34px; }
h1 { margin: 0; font-size: clamp(2.5rem, 7vw, 5.65rem); line-height: .98; letter-spacing: -.075em; }
.intro p { max-width: 270px; margin: 0 0 4px; color: var(--muted); line-height: 1.55; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 14px; }
.editor, .preview { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 23px; }
.preview { background: #e9eedf; color: #1b2219; border-color: #e9eedf; }
.panel-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
label, h2 { margin: 0; font-weight: 700; font-size: 1.07rem; }
button, textarea { font: inherit; }
button { cursor: pointer; min-height: 42px; }
button:disabled { cursor: default; opacity: .56; }
.example, .copy { border: 1px solid var(--line); background: transparent; color: inherit; padding: 7px 12px; border-radius: 100px; font-size: .86rem; }
.copy { border-color: #a6b09f; }
textarea { width: 100%; min-height: 225px; resize: vertical; background: #191d18; color: #f2f5ee; padding: 14px; border-radius: 12px; border: 1px solid #4b5647; line-height: 1.5; }
textarea::placeholder { color: #a5aea2; }
#quote-hint { margin: 8px 0 17px; color: var(--muted); font-size: .87rem; }
.primary { width: 100%; display: flex; align-items: center; justify-content: space-between; color: #171d0a; border: 0; border-radius: 12px; padding: 12px 15px; background: var(--accent); font-weight: 750; }
.primary span { font-size: 1.16rem; }
.total { padding: 8px 0 20px; font-size: clamp(2.25rem, 5vw, 3.8rem); font-weight: 800; line-height: 1; letter-spacing: -.065em; border-bottom: 1px solid #b9c5b1; }
pre { min-height: 100px; margin: 15px 0 0; font: inherit; font-size: .93rem; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
.status { min-height: 19px; margin: 9px 0 0; color: #435540; font-size: .85rem; }
:focus-visible { outline: 2px solid #91ad4a; outline-offset: 3px; }
button:hover:not(:disabled), .telegram:hover { filter: brightness(1.08); }

@media (max-width: 660px) {
  main { width: calc(100% - 28px); padding-bottom: 30px; }
  header { min-height: 64px; }
  .intro { display: block; padding: 34px 0 22px; }
  .intro p { margin-top: 13px; max-width: 330px; }
  .workspace { grid-template-columns: minmax(0, 1fr); }
  .editor, .preview { padding: 16px; border-radius: 16px; }
  textarea { min-height: 170px; }
  .telegram { font-size: .85rem; padding: 8px 11px; }
}
