html,
body {
    height: 100%;
}

.wrap {
    min-height: 100%;
    height: auto;
    margin: 0 auto -60px;
    padding: 0 0 60px;
}

.wrap > .container {
    padding: 70px 15px 20px;
}

.footer {
    height: 60px;
    background-color: #f5f5f5;
    border-top: 1px solid #ddd;
    padding-top: 20px;
}

.jumbotron {
    text-align: center;
    background-color: transparent;
}

.jumbotron .btn {
    font-size: 21px;
    padding: 14px 24px;
}

.not-set {
    color: #c55;
    font-style: italic;
}

/* add sorting icons to gridview sort links */
a.asc:after, a.desc:after {
    position: relative;
    top: 1px;
    display: inline-block;
    font-family: 'Glyphicons Halflings';
    font-style: normal;
    font-weight: normal;
    line-height: 1;
    padding-left: 5px;
}

a.asc:after {
    content: /*"\e113"*/ "\e151";
}

a.desc:after {
    content: /*"\e114"*/ "\e152";
}

.sort-numerical a.asc:after {
    content: "\e153";
}

.sort-numerical a.desc:after {
    content: "\e154";
}

.sort-ordinal a.asc:after {
    content: "\e155";
}

.sort-ordinal a.desc:after {
    content: "\e156";
}

.grid-view th {
    white-space: nowrap;
}

.hint-block {
    display: block;
    margin-top: 5px;
    color: #999;
}

.error-summary {
    color: #a94442;
    background: #fdf7f7;
    border-left: 3px solid #eed3d7;
    padding: 10px 20px;
    margin: 0 0 15px 0;
}

/* align the logout "link" (button in form) of the navbar */
.nav li > form > button.logout {
    padding: 15px;
    border: none;
}

@media(max-width:767px) {
    .nav li > form > button.logout {
        display:block;
        text-align: left;
        width: 100%;
        padding: 10px 15px;
    }
}

.nav > li > form > button.logout:focus,
.nav > li > form > button.logout:hover {
    text-decoration: none;
}

.nav > li > form > button.logout:focus {
    outline: none;
}

/* ДВД: карточки на главной */
.dvd-dashboard .panel-heading .glyphicon {
    margin-right: 6px;
}

.dvd-dashboard .panel-body h2 {
    margin: 6px 0 0;
    font-size: 28px;
    font-weight: 600;
}

.dvd-dashboard .panel-body .dvd-stat-note {
    margin-top: 8px;
    font-size: 12px;
    color: #777;
}

.dvd-dashboard .dvd-top-list {
    margin: 0;
    padding-left: 18px;
}

.dvd-dashboard .dvd-top-list li {
    margin-bottom: 6px;
}

.dvd-dashboard .dvd-dashboard-subline {
    margin: 0;
    font-size: 12px;
}

.dvd-dashboard .dvd-dashboard-empty {
    margin: 0;
}

/* ДВД: панели в одном ряду одинаковой высоты (≥md) */
@media (min-width: 992px) {
    .dvd-dashboard-stat-row {
        display: flex;
        flex-wrap: wrap;
    }

    .dvd-dashboard-stat-row > .dvd-dashboard-equal-col {
        display: flex;
    }

    .dvd-dashboard-stat-row .dvd-dashboard-panel-card {
        display: flex;
        flex-direction: column;
        width: 100%;
        margin-bottom: 15px;
    }

    .dvd-dashboard-stat-row .dvd-dashboard-panel-card > .panel-body {
        flex: 1 1 auto;
    }
}

/* Индексные GridView: колонка кнопок и сводка */
.grid-view th.dvd-grid-actions,
.grid-view td.dvd-grid-actions {
    width: 128px;
    min-width: 128px;
    max-width: 140px;
    white-space: nowrap;
    vertical-align: middle;
}

/* Кнопки действий в списках (просмотр / изменить / удалить) */
.dvd-grid-act-group {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

a.dvd-grid-act {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 30px;
    padding: 0;
    border-radius: 6px;
    border: 1px solid transparent;
    text-decoration: none !important;
    line-height: 1;
    box-sizing: border-box;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

a.dvd-grid-act .glyphicon {
    font-size: 14px;
    top: 0;
}

a.dvd-grid-act--view {
    color: #0d5fa8;
    background: #e3f2fd;
    border-color: #90caf9;
}

a.dvd-grid-act--view:hover,
a.dvd-grid-act--view:focus {
    color: #063d6f;
    background: #bbdefb;
    border-color: #64b5f6;
    box-shadow: 0 1px 3px rgba(13, 95, 168, 0.2);
}

a.dvd-grid-act--edit {
    color: #2e7d32;
    background: #e8f5e9;
    border-color: #81c784;
}

a.dvd-grid-act--edit:hover,
a.dvd-grid-act--edit:focus {
    color: #1b5e20;
    background: #c8e6c9;
    border-color: #66bb6a;
    box-shadow: 0 1px 3px rgba(46, 125, 50, 0.2);
}

a.dvd-grid-act--delete {
    color: #b71c1c;
    background: #ffebee;
    border-color: #ef9a9a;
}

a.dvd-grid-act--delete:hover,
a.dvd-grid-act--delete:focus {
    color: #7f0000;
    background: #ffcdd2;
    border-color: #e57373;
    box-shadow: 0 1px 3px rgba(183, 28, 28, 0.2);
}

.dvd-grid-footer {
    margin-top: 10px;
}

.dvd-grid-summary {
    padding-top: 0;
}

.grid-view .summary {
    float: right;
    clear: both;
    margin-bottom: 0;
    padding-bottom: 0;
    text-align: right;
}

.dvd-grid-summary-wrap {
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Карточки просмотра: подписи полей фиксированной ширины, светло-серый фон */
table.detail-view > tbody > tr > th {
    width: 250px;
    min-width: 250px;
    max-width: 250px;
    background-color: #f0f0f0;
    font-weight: 600;
    vertical-align: top;
}

/* О системе: панели в ряду одинаковой высоты */
.site-about .row.site-about-equal {
    display: flex;
    flex-wrap: wrap;
}

.site-about .row.site-about-equal > [class*="col-"] {
    display: flex;
}

.site-about .row.site-about-equal .panel {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    width: 100%;
    margin-bottom: 0;
}

.site-about .row.site-about-equal .panel-body {
    flex: 1 1 auto;
}

.site-about .site-about-list {
    line-height: 1.75;
    margin-bottom: 0;
}

.site-about .site-about-list li + li {
    margin-top: 6px;
}

.dvd-serial-col {
    width: 42px;
    min-width: 42px;
    max-width: 48px;
}

.panel-body .dvd-top-list li {
    margin-bottom: 12px;
    line-height: 1.45;
}

/* Форма улики: дата и время в одной визуальной строке */
.evidence-date-time-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    margin-left: 0;
    margin-right: 0;
}

.evidence-date-time-row .evidence-date-time-col {
    margin-bottom: 0;
}

.evidence-date-time-row .evidence-date-time-col .form-group {
    margin-bottom: 0;
}

.dvd-view-toolbar {
    margin-bottom: 12px;
}

.dvd-view-print-btn {
    margin-left: 8px;
}

@media print {
    .dvd-no-print {
        display: none !important;
    }
}

/* Заголовки панелей на главной: отступ иконки от текста */
.dvd-panel-heading-icon {
    margin-right: 8px;
}

/* «По статусу дела» – светло-оранжевая панель */
.panel-dvd-quarter-status {
    border-color: #f0c090;
}

.panel-dvd-quarter-status > .panel-heading {
    color: #5c3d1a;
    background-color: #ffe8cc;
    border-color: #f0c090;
}

.panel-dvd-quarter-status > .panel-body {
    background-color: #fff;
}

/* Правонарушение: дата и время в одном ряду */
.offense-occ-datetime-row {
    display: flex;
    flex-wrap: nowrap;
    align-items: flex-start;
    gap: 12px;
    max-width: 100%;
}

.offense-occ-datetime-row .occ-date-field {
    flex: 0 0 200px;
    max-width: 42%;
}

.offense-occ-datetime-row .occ-time-field {
    flex: 1 1 220px;
    min-width: 0;
}

.offense-occ-datetime-row .occ-time-field .bootstrap-timepicker-widget {
    z-index: 1151;
}

/* «О системе» – блок «Безопасность и доступ» */
.panel-site-about-security {
    border-color: #9cb8d4;
}

.panel-site-about-security > .panel-heading {
    color: #1a3550;
    background-color: #d9e8f5;
    border-color: #9cb8d4;
}

.panel-site-about-security > .panel-body {
    background-color: #fff;
}

/* Гостевые страницы: вход, сброс пароля, регистрация (layout main-login) */
body.dvd-auth-page {
    margin: 0;
    min-height: 100vh;
    background: linear-gradient(180deg, #c5dff0 0%, #dcecf8 45%, #eaf4fb 100%);
}

.dvd-auth-layout {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 7vh 12px 40px;
    box-sizing: border-box;
}

.dvd-auth-layout > .alert {
    width: 100%;
    max-width: 420px;
    margin: 0 0 14px;
    border-radius: 8px;
}

.dvd-auth {
    width: 100%;
    max-width: 420px;
    margin-top: -12px;
}

.dvd-auth-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 36px rgba(30, 80, 120, 0.14);
    padding: 28px 26px 26px;
}

.dvd-auth-brand {
    text-align: center;
    margin-bottom: 18px;
}

.dvd-auth-brand-link {
    font-size: 17px;
    font-weight: 600;
    color: #1565a8;
    text-decoration: none;
}

.dvd-auth-brand-link:hover,
.dvd-auth-brand-link:focus {
    color: #0d47a1;
    text-decoration: none;
}

.dvd-auth-title {
    font-size: 22px;
    font-weight: 600;
    margin: 0 0 6px;
    text-align: center;
    color: #222;
}

.dvd-auth-sub {
    text-align: center;
    color: #666;
    font-size: 14px;
    margin: 0 0 22px;
    line-height: 1.45;
}

.dvd-auth-form .form-group {
    margin-bottom: 14px;
}

.dvd-auth-input {
    border-radius: 6px;
}

.dvd-auth-submit-wrap {
    margin-top: 8px;
    margin-bottom: 0;
}

.dvd-auth-submit {
    padding-top: 10px;
    padding-bottom: 10px;
    font-weight: 600;
    border-radius: 8px;
}

.dvd-auth-links {
    text-align: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #eee;
    font-size: 14px;
}

.dvd-auth-link {
    color: #1565a8;
    text-decoration: none;
}

.dvd-auth-link:hover,
.dvd-auth-link:focus {
    color: #0d47a1;
    text-decoration: underline;
}

.dvd-auth-dot {
    color: #bbb;
    margin: 0 6px;
}
