/* JS управляет видимостью атрибутом hidden; display-правила классов не должны его перебивать. */
.nav-screen [hidden] {
    display: none !important;
}

:root {
    --nav-bg: #f4f4f2;
    --nav-surface: #ffffff;
    --nav-surface-soft: #fafafa;
    --nav-ink: #2a2a2a;
    --nav-muted: #727272;
    --nav-subtle: #9a9a9a;
    --nav-line: #e5e5e5;
    --nav-line-strong: #d3d3d3;
    --nav-black: #0a0a0a;
    --nav-accent: #ce7762;
    --nav-accent-dark: #ae5d4c;
    --nav-accent-soft: #fbefeb;
    --nav-green: #287c5a;
    --nav-green-soft: #eaf6ef;
    --nav-amber: #9a6400;
    --nav-amber-soft: #fff6dc;
    --nav-red: #b7433d;
    --nav-red-soft: #fff0ef;
    --nav-blue: #2563a7;
    --nav-blue-soft: #edf5ff;
    --nav-shadow: 0 16px 38px rgba(25, 25, 25, .08);
    --nav-radius: 14px;
}

.nav-screen,
.nav-screen * {
    box-sizing: border-box;
}

.nav-screen {
    min-height: 600px;
    overflow-x: hidden;
    background: var(--nav-bg);
    color: var(--nav-ink);
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 14px;
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
}

.nav-screen button,
.nav-screen input {
    font: inherit;
}

.nav-screen button {
    cursor: pointer;
}

.nav-screen button:disabled {
    cursor: not-allowed;
}

.nav-body {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 31px 0 48px;
}

.nav-section {
    min-width: 0;
}

.nav-section[hidden] {
    display: none !important;
}

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

.nav-screen h1 {
    margin-bottom: 8px;
    color: var(--nav-ink);
    font-size: clamp(24px, 3vw, 32px);
    line-height: 1.12;
    letter-spacing: -.035em;
}

.nav-screen h2 {
    margin-bottom: 5px;
    color: var(--nav-ink);
    font-size: 19px;
    line-height: 1.2;
}

.nav-screen h3 {
    margin-bottom: 5px;
    color: var(--nav-ink);
    font-size: 16px;
    line-height: 1.2;
}

.account-tabs {
    display: flex;
    gap: 18px;
    margin: -4px 0 20px;
    border-bottom: 1px solid var(--nav-line);
}

.account-tab {
    padding: 0 0 9px;
    border: 0;
    border-bottom: 2px solid transparent;
    background: transparent;
    color: var(--nav-muted);
    font-size: 13px;
    font-weight: 750;
}

.account-tab.is-active {
    border-bottom-color: var(--nav-accent);
    color: var(--nav-accent-dark);
}

.lead {
    max-width: 720px;
    margin-bottom: 20px;
    color: var(--nav-muted);
    font-size: 13px;
    line-height: 1.6;
}

.small-label {
    color: var(--nav-subtle);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.tiny {
    color: var(--nav-subtle);
    font-size: 11px;
}

.critical-text,
.draft-note,
.disclosure,
.cta-explanation,
.disabled-hint {
    color: var(--nav-muted);
    font-size: 13px;
    line-height: 1.5;
}

.btn {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 750;
    text-decoration: none;
    transition: border-color .15s ease, background-color .15s ease, color .15s ease, opacity .15s ease;
}

.btn-primary {
    border-color: var(--nav-accent);
    background: var(--nav-accent);
    color: #fff;
}

.btn-primary:hover {
    border-color: var(--nav-accent-dark);
    background: var(--nav-accent-dark);
}

.btn-secondary {
    border-color: var(--nav-line-strong);
    background: var(--nav-surface);
    color: var(--nav-ink);
}

.btn-secondary:hover {
    border-color: var(--nav-accent);
}

.btn-ghost {
    border-color: var(--nav-line);
    background: transparent;
    color: var(--nav-muted);
}

.btn-wide {
    width: 100%;
}

.btn-small {
    min-height: 32px;
    padding: 6px 10px;
    font-size: 11px;
}

.btn:disabled,
.disabled-cta {
    border-color: var(--nav-line-strong);
    background: #eeeeee;
    color: #999;
    opacity: .9;
}

.guest-section {
    max-width: 690px;
    padding: 16px 0 26px;
}

.guest-note {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 17px;
    color: var(--nav-muted);
    font-size: 11px;
}

.guest-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--nav-subtle);
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 12px;
    color: var(--nav-accent-dark);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.hero-kicker::before {
    display: inline-block;
    width: 18px;
    height: 2px;
    background: var(--nav-accent);
    content: "";
}

.step-list {
    display: grid;
    gap: 9px;
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
}

.step {
    display: grid;
    grid-template-columns: 29px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    padding: 11px 0;
    border-bottom: 1px solid var(--nav-line);
}

.step:last-child {
    border-bottom: 0;
}

.step-number {
    display: inline-flex;
    width: 25px;
    height: 25px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--nav-accent-soft);
    color: var(--nav-accent-dark);
    font-size: 10px;
    font-weight: 800;
}

.step strong {
    display: block;
    margin-bottom: 2px;
    font-size: 13px;
}

.step span:not(.step-number) {
    display: block;
    color: var(--nav-muted);
    font-size: 11px;
    line-height: 1.45;
}

.account-note {
    margin: 11px 0 0;
    padding: 10px 12px;
    border-radius: 8px;
    background: var(--nav-blue-soft);
    color: var(--nav-muted);
    font-size: 13px;
    line-height: 1.5;
}

.text-link-cta {
    display: inline-block;
    margin-top: 11px;
    color: var(--nav-accent-dark);
    font-size: 13px;
    font-weight: 750;
    text-decoration: none;
}

.text-link-cta:hover,
.route-link:hover,
.qr-toggle:hover {
    text-decoration: underline;
}

.seo-copy {
    margin-top: 26px;
    padding-top: 19px;
    border-top: 1px solid var(--nav-line);
}

.seo-copy p {
    margin-bottom: 12px;
    color: var(--nav-muted);
    font-size: 11.5px;
    line-height: 1.6;
}

.collect-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 20px;
}

.collect-top .lead {
    margin-bottom: 0;
}

.limit-summary {
    flex: 0 0 auto;
    margin: 0;
    white-space: nowrap;
}

.collect-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 270px;
    gap: 20px;
    align-items: start;
}

.collect-card,
.side-card,
.result-card,
.error-card {
    min-width: 0;
    border: 1px solid var(--nav-line);
    border-radius: 12px;
    background: var(--nav-surface);
}

.collect-card {
    padding: 20px;
}

.input-label {
    display: block;
    margin-bottom: 7px;
    color: var(--nav-ink);
    font-size: 12px;
    font-weight: 750;
}

.input-row {
    display: flex;
    gap: 8px;
}

.text-input {
    width: 100%;
    min-width: 0;
    height: 40px;
    padding: 9px 11px;
    border: 1px solid var(--nav-line-strong);
    border-radius: 8px;
    outline: none;
    background: #fff;
    color: var(--nav-ink);
    font-size: 13px;
}

.text-input.invalid {
    border-color: var(--nav-red);
    background: #fffafa;
}

.input-actions {
    display: flex;
    gap: 8px;
    margin-top: 9px;
}

.file-btn {
    flex-direction: column;
    gap: 2px;
    min-height: 50px;
}

.file-btn span {
    color: var(--nav-muted);
    font-size: 10px;
    font-weight: 600;
}

.error-inline {
    margin: 7px 0 15px;
    color: var(--nav-red);
    font-size: 11px;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.helper {
    margin: 8px 0 18px;
}

.order-rule {
    margin: 0 0 9px;
}

.order-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 0 0 9px;
}

.order-correction {
    color: var(--nav-subtle);
    font-size: 10px;
    font-weight: 650;
}

.state-badge {
    display: inline-flex;
    min-height: 22px;
    align-items: center;
    padding: 4px 8px;
    border-radius: 5px;
    background: var(--nav-green-soft);
    color: var(--nav-green);
    font-size: 10px;
    font-weight: 800;
    line-height: 1.2;
    white-space: nowrap;
}

.state-badge.expiring {
    background: var(--nav-amber-soft);
    color: var(--nav-amber);
}

.state-badge.expired,
.state-badge.failed {
    background: var(--nav-red-soft);
    color: var(--nav-red);
}

.state-badge.building {
    background: var(--nav-blue-soft);
    color: var(--nav-blue);
}

.gap-warning,
.manual-warning {
    margin: 0 0 8px;
    padding: 10px 11px;
    border: 1px solid #eed796;
    border-radius: 9px;
    background: var(--nav-amber-soft);
    color: var(--nav-amber);
    font-size: 11px;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.manual-warning {
    margin-bottom: 9px;
}

.permit-list {
    display: grid;
    gap: 8px;
    margin-bottom: 14px;
}

.permit-row {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto auto;
    gap: 10px;
    align-items: center;
    min-width: 0;
    padding: 11px 10px;
    border: 1px solid var(--nav-line);
    border-radius: 9px;
    background: var(--nav-surface-soft);
}

.permit-row.invalid {
    border-color: var(--nav-red);
    background: var(--nav-red-soft);
}

.permit-index {
    display: inline-flex;
    width: 25px;
    height: 25px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--nav-black);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
}

.permit-number {
    color: var(--nav-ink);
    font-size: 11.5px;
    font-weight: 750;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.permit-route {
    margin-top: 3px;
    color: var(--nav-accent-dark);
    font-size: 11px;
    font-weight: 750;
    overflow-wrap: anywhere;
}

.permit-dates {
    margin-top: 3px;
    color: var(--nav-muted);
    font-size: 13px;
}

.permit-status-error {
    display: block;
    margin-top: 4px;
    color: var(--nav-red);
    font-size: 13px;
    font-weight: 750;
}

.permit-actions {
    display: flex;
    gap: 6px;
    align-items: center;
}

.icon-btn {
    display: inline-flex;
    width: 38px;
    min-width: 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid var(--nav-line);
    border-radius: 8px;
    background: var(--nav-surface);
    color: var(--nav-muted);
    font-size: 17px;
}

.icon-btn.remove {
    width: auto;
    min-width: 66px;
    margin-left: 2px;
    padding: 0 11px;
    color: var(--nav-red);
    font-size: 12px;
    font-weight: 750;
}

.icon-btn:disabled {
    opacity: .35;
}

.permit-fix-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 8px;
}

.permit-fix-actions .btn {
    min-height: 36px;
    padding: 7px 10px;
    font-size: 11px;
}

.combo-group {
    margin-top: 14px;
}

.combo-group:first-child {
    margin-top: 0;
}

.combo-heading {
    margin: 0 0 8px;
    color: var(--nav-ink);
    font-size: 12px;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.combo-note {
    margin: 14px 0;
    padding: 10px 11px;
    border-radius: 8px;
    background: var(--nav-blue-soft);
    color: var(--nav-blue);
    font-size: 12px;
    line-height: 1.45;
}

.manual-group-note {
    margin: 0 0 8px;
    color: var(--nav-muted);
    font-size: 13px;
}

.draft-note,
.disabled-hint {
    margin: 9px 0 0;
}

.disabled-hint {
    text-align: center;
}

.create-footer {
    margin-top: 12px;
}

.side-card {
    padding: 17px;
}

.side-card h2 {
    margin-top: 7px;
    font-size: 14px;
}

.side-list {
    display: grid;
    gap: 10px;
    margin: 15px 0 0;
    padding: 0;
    list-style: none;
}

.side-list li {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr);
    gap: 8px;
    color: var(--nav-muted);
    font-size: 11px;
    line-height: 1.45;
}

.side-list b {
    display: inline-flex;
    width: 21px;
    height: 21px;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: var(--nav-accent-soft);
    color: var(--nav-accent-dark);
    font-size: 10px;
}

.divider {
    height: 1px;
    margin: 20px 0;
    background: var(--nav-line);
}

.building-banner {
    margin: -4px 0 15px;
    padding: 10px 12px;
    border: 1px solid #c4dcef;
    border-radius: 8px;
    background: var(--nav-blue-soft);
    color: var(--nav-blue);
    font-size: 12px;
}

.building-screen {
    min-height: 390px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 36px 20px 48px;
}

.building-card {
    width: min(100%, 350px);
    padding: 26px 21px 22px;
    border: 1px solid var(--nav-line);
    border-radius: 14px;
    background: var(--nav-surface);
    box-shadow: 0 10px 25px rgba(20, 20, 20, .05);
    text-align: center;
}

.building-card h1 {
    margin-bottom: 8px;
    font-size: 19px;
}

.building-card p {
    margin-bottom: 20px;
}

.building-note {
    padding: 10px 12px;
    border: 1px solid #c4dcef;
    border-radius: 8px;
    background: var(--nav-blue-soft);
    color: var(--nav-blue);
    font-size: 12px;
    line-height: 1.45;
}

.spinner {
    position: relative;
    width: 46px;
    height: 46px;
    margin: 0 auto 17px;
    border: 4px solid #f1d8d2;
    border-top-color: var(--nav-accent);
    border-radius: 50%;
    animation: nav-spin 900ms linear infinite;
}

.progress-track {
    height: 7px;
    overflow: hidden;
    border-radius: 99px;
    background: #f1e6e2;
    text-align: left;
}

.progress-track span {
    display: block;
    width: 38%;
    height: 100%;
    border-radius: inherit;
    background: var(--nav-accent);
    animation: nav-progress-slide 1.4s ease-in-out infinite;
}

.progress-caption {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
    color: var(--nav-subtle);
    font-size: 13px;
}

.building-card .btn {
    margin-top: 17px;
}

@keyframes nav-spin {
    to { transform: rotate(360deg); }
}

@keyframes nav-progress-slide {
    0% { transform: translateX(-110%); }
    50% { transform: translateX(145%); }
    100% { transform: translateX(300%); }
}

.results-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
}

.result-card {
    margin-bottom: 14px;
    padding: 19px;
}

.result-heading-card {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
}

.result-heading-card h2 {
    margin-top: 7px;
    margin-bottom: 5px;
    font-size: 20px;
}

.result-heading-card h2,
.result-heading-card > div,
.result-layout > div {
    min-width: 0;
}

.status-pill {
    display: inline-flex;
    min-height: 24px;
    align-items: center;
    padding: 4px 8px;
    border-radius: 99px;
    background: var(--nav-green-soft);
    color: var(--nav-green);
    font-size: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.route-link {
    display: inline-block;
    max-width: 100%;
    color: var(--nav-accent-dark);
    font: 11px "SFMono-Regular", Consolas, monospace;
    overflow-wrap: anywhere;
    text-decoration: none;
}

.result-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 160px;
    gap: 23px;
}

.result-section-title {
    margin-bottom: 9px;
    color: var(--nav-muted);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.result-permits {
    display: grid;
    gap: 8px;
    margin: 0 0 17px;
    padding: 0;
    list-style: none;
}

.result-permits li {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr);
    gap: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--nav-line);
}

.result-permits li:last-child {
    border-bottom: 0;
}

.result-permits b {
    color: var(--nav-subtle);
    font-size: 11px;
}

.result-permits strong {
    display: block;
    font-size: 11px;
    overflow-wrap: anywhere;
}

.result-permits span {
    display: block;
    margin-top: 2px;
    color: var(--nav-muted);
    font-size: 13px;
}

.warning-box {
    margin-bottom: 16px;
    padding: 11px 12px;
    border: 1px solid #eed796;
    border-radius: 9px;
    background: var(--nav-amber-soft);
    color: var(--nav-amber);
    font-size: 13px;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.warning-box strong {
    color: #795000;
}

.qr-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 3px;
}

.qr-code {
    width: 126px;
    height: 126px;
    margin-bottom: 9px;
}

.qr-code svg {
    display: block;
    width: 100%;
    height: 100%;
}

.qr-caption {
    color: var(--nav-subtle);
    font-size: 10px;
    text-align: center;
    white-space: pre-line;
}

.copy-link {
    width: 100%;
    margin-top: 11px;
}

.qr-toggle {
    display: none;
    margin-top: 2px;
    color: var(--nav-accent-dark);
    font-size: 13px;
    font-weight: 750;
    text-decoration: none;
}

.permanent-note {
    margin: 15px 0 0;
}

.cta-explanation {
    margin: 9px 0 0;
}

.result-error,
.result-limited,
.result-building {
    padding: 20px;
    border: 1px solid var(--nav-line);
    border-radius: 10px;
    background: var(--nav-surface-soft);
}

.result-error .error-icon,
.result-limited .error-icon,
.result-building .error-icon {
    margin-bottom: 13px;
}

.result-error h2,
.result-limited h2 {
    font-size: 16px;
}

.result-error p,
.result-limited p {
    color: var(--nav-muted);
    font-size: 13px;
}

.error-section {
    display: flex;
    justify-content: center;
    padding: 45px 0;
}

.error-card {
    width: min(100%, 430px);
    padding: 26px 22px;
    text-align: center;
}

.error-icon {
    display: inline-flex;
    width: 32px;
    height: 32px;
    align-items: center;
    justify-content: center;
    margin-bottom: 13px;
    border-radius: 9px;
    background: var(--nav-red-soft);
    color: var(--nav-red);
    font-size: 18px;
    font-weight: 800;
}

.error-card h1 {
    font-size: 20px;
}

.error-card > p:not(.draft-note) {
    margin-bottom: 17px;
    color: var(--nav-muted);
    font-size: 13px;
}

.history-toolbar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 15px;
    margin-bottom: 18px;
}

.history-toolbar h1 {
    margin-top: 7px;
    margin-bottom: 4px;
}

.history-toolbar p {
    margin-bottom: 0;
    color: var(--nav-muted);
    font-size: 11px;
}

.history-list {
    display: grid;
    gap: 8px;
    margin-bottom: 15px;
}

.history-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    min-width: 0;
    padding: 13px 14px;
    border: 1px solid var(--nav-line);
    border-radius: 9px;
    background: var(--nav-surface);
}

.history-item > div:first-child {
    min-width: 0;
}

.history-name {
    margin-bottom: 4px;
    font-size: 12px;
    font-weight: 750;
    overflow-wrap: anywhere;
}

.history-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 7px 12px;
    color: var(--nav-muted);
    font-size: 10px;
}

.history-right {
    display: flex;
    align-items: center;
    gap: 9px;
}

.expired-history-right {
    align-items: flex-start;
}

.expired-action-group {
    display: grid;
    gap: 0;
}

.expired-action {
    border-color: var(--nav-line-strong);
    background: #f2f2f2;
    color: var(--nav-subtle);
}

.expired-note {
    margin-top: 5px;
    color: var(--nav-red);
    font-size: 13px;
    line-height: 1.4;
}

.expiry-caption {
    display: block;
    margin-top: 3px;
    color: var(--nav-subtle);
    font-size: 9px;
    white-space: nowrap;
}

.empty-state {
    margin: 24px 0 15px;
    padding: 37px 20px 41px;
    border: 1px dashed var(--nav-line-strong);
    border-radius: 11px;
    background: var(--nav-surface);
    text-align: center;
}

.empty-icon {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    border-radius: 50%;
    background: var(--nav-accent-soft);
    color: var(--nav-accent-dark);
    font-size: 20px;
}

.empty-state h2 {
    margin-bottom: 7px;
    font-size: 16px;
}

.empty-state p {
    max-width: 330px;
    margin: 0 auto 17px;
    color: var(--nav-muted);
    font-size: 11px;
}

.toast-stack {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 1000;
    display: grid;
    gap: 8px;
    width: min(360px, calc(100vw - 40px));
}

.toast {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 11px;
    border: 1px solid #b9d9c5;
    border-radius: 8px;
    background: var(--nav-green-soft);
    box-shadow: var(--nav-shadow);
    color: var(--nav-green);
    font-size: 13px;
    font-weight: 700;
}

.toast-message {
    min-width: 0;
    overflow-wrap: anywhere;
}

.toast-action {
    flex: 0 0 auto;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--nav-accent-dark);
    font-size: 13px;
    font-weight: 750;
    text-decoration: underline;
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1001;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(10, 10, 10, .55);
}

.modal-dialog {
    width: min(100%, 390px);
    padding: 23px 21px 20px;
    border-radius: 12px;
    background: var(--nav-surface);
    box-shadow: 0 20px 55px rgba(0, 0, 0, .2);
}

.modal-dialog h2 {
    margin-bottom: 12px;
    font-size: 18px;
}

.modal-dialog p {
    color: var(--nav-muted);
    font-size: 13px;
    line-height: 1.5;
}

.modal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
    margin-top: 20px;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(1px, 1px, 1px, 1px) !important;
    white-space: nowrap !important;
}

.nav-screen :focus-visible {
    outline: 3px solid rgba(37, 99, 167, .55);
    outline-offset: 2px;
}

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

    .side-card {
        display: none;
    }

    .result-layout {
        grid-template-columns: 1fr;
    }

    .qr-panel {
        display: grid;
        grid-template-columns: auto 1fr;
        gap: 10px 15px;
        align-items: center;
        justify-items: start;
    }

    .qr-code {
        grid-row: span 3;
        margin-bottom: 0;
    }

    .qr-toggle {
        display: inline-block;
    }

    .qr-code[hidden] {
        display: none;
    }

    .qr-caption {
        text-align: left;
    }

    .copy-link {
        width: auto;
        margin-top: 0;
    }
}

@media (min-width: 821px) {
    .qr-toggle {
        display: none !important;
    }
}

@media (max-width: 560px) {
    .nav-body {
        width: min(100% - 20px, 1200px);
        padding-top: 23px;
    }

    .nav-screen h1 {
        font-size: 23px;
    }

    .collect-top {
        display: block;
    }

    .limit-summary {
        display: block;
        margin-top: 8px;
    }

    .collect-card {
        padding: 16px;
    }

    .input-row {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
    }

    .input-row .btn {
        padding-right: 12px;
        padding-left: 12px;
    }

    .permit-row {
        grid-template-columns: 27px minmax(0, 1fr);
        gap: 9px;
    }

    .permit-row > .state-badge {
        grid-column: 2;
        justify-self: start;
    }

    .permit-actions,
    .permit-fix-actions {
        grid-column: 2;
    }

    .permit-actions {
        flex-wrap: wrap;
    }

    .results-heading,
    .result-heading-card {
        display: block;
    }

    .results-heading .btn,
    .result-heading-card .status-pill {
        margin-top: 9px;
    }

    .history-item {
        grid-template-columns: 1fr;
        gap: 9px;
    }

    .history-right {
        justify-content: space-between;
    }

    .expired-history-right {
        align-items: flex-start;
    }

    .toast-stack {
        right: 10px;
        bottom: 10px;
        width: calc(100vw - 20px);
    }
}
