.admin { min-height: 100vh; display: grid; grid-template-columns: 272px minmax(0, 1fr); background: var(--paper); color: var(--ink); }
.side { background: var(--blue); color: white; position: sticky; top: 0; height: 100vh; overflow: auto; }
.side-brand { display: flex; align-items: center; background: white; border-bottom: 3px solid var(--orange); padding: .9rem 1rem; overflow: hidden; }
.side-brand img { height: 38px; width: auto; max-width: 100%; object-fit: contain; }
.side-nav { display: flex; flex-direction: column; padding: .7rem .75rem 1.4rem; }
.side-group { margin: 1.05rem .4rem .3rem; color: var(--orange); font-size: .84rem; font-weight: 700; }
.side-link { display: block; color: rgba(255,255,255,.9); text-decoration: none; padding: .58rem .75rem; border-inline-start: 3px solid transparent; font-weight: 600; }
.side-link:hover { background: rgba(255,255,255,.08); color: white; }
.side-link.active { background: rgba(255,255,255,.12); color: white; border-inline-start-color: var(--orange); }
.admin-main { min-width: 0; }
.admin-top { display: flex; justify-content: flex-end; gap: .8rem; align-items: center; min-height: 64px; padding: .7rem 1.3rem; background: white; border-bottom: 1px solid var(--line); }
.admin-top a { color: var(--blue); font-weight: 700; text-decoration: none; }
.admin-body { padding: 1.3rem 1.3rem 3rem; }
.page-head { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-end; margin-bottom: 1rem; }
.page-head h1 { color: var(--blue); font-size: 1.8rem; }
.page-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: .7rem; margin-bottom: 1rem; }
.stat { background: white; border: 1px solid var(--line); padding: .9rem 1rem; }
.stat b { display: block; font-size: 1.5rem; color: var(--blue); }
.stat span { color: var(--muted); font-size: .86rem; }
.quick { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.panel { background: white; border: 1px solid var(--line); padding: 1rem 1rem .4rem; margin-bottom: 1rem; }
.panel h2 { font-size: 1.05rem; margin-bottom: .8rem; color: var(--blue); }
.tabs { display: flex; gap: .35rem; margin-bottom: 1rem; }
.tabs button { border: 1px solid var(--line); background: #f7f7f7; min-height: 38px; padding: .35rem .8rem; cursor: pointer; font-weight: 700; }
.tabs button.is-active { background: white; color: var(--blue); border-color: var(--blue); }
.data { width: 100%; border-collapse: collapse; background: white; }
.data th, .data td { text-align: start; padding: .7rem .75rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.data th { font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
html[lang="ar"] .data th, html[lang="ku"] .data th { letter-spacing: 0; text-transform: none; font-size: .9rem; }
.data tr:hover td { background: #fafaf8; }
.thumb-mini { width: 54px; height: 40px; max-width: 54px; max-height: 40px; object-fit: cover; object-position: center; background: var(--paper); display: block; }
.phone-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)) auto auto; gap: .7rem; align-items: end; padding: .9rem 0; border-bottom: 1px solid var(--line); }
.phone-row .field { margin-bottom: 0; }
.phone-row .check { margin: 0 0 .65rem; white-space: nowrap; }
.filters-row { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.filters-row input, .filters-row select { min-height: 40px; border: 1px solid var(--line); padding: .4rem .6rem; background: white; }
.split { display: grid; grid-template-columns: 1.4fr .8fr; gap: 1rem; }
.check { display: flex; align-items: center; gap: .45rem; margin: .35rem 0; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: .7rem; }
.media-card { border: 1px solid var(--line); background: white; overflow: hidden; display: flex; flex-direction: column; padding: 0; width: 100%; text-align: start; font: inherit; color: inherit; cursor: pointer; }
.media-card img { width: 100%; height: 110px; max-height: 110px; object-fit: cover; object-position: center; background: var(--paper); flex: none; }
.media-card div { padding: .45rem .55rem .6rem; font-size: .82rem; overflow-wrap: anywhere; }
.media-card.is-selected { border-color: var(--orange); }
.dropzone { position: relative; border: 1px dashed #b9b3aa; background: #fafaf8; min-height: 92px; display: flex; align-items: center; justify-content: center; text-align: center; padding: 1rem; margin-bottom: 1rem; }
.dropzone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.picker { position: fixed; inset: 0; background: rgba(20,18,16,.45); z-index: 60; display: flex; justify-content: flex-end; }
.picker-panel { width: min(760px, 100%); height: 100%; background: #f6f6f6; overflow: auto; padding: 1rem; }
.chosen { display: flex; gap: .5rem; flex-wrap: wrap; }
.chosen figure { margin: 0; width: 92px; overflow: hidden; }
.chosen img { width: 92px; height: 72px; max-width: 100%; object-fit: cover; object-position: center; border: 1px solid var(--line); }
.admin-note { color: var(--muted); font-size: .9rem; }
.activity { list-style: none; margin: 0; padding: 0; }
.activity li { display: grid; gap: .2rem; padding: .85rem 0; border-bottom: 1px solid var(--line); }
.activity li:last-child { border-bottom: 0; }
.activity-line { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem .5rem; margin: 0; color: var(--muted); font-size: .82rem; }
.activity-sep { width: .38rem; height: .38rem; border-radius: 50%; background: var(--orange); flex: none; }
.activity strong { color: var(--ink); font-weight: 650; }
.activity time { color: var(--muted); font-size: .8rem; }
.hero-admin-preview { width: min(360px, 100%); max-width: 100%; aspect-ratio: 4 / 3; height: auto; object-fit: cover; object-position: center; border: 1px solid var(--line); border-inline-start: 4px solid var(--orange); margin: .35rem 0 .8rem; background: var(--paper); }
@media (max-width: 980px) {
  .admin { grid-template-columns: 1fr; }
  .side { position: relative; height: auto; }
  .phone-row { grid-template-columns: 1fr 1fr; }
  .stats, .split { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .stats, .split, .page-head { grid-template-columns: 1fr; display: grid; }
  .page-head { align-items: start; }
}
