@charset "UTF-8";

:root {
  --ink: #203b32;
  --green: #396e56;
  --green-deep: #28533f;
  --muted: #78877e;
  --paper: #f4f6f1;
  --surface: #fffefa;
  --line: #e3e9e1;
  --mint: #e5efe4;
  --peach: #f7e7dc;
  --danger: #a85f50;
  --ease: cubic-bezier(.2, .75, .25, 1);
}

* { box-sizing: border-box; }
body { min-height: 100vh; margin: 0; background: var(--paper); color: var(--ink); font-family: "Noto Sans Arabic", "Geeza Pro", Tahoma, Arial, sans-serif; font-size: 15px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { outline-offset: 3px; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid #b77a59; }
a { color: inherit; text-decoration: none; }
button { color: inherit; }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 19px; height: 19px; display: block; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: 0 0 auto; }
.container { width: min(1160px, calc(100% - 56px)); margin-inline: auto; }

.admin-header { height: 76px; border-bottom: 1px solid rgba(219, 228, 217, .8); background: rgba(255, 255, 251, .75); }
.header-inner { height: 100%; display: flex; align-items: center; justify-content: space-between; }
.header-actions { display: flex; align-items: center; gap: 8px; }
.admin-brand { display: inline-flex; align-items: center; gap: 10px; }
.brand-mark { width: 35px; height: 35px; display: grid; grid-template: repeat(2, 1fr) / repeat(2, 1fr); gap: 3px; padding: 6px; border-radius: 11px; background: var(--green-deep); transform: rotate(-4deg); }
.brand-mark i { border-radius: 2px; background: #f3f2e9; }
.brand-mark i:nth-child(2) { opacity: .72; }.brand-mark i:nth-child(3) { opacity: .52; }
.admin-brand > span:last-child { display: grid; line-height: 1.25; }
.admin-brand strong { font-size: 16px; }
.admin-brand small { margin-top: 3px; color: #88948a; font-size: 9px; }
.preview-link { min-height: 42px; display: inline-flex; align-items: center; gap: 8px; padding: 0 13px; border: 1px solid #dce5da; border-radius: 11px; color: #54725e; font-size: 11px; font-weight: 700; transition: background .2s var(--ease), transform .2s var(--ease); }
.preview-link:hover { transform: translateY(-1px); background: white; }
.preview-link .icon { width: 16px; height: 16px; }
.access-denied { margin-top: 40px; padding: clamp(24px, 5vw, 48px); }
.access-denied h1 { margin: 14px 0 8px; font-size: clamp(22px, 4vw, 30px); }
.access-denied p { margin: 0 0 20px; color: var(--muted); font-size: 13px; }
.access-denied .primary-action { text-decoration: none; }

.admin-main { padding-block: 43px 60px; }
.welcome-row { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 25px; }
.section-kicker { display: inline-flex; align-items: center; gap: 8px; color: #77927c; font-size: 10px; font-weight: 700; }
.section-kicker::before { content: ""; width: 15px; height: 1px; background: #94ad96; }
.welcome-row h1 { margin: 6px 0 2px; color: #264638; font-size: clamp(27px, 4vw, 37px); line-height: 1.35; letter-spacing: -.04em; }
.welcome-row h1 span { color: #63896a; }
.welcome-row p { margin: 0; color: #7e8b81; font-size: 12px; }
.save-indicator { min-height: 34px; display: inline-flex; align-items: center; gap: 7px; padding: 0 10px; border: 1px solid #dfe9dc; border-radius: 99px; background: #f7faf4; color: #66816a; font-size: 9px; white-space: nowrap; }
.save-indicator i { width: 6px; height: 6px; border-radius: 50%; background: #87a886; box-shadow: 0 0 0 3px rgba(135, 168, 134, .13); }
.local-notice { display: flex; align-items: center; gap: 11px; margin-bottom: 20px; padding: 13px 15px; border: 1px solid #eadfd1; border-radius: 13px; background: #fbf6ef; }
.notice-icon { width: 31px; height: 31px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 10px; background: #f4e6d8; color: #a27452; }
.notice-icon .icon { width: 17px; height: 17px; }
.local-notice p { display: grid; margin: 0; line-height: 1.5; }
.local-notice strong { color: #755d49; font-size: 10px; }
.local-notice p span { color: #8e8172; font-size: 9px; }

.admin-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(320px, .88fr); align-items: start; gap: 17px; }
.panel { min-width: 0; padding: 21px; border: 1px solid #e5ebe3; border-radius: 17px; background: var(--surface); box-shadow: 0 7px 23px rgba(38, 64, 44, .035); }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.panel-heading h2 { margin: 3px 0 0; color: #304c3b; font-size: 18px; line-height: 1.4; }
.item-count { padding: 5px 9px; border-radius: 99px; background: #eff4ec; color: #648068; font-size: 9px; white-space: nowrap; }
.editor-mark, .settings-mark { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 11px; background: #e8f0e5; color: #62826a; }
.editor-mark .icon { width: 17px; height: 17px; }
.settings-mark { background: #f7e9de; color: #a7795b; font-size: 12px; font-weight: 700; }
.panel-description { margin: 6px 0 16px; color: #879288; font-size: 10px; }
.managed-list { display: grid; gap: 9px; }
.managed-item { display: flex; align-items: center; gap: 10px; min-height: 66px; padding: 10px; border: 1px solid #edf0e9; border-radius: 12px; background: #fdfefb; transition: border-color .2s var(--ease), opacity .2s var(--ease), transform .2s var(--ease); animation: item-in .28s var(--ease) both; }
@keyframes item-in { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
.managed-item:hover { border-color: #dfe8dc; }
.managed-item.is-hidden { opacity: .56; background: #f7f8f5; }
.managed-icon { width: 39px; height: 39px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 12px; background: #e8f0e5; color: #5e8065; }
.managed-icon[data-icon="calendar"] { background: var(--peach); color: #a67353; }
.managed-icon[data-icon="team"] { background: #eeeaf5; color: #7b6e98; }
.managed-icon[data-icon="medical"] { background: #e4f0e7; color: #54816b; }
.managed-icon .icon { width: 19px; height: 19px; }
.managed-copy { min-width: 0; flex: 1; display: grid; line-height: 1.5; }
.managed-copy strong { overflow: hidden; color: #405d49; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.managed-copy span { overflow: hidden; color: #8a968d; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.managed-badge { padding: 4px 7px; border-radius: 99px; background: #edf4e9; color: #668468; font-size: 8px; white-space: nowrap; }
.managed-badge.hidden-badge { background: #f1f1ed; color: #8a918a; }
.item-actions { display: flex; gap: 5px; }
.item-action { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid #e7ece5; border-radius: 9px; background: white; color: #718178; cursor: pointer; transition: background .17s var(--ease), border-color .17s var(--ease), color .17s var(--ease), transform .17s var(--ease); }
.item-action:hover { transform: translateY(-1px); border-color: #d6e2d4; background: #f6f9f4; color: #4e7759; }
.item-action .icon { width: 15px; height: 15px; }
.item-action.delete:hover { border-color: #eedbd4; background: #fbf1ed; color: var(--danger); }
.list-empty[hidden] { display: none; }
.list-empty { min-height: 190px; display: grid; justify-items: center; align-content: center; gap: 5px; border: 1px dashed #dce5da; border-radius: 13px; color: #88948a; text-align: center; }
.empty-icon { width: 39px; height: 39px; display: grid; place-items: center; margin-bottom: 5px; border-radius: 12px; background: #edf3ea; color: #779078; }
.empty-icon .icon { width: 19px; height: 19px; }
.list-empty strong { color: #5d7362; font-size: 11px; }
.list-empty span:last-child { font-size: 9px; }

.admin-form { display: flex; flex-direction: column; margin-top: 16px; }
.admin-form > label:not(.checkbox-row), .field-group label { margin: 11px 0 5px; color: #5b7061; font-size: 10px; font-weight: 700; }
.admin-form input:not([type="checkbox"]), .admin-form select, .admin-form textarea { width: 100%; min-height: 42px; padding: 9px 11px; border: 1px solid #e1e8df; border-radius: 9px; background: #fcfdfa; color: #304b3b; font-size: 11px; transition: border-color .17s var(--ease), box-shadow .17s var(--ease); }
.admin-form textarea { min-height: 62px; resize: vertical; }
.admin-form input::placeholder, .admin-form textarea::placeholder { color: #a0aaa0; font-size: 10px; }
.admin-form input:focus, .admin-form select:focus, .admin-form textarea:focus { border-color: #9cba9b; box-shadow: 0 0 0 3px rgba(123, 163, 122, .12); outline: none; }
.admin-form select { appearance: none; padding-inline-end: 32px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%237b8c7e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E"); background-position: 11px center; background-repeat: no-repeat; }
.icon-picker-trigger { width: 100%; min-height: 58px; display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid #e1e8df; border-radius: 10px; background: #fcfdfa; text-align: right; cursor: pointer; transition: border-color .17s var(--ease), background .17s var(--ease); }
.icon-picker-trigger:hover { border-color: #cbdcc9; background: white; }
.selected-icon-preview { width: 39px; height: 39px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 11px; background: #e8f0e5; color: #5e8065; }
.selected-icon-preview .icon { width: 21px; height: 21px; }
.selected-icon-copy { min-width: 0; flex: 1; display: grid; line-height: 1.45; }
.selected-icon-copy strong { color: #4c6654; font-size: 10px; }
.selected-icon-copy small { color: #929d93; font-size: 9px; }
.picker-chevron { margin-inline-start: auto; color: #87968b; font-size: 18px; line-height: 1; }
.checkbox-row { min-height: 42px; display: flex; align-items: center; gap: 9px; margin-top: 10px; color: #728078; font-size: 10px; cursor: pointer; }
.checkbox-row input { width: 17px; height: 17px; margin: 0; accent-color: #4e7c5d; }
.form-actions { display: flex; gap: 8px; margin-top: 13px; }
.primary-action, .secondary-action { min-height: 43px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 14px; border: 0; border-radius: 10px; font-size: 10px; font-weight: 700; cursor: pointer; transition: background .18s var(--ease), transform .18s var(--ease); }
.primary-action { background: var(--green-deep); color: white; }
.primary-action:hover { transform: translateY(-1px); background: #376a4e; }
.primary-action .icon { width: 15px; height: 15px; }
.secondary-action { border: 1px solid #e0e7df; background: #fafbf8; color: #708077; }
.secondary-action:hover { background: white; }
[hidden] { display: none !important; }

.settings-panel { grid-column: 1 / -1; }
.accounts-panel { margin-top: 17px; }
.accounts-toolbar { display: flex; align-items: center; gap: 10px; margin: 15px 0 10px; }
.account-search-wrap { min-height: 42px; flex: 1; display: flex; align-items: center; gap: 8px; padding-inline: 11px; border: 1px solid #e1e8df; border-radius: 10px; background: #fcfdfa; color: #809286; }
.account-search-wrap:focus-within { border-color: #9cba9b; box-shadow: 0 0 0 3px rgba(123, 163, 122, .12); }
.account-search-wrap .icon { width: 17px; height: 17px; }
.account-search-wrap input { width: 100%; min-width: 0; min-height: 40px; border: 0; outline: 0; background: transparent; color: #304b3b; font-size: 11px; }
.account-search-wrap input::placeholder { color: #9aa59b; }
.accounts-list { display: grid; gap: 8px; }
.accounts-row { min-width: 0; display: grid; grid-template-columns: 42px minmax(0, 1fr) auto auto; align-items: center; gap: 11px; padding: 10px; border: 1px solid #edf0e9; border-radius: 12px; background: #fdfefb; }
.account-avatar { width: 42px; height: 42px; display: grid; place-items: center; overflow: hidden; border: 1px solid #e3ebe0; border-radius: 50%; background: #e9f0e6; color: #52765a; font-size: 15px; font-weight: 700; }
.account-avatar img { width: 100%; height: 100%; object-fit: cover; }
.account-copy { min-width: 0; display: grid; gap: 2px; }
.account-copy strong, .account-copy span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-copy strong { color: #3d5945; font-size: 11px; }
.account-copy span { color: #89958b; font-size: 9px; }
.account-status { padding: 5px 8px; border-radius: 99px; background: #edf4e9; color: #648068; font-size: 9px; white-space: nowrap; }
.account-status.is-paused { background: #f8f1e3; color: #987245; }
.account-status.is-blocked { background: #f9ece8; color: #a45f50; }
.account-status.is-admin { background: #eeeaf5; color: #766a92; }
.account-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.account-action { min-height: 40px; padding: 0 10px; border: 1px solid #e0e8dd; border-radius: 9px; background: #fff; color: #58725f; font-size: 9px; font-weight: 700; cursor: pointer; transition: background .17s var(--ease), border-color .17s var(--ease), color .17s var(--ease); }
.account-action:hover { border-color: #cadcc7; background: #f4f8f1; }
.account-action.is-danger { border-color: #eeddd6; color: #9e6254; }
.account-action.is-danger:hover { background: #fbf1ed; }
.account-action:disabled { opacity: .6; cursor: wait; }
.accounts-state { padding: 28px 14px; border: 1px dashed #dce5da; border-radius: 12px; color: #829087; font-size: 11px; text-align: center; }
.accounts-footnote { margin: 11px 0 0; color: #929d93; font-size: 9px; }
.settings-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 15px; }
.field-group { display: flex; flex-direction: column; }
.field-group label { margin-top: 10px; }
.field-wide { grid-column: 1 / -1; }
.settings-bottom { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 16px; padding-top: 14px; border-top: 1px solid #edf0ea; }
.settings-bottom p { display: inline-flex; align-items: center; gap: 6px; margin: 0; color: #809087; font-size: 9px; }
.settings-bottom p .icon { width: 14px; height: 14px; color: #6f956f; }
.settings-bottom .primary-action { min-width: 118px; }

.icon-picker-dialog { width: min(700px, calc(100% - 28px)); max-width: 700px; max-height: min(82vh, 760px); padding: 0; overflow: hidden; border: 1px solid #e2e9df; border-radius: 19px; background: #fffefa; color: var(--ink); box-shadow: 0 24px 80px rgba(29, 52, 37, .24); }
.icon-picker-dialog::backdrop { background: rgba(26, 48, 36, .38); backdrop-filter: blur(5px); animation: picker-fade .18s ease both; }
@keyframes picker-fade { from { opacity: 0; } to { opacity: 1; } }
.icon-picker-shell { height: min(82vh, 760px); max-height: min(82vh, 760px); display: flex; flex-direction: column; padding: 23px; }
.icon-picker-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.icon-picker-heading h2 { margin: 3px 0 0; color: #304c3b; font-size: 20px; }
.picker-close { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid #e5ebe3; border-radius: 11px; background: #fafbf8; color: #77867c; cursor: pointer; }
.picker-close .icon { width: 17px; height: 17px; }
.icon-search-label { margin: 17px 0 6px; color: #627567; font-size: 10px; font-weight: 700; }
.icon-search-wrap { min-height: 47px; display: flex; align-items: center; gap: 9px; padding-inline: 12px; border: 1px solid #dfe7dd; border-radius: 11px; background: #fbfcf9; color: #809286; }
.icon-search-wrap > .icon { width: 18px; height: 18px; }
.icon-search-wrap input { width: 100%; min-width: 0; min-height: 44px; padding: 0; border: 0; background: transparent; color: #304b3b; font-size: 12px; outline: none; }
.icon-search-wrap input::placeholder { color: #9ca79d; font-size: 10px; }
.icon-search-wrap:focus-within { border-color: #9cba9b; box-shadow: 0 0 0 3px rgba(123, 163, 122, .12); }
.icon-categories { display: flex; gap: 6px; margin-top: 13px; padding-bottom: 2px; overflow-x: auto; scrollbar-width: thin; }
.category-chip { min-height: 34px; flex: 0 0 auto; padding: 0 11px; border: 1px solid #e4eae2; border-radius: 99px; background: #fff; color: #75847a; font-size: 9px; cursor: pointer; transition: background .17s var(--ease), color .17s var(--ease), border-color .17s var(--ease); }
.category-chip:hover { border-color: #cbdcc9; color: #55765c; }
.category-chip.is-selected { border-color: #d5e4d3; background: #eaf2e7; color: #55775d; font-weight: 700; }
.icon-results-count { margin: 13px 0 8px; color: #8a968c; font-size: 9px; }
.icon-results-grid { min-height: 0; flex: 1; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); align-content: start; gap: 8px; overflow-y: auto; padding: 1px 2px 3px; }
.icon-option { min-height: 78px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px; padding: 8px 4px; border: 1px solid #e9eee7; border-radius: 11px; background: #fdfefb; color: #76847a; cursor: pointer; transition: transform .17s var(--ease), border-color .17s var(--ease), background .17s var(--ease), color .17s var(--ease); }
.icon-option:hover { transform: translateY(-2px); border-color: #cbdcc9; background: white; color: #53775c; }
.icon-option.is-active { border-color: #a7c3a4; background: #f0f6ed; color: #4d7657; box-shadow: inset 0 0 0 1px #d4e5d1; }
.icon-option-preview { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 9px; background: #f0f4ed; color: #64816a; }
.icon-option-preview .icon { width: 19px; height: 19px; }
.icon-option-name { max-width: 100%; overflow: hidden; color: #66776b; font-size: 8px; line-height: 1.3; text-overflow: ellipsis; white-space: nowrap; }
.icon-search-empty { padding: 36px 12px; color: #8b968d; font-size: 11px; text-align: center; }
.icon-search-empty[hidden] { display: none; }

.toast { position: fixed; z-index: 10; right: 24px; bottom: 22px; max-width: min(400px, calc(100% - 32px)); padding: 12px 16px; border: 1px solid #d8e6d7; border-radius: 12px; background: #fafff7; color: #42664c; font-size: 11px; box-shadow: 0 12px 32px rgba(35, 59, 41, .13); opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity .2s var(--ease), transform .2s var(--ease); }
.toast.is-visible { opacity: 1; transform: translateY(0); }
.admin-footer { padding-block: 16px; border-top: 1px solid #e2e9e1; color: #93a095; font-size: 9px; }
.admin-footer > div { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.admin-footer a { display: inline-flex; align-items: center; gap: 6px; color: #69836f; }
.admin-footer a .icon { width: 14px; height: 14px; }

@media (max-width: 850px) {
  .admin-grid { grid-template-columns: 1fr; }
  .systems-panel, .editor-panel, .settings-panel { grid-column: 1; }
  .editor-panel { grid-row: 1; }
  .systems-panel { grid-row: 2; }
  .settings-panel { grid-row: 3; }
}

@media (max-width: 560px) {
  .container { width: calc(100% - 30px); }
  .admin-header { height: 68px; }
  .admin-main { padding-block: 30px 42px; }
  .welcome-row { align-items: flex-start; flex-direction: column; gap: 11px; }
  .local-notice { align-items: flex-start; padding: 11px; }
  .panel { padding: 16px; border-radius: 14px; }
  .managed-item { flex-wrap: wrap; gap: 8px; }
  .managed-copy { flex-basis: calc(100% - 60px); }
  .managed-badge { margin-inline-start: 47px; }
  .item-actions { margin-inline-start: auto; }
  .settings-fields { grid-template-columns: 1fr; }
  .field-wide { grid-column: 1; }
  .accounts-toolbar { align-items: stretch; flex-direction: column; }
  .accounts-row { grid-template-columns: 40px minmax(0, 1fr) auto; gap: 9px; }
  .account-avatar { width: 40px; height: 40px; }
  .account-status { grid-column: 3; grid-row: 1; }
  .account-actions { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fit, minmax(115px, 1fr)); }
  .account-action { min-height: 44px; }
  .settings-bottom { align-items: flex-start; flex-direction: column; }
  .settings-bottom .primary-action { width: 100%; }
  .icon-picker-shell { padding: 17px; }
  .icon-picker-dialog { max-height: 88vh; }
  .icon-picker-shell { height: 88vh; max-height: 88vh; }
  .icon-results-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
  .icon-option { min-height: 72px; }
  .toast { right: 15px; bottom: 15px; }
}

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