#map {
    height: 100vh;
    width: 100%;
}

.mission-wizard .mission-stepper {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.mission-wizard .mission-step-indicator {
    padding: 0.4rem 0.9rem;
    border: 1px solid #dee2e6;
    border-radius: 999px;
    color: #6c757d;
    font-weight: 500;
    font-size: 0.9rem;
}

.mission-wizard .mission-step-indicator.active {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: #fff;
}

.info {
    padding: 12px 16px;
    font: 14px/16px Arial, Helvetica, sans-serif;
    background: white;
    background: rgba(255,255,255,0.8);
    box-shadow: 0 0 15px rgba(0,0,0,0.2);
    border-radius: 5px;
}

.info h5 {
    margin: 0 0 5px;
    color: #777;
}

.navbar {
    height: 7vh;
    z-index: 999;
}
body {
    font-family: 'Inter', 'Manrope', 'Helvetica Neue', Arial, sans-serif;
    word-break: normal;
    overflow-wrap: normal;
}

.badge-soft {
    background: #eef2ff;
    color: #1e3a8a;
    border-radius: 999px;
    padding: 0.25rem 0.65rem;
    font-weight: 600;
    font-size: 0.85rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    line-height: 1.35;
    flex-wrap: nowrap;
    white-space: normal;
    min-width: 0;
}

.btn .icon {
    flex-shrink: 0;
    width: 1rem;
    height: 1rem;
}

.btn .btn-label {
    display: inline-flex;
    white-space: normal;
    text-align: center;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    line-height: 1.35;
    white-space: normal;
    min-width: 0;
}

.btn .icon {
    flex-shrink: 0;
}

.btn .btn-label {
    display: inline-flex;
    text-align: center;
}

.navbar,
.navbar .nav-link,
.navbar .navbar-brand,
.navbar .navbar-text {
    font-family: inherit;
}

.table {
    font-size: 0.95rem;
    width: 100%;
}

.table th,
.table td {
    font-size: 0.95rem;
    vertical-align: middle;
    white-space: normal;
    word-break: normal;
    overflow-wrap: normal;
}

.table .badge {
    font-size: 0.85rem;
    font-weight: 500;
    white-space: normal;
}

.table th.sortable {
    cursor: pointer;
    user-select: none;
    position: relative;
    padding-right: 1.2rem;
}

.table th.sortable::after {
    content: '⇅';
    position: absolute;
    right: 0.3rem;
    font-size: 0.7rem;
    opacity: 0.35;
}

.table th.sortable.sort-asc::after {
    content: '▲';
    opacity: 0.8;
}

.table th.sortable.sort-desc::after {
    content: '▼';
    opacity: 0.8;
}

.mission-requests-table .btn,
.mission-requests-table .badge {
    font-size: 0.85rem;
}

.mission-requests-table .btn {
    width: 100%;
    text-align: center;
    white-space: normal;
    line-height: 1.35;
}

.mission-action-stack {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    width: 100%;
}

.mission-action-stack .btn {
    white-space: normal;
    line-height: 1.35;
}

.mission-action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    width: 100%;
}

.mission-action-row > form {
    flex: 1 1 45%;
}

.mission-action-note {
    margin: 0;
    font-size: 0.85rem;
    color: #6c757d;
}

.mission-upload-form {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.leaflet-control-layers {
    display: none !important;
}

.map-viewport {
    position: relative;
    min-height: 100vh;
    z-index: 1;
}

.map-panel {
    position: absolute;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(18px);
    color: #0f172a;
    padding: 1rem 1.25rem;
    border-radius: 1rem;
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.15);
    width: min(320px, calc(100% - 2.5rem));
    max-width: calc(100% - 2.5rem);
    z-index: 1010;
}

@media (max-width: 767.98px) {
    .map-panel {
        position: static;
        width: 100%;
        margin-bottom: 1rem;
    }
    .map-panel--legend {
        left: unset;
        bottom: unset;
        width: 100%;
    }
}

.map-panel--controls {
    top: 1.5rem;
    right: 1.5rem;
    width: 260px;
    max-width: calc(100% - 2.5rem);
}

.map-panel--legend {
    left: 1.5rem;
    bottom: 1.5rem;
    width: 240px;
    background: rgba(4, 7, 28, 0.92);
    color: rgba(255, 255, 255, 0.88);
}

.map-control__section + .map-control__section {
    margin-top: 1rem;
    border-top: 1px solid rgba(15, 23, 42, 0.08);
    padding-top: 1rem;
}

.map-control__title {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(15, 23, 42, 0.6);
}

.map-control__segment {
    display: flex;
    gap: 0.5rem;
    border-radius: 0.75rem;
    background: rgba(15, 23, 42, 0.03);
    padding: 0.35rem;
}

.map-control__segment .map-layer-option {
    flex: 1;
}

.map-layer-option {
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 0.6rem;
    color: #0f172a;
    padding: 0.4rem 0.75rem;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 0.4rem;
    transition: border-color 120ms ease, background 120ms ease, color 120ms ease;
}

.map-layer-option.is-active {
    border-color: #4338ca;
    background: rgba(67, 56, 202, 0.08);
    color: #312e81;
}

.map-control__overlay-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.map-overlay-btn {
    background: #fff;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 0.6rem;
    color: #0f172a;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.35rem 0.75rem;
    width: 100%;
    font-size: 0.85rem;
    transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
    white-space: normal;
    text-align: left;
}

.map-overlay-btn.is-active {
    border-color: #16a34a;
    background: rgba(22, 163, 74, 0.08);
    color: #064e3b;
}

.legend-list {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    color: rgba(255, 255, 255, 0.78);
}

.legend-swatch.risk-low {
    background: linear-gradient(90deg, #0f9d58 0%, #34d399 100%);
    border-color: transparent;
}

.legend-swatch.risk-medium {
    background: linear-gradient(90deg, #f4c430 0%, #fbbf24 100%);
    border-color: transparent;
}

.legend-swatch.risk-high {
    background: linear-gradient(90deg, #f97316 0%, #ea580c 100%);
    border-color: transparent;
}

.legend-swatch.risk-extreme {
    background: linear-gradient(90deg, #ef4444 0%, #b91c1c 100%);
    border-color: transparent;
}

.legend-caption {
    margin-top: 0.65rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.65);
}

.mission-upload-form input[type="file"] {
    font-size: 0.85rem;
}

.table-sort-control {
    max-width: 240px;
}

.btn-icon {
    flex-wrap: nowrap;
    text-align: center;
}

.table-action-btn {
    width: 100%;
    justify-content: center;
    text-align: center;
    flex-wrap: nowrap;
}
