/* Shared visual language for public pages and administration. */
:root { --ink: #17324d; --muted: #687c8e; --blue: #1267a9; --line: #dfe7ee; --surface: #fff; --canvas: #f4f7fa; --green-bg: #edf7f0; --green-line: #cce3d4; }
body { background: var(--canvas); color: var(--ink); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif; font-size: 15px; line-height: 1.55; }
body.frontpage, body.passport { background: var(--canvas); background-image: none; }
.page-wrap { max-width: 1440px; padding-left: 28px; padding-right: 28px; }
.p-top { background: #102b43; color: #d3e0eb; font-size: 12px; line-height: 36px; }
.p-top .page-wrap a, .p-top .page-wrap span { border: 0; }
.p-top a:hover { background: #1c405e; color: #fff; }
.p-header { background: linear-gradient(110deg, #10568c, #177db7); height: auto; min-height: 92px; margin-bottom: 28px; padding: 18px 0; }
.p-header .page-wrap { display: flex; align-items: center; gap: 26px; }
.p-logo { display: block; flex-shrink: 0; }
.p-logo img { display: block; height: 52px; width: auto; max-width: 100%; }
.p-name { margin: 0; color: #edf6ff; font-size: 21px; font-weight: 500; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -.025em; color: var(--ink); }
input, select, textarea, button { border-radius: 8px; font-family: inherit; font-size: 14px; }
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]), select, textarea { background-color: #fff; border-color: #cfdbe5; padding: 10px 12px; color: var(--ink); }
input:focus-visible, select:focus-visible, textarea:focus-visible, button:focus-visible, a:focus-visible { outline: 3px solid #85bceb; outline-offset: 3px; }
button, input[type="submit"] { cursor: pointer; }
button:disabled, input:disabled { cursor: default; }
a.button, .btn-primary, input.submit { background: var(--blue); border-radius: 8px; box-shadow: none; color: #fff; }
a.button:hover, .btn-primary:hover { background: #0b548c; }
a.button.bgorange { background: #eaf0f5; color: var(--ink); box-shadow: none; }
a.button.bgred { background: #b93636; box-shadow: none; }
.table { background: #fff; }
.table th, .table td { border-color: var(--line); padding: 16px 18px; }
.table tr.head, .table tr.head:hover { background: #edf3f8; color: #3d5871; text-transform: none; letter-spacing: .02em; font-size: 12px; }
.table tr:hover { background: #f6f9fc; }
.p-footer { margin-top: 64px; padding: 36px 0; background: #102b43; color: #b8cada; font-size: 13px; }
.p-footer .page-wrap { gap: 32px; }
.passport-bg { background: none; padding-bottom: 0; }
#desc:empty { display: none; }
#desc { background: transparent; scroll-margin-top: 24px; }
.desc_inner { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 24px; gap: 28px; margin: 24px 0; }
.desc_list { background: #f2f6fa; border-radius: 12px; padding: 24px; font-size: 15px; overflow-wrap: anywhere; }
.desc_list label { color: #64788c; font-size: 13px; }
.desc_list span { color: var(--ink); }
.desc_img_big { border-radius: 12px; overflow: hidden; background: #edf2f6; }
.desc_img_min { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.desc_img_min div { border-radius: 8px; background: #edf2f6; }
.desc_img_min img { display: block; width: 100%; height: 100%; min-height: 68px; object-fit: cover; }
.desc_close { z-index: 2; width: 30px; height: 30px; line-height: 30px; border-radius: 50%; background: #17324d; }
.a-content { min-height: 55vh; }
.object_edit { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 24px; }
.object_edit .inputs { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 22px; }
.object_edit label { font-size: 13px; color: #526b80; margin-bottom: 5px; }
.object-list-filters, .photo-filters, .photo-upload { background: var(--green-bg); border-color: var(--green-line); border-radius: 12px; }
.object-list-filters { padding: 20px; }
.camera-tabs { border-color: var(--line); background: #edf3f8; border-radius: 14px; }
.camera-tab { border-radius: 9px; }
.log-entry, .log-date-card { border-color: var(--line); border-radius: 10px; }
.photo-table-wrap { border: 1px solid var(--line); border-radius: 12px; }
.photo-table { margin: 0; }
.photo-table-preview img { border-radius: 7px; }
@media (max-width: 760px) {
  .page-wrap { padding-left: 16px; padding-right: 16px; }
  .p-header { min-height: 78px; padding: 14px 0; margin-bottom: 20px; }
  .p-header .page-wrap { gap: 16px; flex-wrap: wrap; }
  .p-logo img { height: 43px; }
  .p-name { font-size: 16px; }
  .p-top .page-wrap { overflow-x: auto; white-space: nowrap; }
  .p-top .page-wrap a, .p-top .page-wrap span { padding: 0 8px; }
  .object_edit { padding: 16px; }
  .desc_inner { display: flex; flex-direction: column; padding: 14px; gap: 16px; border-radius: 12px; }
  .desc_img_big .img_wrapper { height: 260px; }
  .desc_list { padding: 18px; }
  .table th, .table td { padding: 12px; }
  .p-footer { margin-top: 40px; }
  .a-content > .table, #admin-object-list { display: block; overflow-x: auto; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; } }
.passport-back { color: #fff; text-decoration: none !important; margin-left: auto; font-size: 13px; }
body.login-page { min-height: 100vh; background: #eff5fa; padding: 24px; color: var(--ink); }
.login-page .login { width: min(100%, 420px); margin: 12vh auto 32px; padding: 36px; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 12px 50px #17324d0a; }
.login-page h2 { color: var(--ink); margin-bottom: 28px; }
.login-page .input { border: 1px solid #cfdbe5; border-radius: 8px; margin-bottom: 14px; padding: 12px; background: #fff; }
.login-page .submit { width: 100%; height: auto; padding: 12px; margin-top: 12px; border-radius: 8px; background: var(--blue); }
.login-page .red { color: #b93636; margin-top: 14px; }
@media (max-width: 420px) { .login-page .login { padding: 24px; } }

/* Compact filters across administration pages. */
.object-list-filters, .photo-filters { padding: 12px 14px; gap: 10px 14px; grid-template-columns: repeat(auto-fit, minmax(155px, 1fr)); }
.object-list-filters label, .photo-filters label { font-size: 12px; gap: 4px; }
.object-list-filters input, .object-list-filters select, .object-list-filters button,
.photo-filters input, .photo-filters select, .photo-filters button { padding: 6px 9px !important; min-height: 34px; font-size: 12px; line-height: 1.4; }
