/* WAWEL_AUTH_DEFAULT_PUBLIC_PAGE */
@font-face {
    font-family: "Wawel Nerd Symbols";
    src: url("./fonts/nerd-fonts/SymbolsNerdFont-Subset.woff2") format("woff2");
    font-weight: normal;
    font-style: normal;
    font-display: block;
}

:root {
    color-scheme: dark;
    --bg: #101312;
    --panel: #19201e;
    --panel-2: #202825;
    --panel-3: #121716;
    --line: #35423e;
    --line-soft: rgba(129, 151, 142, 0.18);
    --text: #eff7f3;
    --text-dim: #adbbb4;
    --text-muted: #82938b;
    --accent: #3ddc97;
    --accent-2: #8fd3ff;
    --warn: #f4b860;
    --radius: 8px;
    --radius-sm: 6px;
    --shadow: 0 18px 52px rgba(0, 0, 0, 0.32);
    --font: "Inter", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    font-size: 15px;
    background: var(--bg);
}

body {
    min-height: 100vh;
    margin: 0;
    background:
        linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.014) 1px, transparent 1px),
        linear-gradient(180deg, #121614 0%, #0e1111 100%);
    background-size: 34px 34px, 34px 34px, auto;
    color: var(--text);
    font-family: var(--font);
    line-height: 1.48;
}

a {
    color: var(--accent-2);
}

button {
    font: inherit;
}

a[role="button"] {
    min-height: 2.25rem;
    border: 1px solid rgba(61, 220, 151, 0.5);
    border-radius: var(--radius-sm);
    background: #1f5f46;
    color: #f5fff9;
    padding: 0.45rem 0.75rem;
    font-weight: 650;
    line-height: 1.25;
    text-align: center;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}

a[role="button"]:hover {
    background: #287456;
    border-color: rgba(61, 220, 151, 0.9);
}

a[role="button"].secondary {
    background: #252d2a;
    border-color: var(--line);
    color: var(--text);
}

a[role="button"].secondary:hover {
    background: #303a36;
    border-color: #50625c;
}

a[role="button"].outline {
    background: transparent;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible {
    outline: 2px solid rgba(143, 211, 255, 0.9);
    outline-offset: 2px;
}

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

h1,
h2,
h3 {
    letter-spacing: 0;
}

code {
    font-family: var(--mono);
    font-size: 0.9em;
    color: #def8ff;
    background: rgba(143, 211, 255, 0.08);
    border: 1px solid rgba(143, 211, 255, 0.16);
    border-radius: 4px;
    padding: 0.08rem 0.3rem;
}

.container,
.wa-page {
    width: min(1280px, calc(100vw - 2rem));
    margin: 0 auto;
}

.wa-page {
    min-height: 100vh;
    padding: 1rem 0 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

article,
.info-card,
.fallback-entry,
.mod-entry,
.player-entry {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: linear-gradient(180deg, rgba(31, 39, 36, 0.97), rgba(24, 30, 28, 0.98));
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.03) inset;
}

article {
    padding: 0.9rem;
}

.hidden {
    display: none !important;
}

.muted {
    color: var(--text-muted);
}

.small {
    font-size: 0.86rem;
}

.nf-icon {
    font-family: "Wawel Nerd Symbols", sans-serif;
    font-style: normal;
    font-weight: normal;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-rendering: geometricPrecision;
    -webkit-font-smoothing: antialiased;
}

.section-title,
.label {
    display: block;
    margin: 0 0 0.7rem;
    color: var(--text-muted);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.label {
    margin-bottom: 0.35rem;
}

.section-help {
    margin: -0.35rem 0 0.7rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.45;
}

.value {
    margin: 0;
    color: var(--text);
    font-size: 1rem;
}

.value-wrap {
    overflow-wrap: anywhere;
}

.offscreen-clipboard {
    position: fixed;
    top: -1000px;
    left: -1000px;
    opacity: 0;
    pointer-events: none;
}

.hero {
    display: grid;
    grid-template-columns: 128px minmax(0, 1fr);
    gap: 0.95rem;
    align-items: center;
    padding: 0.9rem 1rem;
}

.hero-art {
    display: flex;
    justify-content: center;
}

.icon-wrap {
    width: 112px;
    height: 112px;
    border: 0;
    border-radius: var(--radius);
    background: transparent;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.icon-wrap img {
    width: 100%;
    height: 100%;
    border-radius: var(--radius);
    object-fit: cover;
    image-rendering: auto;
}

.icon-wrap.is-switchable {
    cursor: pointer;
}

.icon-wrap.fallback img {
    filter: grayscale(1) brightness(0.9);
}

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

.hero-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.hero-head hgroup {
    min-width: 0;
    margin: 0;
}

.hero h1 {
    margin: 0;
    font-size: clamp(1.75rem, 2.8vw, 2.35rem);
    line-height: 1.04;
    overflow-wrap: anywhere;
}

.motd-line {
    margin: 0.42rem 0 0;
    color: var(--text-dim);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hero-corner-actions {
    flex: 0 0 auto;
    display: flex;
    gap: 0.45rem;
}

.icon-only-btn {
    width: 2.35rem;
    height: 2.35rem;
    min-height: 2.35rem;
    padding: 0;
}

.icon-only-btn .nf-icon {
    font-size: 1.12rem;
}

.desc {
    margin: 0.75rem 0 0;
    max-width: 70ch;
    color: var(--text-dim);
    white-space: pre-wrap;
}

.badge-row,
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.badge-row {
    margin-top: 0.75rem;
}

.hero-actions {
    margin-top: 0.8rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    min-height: 1.75rem;
    border: 1px solid rgba(61, 220, 151, 0.36);
    border-radius: 999px;
    background: #17221e;
    color: #d9fff0;
    padding: 0.24rem 0.62rem;
    font-size: 0.84rem;
    font-weight: 700;
}

.badge.muted {
    border-color: var(--line);
    background: #171c1b;
    color: var(--text-dim);
}

.server-address-btn {
    max-width: 100%;
    font-weight: 750;
    overflow-wrap: anywhere;
}

.server-address-btn .nf-icon {
    font-size: 1rem;
}

#serverAddressWarning {
    margin: 0.55rem 0 0;
    color: var(--warn);
}

.layout {
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(300px, 0.88fr);
    gap: 1rem;
    align-items: start;
}

.stack {
    display: grid;
    gap: 1rem;
}

.info-card {
    padding: 0.85rem;
    background: #151a19;
    box-shadow: none;
}

.info-card p {
    margin: 0;
}

.info-grid {
    display: grid;
    gap: 0.75rem;
}

.info-card .value {
    margin-bottom: 0.28rem;
}

.copy-value {
    width: 100%;
    min-height: 0;
    border: 1px solid rgba(143, 211, 255, 0.2);
    border-radius: var(--radius-sm);
    background: rgba(143, 211, 255, 0.06);
    color: var(--text);
    padding: 0.22rem 0.4rem;
    text-align: left;
    cursor: pointer;
}

.copy-value:hover {
    border-color: rgba(143, 211, 255, 0.45);
    background: rgba(143, 211, 255, 0.11);
}

.copy-value:disabled {
    cursor: default;
    opacity: 1;
}

.copy-value:disabled:hover {
    border-color: rgba(143, 211, 255, 0.2);
    background: rgba(143, 211, 255, 0.06);
}

.info-copy-value {
    display: block;
    margin: 0 0 0.28rem;
    overflow-wrap: anywhere;
}

#fallbackList {
    display: grid;
    gap: 0.6rem;
}

.fallback-entry {
    padding: 0.15rem 0.8rem;
    background: #151a19;
    box-shadow: none;
}

.fallback-entry summary {
    padding: 0.6rem 0;
    font-weight: 800;
    cursor: pointer;
}

.fallback-details {
    display: grid;
    gap: 0.52rem;
    padding: 0.2rem 0 0.72rem;
    border-top: 1px solid var(--line-soft);
}

.fallback-link-row {
    display: grid;
    gap: 0.18rem;
}

.fallback-link-label {
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.fallback-link-value {
    overflow-wrap: anywhere;
}

.modlist-details {
    padding: 0;
}

.modlist-details summary {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.1rem 0 0.6rem;
    font-weight: 800;
    cursor: pointer;
}

.modlist-details summary .badge {
    margin-left: auto;
}

.modlist {
    display: grid;
    gap: 0;
    padding: 0.1rem 0 0;
    border-top: 1px solid var(--line-soft);
}

.mod-entry {
    padding: 0.55rem 0;
    border: 0;
    border-bottom: 1px solid var(--line-soft);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.mod-entry:last-child {
    border-bottom: 0;
}

.mod-mainline {
    color: var(--text);
}

.mod-filename {
    margin-top: 0.22rem;
    color: var(--text-muted);
    font-size: 0.82rem;
    overflow-wrap: anywhere;
}

.player-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 0.6rem;
}

.player-entry {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 0;
    padding: 0.65rem 0.75rem;
    background: #151a19;
    box-shadow: none;
}

.player-avatar {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    image-rendering: pixelated;
    flex: 0 0 auto;
}

.player-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 800;
}

.wa-footer {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
}

.footer-brand {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-width: 0;
}

.footer-logo {
    width: 1.65rem;
    height: 1.65rem;
    object-fit: contain;
    opacity: 0.92;
    flex: 0 0 auto;
}

.footer-textline {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    align-items: center;
    justify-content: center;
}

.footer-links {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.58rem;
}

.footer-link {
    width: 1.55rem;
    height: 1.55rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 0.78;
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.footer-link:hover {
    opacity: 1;
    transform: translateY(-1px);
}

.footer-link img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.github-link img {
    filter: invert(1);
}

@media (max-width: 900px) {
    .layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    html {
        font-size: 14px;
    }

    .container,
    .wa-page {
        width: min(100vw - 1rem, 1280px);
    }

    .wa-page {
        padding: 0.6rem 0 0.9rem;
    }

    article {
        padding: 0.85rem;
    }

    .hero {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
    }

    .hero-head {
        flex-direction: column;
        align-items: center;
    }

    .motd-line {
        white-space: normal;
    }

    .badge-row,
    .hero-actions,
    .wa-footer {
        justify-content: center;
    }

    .hero-corner-actions {
        justify-content: center;
    }

    .wa-footer {
        flex-direction: column;
        text-align: center;
    }
}
