:root {
    color-scheme: dark;
    --mh-primary: #007BEE;
    --mh-primary-light: #4DA3FF;
    --mh-primary-subtle: #CCE4FC;
    --mh-navy: #002752;
    --mh-dark: #2B2D30;
    --mh-gray: #464A4F;
    --mh-light: #F0F6FF;
    --mh-white: #FFFFFF;
    --mh-gray-100: #E8EEF7;
    --mh-gray-200: #D4DCE8;
    --mh-gray-300: #B8C2D0;
    --mh-gray-400: #9AA5B3;
    --mh-gray-500: #7A8796;
    --mh-gray-700: #3A3D42;
    --surface: rgba(0, 39, 82, .78);
    --surface-strong: #002752;
    --surface-soft: rgba(0, 123, 238, .12);
    --line: rgba(77, 163, 255, .26);
    --line-strong: rgba(204, 228, 252, .34);
    --text: #F0F6FF;
    --muted: #B8C2D0;
    --amber: #fbbf24;
    --rose: #fb7185;
    --shadow: 0 22px 70px rgba(0, 39, 82, .38);
    --radius: 12px;
    --radius-pill: 999px;
    --display-font: "Paytone One", Inter, ui-sans-serif, system-ui, sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
}

body {
    margin: 0;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    background: var(--mh-navy);
    color: var(--text);
    font: 15px/1.5 Inter, system-ui, sans-serif;
}

body::before,
body::after {
    content: "";
    position: absolute;
    pointer-events: none;
}

body::before {
    top: -18px;
    right: -18px;
    left: -18px;
    height: 1080px;
    z-index: 0;
    background: url("https://storage.minehub.cz/storage/minehub/backgrounds/background_main.webp") center top / cover no-repeat;
    filter: blur(3px);
    opacity: .88;
    transform: scale(1.02);
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 72%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 0%, #000 72%, transparent 100%);
}

body::after {
    top: 0;
    right: 0;
    left: 0;
    height: 1020px;
    z-index: 0;
    pointer-events: none;
    background: rgba(0, 39, 82, .52);
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 72%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 0%, #000 72%, transparent 100%);
}

.shell {
    position: relative;
    z-index: 1;
    width: min(1600px, calc(100% - 32px));
    margin: 0 auto;
    padding: 28px 0 42px;
}

.hero {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(360px, 560px);
    gap: 18px;
    align-items: end;
    margin-bottom: 22px;
}

.hero-copy {
    display: flex;
    align-items: center;
    align-self: start;
    gap: 16px;
    min-width: 0;
}

.headline-logo-link {
    display: block;
    flex: 0 0 auto;
    border-radius: 18px;
    transition: transform .2s ease, filter .2s ease;
}

.headline-logo {
    display: block;
    width: clamp(72px, 6vw, 88px);
    height: clamp(72px, 6vw, 88px);
    object-fit: contain;
}

.headline-logo-link:hover {
    transform: translateY(-2px) scale(1.09) rotate(-2deg);
    filter: drop-shadow(0 10px 18px rgba(77, 163, 255, .48));
}

.headline-logo-link:focus-visible {
    outline: 0;
    box-shadow: 0 0 0 3px rgba(77, 163, 255, .5);
    transform: scale(1.06);
}

.hero-copy-text {
    min-width: 0;
}

.hero-copy h1 {
    margin-bottom: 0;
}

.hero-copy-text p {
    margin: 7px 0 0;
    color: var(--muted);
    font-size: .95rem;
}

.hero-side {
    display: grid;
    gap: 10px;
}

.language-picker {
    position: relative;
    justify-self: end;
    z-index: 10;
    flex: none;
}

.language-picker summary {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 132px;
    padding: 9px 11px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(0, 39, 82, .88);
    color: var(--text);
    cursor: pointer;
    font-family: Inter, system-ui, sans-serif;
    font-size: .78rem;
    font-weight: 700;
    list-style: none;
    backdrop-filter: blur(8px);
}

.language-picker summary::-webkit-details-marker {
    display: none;
}

.language-picker .chevron {
    margin-left: auto;
    color: var(--mh-primary-light);
    font-size: 18px;
    line-height: 1;
    font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 20;
    transition: transform .2s;
}

.language-picker[open] .chevron {
    transform: rotate(180deg);
}

.language-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    display: grid;
    min-width: 170px;
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(0, 39, 82, .98);
    box-shadow: 0 12px 32px rgba(0, 0, 0, .35);
}

.language-menu a {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px 9px;
    border-radius: 9px;
    color: var(--muted);
    font-family: Inter, system-ui, sans-serif;
    font-size: .78rem;
    font-weight: 700;
    text-decoration: none;
    transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}

.language-flag {
    display: block;
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    object-fit: contain;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
}

.language-menu a:hover {
    background: rgba(0, 123, 238, .12);
    color: var(--mh-white);
}

.language-menu a[aria-current="true"] {
    background: rgba(0, 123, 238, .18);
    color: var(--mh-white);
    box-shadow: inset 3px 0 0 var(--mh-primary-light);
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 12px;
    font-family: var(--display-font);
    font-size: clamp(34px, 4vw, 56px);
    font-weight: 400;
    line-height: 1;
    text-shadow: 0 9px 28px rgba(0, 39, 82, .45);
}

.summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.summary span {
    min-height: 72px;
    padding: 13px 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(0, 39, 82, .82);
    box-shadow: 0 14px 45px rgba(0, 39, 82, .28);
    color: var(--muted);
    font-size: 13px;
}

.summary strong {
    display: block;
    margin-bottom: 2px;
    color: var(--mh-white);
    font-family: var(--display-font);
    font-size: 28px;
    font-weight: 400;
    line-height: 1;
}

.filters {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(260px, 360px) minmax(160px, 220px) auto;
    gap: 12px;
    align-items: end;
    margin-bottom: 16px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(0, 39, 82, .86);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tabs a,
.button,
.pagination-link {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(0, 39, 82, .58);
    color: var(--text);
    font-weight: 800;
    text-decoration: none;
    transition: background .15s ease, border-color .15s ease, box-shadow .15s ease, color .15s ease, transform .18s ease;
}

.tabs a {
    padding: 0 14px;
    font-family: var(--display-font);
    font-weight: 400;
}

.tabs a:hover,
.pagination-link:hover {
    border-color: rgba(77, 163, 255, .68);
    background: rgba(0, 123, 238, .16);
}

.tabs a[aria-current="page"],
.button,
.pagination-link[aria-current="page"] {
    border-color: rgba(77, 163, 255, .92);
    background: var(--mh-primary);
    color: var(--mh-white);
}

/* MineHub inset accent: horizontal tabs use a 3px highlight along the top edge. */
.tabs a[aria-current="page"] {
    border-color: rgba(77, 163, 255, .68);
    background: rgba(0, 123, 238, .18);
    box-shadow: inset 0 3px 0 var(--mh-primary-light);
}

.tabs a[aria-current="page"]:hover {
    background: rgba(0, 123, 238, .22);
}

.button {
    padding: 0 18px;
    cursor: pointer;
    font-family: var(--display-font);
    font-weight: 400;
}

.button:hover {
    transform: translateY(-1px);
}

.search span,
.select span {
    display: block;
    margin-bottom: 6px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
}

input,
select {
    width: 100%;
    min-height: 40px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(0, 39, 82, .62);
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    outline: none;
}

select {
    color-scheme: dark;
    cursor: pointer;
}

select option {
    background: var(--mh-navy);
    color: var(--mh-light);
}

select option:checked,
select option:hover {
    background: var(--mh-primary);
    color: var(--mh-white);
}

input:focus,
select:focus {
    border-color: var(--mh-primary-light);
    box-shadow: 0 0 0 3px rgba(0, 123, 238, .20);
}

.notice {
    display: grid;
    gap: 6px;
    margin: 0 0 16px;
    padding: 16px;
    border: 1px solid rgba(251, 191, 36, .28);
    border-left: 4px solid var(--amber);
    border-radius: var(--radius);
    background: rgba(251, 191, 36, .10);
}

.notice span {
    color: var(--muted);
}

.records-panel {
    border: 1px solid rgba(77, 163, 255, .34);
    border-radius: var(--radius);
    background: rgba(0, 39, 82, .92);
    box-shadow: 0 22px 70px rgba(0, 39, 82, .46);
    overflow: hidden;
}

.records-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 18px;
    border-bottom: 1px solid rgba(77, 163, 255, .28);
    background: rgba(0, 54, 113, .78);
}

.records-head h2 {
    margin-bottom: 2px;
    font-family: var(--display-font);
    font-size: 18px;
    font-weight: 400;
}

.records-head p {
    margin-bottom: 0;
    color: var(--muted);
}

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

table {
    width: 100%;
    min-width: 1040px;
    border-collapse: collapse;
    background: rgba(0, 39, 82, .78);
}

th,
td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(204, 228, 252, .13);
    text-align: left;
    vertical-align: middle;
}

th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: rgba(0, 39, 82, .98);
    color: var(--mh-primary-subtle);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
}

tbody tr {
    background: rgba(0, 39, 82, .74);
}

tbody tr:nth-child(even) {
    background: rgba(0, 54, 113, .62);
}

tbody tr:hover {
    background: rgba(0, 123, 238, .18);
}

.identity {
    display: grid;
    grid-template-columns: 34px minmax(120px, 1fr);
    gap: 10px;
    align-items: center;
}

.identity img {
    width: 34px;
    height: 34px;
    image-rendering: pixelated;
    border: 1px solid var(--line);
    border-radius: calc(var(--radius) - 3px);
    background: var(--mh-navy);
}

.identity strong,
.reason {
    display: block;
    max-width: 340px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.identity small {
    display: block;
    color: var(--muted);
    font-size: 12px;
}

.type,
.state,
.expiry {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border: 1px solid transparent;
    border-radius: var(--radius-pill);
    font-size: 13px;
    font-weight: 900;
    white-space: nowrap;
}

.type-bans,
.expiry-permanent {
    background: #dc2626;
    border-color: #f87171;
    color: #ffffff;
}

.type-mutes {
    background: #2563eb;
    border-color: #60a5fa;
    color: #ffffff;
}

.type-warns {
    background: #eab308;
    border-color: #fde047;
    color: #1f1600;
}

.type-kicks,
.expiry-recorded {
    background: #f97316;
    border-color: #fdba74;
    color: #ffffff;
}

.state-active,
.state-permanent {
    background: #16a34a;
    border-color: #4ade80;
    color: #ffffff;
}

.state-expired,
.expiry-past {
    background: #facc15;
    border-color: #fde68a;
    color: #241a00;
}

.state-removed,
.expiry-removed {
    background: #64748b;
    border-color: #cbd5e1;
    color: #ffffff;
}

.state-recorded {
    background: #7c3aed;
    border-color: #a78bfa;
    color: #ffffff;
}

.expiry-future {
    background: #16a34a;
    border-color: #4ade80;
    color: #ffffff;
}

.empty {
    padding: 36px;
    color: var(--muted);
    text-align: center;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 7px;
    padding: 14px 18px;
    border-top: 1px solid rgba(77, 163, 255, .26);
    background: rgba(0, 39, 82, .76);
}

.pagination-link {
    min-width: 40px;
    padding: 0 12px;
    font-family: var(--display-font);
    font-weight: 400;
}

.pagination-link.is-disabled,
.pagination-gap {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius);
    color: rgba(154, 167, 184, .58);
}

.pagination-link.is-disabled {
    min-width: 40px;
    padding: 0 12px;
    border: 1px solid rgba(77, 163, 255, .14);
    background: rgba(0, 39, 82, .44);
}

.pagination-gap {
    min-width: 24px;
}

.legal-note {
    margin: 24px 0 0;
    color: var(--muted);
    font-size: .75rem;
    text-align: center;
}

@media (max-width: 1080px) {
    .hero,
    .filters {
        grid-template-columns: 1fr;
    }

    .language-picker {
        justify-self: start;
    }
}

@media (max-width: 760px) {
    .shell {
        width: min(100% - 20px, 1600px);
        padding-top: 18px;
    }

    .summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tabs a,
    .button {
        flex: 1 1 44%;
    }

    .records-head,
    .pagination {
        align-items: stretch;
        flex-direction: column;
    }

    .pagination {
        flex-direction: row;
        justify-content: flex-start;
        overflow-x: auto;
    }
}

@media (max-width: 600px) {
    .headline-logo {
        width: 64px;
        height: 64px;
    }

    .language-picker {
        justify-self: end;
    }

    .language-picker summary {
        min-width: 44px;
        padding: 9px;
    }

    .language-picker summary > span:not(:last-child) {
        display: none;
    }

    .language-menu {
        right: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .headline-logo-link {
        transition: none;
    }

    .headline-logo-link:hover {
        transform: none;
    }
}
