:root {
  color-scheme: light;
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  --paper: #f6f5f1;
  --surface: #fdfcf9;
  --surface-soft: #faf9f6;
  --ink: #27362e;
  --ink-muted: #798077;
  --ink-faint: #9c9c90;
  --rule: #eae8e1;
  --green: #34483b;
  --green-light: #eef0e9;
  --orange: #d67b59;
  --mono: 'DM Mono', 'SFMono-Regular', Consolas, monospace;
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --shadow: 0 6px 20px rgba(44, 49, 37, .045), 0 1px 3px rgba(44, 49, 37, .035);
}

*, *::before, *::after { box-sizing: border-box; }

html { min-width: 360px; min-height: 100%; scroll-behavior: smooth; }
body { min-width: 360px; min-height: 100vh; margin: 0; color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased; }
button, input { color: inherit; font: inherit; }
button { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid #d28667; outline-offset: 3px; }
::selection { background: #ead9c7; color: #364336; }
[hidden] { display: none !important; }

.app-shell { min-height: 100vh; }

.rail { position: fixed; inset: 0 auto 0 0; z-index: 5; display: flex; width: 64px; align-items: center; flex-direction: column; padding: 17px 0 17px; border-right: 1px solid var(--rule); background: #faf9f6; }
.brand-mark { display: grid; width: 40px; height: 40px; transition: transform .2s ease; }
.brand-mark:hover { transform: rotate(-6deg); }
.brand-mark svg { width: 40px; height: 40px; }
.rail-divider { width: 23px; height: 1px; margin: 23px 0 14px; background: #e8e6de; }
.rail-button { display: grid; width: 38px; height: 38px; place-items: center; margin: 0 0 7px; padding: 0; border: 1px solid transparent; border-radius: 12px; color: #888b80; background: transparent; cursor: pointer; transition: color .18s, border-color .18s, background .18s; }
.rail-button:hover { color: var(--green); background: #f1f0e9; }
.rail-button.is-current { border-color: #e8e8df; color: #354b3d; background: #eeefe8; }
.rail-button svg { width: 19px; height: 19px; }
.rail-spacer { flex: 1; }
.rail-flower { margin-bottom: 9px; color: #ce8b70; font-size: 16px; }
.rail-status { display: flex; align-items: center; gap: 8px; writing-mode: vertical-rl; transform: rotate(180deg); color: #8b8b7f; font-family: var(--mono); font-size: 8px; letter-spacing: .9px; white-space: nowrap; }
.rail-status > span { display: inline-block; width: 6px; height: 6px; margin-top: 3px; border-radius: 50%; background: #789173; }

.workspace { min-height: 100vh; margin-left: 64px; }
.topbar { position: sticky; top: 0; z-index: 4; display: flex; height: 65px; align-items: center; justify-content: space-between; padding: 0 clamp(23px, 4vw, 62px); border-bottom: 1px solid rgba(231, 229, 222, .84); background: rgba(250, 249, 246, .94); backdrop-filter: blur(14px); }
.wordmark { color: #324338; font-family: var(--serif); font-size: 24px; font-weight: 600; letter-spacing: -1.1px; text-decoration: none; }
.wordmark-dot { color: var(--orange); }
.topbar-center { position: absolute; left: 50%; display: flex; align-items: center; gap: 9px; transform: translateX(-50%); color: #898a7e; font-family: var(--mono); font-size: 9px; letter-spacing: 1.15px; }
.season-dot { width: 7px; height: 7px; border-radius: 50%; background: #bd896c; box-shadow: 0 0 0 3px rgba(189,137,108,.12); }
.topbar-right { display: flex; align-items: center; gap: 15px; }
.quiet-button { display: inline-flex; min-height: 35px; align-items: center; justify-content: center; gap: 8px; padding: 0 11px; border: 1px solid #e7e5de; border-radius: 9px; color: #546055; background: transparent; font-size: 12px; font-weight: 550; cursor: pointer; transition: background .15s, border-color .15s; }
.quiet-button:hover { border-color: #cfd1c7; background: #fff; }
.quiet-button svg { width: 16px; height: 16px; }
.profile-avatar { display: grid; width: 32px; height: 32px; place-items: center; border: 1px solid #eddfd4; border-radius: 50%; color: #825e49; background: #f3eae0; font-family: var(--serif); font-size: 17px; }

.content { width: min(1496px, 100%); min-height: calc(100vh - 65px); margin-inline: auto; padding: 36px clamp(25px, 4.1vw, 66px) 17px; }
.welcome-row { display: flex; min-height: 133px; align-items: flex-start; justify-content: space-between; gap: 16px; }
.eyebrow { display: flex; align-items: center; gap: 10px; color: #88877a; font-family: var(--mono); font-size: 8.5px; letter-spacing: 1.06px; line-height: 1.5; }
.eyebrow-line { width: 16px; height: 1px; background: #bf8d73; }
.welcome-row h1 { margin: 13px 0 5px; font-family: var(--serif); font-size: clamp(34px, 4vw, 50px); font-weight: 500; letter-spacing: -1.7px; line-height: 1.05; }
.welcome-row h1 > span, .inspector-heading h2 em, .gallery-heading h2 em, .preset-dialog h2 em { color: #9c735b; font-family: var(--serif); font-weight: 500; }
.welcome-copy { margin: 9px 0 0; color: #7e8076; font-size: 12.2px; letter-spacing: .02px; }
.welcome-note { display: flex; align-items: center; gap: 11px; margin-top: 28px; padding: 11px 15px; border: 1px solid #e8e6de; border-radius: 11px; color: #696c61; background: rgba(255,255,255,.34); font-family: var(--serif); font-size: 11px; font-style: italic; line-height: 1.65; }
.note-sun { color: #bd8562; font-family: 'DM Sans', sans-serif; font-size: 17px; }

.studio-grid { display: grid; grid-template-columns: minmax(0, 1fr) 278px; align-items: start; gap: clamp(20px, 2.7vw, 38px); }
.preview-column { min-width: 0; }
.artboard { position: relative; overflow: hidden; padding: 11px 11px 0; border: 1px solid #eceae3; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); }
.canvas-stage { position: relative; overflow: hidden; width: 100%; aspect-ratio: 900 / 644; border-radius: 9px 9px 1px 1px; background: #f4f0e6; isolation: isolate; }
#art-canvas { display: block; width: 100%; height: 100%; }
.canvas-loading { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: #f4f0e6; color: #748071; font-family: var(--mono); font-size: 9px; letter-spacing: 1.5px; transition: opacity .3s; }
.canvas-loading.is-ready { opacity: 0; pointer-events: none; }
.canvas-format-tag { position: absolute; top: 12px; left: 13px; display: flex; align-items: center; gap: 7px; padding: 6px 9px; border: 1px solid rgba(237, 235, 223, .62); border-radius: 5px; color: rgba(65, 75, 59, .77); background: rgba(247, 245, 236, .68); backdrop-filter: blur(5px); font-family: var(--mono); font-size: 7px; letter-spacing: .6px; }
.canvas-format-tag > span { width: 5px; height: 5px; border-radius: 50%; background: #ad8964; }
.artwork-caption { display: flex; min-height: 54px; align-items: center; justify-content: space-between; padding: 3px 5px 1px; }
.caption-info { display: flex; min-width: 0; align-items: baseline; flex-wrap: wrap; gap: 9px; }
.caption-style { color: #85857b; font-family: var(--mono); font-size: 8px; letter-spacing: .65px; text-transform: uppercase; }
.caption-title { color: #354238; font-family: var(--serif); font-size: 14px; font-weight: 500; }
.caption-actions { display: flex; gap: 3px; }
.icon-button { display: grid; width: 32px; height: 32px; place-items: center; border: 1px solid transparent; border-radius: 8px; color: #74776d; background: transparent; cursor: pointer; transition: color .16s, border-color .16s, background .16s; }
.icon-button:hover { border-color: #e7e5dc; color: #34483b; background: #faf9f5; }
.icon-button.is-saved { border-color: #dce7d8; color: #52704e; background: #f1f5ed; }
.icon-button svg { width: 17px; height: 17px; }

.action-bar { display: flex; min-height: 50px; align-items: center; gap: 13px; margin-top: 12px; }
.grow-button { display: flex; min-height: 39px; align-items: center; gap: 8px; padding: 0 12px; border: 1px solid #334a3c; border-radius: 8px; color: #f7f5ef; background: #34483b; box-shadow: 0 2px 5px rgba(42, 58, 47, .1); font-size: 11px; font-weight: 550; cursor: pointer; transition: transform .15s, background .15s, box-shadow .15s; }
.grow-button:hover { transform: translateY(-1px); background: #405b48; box-shadow: 0 4px 10px rgba(42, 58, 47, .13); }
.grow-button:active { transform: translateY(0); }
.grow-button > svg { width: 17px; height: 17px; color: #e5cba9; }
.grow-button kbd { margin-left: 5px; padding: 2px 5px; border: 1px solid rgba(255,255,255,.22); border-radius: 4px; color: rgba(251,248,238,.77); font-family: var(--mono); font-size: 9px; }
.seed-badge { display: inline-flex; align-items: center; gap: 5px; color: #838277; font-family: var(--mono); font-size: 8px; letter-spacing: .8px; }
.seed-badge::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: #b1a387; }
.animation-button, .export-button { display: inline-flex; min-height: 35px; flex-shrink: 0; align-items: center; justify-content: center; gap: 6px; padding: 0 9px; border: 1px solid transparent; border-radius: 8px; color: #686b60; background: transparent; font-size: 10px; font-weight: 500; cursor: pointer; transition: background .15s, border-color .15s; }
.animation-button:hover, .export-button:hover, .animation-button[aria-pressed=true] { border-color: #e7e5de; color: #34483b; background: #fff; }
.animation-button svg, .export-button svg { width: 15px; height: 15px; }
.animation-button .pause-icon, .animation-button[aria-pressed=true] .play-icon { display: none; }
.animation-button[aria-pressed=true] .pause-icon { display: block; }
.action-bar > .animation-button { margin-left: auto; }
.export-wrap { position: relative; }
.export-button { gap: 6px; border-color: #e6e4dd; background: #faf9f6; }
.export-button:hover { background: #fff; }
.export-button > svg:first-child { color: #72816e; }
.export-button .chevron { width: 12px; height: 12px; margin-left: 1px; }
.export-menu { position: absolute; z-index: 6; top: calc(100% + 8px); right: 0; display: grid; width: 229px; gap: 3px; padding: 6px; border: 1px solid #e8e6de; border-radius: 11px; background: #fffefa; box-shadow: 0 12px 40px rgba(41, 45, 34, .13); animation: reveal .15s ease both; }
@keyframes reveal { from { transform: translateY(-4px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.export-menu > button { display: flex; width: 100%; align-items: center; gap: 10px; padding: 9px; border: 0; border-radius: 7px; text-align: left; background: transparent; cursor: pointer; transition: background .15s; }
.export-menu > button:hover { background: #f5f4ee; }
.format-icon { display: grid; width: 37px; height: 32px; place-items: center; border: 1px solid #e9e6de; border-radius: 7px; color: #526850; background: #f2f3ec; font-family: var(--mono); font-size: 9px; letter-spacing: .3px; }
.format-icon.json-icon { color: #85674a; background: #f7f1e7; }
.export-menu > button > span:last-child { display: grid; gap: 3px; }
.export-menu b { color: #344137; font-size: 11px; font-weight: 550; }
.export-menu small { color: #8b897f; font-size: 10px; }

.gallery-section { padding-top: 34px; scroll-margin-top: 79px; }
.gallery-heading { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 14px; }
.gallery-eyebrow { font-size: 8px; }
.gallery-heading h2 { margin: 6px 0 0; font-family: var(--serif); font-size: 23px; font-weight: 500; letter-spacing: -.6px; }
.gallery-count { padding-bottom: 5px; color: #919087; font-family: var(--mono); font-size: 8px; letter-spacing: .7px; }
.gallery-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.gallery-card { overflow: hidden; min-width: 0; padding: 0; border: 1px solid #ebe9e2; border-radius: 10px; text-align: left; background: var(--surface); cursor: pointer; box-shadow: 0 2px 6px rgba(44,49,37,.018); transition: transform .19s, border-color .19s, box-shadow .19s; }
.gallery-card:hover { transform: translateY(-2px); border-color: #d7d9cf; box-shadow: 0 6px 16px rgba(44,49,37,.07); }
.gallery-card.is-active { border-color: #758571; box-shadow: 0 0 0 1px rgba(95,115,85,.11); }
.gallery-card-canvas { display: block; width: 100%; aspect-ratio: 1.68; }
.gallery-card-caption { display: flex; min-height: 35px; align-items: center; justify-content: space-between; gap: 4px; padding: 0 8px; }
.gallery-card-name { overflow: hidden; color: #44473e; font-family: var(--serif); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.gallery-card-glyph { color: #a9866d; font-size: 13px; }
.gallery-card-count { display: none; }

.inspector { min-width: 0; padding: 17px 17px 0; border: 1px solid #ebe9e2; border-radius: 13px; background: #fcfbf8; box-shadow: var(--shadow); }
.inspector-heading { display: flex; min-height: 56px; align-items: center; justify-content: space-between; }
.inspector-eyebrow { font-size: 7.6px; letter-spacing: .92px; }
.inspector-heading h2 { margin: 6px 0 0; font-family: var(--serif); font-size: 19px; font-weight: 500; letter-spacing: -.5px; }
.inspector-asterisk { margin-top: -8px; color: #ce9a71; font-size: 23px; }
.inspector-divider { height: 1px; margin: 14px 0 13px; background: #eceae4; }
.section-label { display: flex; align-items: center; justify-content: space-between; color: #8a897e; font-family: var(--mono); font-size: 7.7px; letter-spacing: .78px; }
#style-count { color: #a09d90; }
.style-picker { display: grid; gap: 3px; margin-top: 8px; }
.style-option { display: flex; width: 100%; min-height: 33px; align-items: center; gap: 9px; padding: 4px 8px; border: 1px solid transparent; border-radius: 7px; color: #55584e; background: transparent; text-align: left; cursor: pointer; transition: border-color .16s, color .16s, background .16s; }
.style-option:hover { color: #35493a; background: #f5f4ee; }
.style-option.is-active { border-color: #e4e7dd; color: #30483a; background: #eff0e9; }
.style-glyph { display: grid; width: 21px; height: 21px; flex: 0 0 21px; place-items: center; border-radius: 6px; color: #819075; background: #eff0e9; font-family: var(--serif); font-size: 14px; }
.style-option.is-active .style-glyph { color: #627854; background: #e3e8dc; }
.style-label { overflow: hidden; font-size: 10px; font-weight: 500; letter-spacing: -.1px; text-overflow: ellipsis; white-space: nowrap; }
.style-description { display: none; }
.style-check { width: 7px; height: 7px; flex: 0 0 7px; margin-left: auto; border: 1px solid #c7c8bb; border-radius: 50%; }
.style-option.is-active .style-check { border: 2px solid #617954; background: #fff; }
.adjustment-divider { margin-top: 14px; margin-bottom: 12px; }
.reset-button { padding: 3px 0 3px 7px; border: 0; color: #969287; background: transparent; font-family: var(--mono); font-size: 7px; letter-spacing: .55px; cursor: pointer; transition: color .15s; }
.reset-button:hover { color: #536d4e; }
.slider-list { display: grid; gap: 12px; margin-top: 13px; }
.slider-control { display: grid; gap: 6px; }
.slider-topline { display: flex; align-items: center; justify-content: space-between; }
.slider-label { color: #55594f; font-size: 9px; }
.slider-readout { min-width: 21px; color: #76786c; font-family: var(--mono); font-size: 9px; text-align: right; }
.range-wrap { position: relative; display: flex; height: 19px; align-items: center; }
.slider-track { position: absolute; right: 0; left: 0; height: 3px; border-radius: 4px; background: #e9e8df; pointer-events: none; }
.slider-fill { position: absolute; left: 0; height: 3px; border-radius: 4px; background: #87967a; pointer-events: none; }
.slider-input { position: absolute; z-index: 1; inset: 0; width: 100%; height: 19px; margin: 0; appearance: none; background: transparent; cursor: pointer; }
.slider-input::-webkit-slider-runnable-track { height: 3px; background: transparent; }
.slider-input::-moz-range-track { height: 3px; background: transparent; }
.slider-input::-webkit-slider-thumb { width: 12px; height: 12px; margin-top: -4.5px; appearance: none; border: 2px solid #697f63; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(41,54,39,.12); transition: transform .14s; }
.slider-input:hover::-webkit-slider-thumb { transform: scale(1.13); }
.slider-input::-moz-range-thumb { width: 9px; height: 9px; border: 2px solid #697f63; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(41,54,39,.12); }
.palette-divider { margin-top: 18px; margin-bottom: 12px; }
.shuffle-button { display: flex; align-items: center; gap: 4px; padding: 3px 0 3px 6px; border: 0; color: #8b8779; background: transparent; font-size: 8px; cursor: pointer; }
.shuffle-button:hover { color: #566c4f; }
.shuffle-button svg { width: 12px; height: 12px; }
.palette-picker { display: flex; justify-content: space-between; gap: 6px; margin-top: 11px; }
.palette-swatch { position: relative; display: flex; width: 37px; height: 25px; overflow: visible; align-items: center; justify-content: center; gap: 2px; padding: 2px; border: 1.5px solid transparent; border-radius: 7px; background: transparent; cursor: pointer; transition: border-color .16s, transform .16s; }
.palette-swatch:hover { transform: translateY(-1px); }
.palette-swatch.is-active { border-color: #8e9581; }
.palette-dot { display: inline-block; width: 5px; height: 15px; flex: 0 0 5px; border-radius: 4px; }
.palette-name { min-height: 22px; padding-top: 8px; color: #8d897c; font-family: var(--mono); font-size: 7px; letter-spacing: .65px; }
.seed-divider { margin-top: 7px; margin-bottom: 13px; }
.seed-control { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.seed-control > div { display: grid; gap: 5px; }
.seed-label { font-size: 7.2px; }
.seed-note { color: #99968b; font-size: 8px; }
.seed-input-wrap { display: flex; height: 30px; align-items: center; gap: 1px; padding: 0 4px 0 8px; border: 1px solid #e7e5dd; border-radius: 7px; background: #fffefa; }
.seed-input-hidden-label { position: absolute; overflow: hidden; width: 1px; height: 1px; clip: rect(0, 0, 0, 0); white-space: nowrap; }
#seed-input { width: 86px; padding: 0; border: 0; outline: 0; color: #52564c; background: transparent; font-family: var(--mono); font-size: 10px; letter-spacing: .25px; }
#seed-input:focus-visible { outline: 0; }
.lock-button { display: grid; width: 24px; height: 24px; flex: 0 0 24px; place-items: center; padding: 0; border: 0; border-radius: 5px; color: #657d61; background: transparent; cursor: pointer; }
.lock-button:hover { background: #eff0e9; }
.lock-button[aria-pressed=false] { color: #a4a094; }
.lock-button svg { width: 16px; height: 16px; }
.presets-panel { min-height: 67px; margin: 15px -17px 0; padding: 12px 17px 11px; border-top: 1px solid #eceae4; background: rgba(246,245,239,.46); }
.preset-heading { margin-bottom: 9px; }
.save-preset-button { padding: 3px 5px; border: 1px solid #e7e5dd; border-radius: 5px; color: #66705d; background: #fbfaf6; font-family: var(--mono); font-size: 7.5px; letter-spacing: .2px; cursor: pointer; transition: border-color .15s, color .15s; }
.save-preset-button:hover { border-color: #cfd4c5; color: #34483b; }
.saved-presets { display: flex; overflow-x: auto; gap: 5px; scrollbar-width: thin; }
.empty-presets { padding: 3px 0; color: #a19d92; font-family: var(--serif); font-size: 10px; font-style: italic; }
.preset-chip { display: inline-flex; max-width: 100%; min-height: 24px; flex: 0 0 auto; align-items: center; gap: 5px; padding: 0 7px; border: 1px solid #e6e6dc; border-radius: 6px; color: #59634f; background: #fbfaf5; font-size: 8px; cursor: pointer; transition: border-color .14s, background .14s; }
.preset-chip:hover { border-color: #ccd2c4; background: #f1f2ea; }
.preset-chip.is-selected { border-color: #c8d2c1; background: #f1f3ec; }
.preset-wrap { display: inline-flex; flex: 0 0 auto; align-items: center; }
.preset-wrap .preset-remove { display: grid; width: 0; height: 22px; overflow: hidden; flex: 0 0 0; place-items: center; padding: 0; border: 0; border-radius: 5px; color: #8f8175; background: #f4f1ea; font-size: 13px; opacity: 0; cursor: pointer; transition: width .14s, flex-basis .14s, opacity .14s; }
.preset-wrap:hover .preset-remove, .preset-wrap:focus-within .preset-remove { width: 22px; flex-basis: 22px; margin-left: 2px; opacity: 1; }
.preset-wrap .preset-remove:hover { color: #a65d4c; background: #f6ece7; }
.preset-chip span:last-child { overflow: hidden; max-width: 112px; text-overflow: ellipsis; white-space: nowrap; }
.preset-chip-mark { color: #b58a68; }
.inspector-footer { display: flex; min-height: 36px; align-items: center; gap: 7px; margin: 0 -17px; padding: 0 14px; border-top: 1px solid #eeece5; color: #a09b8d; font-family: var(--serif); font-size: 9px; font-style: italic; }
.footer-bloom { color: #cb9676; font-size: 12px; font-style: normal; }
.footer-version { margin-left: auto; color: #aaa79c; font-family: var(--mono); font-size: 7px; font-style: normal; letter-spacing: .3px; }

.page-footer { display: flex; min-height: 43px; align-items: center; justify-content: space-between; margin-top: 25px; border-top: 1px solid #eae8e1; color: #8e8d82; font-size: 9px; }
.page-footer > span:first-child { font-family: var(--serif); font-size: 11px; font-style: italic; }
.page-footer > span:last-child { font-family: var(--mono); font-size: 7.5px; letter-spacing: .5px; }
.page-footer > span:last-child > span { color: #c38c6e; }
.toast { position: fixed; z-index: 15; right: 24px; bottom: 24px; display: flex; min-height: 43px; max-width: min(410px, calc(100vw - 32px)); align-items: center; gap: 9px; padding: 0 15px; transform: translateY(12px); border: 1px solid #e9e6de; border-radius: 9px; color: #37473a; background: #fffefa; box-shadow: 0 6px 24px rgba(37, 43, 34, .11); font-size: 11px; opacity: 0; pointer-events: none; transition: opacity .22s, transform .22s; }
.toast.is-visible { transform: translateY(0); opacity: 1; }
.toast::before { content: '✳'; color: #b68767; }

.preset-dialog { width: min(424px, calc(100% - 34px)); overflow: hidden; padding: 29px 31px 24px; border: 1px solid #eae7df; border-radius: 15px; color: #344137; background: #fcfbf7; box-shadow: 0 24px 80px rgba(32,39,30,.2); }
.preset-dialog::backdrop { background: rgba(34, 40, 33, .26); backdrop-filter: blur(3px); }
.preset-dialog form { display: flex; flex-direction: column; }
.dialog-mark { display: grid; width: 33px; height: 33px; place-items: center; margin-bottom: 17px; border: 1px solid #ebe5d9; border-radius: 10px; color: #bd8664; background: #f6f0e5; font-size: 16px; }
.preset-dialog .eyebrow { font-size: 8px; }
.preset-dialog h2 { margin: 11px 0 6px; font-family: var(--serif); font-size: 29px; font-weight: 500; letter-spacing: -.7px; }
.preset-dialog > form > p { margin: 2px 0 19px; color: #77776d; font-size: 11.5px; line-height: 1.65; }
.preset-name-label { margin-bottom: 6px; color: #868479; font-family: var(--mono); font-size: 8px; letter-spacing: .7px; }
.preset-name-input { width: 100%; height: 41px; padding: 0 11px; border: 1px solid #e5e3db; border-radius: 8px; color: #394438; background: #fffefa; font-size: 12px; }
.preset-name-input::placeholder { color: #aaa79d; font-family: var(--serif); font-style: italic; }
.dialog-actions { display: flex; align-items: center; justify-content: flex-end; gap: 9px; margin-top: 20px; }
.dialog-actions button { min-height: 36px; padding: 0 12px; border-radius: 7px; font-size: 10px; cursor: pointer; transition: background .14s; }
.dialog-cancel { border: 1px solid #e7e5de; color: #77776c; background: transparent; }
.dialog-cancel:hover { background: #f5f4ed; }
.dialog-save { display: inline-flex; align-items: center; gap: 9px; border: 1px solid #344b3d; color: #faf9f4; background: #344b3d; }
.dialog-save:hover { background: #405d49; }

.artboard.is-fullscreen { position: fixed; z-index: 12; inset: 3vh 4vw; display: flex; flex-direction: column; justify-content: center; padding: 18px 18px 0; border: 1px solid #e4e1d8; background: #fdfcf9; box-shadow: 0 0 0 100vmax rgba(32,37,32,.76); }
.artboard.is-fullscreen .canvas-stage { width: 100%; max-height: calc(94vh - 100px); align-self: center; aspect-ratio: 900 / 644; }
.artboard.is-fullscreen .artwork-caption { min-height: 53px; }
.artboard.is-fullscreen canvas { object-fit: contain; }
body.has-fullscreen { overflow: hidden; }

@media (min-width: 1600px) {
  .content { padding-top: 43px; }
  .welcome-row { min-height: 150px; }
  .studio-grid { grid-template-columns: minmax(0, 1fr) 296px; gap: 40px; }
  .inspector { padding-inline: 19px; }
  .presets-panel, .inspector-footer { margin-right: -19px; margin-left: -19px; padding-right: 19px; padding-left: 19px; }
  .inspector-footer { padding-right: 14px; padding-left: 14px; }
  .style-option { min-height: 35px; }
  .style-option:nth-child(n) { min-height: 35px; }
  .style-option .style-description { display: none; }
}

@media (max-width: 1160px) {
  .topbar-center { display: none; }
  .content { padding-inline: 29px; }
  .studio-grid { grid-template-columns: minmax(0, 1fr) 264px; gap: 20px; }
  .inspector { padding-inline: 14px; }
  .presets-panel { margin-inline: -14px; padding-inline: 14px; }
  .inspector-footer { margin-inline: -14px; }
  .gallery-grid { gap: 8px; }
}

@media (max-width: 890px) {
  .rail { width: 55px; }
  .workspace { margin-left: 55px; }
  .content { padding: 30px 24px 16px; }
  .studio-grid { grid-template-columns: minmax(0, 1fr) 246px; gap: 16px; }
  .gallery-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
  .gallery-card-name { font-size: 10px; }
  .action-bar { flex-wrap: wrap; gap: 7px; }
  .grow-button { padding-inline: 9px; font-size: 10px; }
}

@media (max-width: 680px) {
  .rail { position: sticky; inset: 0 0 auto; width: 100%; height: 53px; flex-direction: row; justify-content: flex-start; gap: 7px; padding: 0 14px; border-right: 0; border-bottom: 1px solid var(--rule); }
  .brand-mark, .brand-mark svg { width: 33px; height: 33px; }
  .rail-divider { width: 1px; height: 22px; margin: 0 4px 0 7px; }
  .rail-button { width: 33px; height: 33px; margin: 0; }
  .rail-spacer, .rail-flower, .rail-status { display: none; }
  .workspace { margin-left: 0; }
  .topbar { position: relative; height: 56px; padding-inline: 17px; }
  .wordmark { font-size: 22px; }
  .topbar-right { gap: 9px; }
  .quiet-button { min-height: 32px; padding-inline: 8px; font-size: 10px; }
  .profile-avatar { width: 29px; height: 29px; }
  .content { padding: 26px 16px 14px; }
  .welcome-row { min-height: 112px; }
  .welcome-row h1 { font-size: clamp(31px, 8vw, 43px); letter-spacing: -1.3px; }
  .welcome-copy { max-width: 265px; font-size: 10px; line-height: 1.65; }
  .welcome-note { display: none; }
  .studio-grid { grid-template-columns: minmax(0, 1fr); gap: 23px; }
  .artboard { padding: 7px 7px 0; border-radius: 10px; }
  .canvas-stage { border-radius: 6px 6px 1px 1px; }
  .canvas-format-tag { top: 7px; left: 7px; padding: 4px 6px; font-size: 6px; }
  .artwork-caption { min-height: 47px; }
  .caption-style { font-size: 7px; }
  .caption-title { font-size: 12px; }
  .action-bar { gap: 5px; margin-top: 8px; }
  .grow-button { min-height: 37px; gap: 6px; padding-inline: 8px; font-size: 9px; }
  .grow-button kbd { display: none; }
  .seed-badge { font-size: 7px; }
  .animation-button, .export-button { min-height: 33px; padding-inline: 7px; font-size: 9px; }
  .gallery-section { padding-top: 26px; scroll-margin-top: 15px; }
  .gallery-heading h2 { font-size: 21px; }
  .gallery-count { font-size: 7px; }
  .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .gallery-card-caption { min-height: 34px; padding-inline: 8px; }
  .gallery-card-name { font-size: 11px; }
  .inspector { display: grid; grid-template-columns: minmax(0, 1fr); padding: 16px; }
  .inspector-heading { min-height: 52px; }
  .inspector-heading h2 { font-size: 21px; }
  .style-picker { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
  .style-option { min-height: 36px; }
  .style-option:nth-child(n) { min-height: 36px; }
  .slider-list { grid-template-columns: 1fr; gap: 15px; }
  .slider-label { font-size: 10px; }
  .slider-list .slider-control { gap: 7px; }
  .palette-picker { justify-content: flex-start; gap: 9px; }
  .palette-swatch { width: 43px; height: 29px; gap: 3px; }
  .palette-dot { width: 7px; height: 17px; flex-basis: 7px; }
  .palette-name { padding-top: 9px; }
  .seed-control { max-width: 100%; }
  #seed-input { width: min(23vw, 115px); }
  .presets-panel { min-height: 68px; margin-inline: -16px; padding-inline: 16px; }
  .inspector-footer { margin-inline: -16px; }
  .page-footer { gap: 8px; font-size: 8px; }
  .page-footer > span:first-child { font-size: 9px; }
  .page-footer > span:last-child { max-width: 47%; font-size: 6px; text-align: right; }
  .toast { right: 12px; bottom: 12px; }
}

@media (max-width: 400px) {
  .quiet-button { gap: 5px; font-size: 9px; }
  .topbar { padding-inline: 13px; }
  .content { padding-inline: 12px; }
  .welcome-row h1 { font-size: 30px; }
  .action-bar { gap: 3px; }
  .grow-button { gap: 4px; padding-inline: 6px; font-size: 8px; }
  .grow-button > svg { width: 15px; }
  .seed-badge { gap: 3px; font-size: 6px; }
  .animation-button, .export-button { gap: 4px; padding-inline: 5px; font-size: 8px; }
  .gallery-grid { gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
