:root {
    --navy: #2f3245;
    --navy-dark: #252a33;
    --panel-header: #f3f3f6;
    --panel-body: #303346;
    --accent: #f34f3a;
    --green: #5bb75b;
    --green-dark: #469546;
    --white: #ffffff;
    --page: #ffffff;
    --text-dark: #2d2f43;
    --table-line: #d4d8e0;
    --success-bg: #e7f7e8;
    --success-text: #265d2f;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background: var(--page);
    color: var(--text-dark);
}

a {
    color: inherit;
    text-decoration: none;
}

a:hover {
    opacity: 0.94;
}

.alert {
    margin-bottom: 12px;
    padding: 10px 12px;
    border: 1px solid #b9dfc0;
    font-size: 12px;
    line-height: 1.5;
}

.success {
    background: var(--success-bg);
    color: var(--success-text);
}

.app-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.topbar {
    height: 87px;
    background: var(--navy);
    color: var(--white);
    display: flex;
    align-items: center;
}

.topbar-inner,
.footer-inner {
    width: 100%;
    padding: 0 34px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-title {
    margin: 0;
    font-size: 23px;
    font-weight: 700;
}

.content-area {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 26px 16px 32px;
}

.content-area-wide {
    padding-top: 42px;
}

.login-panel {
    width: 307px;
    margin-top: 0;
    margin-left: 12px;
}

.records-panel {
    width: min(100%, 980px);
    background: var(--white);
    border: 1px solid var(--table-line);
}

.panel-header {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 60px;
    padding: 10px 12px 11px;
    border-top: 6px solid var(--accent);
    background: var(--panel-header);
    color: var(--text-dark);
}

.panel-header h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
}

.panel-header p {
    margin: 3px 0 0;
    font-size: 10px;
    color: #686d79;
}

.panel-icon {
    width: 31px;
    height: 31px;
    border: 2px solid #4a5165;
    border-radius: 50%;
    position: relative;
    flex: 0 0 auto;
}

.panel-icon::before {
    content: "";
    position: absolute;
    top: 4px;
    left: 8px;
    width: 9px;
    height: 9px;
    border: 2px solid #4a5165;
    border-radius: 50%;
    background: transparent;
}

.panel-icon::after {
    content: "";
    position: absolute;
    left: 6px;
    bottom: 3px;
    width: 13px;
    height: 10px;
    border: 2px solid #4a5165;
    border-top: 0;
    border-radius: 0 0 10px 10px;
}

.panel-body {
    background: var(--panel-body);
    padding: 11px 18px 13px;
}

.login-form {
    display: grid;
    gap: 11px;
}

.field {
    display: grid;
    gap: 3px;
}

.field span {
    color: var(--white);
    font-size: 12px;
    font-weight: 700;
}

.field input {
    width: 100%;
    height: 29px;
    border: 1px solid #b6b8bf;
    background: var(--white);
    padding: 4px 8px;
    font-size: 13px;
    color: #000;
}

.field input:focus {
    outline: 1px solid #9ea7b8;
}

.actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 6px;
}

.danger-link,
.success-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 0 8px;
    border: 0;
    color: var(--white);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}

.danger-link {
    background: var(--accent);
    width: 122px;
}

.success-button {
    background: var(--green);
    width: 60px;
}

.success-button-wide {
    width: 74px;
}

.success-button:hover {
    background: var(--green-dark);
}

.records-toolbar {
    padding: 14px;
    background: var(--panel-body);
    border-bottom: 1px solid #3f4657;
}

.table-wrap {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
}

thead {
    background: #eef1f5;
}

th,
td {
    text-align: left;
    padding: 12px 14px;
    border-bottom: 1px solid var(--table-line);
    font-size: 13px;
    vertical-align: top;
}

.hash-cell {
    font-family: Consolas, "Courier New", monospace;
    font-size: 12px;
    word-break: break-all;
}

tbody tr:last-child td {
    border-bottom: 0;
}

.empty-state {
    text-align: center;
    color: #5b6170;
}

.footer-bar {
    height: 70px;
    background: var(--navy-dark);
    color: #c4c7cf;
    display: flex;
    align-items: center;
    font-size: 12px;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 26px;
}

.footer-logo {
    display: block;
    width: auto;
    height: 40px;
    object-fit: contain;
}

@media (max-width: 640px) {
    .topbar-inner,
    .footer-inner {
        padding: 0 16px;
    }

    .site-title {
        font-size: 20px;
    }

    .content-area {
        padding-left: 12px;
        padding-right: 12px;
    }

    .login-panel {
        width: 100%;
        max-width: 307px;
    }

    .footer-inner,
    .footer-left {
        gap: 12px;
    }

    th,
    td {
        padding: 12px;
    }
}
