:root {
    --bg: #f5f6f8;
    --surface: #fff;
    --surface-2: #eef0f3;
    --text: #17191d;
    --muted: #6f747d;
    --line: #dfe2e7;
    --ink: #22252a;
    --coral: #ef684f;
    --coral-dark: #d9513a;
    --green: #238565;
    --green-soft: #e7f5ef;
    --amber: #a36b0a;
    --amber-soft: #fff3d7;
    --red: #b43b3b;
    --red-soft: #fdeaea;
    --blue: #3766b1;
    --blue-soft: #eaf0fb;
    --shadow: 0 12px 32px rgba(25, 31, 41, .07);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: "DM Sans", sans-serif; color: var(--text); background: var(--bg); letter-spacing: 0; }
button, input, textarea, select { font: inherit; letter-spacing: 0; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
svg { width: 19px; height: 19px; stroke-width: 1.8; flex: 0 0 auto; }

.app-shell { padding-left: 248px; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: 248px; background: #1d2025; color: #fff; padding: 26px 16px 18px; display: flex; flex-direction: column; z-index: 20; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; }
.sidebar > .brand { padding: 0 10px 28px; }
.brand-mark { width: 31px; height: 31px; background: var(--coral); border-radius: 7px; display: inline-grid; place-items: center; color: #fff; font-weight: 700; }
.nav-list { display: grid; gap: 5px; }
.nav-list a { min-height: 44px; display: flex; align-items: center; gap: 12px; color: #aeb3bc; padding: 0 12px; border-radius: 7px; font-size: 14px; font-weight: 600; }
.nav-list a:hover, .nav-list a.active { color: #fff; background: #2c3037; }
.nav-list a.active { box-shadow: inset 3px 0 var(--coral); }
.sidebar-user { margin-top: auto; padding: 15px 7px 0; border-top: 1px solid #353941; display: grid; grid-template-columns: 36px 1fr 32px; gap: 9px; align-items: center; }
.sidebar-user strong, .sidebar-user small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user strong { font-size: 13px; }
.sidebar-user small { color: #8f959f; margin-top: 2px; font-size: 11px; }
.sidebar-user form { margin: 0; }
.sidebar .icon-button { color: #aeb3bc; }
.avatar { width: 38px; height: 38px; display: inline-grid; place-items: center; border-radius: 50%; background: #e7ebf0; color: #3e4857; font-size: 13px; font-weight: 700; flex: 0 0 auto; }
.avatar.small { width: 32px; height: 32px; }
.mobile-header, .mobile-menu { display: none; }
.main-content { max-width: 1510px; margin: 0 auto; padding: 38px 44px 70px; }

.page-header { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 30px; }
.page-header.compact { align-items: center; }
.page-header h1 { font-size: 31px; line-height: 1.15; margin: 5px 0 7px; }
.page-header p { color: var(--muted); margin: 0; font-size: 14px; }
.eyebrow { font-size: 11px !important; color: #8a909a !important; letter-spacing: .12em !important; font-weight: 700; margin: 0; }
.button { border: 1px solid transparent; border-radius: 7px; min-height: 42px; padding: 0 17px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; font-size: 13px; font-weight: 700; transition: .18s ease; }
.button:hover { transform: translateY(-1px); }
.button-primary { background: var(--coral); color: #fff; }
.button-primary:hover { background: var(--coral-dark); }
.button-secondary { background: var(--surface); border-color: var(--line); color: var(--ink); }
.button-danger { color: var(--red); background: var(--red-soft); border-color: #f7cece; }
.button-block { width: 100%; }
.icon-button { width: 36px; height: 36px; border: 0; border-radius: 7px; display: inline-grid; place-items: center; background: transparent; cursor: pointer; color: inherit; }
.icon-button:hover { background: rgba(120, 126, 136, .12); }

.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); background: var(--surface); border-radius: 8px; overflow: hidden; margin-bottom: 38px; }
.stat { min-height: 108px; padding: 24px; display: flex; gap: 15px; align-items: center; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat-icon { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 7px; }
.stat-icon.neutral { background: #eceef1; color: #4b535e; }
.stat-icon.pending { background: var(--amber-soft); color: var(--amber); }
.stat-icon.approved { background: var(--green-soft); color: var(--green); }
.stat-icon.rejected { background: var(--red-soft); color: var(--red); }
.stat small, .stat strong { display: block; }
.stat small { color: var(--muted); font-size: 12px; margin-bottom: 5px; }
.stat strong { font-size: 25px; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; margin: 0 0 17px; }
.section-head h2 { margin: 0 0 4px; font-size: 19px; }
.section-head p { margin: 0; color: var(--muted); font-size: 13px; }
.section-head h2 span { color: var(--muted); font-weight: 500; margin-left: 5px; }
.text-link { display: inline-flex; align-items: center; gap: 6px; color: var(--coral-dark); font-size: 13px; font-weight: 700; }

.designs-hero { align-items: center; }
.designs-hero h1 { font-size: 34px; }
.designs-hero-actions { display: flex; align-items: center; gap: 12px; }
.designs-hero-actions > span { min-height: 42px; display: inline-flex; align-items: center; gap: 5px; padding: 0 13px; background: var(--surface); border: 1px solid var(--line); border-radius: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.designs-hero-actions strong { color: var(--text); }
.designs-toolbar { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 12px; display: grid; grid-template-columns: minmax(260px, 1fr) auto auto; gap: 12px; align-items: center; box-shadow: 0 10px 24px rgba(25, 31, 41, .04); }
.designs-overview { margin: 16px 0 20px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.designs-overview > div { min-height: 74px; display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; }
.designs-overview svg { width: 20px; height: 20px; color: var(--coral-dark); }
.designs-overview strong, .designs-overview small { display: block; }
.designs-overview strong { font-size: 20px; line-height: 1; }
.designs-overview small { margin-top: 5px; color: var(--muted); font-size: 11px; font-weight: 700; }
.design-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.design-card { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; transition: .2s ease; min-width: 0; display: flex; flex-direction: column; }
.design-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: #d3d7df; }
.design-image { aspect-ratio: 16 / 10; position: relative; overflow: hidden; background: #e9ebee; display: block; }
.design-image::after { content: ""; position: absolute; inset: auto 0 0; height: 52%; background: linear-gradient(to top, rgba(18, 21, 26, .42), rgba(18, 21, 26, 0)); pointer-events: none; }
.design-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.design-card:hover img { transform: scale(1.025); }
.status { display: inline-flex; align-items: center; min-height: 25px; padding: 0 9px; border-radius: 999px; font-size: 10px; font-weight: 700; white-space: nowrap; }
.design-image .status { position: absolute; top: 12px; left: 12px; z-index: 1; box-shadow: 0 2px 10px rgba(0, 0, 0, .08); }
.status-pending { color: #865808; background: #fff1ca; }
.status-approved { color: #176b4e; background: #dff3ea; }
.status-rejected { color: #9c3030; background: #fae1e1; }
.status-revision { color: #315d9d; background: #e3ecfa; }
.image-count { position: absolute; right: 12px; bottom: 12px; z-index: 1; min-height: 28px; display: inline-flex; align-items: center; gap: 6px; padding: 0 10px; border-radius: 999px; background: rgba(24, 27, 32, .82); color: #fff; font-size: 11px; font-weight: 700; }
.image-count svg { width: 14px; height: 14px; }
.design-card-body { padding: 17px; display: flex; flex-direction: column; flex: 1; }
.design-card-head { display: grid; grid-template-columns: minmax(0, 1fr) 34px; gap: 10px; align-items: start; }
.design-title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; min-height: 40px; overflow: hidden; font-size: 16px; line-height: 1.25; font-weight: 700; }
.open-design { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); transition: .18s ease; }
.open-design:hover { color: var(--coral-dark); border-color: #efc1b8; background: #fff7f5; }
.open-design svg { width: 17px; height: 17px; }
.design-summary { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 38px; color: var(--muted); font-size: 12px; line-height: 1.55; margin: 10px 0 14px; }
.design-author { display: flex; align-items: center; gap: 9px; margin-top: auto; }
.design-author strong, .design-author small { display: block; }
.design-author strong { max-width: 170px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.design-author small { color: var(--muted); margin-top: 2px; font-size: 10px; }
.design-meta { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; border-top: 1px solid var(--line); padding-top: 13px; margin-top: 15px; color: #777d86; }
.design-meta span { min-width: 0; display: grid; grid-template-columns: 16px 1fr; gap: 2px 6px; align-items: center; background: #f7f8fa; border: 1px solid #eceff3; border-radius: 7px; padding: 8px; font-size: 11px; }
.design-meta span svg { width: 15px; height: 15px; grid-row: 1 / span 2; color: #8b929d; }
.design-meta strong { color: var(--text); font-size: 13px; line-height: 1; }
.design-meta small { color: var(--muted); font-size: 9px; font-weight: 700; white-space: nowrap; }
.card-actions { display: flex; gap: 8px; border-top: 1px solid var(--line); padding-top: 12px; margin-top: 12px; }
.card-actions .button { flex: 1; min-height: 34px; padding: 0 8px; font-size: 11px; }
.card-actions form { flex: 1; margin: 0; }
.card-actions form .button { width: 100%; }
.result-count { color: var(--muted); font-size: 12px; margin: 20px 0 12px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.result-count span:last-child { color: var(--coral-dark); font-weight: 700; }
.empty-state { background: var(--surface); border: 1px dashed #cbd0d7; padding: 70px 20px; text-align: center; border-radius: 8px; }
.empty-state > svg { width: 36px; height: 36px; color: #9aa0a9; }
.empty-state h3 { margin: 15px 0 7px; }
.empty-state p { margin: 0 0 20px; color: var(--muted); font-size: 13px; }

.filter-bar { display: grid; grid-template-columns: minmax(220px, 1fr) 38px; align-items: center; gap: 8px; min-width: 0; }
.search-box, .input-wrap { display: flex; align-items: center; gap: 9px; background: var(--bg); border: 1px solid transparent; border-radius: 7px; padding: 0 12px; min-height: 40px; color: #90959d; }
.search-box:focus-within, .input-wrap:focus-within { border-color: var(--coral); background: #fff; box-shadow: 0 0 0 3px rgba(239, 104, 79, .11); }
.search-box input, .input-wrap input { border: 0; background: transparent; outline: 0; width: 100%; min-width: 0; }
.search-box svg, .input-wrap svg { width: 17px; }
.status-tabs { display: flex; gap: 3px; overflow-x: auto; }
.status-tabs a { min-height: 35px; padding: 0 11px; border-radius: 6px; display: inline-flex; align-items: center; color: var(--muted); white-space: nowrap; font-size: 11px; font-weight: 700; }
.status-tabs a.active { background: var(--ink); color: #fff; }
.filter-submit { background: var(--coral); color: #fff; }
.clear-filter { min-height: 35px; display: inline-flex; align-items: center; gap: 6px; color: var(--coral-dark); font-size: 11px; font-weight: 700; white-space: nowrap; padding: 0 6px; }
.clear-filter svg { width: 14px; height: 14px; }

.activity-section { margin-top: 40px; }
.activity-list { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.activity-list a { display: grid; grid-template-columns: 32px 1fr auto; align-items: center; gap: 12px; padding: 14px 17px; border-bottom: 1px solid var(--line); font-size: 12px; }
.activity-list a:last-child { border: 0; }
.activity-list em { color: var(--coral-dark); font-style: normal; font-weight: 600; }
.activity-list small { display: block; color: var(--muted); margin-top: 3px; }
.activity-list time { color: var(--muted); font-size: 10px; }

.upload-layout { max-width: 970px; }
.form-section { display: grid; grid-template-columns: 270px 1fr; gap: 45px; border-top: 1px solid var(--line); padding: 30px 0; }
.form-section-head { display: flex; gap: 13px; }
.form-section-head > span { width: 29px; height: 29px; border-radius: 50%; display: grid; place-items: center; background: var(--ink); color: #fff; font-size: 10px; flex: 0 0 auto; }
.form-section h2 { font-size: 16px; margin: 3px 0 6px; }
.form-section p { color: var(--muted); font-size: 12px; line-height: 1.5; margin: 0; }
.form-fields { display: grid; gap: 21px; }
.form-fields label, .status-form label { display: block; font-size: 12px; font-weight: 700; position: relative; }
.form-fields label > small { float: right; color: #a0a4ab; font-weight: 500; }
.form-fields input, .form-fields textarea, .status-form select, .comment-form textarea { width: 100%; border: 1px solid #ccd1d8; border-radius: 7px; background: #fff; outline: 0; padding: 12px 13px; margin-top: 8px; resize: vertical; transition: .15s; }
.form-fields input:focus, .form-fields textarea:focus, .status-form select:focus, .comment-form textarea:focus { border-color: var(--coral); box-shadow: 0 0 0 3px rgba(239, 104, 79, .11); }
.field-help { display: block; text-align: right; font-size: 10px; color: #9a9fa7; font-weight: 500; margin-top: 5px; }
.dropzone { min-height: 310px; border: 1.5px dashed #bfc5cd; background: #fafbfc; border-radius: 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; cursor: pointer; padding: 30px; position: relative; overflow: hidden; }
.dropzone.dragging { border-color: var(--coral); background: #fff7f5; }
.dropzone input { position: absolute; opacity: 0; pointer-events: none; }
.upload-icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: #eceef1; margin-bottom: 15px; }
.dropzone strong { font-size: 14px; }
.dropzone > span:not(.upload-icon) { font-size: 12px; color: var(--muted); margin: 5px 0 16px; }
.dropzone > small { font-size: 10px; color: #9a9fa7; }
.dropzone img { display: none; position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #eef0f3; }
.dropzone.has-preview img[src] { display: block; }
.preview-remove { display: none; position: absolute; top: 10px; right: 10px; z-index: 2; width: 34px; height: 34px; border: 0; border-radius: 50%; background: #fff; box-shadow: var(--shadow); cursor: pointer; }
.dropzone.has-preview .preview-remove { display: grid; place-items: center; }
.multi-preview { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; margin-top: 12px; }
.preview-tile { aspect-ratio: 1 / 1; position: relative; border: 1px solid var(--line); border-radius: 7px; overflow: hidden; background: #eef0f3; }
.preview-tile img { width: 100%; height: 100%; object-fit: cover; }
.preview-tile button { position: absolute; top: 5px; right: 5px; width: 24px; height: 24px; border: 0; border-radius: 50%; background: #fff; box-shadow: var(--shadow); cursor: pointer; }
.form-actions { border-top: 1px solid var(--line); padding-top: 20px; display: flex; justify-content: flex-end; gap: 10px; }

.detail-topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.detail-actions { display: flex; gap: 8px; align-items: center; }
.detail-actions form { margin: 0; }
.back-link { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; font-weight: 700; }
.design-group-head { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 26px; margin-bottom: 20px; }
.design-group-head h1 { font-size: 28px; margin: 14px 0 17px; line-height: 1.2; }
.design-group-head > p { color: var(--muted); font-size: 13px; line-height: 1.65; margin: 18px 0 0; max-width: 820px; }
.item-gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.item-card { background: #fff; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.item-preview { position: relative; background: #e9ebee; padding: 14px; min-height: 320px; display: grid; place-items: center; }
.item-preview img { max-width: 100%; max-height: 560px; object-fit: contain; box-shadow: 0 8px 26px rgba(26, 30, 36, .12); }
.item-preview span { position: absolute; top: 12px; left: 12px; min-height: 24px; padding: 0 8px; border-radius: 999px; background: rgba(255,255,255,.92); display: inline-flex; align-items: center; font-size: 10px; font-weight: 700; }
.item-vote-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; padding: 12px; align-items: center; }
.item-vote-row form { margin: 0; }
.icon-button.danger { color: var(--red); background: var(--red-soft); }
.edit-item-list { display: grid; gap: 12px; }
.edit-item { display: grid; grid-template-columns: 112px 100px 80px; gap: 13px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 10px; }
.edit-item img { width: 112px; height: 80px; object-fit: cover; border-radius: 6px; background: #e9ebee; }
.edit-item label { font-size: 11px; font-weight: 700; }
.edit-item input[type="number"] { width: 100%; height: 36px; border: 1px solid var(--line); border-radius: 6px; padding: 0 8px; margin-top: 5px; }
.check-row { display: flex !important; align-items: center; gap: 7px; }
.detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 355px; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.preview-panel { min-width: 0; background: #e9ebee; }
.preview-toolbar { height: 48px; background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 14px 0 17px; color: #8c929b; font-size: 10px; font-weight: 700; letter-spacing: .1em; }
.large-preview { min-height: 610px; height: calc(100vh - 180px); max-height: 820px; display: grid; place-items: center; padding: 30px; }
.large-preview img { max-width: 100%; max-height: 100%; object-fit: contain; box-shadow: 0 8px 30px rgba(26, 30, 36, .13); }
.version-strip { display: flex; gap: 9px; overflow-x: auto; padding: 12px 14px; border-top: 1px solid #d5d8dd; background: #fff; }
.version-thumb { width: 70px; height: 54px; flex: 0 0 auto; position: relative; border: 2px solid transparent; border-radius: 6px; padding: 0; overflow: hidden; background: #e9ebee; cursor: pointer; }
.version-thumb.active { border-color: var(--coral); }
.version-thumb img { width: 100%; height: 100%; object-fit: cover; }
.version-thumb span { position: absolute; right: 3px; bottom: 3px; min-width: 20px; padding: 2px 4px; border-radius: 3px; background: rgba(24, 27, 32, .82); color: #fff; font-size: 8px; font-weight: 700; }
.detail-sidebar { padding: 28px; border-left: 1px solid var(--line); }
.detail-sidebar > h1 { font-size: 23px; line-height: 1.25; margin: 15px 0 20px; overflow-wrap: anywhere; }
.author-row { display: flex; align-items: center; gap: 10px; }
.author-row strong, .author-row small { display: block; }
.author-row strong { font-size: 12px; }
.author-row small { color: var(--muted); font-size: 10px; margin-top: 3px; }
.description, .vote-block, .status-form { border-top: 1px solid var(--line); margin-top: 23px; padding-top: 21px; }
.description h2, .vote-block h2 { font-size: 12px; margin: 0 0 8px; }
.description p { font-size: 12px; color: var(--muted); line-height: 1.65; margin: 0; }
.vote-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.vote-buttons form { min-width: 0; }
.vote-button { width: 100%; min-height: 66px; display: flex; align-items: center; gap: 9px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 7px; background: #fff; cursor: pointer; text-align: left; }
.vote-button > span { font-size: 11px; font-weight: 700; }
.vote-button small { display: block; font-size: 9px; color: var(--muted); margin-top: 2px; }
.vote-button.like.selected { border-color: var(--green); color: var(--green); background: var(--green-soft); }
.vote-button.dislike.selected { border-color: var(--red); color: var(--red); background: var(--red-soft); }
.vote-hint { font-size: 9px; color: var(--green); display: flex; gap: 4px; margin: 9px 0 0; }
.vote-hint svg { width: 13px; }
.voter-details { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 10px; }
.voter-details summary { display: flex; justify-content: space-between; align-items: center; list-style: none; cursor: pointer; color: var(--muted); font-size: 10px; font-weight: 700; }
.voter-details summary::-webkit-details-marker { display: none; }
.voter-details summary svg { width: 14px; }
.voter-details > div { display: grid; gap: 7px; margin-top: 10px; }
.voter-details span { display: flex; justify-content: space-between; align-items: center; font-size: 10px; }
.voter-details em { font-style: normal; font-size: 8px; font-weight: 700; padding: 3px 6px; border-radius: 4px; }
.voter-details em.like { color: var(--green); background: var(--green-soft); }
.voter-details em.dislike { color: var(--red); background: var(--red-soft); }
.status-form { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: end; }
.status-form select { height: 40px; padding: 0 9px; }
.status-form .button { padding: 0 10px; }
.revision-form { border-top: 1px solid var(--line); margin-top: 23px; padding-top: 21px; display: grid; gap: 12px; }
.revision-form h2 { font-size: 12px; margin: 0; }
.revision-file { min-height: 68px; border: 1px dashed #bcc2ca; border-radius: 7px; padding: 10px; display: flex; align-items: center; gap: 10px; cursor: pointer; color: var(--coral-dark); }
.revision-file input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.revision-file span { color: var(--text); font-size: 10px; font-weight: 700; }
.revision-file small { display: block; color: var(--muted); font-size: 8px; margin-top: 3px; font-weight: 500; }
.revision-note { display: block; font-size: 10px; font-weight: 700; }
.revision-note textarea { width: 100%; border: 1px solid #ccd1d8; border-radius: 7px; padding: 10px; margin-top: 6px; resize: vertical; outline: 0; font-size: 11px; }
.revision-note textarea:focus { border-color: var(--coral); box-shadow: 0 0 0 3px rgba(239, 104, 79, .11); }
.version-history { max-width: 930px; margin: 40px auto 0; }
.version-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.version-list button { min-width: 0; border: 1px solid var(--line); border-radius: 7px; background: #fff; padding: 8px; display: grid; grid-template-columns: 76px 1fr; align-items: center; gap: 10px; text-align: left; cursor: pointer; }
.version-list button:hover { border-color: #b8bdc5; }
.version-list img { width: 76px; height: 58px; object-fit: cover; border-radius: 5px; background: #e9ebee; }
.version-list strong, .version-list small, .version-list em { display: block; overflow: hidden; text-overflow: ellipsis; }
.version-list strong { font-size: 10px; white-space: nowrap; }
.version-list small { color: var(--muted); font-size: 8px; margin-top: 3px; white-space: nowrap; }
.version-list em { color: #555b64; font-size: 8px; font-style: normal; margin-top: 5px; line-height: 1.3; }
.comments-section { max-width: 930px; margin: 40px auto 0; }
.comment-form { display: grid; grid-template-columns: 38px 1fr; gap: 12px; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 17px; }
.comment-form textarea { margin: 0 0 9px; }
.comment-form > div { text-align: right; }
.comment-list { margin-top: 14px; }
.comment { display: grid; grid-template-columns: 38px 1fr; gap: 12px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.comment header { display: flex; align-items: center; gap: 8px; font-size: 11px; }
.comment header span { background: #e9ebee; color: var(--muted); padding: 3px 6px; border-radius: 4px; font-size: 8px; font-weight: 700; }
.comment time { margin-left: auto; color: var(--muted); font-size: 9px; }
.comment p { margin: 7px 0 0; font-size: 12px; color: #4f555e; line-height: 1.6; }
.empty-inline { padding: 30px; color: var(--muted); text-align: center; font-size: 12px; }
.empty-inline svg { width: 25px; }

.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 8px; }
table { border-collapse: collapse; width: 100%; min-width: 720px; }
th, td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--line); font-size: 12px; }
th { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; background: #fafbfc; }
tbody tr:last-child td { border-bottom: 0; }
.user-cell { display: flex; align-items: center; gap: 10px; }
.user-cell strong, .user-cell small { display: block; }
.user-cell small { color: var(--muted); margin-top: 3px; }
.role-pill { font-size: 9px; font-weight: 700; padding: 5px 8px; border-radius: 5px; background: #eceef1; }
.role-admin { color: var(--red); background: var(--red-soft); }
.role-designer { color: var(--blue); background: var(--blue-soft); }
.role-reviewer { color: var(--green); background: var(--green-soft); }
.role-0 { color: var(--amber); background: var(--amber-soft); }
.sr-only { position: absolute; left: 0; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
.table-action { margin-left: auto; color: var(--muted); }
.user-create-form { display: none; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 22px; margin-bottom: 18px; }
.user-create-form.open { display: block; }
.user-form-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; }
.user-form-head h2 { margin: 0 0 4px; font-size: 17px; }
.user-form-head p { margin: 0; color: var(--muted); font-size: 11px; }
.user-form-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; }
.user-create-form label, .user-edit-form label { display: block; font-size: 11px; font-weight: 700; }
.user-create-form input, .user-create-form select, .user-edit-form input, .user-edit-form select { width: 100%; height: 42px; border: 1px solid #ccd1d8; border-radius: 7px; background: #fff; padding: 0 11px; margin-top: 7px; outline: 0; }
.user-create-form input:focus, .user-create-form select:focus, .user-edit-form input:focus, .user-edit-form select:focus { border-color: var(--coral); box-shadow: 0 0 0 3px rgba(239, 104, 79, .11); }
.user-form-actions { display: flex; justify-content: flex-end; margin-top: 17px; }
.user-dialog { width: min(480px, calc(100% - 28px)); border: 0; border-radius: 8px; padding: 0; box-shadow: 0 24px 70px rgba(20, 25, 33, .22); }
.user-dialog::backdrop { background: rgba(22, 25, 30, .48); }
.user-edit-form { padding: 23px; display: grid; gap: 15px; }
.user-edit-form .user-form-head { margin-bottom: 0; }
.user-edit-form label small { float: right; color: var(--muted); font-weight: 500; }
.dialog-actions { display: flex; justify-content: flex-end; margin-top: 5px; }
.user-delete-form { border-top: 1px solid var(--line); padding: 15px 23px; display: flex; justify-content: flex-start; }

.toast { position: fixed; top: 18px; right: 20px; z-index: 50; min-width: 280px; max-width: 430px; min-height: 48px; padding: 10px 12px; border-radius: 7px; display: flex; align-items: center; gap: 9px; color: #fff; box-shadow: var(--shadow); font-size: 12px; }
.toast-success { background: #23745b; }
.toast-error { background: #a74343; }
.toast .icon-button { margin-left: auto; color: #fff; }
.error-page { min-height: 65vh; display: grid; place-content: center; justify-items: center; text-align: center; }
.error-page > span { font-size: 70px; font-weight: 700; color: var(--coral); }
.error-page h1 { margin: 0; }
.error-page p { color: var(--muted); }

.auth-shell { min-height: 100vh; background: #fff; }
.login-layout { min-height: 100vh; display: grid; place-items: center; background: #fff; }
.login-visual { position: relative; overflow: hidden; background: #202329; color: #fff; padding: 40px 50px; min-height: 680px; }
.visual-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.visual-copy { position: relative; z-index: 2; margin-top: 12vh; max-width: 520px; }
.visual-copy h1 { font-size: clamp(42px, 5vw, 72px); line-height: 1.02; margin: 12px 0 20px; }
.visual-copy > p:last-child { color: #bec3cb; font-size: 15px; line-height: 1.7; max-width: 410px; }
.artwork-stack { position: absolute; width: 60%; height: 55%; right: -5%; bottom: -9%; transform: rotate(-7deg); }
.artwork-card { position: absolute; width: 48%; aspect-ratio: 4 / 5; padding: 22px; box-shadow: 0 20px 40px rgba(0, 0, 0, .26); font-size: clamp(19px, 2.5vw, 38px); font-weight: 700; line-height: .9; }
.artwork-card b { position: absolute; bottom: 16px; right: 18px; font-size: 14px; }
.art-one { background: #ef684f; left: 0; top: 12%; }
.art-two { background: #77d72d; color: #14200d; left: 27%; top: 0; z-index: 2; }
.art-three { background: #f2e5d6; color: #b6342e; left: 53%; top: 18%; z-index: 3; }
.login-panel { width: 100%; display: grid; place-items: center; padding: 45px; }
.login-form-wrap { width: 100%; max-width: 520px; }
.login-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 70px; font-size: 22px; font-weight: 600; color: var(--text); }
.login-brand strong { color: var(--coral); }
.login-brand-mark { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 7px; background: var(--coral); color: #fff; font-size: 20px; font-weight: 700; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; background: var(--bg); border: 1px solid var(--line); border-radius: 7px; padding: 4px; margin-bottom: 36px; }
.auth-tabs a { min-height: 38px; display: grid; place-items: center; border-radius: 5px; color: var(--muted); font-size: 12px; font-weight: 700; }
.auth-tabs a.active { background: #fff; color: var(--text); box-shadow: 0 2px 8px rgba(25, 31, 41, .07); }
.login-form-wrap h2 { font-size: 28px; margin: 9px 0 7px; }
.muted { color: var(--muted); font-size: 13px; line-height: 1.5; }
.stack-form { display: grid; gap: 17px; margin-top: 30px; }
.stack-form > label { font-size: 12px; font-weight: 700; }
.stack-form .input-wrap { border-color: var(--line); background: #fff; margin-top: 8px; min-height: 47px; }
.stack-form .button { min-height: 47px; margin-top: 5px; }
.demo-note { margin-top: 30px; padding: 13px 15px; display: grid; grid-template-columns: 1fr auto; gap: 3px 10px; border: 1px solid var(--line); border-radius: 7px; font-size: 11px; color: var(--muted); }
.demo-note strong { grid-column: 1 / -1; color: var(--text); }
.demo-note code { color: var(--coral-dark); }
.registration-note { display: flex; align-items: center; justify-content: center; gap: 7px; margin: 18px 0 0; color: var(--muted); font-size: 11px; }
.registration-note svg { width: 15px; }

@media (max-width: 1100px) {
    .main-content { padding: 32px 28px 60px; }
    .design-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .stat:nth-child(2) { border-right: 0; }
    .stat:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
    .designs-toolbar { grid-template-columns: 1fr; }
    .status-tabs { width: 100%; }
    .clear-filter { justify-content: center; border-top: 1px solid var(--line); padding-top: 10px; }
    .detail-layout { grid-template-columns: minmax(0, 1fr) 310px; }
}

@media (max-width: 760px) {
    .app-shell { padding: 0; }
    .sidebar { display: none; }
    .mobile-header { height: 61px; padding: 0 17px; display: flex; align-items: center; justify-content: space-between; background: #1d2025; color: #fff; position: sticky; top: 0; z-index: 30; }
    .mobile-header .brand { font-size: 15px; }
    .mobile-menu { display: none; position: fixed; top: 61px; left: 0; right: 0; z-index: 29; background: #25292f; padding: 8px 17px 14px; box-shadow: var(--shadow); }
    .mobile-menu.open { display: grid; }
    .mobile-menu a { color: #fff; padding: 12px 4px; border-bottom: 1px solid #3b4048; font-size: 13px; }
    .main-content { padding: 24px 16px 50px; }
    .page-header { align-items: flex-start; margin-bottom: 22px; }
    .page-header h1 { font-size: 26px; }
    .page-header > .button { min-width: 42px; padding: 0 12px; }
    .designs-hero { display: grid; }
    .designs-hero-actions { width: 100%; display: grid; grid-template-columns: 1fr auto; }
    .designs-hero-actions > span { justify-content: center; }
    .designs-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .stats-grid { gap: 0; }
    .stat { padding: 16px; min-height: 92px; }
    .stat-icon { width: 36px; height: 36px; }
    .stat strong { font-size: 21px; }
    .design-grid { grid-template-columns: 1fr; gap: 14px; }
    .filter-bar { display: grid; }
    .status-tabs a { padding: 0 10px; }
    .result-count { align-items: flex-start; flex-direction: column; }
    .activity-list a { grid-template-columns: 32px 1fr; }
    .activity-list time { display: none; }
    .form-section { grid-template-columns: 1fr; gap: 22px; padding: 24px 0; }
    .dropzone { min-height: 260px; }
    .detail-layout { grid-template-columns: 1fr; }
    .preview-toolbar { height: 43px; }
    .large-preview { height: auto; min-height: 340px; max-height: none; padding: 16px; }
    .detail-sidebar { border-left: 0; border-top: 1px solid var(--line); padding: 22px 18px; }
    .version-list { grid-template-columns: 1fr; }
    .item-gallery { grid-template-columns: 1fr; }
    .item-preview { min-height: 260px; padding: 10px; }
    .item-vote-row { grid-template-columns: 1fr; }
    .edit-item { grid-template-columns: 82px 1fr 70px; }
    .edit-item img { width: 82px; height: 64px; }
    .comments-section { margin-top: 30px; }
    .comment-form { grid-template-columns: 1fr; }
    .comment-form > .avatar { display: none; }
    .comment header { flex-wrap: wrap; }
    .comment time { width: 100%; margin-left: 0; }
    .login-layout { display: block; min-height: 100vh; }
    .login-panel { min-height: 100vh; padding: 30px 22px; }
    .login-brand { margin-bottom: 60px; }
    .toast { left: 12px; right: 12px; top: 72px; min-width: 0; }
    .user-form-grid { grid-template-columns: 1fr; }
}

@media (max-width: 430px) {
    .page-header { display: grid; }
    .page-header > .button { width: 100%; }
    .designs-hero-actions { grid-template-columns: 1fr; }
    .designs-overview { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
    .stat { display: block; }
    .stat-icon { margin-bottom: 9px; }
    .section-head { align-items: flex-start; }
    .vote-buttons { grid-template-columns: 1fr; }
    .status-form { grid-template-columns: 1fr; }
    .form-actions .button { flex: 1; padding: 0 8px; }
}
