/* Career Portal admin: compact, dense screens. Help text lives behind the small "i" buttons. */
body.admin { display: grid; grid-template-columns: 208px 1fr; min-height: 100vh; font-size: 13.5px; background: #f4f5f8; }
body.admin-bare { display: block; }
.admin h1 { font-size: 1.25rem; margin: 0; }
.admin h2 { font-size: 1rem; margin: 0 0 6px; }
.admin h3 { font-size: .92rem; margin: 10px 0 5px; }
.admin h3:first-child { margin-top: 0; }
.admin p { margin: 0 0 6px; }
.admin .button { padding: 4px 12px; }
.admin .button-small { padding: 2px 9px; font-size: .88rem; }
.admin input[type], .admin select, .admin textarea { padding: 4px 8px; font-size: 13.5px; }
.admin input[type="color"] { padding: 0; width: 30px; height: 24px; border: 1px solid #cfd4df; border-radius: 4px; background: none; vertical-align: middle; }
.admin .field { margin-bottom: 7px; }
.admin label { font-size: .88rem; margin-bottom: 2px; color: #3a4257; }
.admin .badge { font-size: .76rem; padding: 1px 8px; }
.admin .badge-large { font-size: .85rem; padding: 3px 11px; }
.admin .flash { padding: 7px 11px; margin-bottom: 10px; }
.admin .crumbs { margin: 0 0 6px; font-size: .85rem; }
.admin .detail-list { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 6px 14px; margin: 4px 0 8px; }
.admin dt { font-size: .78rem; }
.admin .tags li { font-size: .8rem; padding: 1px 9px; }
.admin .timeline { gap: 7px; }
.admin .pager { margin-top: 10px; }
.admin .pager a { padding: 2px 9px; }
.nowrap { white-space: nowrap; }

.a-bare { max-width: 380px; margin: 9vh auto 0; padding: 0 16px; }
.a-bare-brand { font-weight: 600; font-size: 1.1rem; text-align: center; margin-bottom: 12px; }
.a-bare-brand span { display: block; font-weight: 400; font-size: .85rem; color: var(--muted); }
.a-bare h1 { margin-bottom: 10px; }

.a-side { background: var(--ink); color: #c9cfdd; padding: 12px 10px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.a-brand { display: flex; align-items: center; gap: 9px; color: #fff; font-weight: 600; padding: 2px 6px 12px; line-height: 1.2; }
.a-brand:hover { text-decoration: none; }
.a-brand small { display: block; font-weight: 400; font-size: .76rem; color: #9aa3b8; }
.a-brand .brand-mark { width: 28px; height: 28px; flex: none; }
.a-side nav { display: grid; gap: 1px; }
.a-side nav a { color: #c9cfdd; padding: 5px 9px; border-radius: 6px; }
.a-side nav a:hover { background: rgba(255, 255, 255, .08); color: #fff; text-decoration: none; }
.a-side nav a[aria-current="page"] { background: var(--primary); color: var(--on-primary); font-weight: 600; }
.a-nav-title { margin: 12px 9px 3px !important; font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: #8791a8; }
.a-main { min-width: 0; }
.a-top { display: flex; justify-content: flex-end; align-items: center; gap: 16px; background: #fff; border-bottom: 1px solid var(--line); padding: 6px 18px; position: sticky; top: 0; z-index: 4; }
.a-content { padding: 14px 18px 30px; max-width: 1500px; }

.a-head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.a-actions { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.a-sub { margin: -4px 0 10px !important; }
.tip { position: relative; display: inline-block; }
.tip summary { list-style: none; cursor: pointer; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--primary); color: var(--primary); font: italic 700 11px/15px Georgia, serif; text-align: center; user-select: none; }
.tip summary::-webkit-details-marker { display: none; }
.tip[open] summary, .tip summary:hover { background: var(--primary); color: var(--on-primary); }
.tip-body { position: absolute; z-index: 8; left: 0; top: 24px; width: min(380px, 80vw); background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 9px 12px; box-shadow: 0 12px 34px rgba(20, 24, 46, .16); font-size: .86rem; line-height: 1.5; color: var(--ink); font-weight: 400; }
.tip-small summary { width: 15px; height: 15px; font-size: 10px; line-height: 12px; }

.a-stats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-bottom: 10px; }
.a-stat { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; color: var(--ink); display: grid; }
.a-stat:hover { border-color: var(--primary); text-decoration: none; }
.a-stat strong { font-size: 1.35rem; line-height: 1.2; }
.a-stat span { color: var(--muted); font-size: .82rem; }
.a-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: start; }
.a-split { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 10px; align-items: start; }
.a-split-even { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
.a-panel { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin-bottom: 10px; }
.a-panel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.a-panel-head h2, .a-panel-head h3 { margin: 0; }

.a-table { width: 100%; border-collapse: collapse; }
.a-table th { text-align: left; font-weight: 500; font-size: .78rem; color: var(--muted); padding: 3px 10px 5px 0; border-bottom: 1px solid var(--line); white-space: nowrap; }
.a-table td { padding: 5px 10px 5px 0; border-bottom: 1px solid #eef0f4; vertical-align: top; line-height: 1.35; }
.a-table tr:last-child td { border-bottom: 0; }
.a-table tbody tr:hover td { background: #fafbfd; }
.a-table code, .a-codes code, .a-secret code { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .84rem; overflow-wrap: anywhere; }
.a-row-actions { text-align: right; white-space: nowrap; }
.a-row-actions > * + * { margin-left: 10px; }
.a-off td { color: var(--muted); }

.a-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.a-pills { display: flex; flex-wrap: wrap; gap: 4px; }
.a-pills a { padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-size: .86rem; }
.a-pills a:hover { border-color: var(--primary); text-decoration: none; }
.a-pills a[aria-current] { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.a-pills span { opacity: .7; font-size: .8rem; }
.a-search { display: flex; gap: 6px; align-items: center; }
.a-search input[type="search"] { width: 230px; }
.a-search select { width: auto; max-width: 220px; }
.a-filter-note { background: #fffaeb; border: 1px solid #fedf89; border-radius: 6px; padding: 4px 10px; }

.a-form .form-grid, .a-more .form-grid { gap: 0 12px; }
.form-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.form-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-grid .half { grid-column: span 2; }
.a-form-foot { display: flex; align-items: flex-end; gap: 8px; margin-top: 6px; padding-top: 8px; border-top: 1px solid var(--line); }
.a-form-foot .field { margin: 0 auto 0 0; }
.a-inline-form { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 6px 0 0; }
.a-inline-form input[type="text"], .a-inline-form input[type="url"], .a-inline-form input[type="email"] { flex: 1 1 180px; width: auto; }
.a-inline-form select, .a-inline-form input[type="date"], .a-inline-form input[type="time"] { width: auto; }
.a-links { display: grid; grid-template-columns: 1fr 2fr; gap: 5px 8px; }

.a-person { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: start; }
.a-person .avatar, .a-person .avatar img, .a-person .avatar > span { width: 56px; height: 56px; font-size: 1.3rem; margin: 0; }
.a-person h2 { margin: 0; }
.a-contact { color: var(--ink); }
.a-person-side { display: grid; gap: 5px; justify-items: end; min-width: 130px; }
.a-person-side progress { height: 6px; }
.a-entry { border-top: 1px solid #eef0f4; padding-top: 6px; }
.a-item { border-top: 1px solid #eef0f4; padding: 7px 0; }
.a-item:first-of-type { border-top: 0; }
.a-item-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.a-more { margin-top: 6px; border-top: 1px solid #eef0f4; padding-top: 6px; }
.a-more summary { cursor: pointer; color: var(--primary); font-weight: 600; margin-bottom: 6px; }

.a-themes { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; }
.a-theme { display: grid; justify-items: center; gap: 3px; border: 1.5px solid var(--line); border-radius: 8px; padding: 7px 4px 5px; cursor: pointer; text-align: center; margin: 0; position: relative; font-size: .8rem; }
.a-theme input { position: absolute; opacity: 0; }
.a-theme:hover { border-color: #aab2c5; }
.a-theme:has(input:checked) { border-color: var(--primary); box-shadow: 0 0 0 2px var(--soft); font-weight: 600; }
.a-theme:has(input:focus-visible) { outline: 3px solid var(--accent); }
.a-colours { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; margin-top: 10px; padding-top: 8px; border-top: 1px solid #eef0f4; }
.a-colours label { display: inline-flex; align-items: center; gap: 6px; margin: 0; }
.a-switches { list-style: none; padding: 0; margin: 0; display: grid; gap: 7px; }
.a-switches li { display: flex; align-items: center; gap: 8px; }
.a-switches .check { margin: 0; font-size: .95rem; }
.a-logo-preview { display: grid; place-items: center; min-height: 84px; border: 1px dashed var(--line); border-radius: 8px; background: repeating-conic-gradient(#f3f4f7 0 25%, #fff 0 50%) 0 0 / 16px 16px; margin-bottom: 8px; padding: 10px; }
.a-logo-preview img { max-height: 64px; max-width: 100%; }
.a-secret { background: #fffaeb; border: 1px solid #fedf89; border-radius: 8px; padding: 8px 12px; margin-bottom: 8px; display: grid; gap: 4px; }
.a-secret code { user-select: all; font-size: .92rem; }

@media (max-width: 1100px) {
  .a-stats { grid-template-columns: repeat(3, 1fr); }
  .a-cols, .a-split, .a-split-even { grid-template-columns: 1fr; }
  .form-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  body.admin { display: block; }
  .a-side { position: static; height: auto; }
  .a-side nav { grid-template-columns: repeat(3, 1fr); }
  .a-nav-title { grid-column: 1 / -1; }
  .a-stats { grid-template-columns: repeat(2, 1fr); }
  .form-grid-4, .form-grid-3 { grid-template-columns: 1fr; }
  .form-grid .half { grid-column: auto; }
  .a-person { grid-template-columns: auto 1fr; }
  .a-person-side { grid-column: 1 / -1; justify-items: start; }
  .a-table { display: block; overflow-x: auto; }
  .a-search input[type="search"] { width: 150px; }
}

/* ATS pipeline uses the existing permission-checked application workflow. */
.ats-heading { display:flex; flex-wrap:wrap; justify-content:space-between; gap:16px; align-items:center; margin-bottom:18px; }
.ats-board { display:flex; gap:14px; overflow-x:auto; padding:4px 2px 20px; align-items:stretch; }
.ats-column { flex:0 0 260px; background:var(--page); border:1px solid var(--line); border-radius:var(--radius); padding:14px; }
.ats-column h2 { display:flex; align-items:center; justify-content:space-between; gap:10px; font-size:.95rem; padding-bottom:14px; border-bottom:2px solid var(--primary); }
.ats-candidate { padding:16px; margin-top:12px; background:var(--surface); border:1px solid var(--line); border-radius:var(--radius-control); overflow-wrap:anywhere; }
.ats-candidate p { margin:8px 0; }
.ats-empty { color:var(--muted); font-size:.85rem; padding:20px 0; }

/* Side menu pictures (shared shapes such as .i-brief, .i-doc, .i-people come from app.css) */
.i-dashboard { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='8' height='9' rx='1.5'/%3E%3Crect x='13' y='3' width='8' height='5' rx='1.5'/%3E%3Crect x='13' y='10' width='8' height='11' rx='1.5'/%3E%3Crect x='3' y='14' width='8' height='7' rx='1.5'/%3E%3C/svg%3E"); }
.i-tag { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 12V4a1 1 0 0 1 1-1h8l9 9-9 9z'/%3E%3Ccircle cx='8' cy='8' r='1.6'/%3E%3C/svg%3E"); }
.i-palette { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3a9 9 0 1 0 0 18c1.2 0 1.8-.8 1.8-1.8 0-1.300-1-1.700-1-2.800 0-1 .8-1.700 1.800-1.700H17a4 4 0 0 0 4-4C21 6.600 17 3 12 3z'/%3E%3Ccircle cx='7.5' cy='11' r='1.2'/%3E%3Ccircle cx='10' cy='7' r='1.2'/%3E%3Ccircle cx='15' cy='7.500' r='1.2'/%3E%3C/svg%3E"); }
.i-sliders { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6h10M18 6h2M4 12h4M12 12h8M4 18h12M20 18h0'/%3E%3Ccircle cx='16' cy='6' r='2'/%3E%3Ccircle cx='10' cy='12' r='2'/%3E%3Ccircle cx='18' cy='18' r='2'/%3E%3C/svg%3E"); }
.i-plug { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 3v5M15 3v5M6 8h12v3a6 6 0 0 1-12 0zM12 17v4'/%3E%3C/svg%3E"); }
.i-list { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 6h12M9 12h12M9 18h12'/%3E%3Ccircle cx='4.5' cy='6' r='1.2'/%3E%3Ccircle cx='4.5' cy='12' r='1.2'/%3E%3Ccircle cx='4.5' cy='18' r='1.2'/%3E%3C/svg%3E"); }
.i-refresh { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 11a8 8 0 0 0-14.500-4.500L4 8M4 4v4h4M4 13a8 8 0 0 0 14.500 4.500L20 16M20 20v-4h-4'/%3E%3C/svg%3E"); }
.i-shield { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3l8 3v6c0 4.500-3.400 8-8 9-4.600-1-8-4.500-8-9V6z'/%3E%3Cpath d='M9 12l2 2 4-4'/%3E%3C/svg%3E"); }
.i-store { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 9l1.500-5h13L20 9M4 9h16v2a3 3 0 0 1-5.300 2 3 3 0 0 1-5.400 0A3 3 0 0 1 4 11zM5 13v7h14v-7M10 20v-4h4v4'/%3E%3C/svg%3E"); }
.i-mail { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='M3 7l9 6 9-6'/%3E%3C/svg%3E"); }
.a-side nav a { display: flex; align-items: center; gap: 9px; }
.a-side nav a .ico { width: 16px; height: 16px; opacity: .8; }
.a-side nav a:hover .ico, .a-side nav a[aria-current="page"] .ico { opacity: 1; }
@media (max-width: 900px) { .a-side nav a { gap: 7px; } }

/* Options: a labelled select in the switches list (waiting time between applications). */
.a-switches .a-select-row { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; }
.a-switches .a-select-row label { font-weight: 500; margin: 0; }
.a-switches .a-select-row select { width: auto; min-width: 11rem; max-width: 100%; }
@media (min-width: 720px) { .a-switches .a-select-row label { flex: 0 0 22rem; } }
.a-history { list-style: none; margin: 0; padding: 0; }
.a-history li { padding: 6px 0; border-top: 1px solid var(--line); font-size: .9rem; }
.a-history li:first-child { border-top: 0; }
.a-history .muted { display: inline-block; min-width: 110px; }
