:root { color-scheme: light; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif; color: #333; background: #f2f3f5; font-size: 16px; }
* { box-sizing: border-box; }
.admin-confirm { width: min(520px, calc(100% - 32px)); padding: 28px; border: 1px solid #ddd; border-radius: 8px; color: #333; }
.admin-confirm::backdrop { background: rgba(0,0,0,.5); }
body { margin: 0; line-height: 1.6; }
[hidden] { display: none !important; }
a { color: #333; text-underline-offset: 3px; }
button, input, textarea, select { font: inherit; }
button, select, summary { cursor: pointer; }
button:disabled, fieldset:disabled { cursor: default; opacity: .65; }
:focus-visible { outline: 3px solid #cd1713; outline-offset: 3px; }
h1, h2, h3, p { margin: 0 0 16px; }
h1 { font-size: clamp(1.75rem, 4vw, 2.3rem); line-height: 1.2; }
h2 { font-size: 1.5rem; line-height: 1.3; }
code { overflow-wrap: anywhere; }
.admin-header { background: #333; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px max(24px, calc((100vw - 1140px) / 2)); }
.admin-header img { display: block; max-width: 100%; width: 221px; height: auto; }
.admin-header a { color: #fff; flex-shrink: 0; }
.admin-shell { width: min(1140px, calc(100% - 48px)); margin: 36px auto 0; }
.admin-panel { padding: 28px; background: #fff; border: 1px solid #ddd; border-radius: 8px; margin-bottom: 24px; scroll-margin-top: 20px; }
.login-panel { width: min(100%, 600px); margin: 64px auto; }
.admin-eyebrow { color: #cd1713; text-transform: uppercase; letter-spacing: .09em; font-size: .8rem; font-weight: 700; margin-bottom: 8px; }
.admin-panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 12px; }
.admin-panel-heading > div { min-width: 0; }
.admin-panel-heading button { flex-shrink: 0; }
.admin-panel-heading p:last-child { margin-bottom: 0; }
.admin-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.admin-field { margin-bottom: 20px; min-width: 0; }
.admin-field label { display: block; font-weight: 650; margin-bottom: 6px; }
.admin-field input, .admin-field textarea, .admin-field select { display: block; width: 100%; border: 1px solid #999; border-radius: 4px; color: #333; background: #fff; padding: 11px 12px; min-height: 46px; }
.admin-field textarea { min-height: 160px; resize: vertical; line-height: 1.6; }
.admin-field textarea.short-text { min-height: 80px; }
.admin-field input[type="file"] { padding: 9px; font-size: .9rem; }
.admin-field input[type="file"]::file-selector-button { max-width: 100%; margin-right: 8px; border: 0; background: #eee; color: #333; padding: 5px; border-radius: 3px; }
.admin-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0; }
.admin-button { display: inline-flex; align-items: center; justify-content: center; border: 1px solid #333; border-radius: 4px; min-height: 44px; padding: 10px 16px; background: #333; color: #fff; font-weight: 600; line-height: 1.4; text-align: center; }
.admin-button:hover { background: #202020; }
.admin-button.secondary { background: #fff; color: #333; }
.admin-button.secondary:hover { background: #f2f3f5; }
.admin-button.danger { border-color: #cd1713; background: #fff; color: #ae1410; }
.admin-button.danger:hover { background: #fff2f1; }
.admin-muted { font-size: .9rem; color: #606060; margin: 12px 0; }
.admin-status { font-size: .95rem; color: #444; min-height: 24px; margin: 12px 0 0; overflow-wrap: anywhere; }
.admin-status.is-error { color: #b11915; font-weight: 600; }
.backup-tools { margin-top: 20px; padding-top: 16px; border-top: 1px solid #ddd; }
.backup-tools summary { font-weight: 600; padding: 8px 0; }
.editor-navigation { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 24px; }
.editor-navigation a { background: #fff; border: 1px solid #ccc; border-radius: 4px; text-decoration: none; padding: 9px 16px; font-weight: 600; }
.editor-navigation a:hover { border-color: #333; }
fieldset { margin: 0; padding: 0; border: 0; min-width: 0; }
.rich-editor { min-height: 200px; max-height: 460px; overflow: auto; border: 1px solid #999; padding: 12px; border-radius: 0 0 4px 4px; overflow-wrap: anywhere; }
.rich-editor p:last-child { margin-bottom: 0; }
.rich-editor ul, .rich-editor ol { padding-left: 24px; }
.format-toolbar { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px; border: 1px solid #999; border-bottom: 0; border-radius: 4px 4px 0 0; background: #f2f3f5; }
.format-toolbar button { background: #fff; border: 1px solid #ccc; border-radius: 3px; min-height: 40px; padding: 6px 10px; font-size: .85rem; color: #333; }
.admin-preview-logo { display: block; max-width: 100px; max-height: 80px; margin: 12px 0; object-fit: contain; }
#sitePreview { display: block; width: 100%; height: 660px; border: 1px solid #aaa; background: #fff; }
.admin-footer { display: flex; justify-content: space-between; gap: 20px; padding: 12px 0 32px; font-size: .9rem; color: #606060; }
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (max-width: 700px) { .admin-shell { width: calc(100% - 24px); margin-top: 20px; } .admin-header { padding: 12px 18px; gap: 12px; } .admin-header img { width: 168px; } .admin-header > a:last-child { font-size: .85rem; } .admin-panel { padding: 20px 16px; } .login-panel { margin: 28px auto; } .admin-grid { grid-template-columns: minmax(0, 1fr); gap: 0; } .admin-panel-heading { flex-wrap: wrap; } .admin-panel-heading button { flex-shrink: 1; } .admin-actions > .admin-button { width: 100%; } .admin-footer { flex-wrap: wrap; } #sitePreview { height: 600px; } }
