/* Hiring Desk skin: mirrors the Upjovo careers homepage while keeping the admin tools calm and readable. */
:root {
  --cream: #fff7eb;
  --paper: #fffdf8;
  --ink: #171715;
  --red: #f04438;
  --yellow: #ffd45a;
  --blue: #b8d9ff;
  --green: #bfe7c8;
  --orange: #ff8d58;
  --muted: #777168;
  --line: #e9dfd0;
  --shadow: 5px 5px 0 var(--ink);
}

body {
  position: relative;
  min-height: 100vh;
  background:
    radial-gradient(ellipse at 2% 18%, rgba(255, 212, 90, .15), transparent 27rem),
    radial-gradient(ellipse at 98% 44%, rgba(184, 217, 255, .2), transparent 30rem),
    var(--cream);
  font-family: Manrope, system-ui, sans-serif;
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 19;
  pointer-events: none;
  opacity: .075;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.15'/%3E%3C/svg%3E");
}

.top {
  border-bottom: 1.5px solid var(--ink);
  background: rgba(255, 247, 235, .9);
  box-shadow: 0 7px 24px rgba(23, 23, 21, .055);
}
.topin { min-height: 72px; }
.logo { font-family: "Space Grotesk", Manrope, system-ui, sans-serif; font-size: 29px; }
.logo b { color: var(--red); }
.topnav { gap: 17px; }
.topnav a:not(.adminmark) { position: relative; }
.topnav a:not(.adminmark)::after {
  content: ""; position: absolute; right: 100%; bottom: -5px; left: 0;
  height: 2px; background: var(--red); transition: right .22s ease;
}
.topnav a:not(.adminmark):hover::after { right: 0; }
.topnav .adminmark {
  border: 1.5px solid var(--ink); background: var(--yellow); color: var(--ink);
  box-shadow: 2px 2px 0 var(--ink); font: 700 9px "DM Mono", monospace;
}

main.wrap { width: min(1320px, calc(100% - 48px)); padding-top: 42px; }
h1, h2, h3, .stat strong { font-family: "Space Grotesk", Manrope, system-ui, sans-serif; }
h1 { letter-spacing: -.055em; }
.kicker { color: #a83229; font-family: "DM Mono", monospace; font-weight: 700; }
.muted, .tiny, .small { color: #625e56; }

.panel {
  border: 1.5px solid var(--ink);
  border-radius: 20px;
  background: var(--paper);
  box-shadow: 4px 4px 0 rgba(23, 23, 21, .12);
}
.login {
  max-width: 600px;
  margin: clamp(32px, 8vh, 78px) auto;
  padding: clamp(24px, 5vw, 42px);
  border-radius: 25px;
  box-shadow: 8px 8px 0 var(--ink);
}
.login h1 { font-size: clamp(42px, 6vw, 64px); margin: 14px 0 16px; }
.login .kicker {
  display: inline-flex; padding: 8px 12px; border: 1.5px solid var(--ink);
  border-radius: 99px; background: var(--yellow); color: var(--ink); transform: rotate(-1deg);
}
.login .alert { border: 1.5px solid var(--ink); background: #fff0bd; }

.head { padding: 9px 0 15px; }
#dashboard .head {
  position: relative;
  overflow: hidden;
  padding: clamp(20px, 3vw, 34px);
  border: 1.5px solid var(--ink);
  border-radius: 23px;
  background: linear-gradient(112deg, #fff0bd 0%, #fffaf0 57%, #fffdf8 100%);
  box-shadow: 6px 6px 0 var(--ink);
}
#dashboard .head::after {
  content: "✳"; position: absolute; z-index: 0; right: 28%; top: -55px;
  color: rgba(240,68,56,.11); font-size: 190px; line-height: 1; pointer-events: none;
  animation: desk-star-turn 32s linear infinite;
}
#dashboard .head > * { position: relative; z-index: 1; }
.head h1 { font-size: clamp(38px, 5vw, 58px); }
.head .kicker { letter-spacing: 1.5px; }
.site-state { display: inline-flex; align-items: center; gap: 8px; padding: 9px 12px; border: 1px solid #b8d8c2; border-radius: 99px; background: #edf8ef; }
.site-state::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #23834b; box-shadow: 0 0 0 4px #23834b1b; }
.site-state.off { border-color: #f1c5be; background: #fff0ed; }
.site-state.off::before { background: #b83227; box-shadow: 0 0 0 4px #b832271b; }

.sidebar {
  border: 1.5px solid var(--ink);
  border-radius: 19px;
  background: var(--paper);
  box-shadow: 4px 4px 0 rgba(23, 23, 21, .12);
}
.side-label { color: #79736a; font-family: "DM Mono", monospace; }
.side-link { min-height: 46px; border: 1px solid transparent; }
.side-link.active { background: var(--ink); color: white; box-shadow: 3px 3px 0 var(--red); }
.side-link.active span { color: var(--yellow); }
.side-link:hover:not(.active) { background: #fff0bd; color: var(--ink); }
.side-help { line-height: 1.7; }

.stats .stat {
  min-height: 118px;
  border: 1.5px solid var(--ink);
  border-radius: 17px;
  box-shadow: 3px 3px 0 rgba(23, 23, 21, .15);
  background: var(--paper);
}
.stats .stat:nth-child(1) { background: #fff0bd; }
.stats .stat:nth-child(2) { background: #dceaff; }
.stats .stat:nth-child(3) { background: #dff2df; }
.stats .stat:nth-child(4) { background: #ffe1d5; }
.stats .stat:nth-child(5) { background: #e5defb; }
.stats .stat:nth-child(6) { background: #fffdf8; }
.stat span { color: #534d45; }
.stat strong { font-size: 36px; letter-spacing: -.05em; }
.stat:hover { transform: translateY(-4px) rotate(-.5deg); box-shadow: 5px 6px 0 var(--ink); }

.chart-panel, .recent-panel, .maintenance-panel, .section-panel { border-radius: 20px; }
.maintenance-panel {
  position: relative;
  overflow: hidden;
  border: 1.5px solid var(--ink);
  background: linear-gradient(135deg, #fffdf8 0%, #fff8e9 72%, #fff0bd 100%);
  box-shadow: 5px 5px 0 var(--ink);
}
.maintenance-panel::after {
  content: "✳";
  position: absolute;
  right: 25px;
  top: 17px;
  color: rgba(240, 68, 56, .12);
  font-size: clamp(90px, 15vw, 180px);
  line-height: 1;
  pointer-events: none;
  animation: desk-star-turn 28s linear infinite;
}
.maintenance-panel > * { position: relative; z-index: 1; }
.maintenance-panel .panel-heading { align-items: center; }
.maintenance-panel .maintenance-preview {
  border: 1.5px dashed #a99d8e;
  border-radius: 15px;
  background: rgba(255,255,255,.86);
  box-shadow: 0 5px 16px rgba(23,23,21,.04);
}
.maintenance-actions .editbtn { padding: 11px 16px; font-weight: 900; }
.maintenance-actions .btn { white-space: nowrap; }
.maintenance-badge { border: 1px solid #b8d8c2; }
.maintenance-badge.off { border: 1px solid #efc3bc; }
.maintenance-panel + .safety-note { border-left: 5px solid var(--yellow); }
.form-message { min-height: 1.5em; line-height: 1.5; }
.chart-panel { min-height: 290px; }
.panel-heading h2 { font-family: "Space Grotesk", Manrope, sans-serif; letter-spacing: -.04em; }
.text-action { color: #a83229; text-underline-offset: 4px; }
.text-action:hover { color: var(--ink); }

.btn, .btn.dark {
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  padding: 11px 16px;
  box-shadow: 3px 3px 0 var(--ink);
  font-weight: 900;
}
.btn { background: var(--red); color: #fff; }
.btn.dark { background: var(--ink); color: #fff; }
.btn:hover, .editbtn:hover { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.editbtn { border: 1px solid var(--ink); border-radius: 999px; background: #fff; }
.danger { background: #a9231c; color: #fff; }

input, select, textarea {
  border: 1.5px solid #d1c6b8;
  border-radius: 10px;
  background: #fff;
  transition: border-color .18s, box-shadow .18s, background .18s;
}
input:focus, select:focus, textarea:focus,
button:focus-visible, select:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 3px solid #f0443855;
  outline-offset: 2px;
  border-color: var(--red);
}
.tablewrap { border: 1.5px solid var(--ink); border-radius: 14px; background: #fff; }
table { background: #fff; }
th { background: #fff0bd; color: var(--ink); border-bottom: 1.5px solid var(--ink); font-family: "DM Mono", monospace; }
tbody tr { transition: background .16s ease; }
tbody tr:nth-child(even) { background: #fffdf8; }
tbody tr:hover { background: #fff7e4; }
td { line-height: 1.55; }
.status { border: 1px solid rgba(23,23,21,.12); font-weight: 700; }
.modal { border: 1.5px solid var(--ink); border-radius: 22px; box-shadow: 8px 8px 0 rgba(23,23,21,.28); }

@media (max-width: 720px) {
  main.wrap { width: calc(100% - 28px); padding-top: 26px; }
  .topin { min-height: 0; }
  .sidebar { border-radius: 15px; }
  #dashboard .head { gap: 14px; }
  #dashboard .head::after { right: 2%; top: -34px; font-size: 135px; }
}
@media (max-width: 560px) {
  .stats .stat { min-height: 100px; }
  .stat strong { font-size: 30px; }
  .topnav .adminmark { font-size: 8px; }
  .login { box-shadow: 5px 5px 0 var(--ink); }
  #dashboard .head { padding: 17px; }
}
@media (prefers-reduced-motion: reduce) {
  body::after { display: none; }
  .maintenance-panel::after { animation: none; }
}
@keyframes desk-star-turn { to { transform: rotate(360deg); } }

/* Credential management view */
.credential-panel .panel-heading { align-items: center; }
.credential-lock {
  display: grid; place-items: center; flex: 0 0 48px; width: 48px; height: 48px;
  border: 1.5px solid var(--ink); border-radius: 15px; background: var(--yellow);
  box-shadow: 2px 2px 0 var(--ink); font-size: 25px;
}
.credential-security-note {
  display: grid; gap: 5px; margin: 0 0 22px; padding: 14px 16px;
  border: 1px solid #e6d08a; border-radius: 13px; background: #fff6d8;
  color: #55451b; font-size: 12px; line-height: 1.6;
}
.credential-security-note strong { color: var(--ink); font-size: 11px; }
.credential-panel .field small { color: var(--muted); font-size: 10px; line-height: 1.55; }
.credential-panel input[readonly] { background: #f2eee7; color: #625e56; }
.credential-help { border-left: 4px solid var(--yellow); }
.credential-help h2 { margin: 0 0 7px; font: 700 17px "Space Grotesk"; }
.credential-help p { margin: 0; }
#credentialMessage.error { color: #a9231c; }
@media (max-width: 720px) {
  .credential-lock { display: none; }
  .credential-panel .field { min-width: 0; }
  .credential-panel .form-actions { align-items: flex-start; }
}

.backup-panel { overflow: hidden; }
.backup-mark { display: grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px; border: 1.5px solid var(--ink); border-radius: 14px; background: var(--yellow); box-shadow: 3px 3px 0 var(--ink); font-size: 20px; font-weight: 900; }
.backup-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 20px 0; }
.backup-grid > div { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.backup-grid > div > strong { font-size: 12px; }
.backup-grid ul { margin: 12px 0 0; padding-left: 19px; color: #625e56; font-size: 11px; line-height: 1.85; }
.backup-grid p { margin: 9px 0 0; color: #625e56; font-size: 11px; line-height: 1.7; }
.backup-warning { border-color: #e7c17a !important; background: #fff8e8 !important; }
.backup-warning > strong { color: #7a4b06; }
.backup-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding-top: 2px; }
.backup-actions .muted { max-width: 450px; }
#backupMessage { min-height: 18px; margin-top: 12px; }
@media (max-width: 720px) { .backup-grid { grid-template-columns: 1fr; } }
