﻿h1:focus {
    outline: none;
}

:root {
    --app-ink: #17212b;
    --app-muted: #708090;
    --app-line: #e7edf2;
    --app-primary: #157f71;
    --app-primary-dark: #0c655a;
    --app-surface: #ffffff;
    --app-bg: #f5f8fa;
    --app-shadow: 0 12px 35px rgba(28, 55, 74, .08);
}

html, body {
    background: var(--app-bg);
    color: var(--app-ink);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body { min-height: 100vh; }
.app-header { background: var(--app-surface); border-bottom: 1px solid var(--app-line); }
.app-nav { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.brand { display: inline-flex; align-items: center; gap: .7rem; color: var(--app-ink); text-decoration: none; font-size: 1.12rem; letter-spacing: -.02em; }
.brand strong { font-weight: 800; }
.brand small { display: block; color: var(--app-muted); font-size: .62rem; letter-spacing: .09em; text-transform: uppercase; margin-top: .1rem; }
.brand-mark { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; color: #fff; background: linear-gradient(135deg, #1a9b88, #10695f); font-weight: 800; box-shadow: 0 6px 14px rgba(21, 127, 113, .22); }
.app-links { align-items: center; gap: .25rem; }
.app-links .nav-link { color: #61717e; border-radius: 9px; padding: .55rem .75rem; font-size: .9rem; font-weight: 600; }
.app-links .nav-link:hover, .app-links .nav-link.active { color: var(--app-primary); background: #edf8f5; }
.user-pill { color: var(--app-muted); background: #f3f6f8; border-radius: 99px; padding: .45rem .75rem; font-size: .78rem; margin-left: .75rem; }
.logout-link { color: #a85c5c !important; }
.app-main { padding-top: 2.5rem; padding-bottom: 4rem; }
.app-main > h1 { margin-bottom: .45rem; }
.app-main > p.text-muted { margin-bottom: 2rem; color: var(--app-muted) !important; }
.row { display: flex; flex-wrap: wrap; margin-right: -.5rem; margin-left: -.5rem; }
.row > * { padding-right: .5rem; padding-left: .5rem; }
.g-3 { gap: 1rem; margin-right: 0; margin-left: 0; }
.g-3 > * { padding-right: 0; padding-left: 0; }
.align-items-end { align-items: flex-end; }
.justify-content-center { justify-content: center; }
.col-auto { flex: 0 0 auto; width: auto; }
.col-sm-4, .col-md-3 { flex: 0 0 100%; width: 100%; }
.mb-4 { margin-bottom: 2rem !important; }
.mt-2 { margin-top: .55rem !important; }
.text-muted { color: var(--app-muted) !important; }
.text-danger { color: #b74b58 !important; }
.text-success { color: #16806d !important; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: .58rem 1rem; border: 1px solid transparent; border-radius: 9px; font-weight: 650; text-decoration: none; cursor: pointer; }
.btn:disabled { opacity: .6; cursor: not-allowed; }
.btn-outline-secondary { color: #536672; border-color: #d6e0e5; background: #fff; }
.btn-outline-secondary:hover { background: #f2f6f7; }
.btn-outline-success { color: var(--app-primary); border-color: #8bcbbd; background: #fff; }
.btn-outline-success:hover { background: #edf8f5; }
.alert { padding: .9rem 1rem; border-radius: 10px; border: 1px solid transparent; }
.alert-warning { color: #735e23; background: #fff8dc; border-color: #f2dda0; }
.alert-danger { color: #8b3640; background: #fff0f1; border-color: #f0c6ca; }
.alert-success { color: #17654f; background: #e9f8f1; border-color: #b7e5d2; }
.table-responsive { width: 100%; overflow-x: auto; }
.table { width: 100%; border-collapse: separate; border-spacing: 0; }
.table th, .table td { padding: .75rem .85rem; border-bottom: 1px solid var(--app-line); text-align: left; }
.table tbody tr:last-child td { border-bottom: 0; }
.table-striped tbody tr:nth-child(even) td { background: #fbfcfd; }
.form-label { display: inline-block; margin-bottom: .45rem; font-weight: 650; font-size: .86rem; }
.validation-message { margin-top: .35rem; font-size: .8rem; }
.btn-primary { background: var(--app-primary); border-color: var(--app-primary); box-shadow: 0 6px 14px rgba(21, 127, 113, .18); }
.btn-primary:hover, .btn-primary:focus { background: var(--app-primary-dark); border-color: var(--app-primary-dark); }
.form-control, .form-select { border-color: #dce5ea; border-radius: 9px; padding: .65rem .8rem; }
.form-control:focus, .form-select:focus { border-color: #55b5a7; box-shadow: 0 0 0 .2rem rgba(21, 127, 113, .12); }
.card, .table { background: var(--app-surface); border-color: var(--app-line); box-shadow: var(--app-shadow); }
.card { border-radius: 14px; }
.table { border-radius: 12px; overflow: hidden; }
.table thead th { background: #f1f6f7; color: #58717b; border-bottom: 1px solid var(--app-line); font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; }
.table td { vertical-align: middle; }
.dzialki-table th:nth-child(1) { width: 18%; }
.dzialki-table th:nth-child(2) { width: 18%; }
.dzialkowcy-list { margin: 0; padding-left: 1.2rem; }
h1 { font-weight: 800; letter-spacing: -.04em; }
h2 { font-size: 1.2rem; font-weight: 750; }
.eyebrow { display: inline-block; color: var(--app-primary); font-size: .7rem; font-weight: 800; letter-spacing: .13em; margin-bottom: .7rem; }
.hero-panel { position: relative; overflow: hidden; display: flex; justify-content: space-between; align-items: center; min-height: 285px; padding: 3rem 4rem; border-radius: 22px; color: #fff; background: linear-gradient(120deg, #125f57, #19917d); box-shadow: 0 18px 38px rgba(21, 127, 113, .2); }
hero-panel h1 { font-size: clamp(2.1rem, 5vw, 3.6rem); margin: 0 0 .8rem; }
.hero-panel h1 span { color: #9de1d2; }
.hero-panel p { max-width: 520px; color: #d8f1ec; font-size: 1.05rem; margin-bottom: 1.6rem; }
.hero-panel .btn-primary { color: var(--app-primary-dark); background: #fff; border-color: #fff; box-shadow: none; }
.hero-art { position: relative; width: 230px; height: 190px; opacity: .9; }
.hero-art span { position: absolute; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.35); border-radius: 50%; color: #bcebe1; }
.hero-art span:first-child { width: 170px; height: 170px; right: 0; top: 0; font-size: 5rem; }
.hero-art span:nth-child(2) { width: 110px; height: 110px; left: 0; bottom: 0; font-size: 3rem; }
.hero-art span:last-child { width: 20px; height: 20px; right: 50px; bottom: 23px; background: #bcebe1; color: transparent; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 1.5rem; }
.feature-card { display: flex; align-items: center; gap: .9rem; padding: 1.25rem; background: var(--app-surface); border: 1px solid var(--app-line); border-radius: 15px; color: var(--app-ink); text-decoration: none; transition: transform .18s ease, box-shadow .18s ease; }
.feature-card:hover { color: var(--app-ink); transform: translateY(-3px); box-shadow: var(--app-shadow); }
.feature-card h2 { margin: 0 0 .25rem; font-size: 1rem; }
.feature-card p { color: var(--app-muted); font-size: .82rem; margin: 0; }
.feature-icon { flex: 0 0 42px; width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; color: var(--app-primary); background: #e7f6f2; font-weight: 800; font-size: 1.25rem; }
.arrow { margin-left: auto; color: var(--app-primary); font-size: 1.2rem; }
.login-shell { max-width: 430px; margin: 3rem auto; }
.login-card { padding: 2.4rem; background: var(--app-surface); border: 1px solid var(--app-line); border-radius: 20px; box-shadow: var(--app-shadow); }
.login-brand { display: flex; align-items: center; gap: .7rem; margin-bottom: 2rem; font-size: 1.15rem; }
.login-card h1 { margin-bottom: .5rem; }
.login-card .text-muted { margin-bottom: 1.8rem; }
.login-card .mb-3 { margin-bottom: 1.15rem !important; }
.login-card .form-label { display: block; margin-bottom: .45rem; color: var(--app-ink); font-size: .88rem; font-weight: 650; }
.login-card .form-control { display: block; width: 100%; }
.login-card .btn { display: block; width: 100%; padding: .7rem; font-weight: 700; }
.report-toolbar { display: flex; align-items: end; justify-content: space-between; gap: 1.5rem; margin-bottom: 1.5rem; }
.report-toolbar h1 { margin: 0 0 .35rem; }
.report-toolbar p { margin: 0; color: var(--app-muted); }
.report-toolbar-actions { display: flex; align-items: end; gap: .65rem; }
.report-toolbar-actions label { margin-bottom: .45rem; font-size: .82rem; font-weight: 650; }
.report-year { width: 7rem; }
.report-sheet { overflow: hidden; border: 1px solid #cfd8dc; background: #fff; box-shadow: 0 10px 24px rgba(28, 55, 74, .08); }
.report-sheet-heading { padding: 1.15rem 1rem .9rem; text-align: center; border-bottom: 1px solid #aeb9bd; background: #fff; }
.report-sheet-heading h2 { margin: 0 0 .3rem; color: #17212b; font-size: 1.05rem; font-weight: 800; letter-spacing: .02em; }
.report-sheet-heading p { margin: 0; color: #27343a; font-size: .88rem; font-weight: 650; }
.report-scroll { overflow-x: auto; }
.fee-register { width: max-content; min-width: 100%; table-layout: fixed; border-collapse: collapse; box-shadow: none; border-radius: 0; font-size: .73rem; }
.fee-register th, .fee-register td { border: 1px solid #aeb9bd; padding: .35rem .4rem; text-align: center; vertical-align: middle; }
.fee-register thead th { height: 5.2rem; min-width: 5.3rem; background: #f3f5f5; color: #17212b; font-size: .69rem; font-weight: 700; line-height: 1.18; letter-spacing: 0; text-transform: none; white-space: normal; }
.fee-register thead th:nth-child(1) { min-width: 4.3rem; }
.fee-register thead th:nth-child(2) { min-width: 2rem; }
.fee-register thead th:nth-child(3), .fee-register thead th:nth-child(4) { min-width: 7rem; }
.fee-register thead th:nth-child(5) { min-width: 5rem; }
.fee-register thead th:nth-child(6) { min-width: 6rem; }
.fee-register thead th:nth-child(n+7) { min-width: 8rem; }
.fee-register thead th:nth-child(n+18) { min-width: 5.2rem; }
.fee-register .report-rates th { height: 1.8rem; min-width: 0; background: #fff; font-size: .72rem; font-weight: 500; }
.fee-register tbody td { height: 2rem; background: #fff; }
.fee-register tbody tr:nth-child(even) td { background: #fbfcfc; }
.fee-register tfoot th { height: 2rem; background: #f3f5f5; font-weight: 700; }
.fee-register .number { text-align: right; font-variant-numeric: tabular-nums; }

@media (max-width: 900px) {
    .report-toolbar { align-items: stretch; flex-direction: column; }
    .report-toolbar-actions { align-items: center; flex-wrap: wrap; }
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGl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xMTgyIDI2Ni40NDg2IDY2LjA0MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}
