:root {
    --bg-sidebar: #ffffff;
    --text-main: #0f1f14;
    --text-muted: #4d7260;
    --border-color: #cde3d4;
    --accent-color: #1e6b45;
    --accent-hover: #134d31;
    --accent-light: #4db87a;
    --accent-pale: #e6f4ec;
    --bg-section: #f0f7f3;
    --bg-dark: #0f2318;
    --font-heading: 'Lora', serif;
    --font-body: 'Inter', sans-serif;
    --sidebar-width: 300px;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.07);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.10);
    --shadow-premium: 0 8px 32px rgba(0, 0, 0, 0.14);
    --glow-color: rgba(30, 107, 69, 0.22);
    --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-quart: cubic-bezier(0.25, 1, 0.5, 1);
    --ease-std: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-spring: cubic-bezier(0.34, 1.2, 0.64, 1);
    --t-micro: 110ms;
    --t-fast: 200ms;
    --t-std: 280ms;
    --t-slow: 440ms;
    --t-reveal: 600ms;
    --stagger: 50ms;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
}

::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}

::-webkit-scrollbar-track {
    background: #f4f6f7;
}

::-webkit-scrollbar-thumb {
    background: #bdc3c7;
    border-radius: 5px;
}

.cursor-distance {
    cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%231e6b45" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"><line x1="2" y1="22" x2="22" y2="2"/><path d="M7 2h5"/><path d="M2 7v5"/></svg>'), crosshair !important;
}

.cursor-area {
    cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%231e6b45" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="m3 3 18 6-9 3-3 9-6-18Z"/></svg>'), crosshair !important;
}

.cursor-coords {
    cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="%231e6b45" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="12" cy="12" r="10"/><line x1="22" y1="12" x2="18" y2="12"/><line x1="6" y1="12" x2="2" y2="12"/><line x1="12" y1="6" x2="12" y2="2"/><line x1="12" y1="22" x2="12" y2="18"/></svg>'), crosshair !important;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body,
html {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    font-family: var(--font-body);
    color: var(--text-main);
    background: #fdfefe;
}

.splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(160deg, #f0f7f3 0%, #d8eee2 40%, #eaf4ee 100%);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease, visibility 0.8s;
}

.splash-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.splash-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    animation: splashFloat 3s ease-in-out infinite;
    position: relative;
}

.splash-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 20px;
}

.splash-logos img {
    height: 64px;
    width: auto;
    object-fit: contain;
    border-radius: 10px;
    background: #ffffff;
    padding: 6px 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.10);
}

.splash-logos img.splash-logo-main {
    height: 78px;
    border-radius: 12px;
    padding: 8px 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.13);
}

.splash-logo-sep {
    width: 1px;
    height: 32px;
    background: rgba(0, 0, 0, 0.12);
    border-radius: 1px;
}

.splash-title {
    font-family: var(--font-heading);
    font-size: 1.85rem;
    color: var(--text-main);
    margin-bottom: 28px;
    font-weight: 700;
}

.splash-progress-wrapper {
    width: 360px;
    max-width: 90vw;
    align-self: center;
}

.splash-progress-track {
    width: 100%;
    height: 6px;
    background: rgba(0, 0, 0, 0.12);
    border-radius: 99px;
    overflow: hidden;
    margin-bottom: 10px;
}

.splash-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--accent-color), var(--accent-light));
    border-radius: 99px;
    transition: width 0.25s ease-out;
    box-shadow: 0 0 8px rgba(30, 107, 69, 0.35);
}

.splash-progress-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.splash-progress-status {
    font-family: var(--font-body);
    font-size: 0.85rem;
    color: var(--text-muted, #555);
}

.splash-progress-pct {
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent-color, #1a5276);
    min-width: 36px;
    text-align: right;
}

@keyframes splashFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-5px);
    }
}

.app-container {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.main-header {
    height: 68px;
    background: linear-gradient(135deg, #1e6b45 0%, #155235 60%, #0f3d27 100%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    z-index: 1100;
    box-shadow: 0 3px 16px rgba(0, 0, 0, 0.22);
    position: relative;
    flex-shrink: 0;
    transition: height 0.5s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.5s, padding 0.5s;
}

.main-header::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle at 80% 50%, rgba(255, 255, 255, 0.04) 0%, transparent 60%);
    pointer-events: none;
}

.main-header.collapsed {
    height: 0;
    min-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
    border: none;
    pointer-events: none;
    overflow: hidden;
}

.header-logos {
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1;
}

.header-logo-link {
    display: flex;
    align-items: center;
}

.header-logo-link img {
    height: 40px;
    width: auto;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.92);
    padding: 4px 6px;
    object-fit: contain;
    transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275),
        box-shadow 0.25s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.header-logo-link:hover img {
    transform: translateY(-2px) scale(1.06);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28);
}

.header-logo-sep {
    width: 1px;
    height: 26px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 1px;
}

.header-info {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 1;
}

.header-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: #ffffff;
    margin: 0;
    font-weight: 700;
    letter-spacing: 0.2px;
    line-height: 1;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

.header-subtitle {
    font-family: var(--font-body);
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.72);
    margin: 5px 0 0 0;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.header-toggle-btn {
    position: absolute;
    bottom: -22px;
    left: 50%;
    transform: translateX(-50%);
    width: 44px;
    height: 22px;
    background: linear-gradient(135deg, #1e6b45 0%, #155235 100%);
    border: none;
    border-radius: 0 0 12px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    z-index: 10;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.15);
}

.header-toggle-btn i {
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.header-toggle-btn:hover {
    background: linear-gradient(135deg, #248253 0%, #196642 100%);
    color: #ffffff;
    height: 26px;
    bottom: -26px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25);
}

.header-toggle-btn:hover i {
    transform: translateY(2px) scale(1.1);
}

.header-toggle-btn:active i {
    transform: translateY(0) scale(0.95);
}

.header-docs {
    position: absolute;
    right: 46px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.header-doc-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.8rem;
    font-family: var(--font-body);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.25, 1, 0.5, 1);
    backdrop-filter: blur(8px);
    white-space: nowrap;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    text-decoration: none;
}

.header-doc-btn i {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8);
    transition: transform 0.2s ease;
}

.header-doc-btn:not(:disabled):hover {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.header-doc-btn:not(:disabled):hover i {
    transform: scale(1.1);
}

.header-doc-btn:not(:disabled):active {
    transform: translateY(1px) scale(0.98);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.header-doc-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.header-report-btn {
    background: linear-gradient(135deg, #1e6b45 0%, #0d4a2c 100%);
    border: 2px solid rgba(120, 240, 160, 0.85);
    color: #ffffff;
    box-shadow: 0 0 0 3px rgba(30, 107, 69, 0.25), 0 6px 20px rgba(30, 107, 69, 0.45);
    font-weight: 700;
    font-size: 0.82rem;
    letter-spacing: 0.3px;
    position: relative;
    overflow: hidden;
    animation: reportGlow 2.5s ease-in-out infinite;
}

@keyframes reportGlow {

    0%,
    100% {
        box-shadow: 0 0 0 3px rgba(30, 107, 69, 0.2), 0 6px 20px rgba(30, 107, 69, 0.4);
    }

    50% {
        box-shadow: 0 0 0 4px rgba(80, 200, 120, 0.4), 0 8px 24px rgba(30, 107, 69, 0.6);
    }
}

.header-report-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.18) 0%, transparent 55%);
    pointer-events: none;
}

.header-report-btn:disabled {
    opacity: 0.9;
    cursor: not-allowed;
}

.header-report-btn i {
    color: #a8ffd0;
    font-size: 1rem;
}

.modal-cluster-list {
    list-style: none;
    padding: 0;
    margin: 8px 0 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.modal-cluster-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.83rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.cluster-dot {
    display: inline-block;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    flex-shrink: 0;
    opacity: 0.85;
}

.map-wrapper {
    flex: 1;
    width: 100%;
    position: relative;
    overflow: hidden;
}

.map-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #e5e3df;
    z-index: 1;
}

.sidebar {
    position: absolute;
    top: 15px;
    left: 20px;
    bottom: 5px;
    width: var(--sidebar-width);
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.06);
    z-index: 1000;
    overflow: hidden;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.3s ease;
}

.sidebar:hover {
    box-shadow: 0 8px 35px rgba(0, 0, 0, 0.1);
}

.sidebar.collapsed {
    transform: translateX(calc(-100% - 30px));
    box-shadow: none;
}

.sidebar-header {
    padding: 8px 12px;
    background: linear-gradient(135deg, #1e6b45, #2d9a63);
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.sidebar-header-icon {
    width: 24px;
    height: 24px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.9);
    flex-shrink: 0;
}

.sidebar-header h2 {
    font-family: var(--font-heading);
    font-size: 0.76rem;
    font-weight: 600;
    color: #ffffff;
    margin: 0;
    line-height: 1.2;
    border: none;
    padding: 0;
    text-transform: none;
    letter-spacing: 0;
}

.sidebar-header-sub {
    font-family: var(--font-body);
    font-size: 0.60rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 1px 0 0 0;
    font-weight: 400;
}

.sidebar-content {
    padding: 0;
    flex-grow: 1;
    overflow: hidden;
    background: var(--bg-section);
}

.sidebar-content::-webkit-scrollbar {
    width: 6px;
}

.sidebar-content::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar-content::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.15);
    border-radius: 10px;
}

.sidebar-content::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

.control-group {
    background: #ffffff;
    border-radius: 8px;
    padding: 7px 10px 5px;
    margin-bottom: 0;
    border-left: 3px solid var(--accent-color);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.control-group:hover {
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
}

.control-group h2 {
    font-family: var(--font-heading);
    font-size: 0.62rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.7px;
    color: var(--accent-color);
    margin-bottom: 5px;
    padding-bottom: 4px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 7px;
}

.section-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    background: var(--accent-color);
    border-radius: 50%;
    flex-shrink: 0;
}

.switch {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 18px;
    margin-right: 8px;
    flex-shrink: 0;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #c5d8c5;
    border-radius: 20px;
    transition:
        background-color var(--t-std) var(--ease-std),
        box-shadow var(--t-fast) var(--ease-std);
}

.slider:before {
    position: absolute;
    content: "";
    height: 13px;
    width: 13px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    transition:
        transform var(--t-std) var(--ease-spring),
        box-shadow var(--t-fast) var(--ease-std);
    will-change: transform;
}

input:checked+.slider {
    background-color: var(--accent-color);
}

input:focus+.slider {
    box-shadow: 0 0 0 2px var(--glow-color);
}

input:checked+.slider:before {
    transform: translateX(16px);
}

.slider.round {
    border-radius: 24px;
}

.slider.round:before {
    border-radius: 50%;
}

.checkbox-item {
    display: flex;
    align-items: center;
    margin-bottom: 2px;
    position: relative;
    font-size: 0.75rem;
    color: var(--text-main);
    transition: color 0.25s ease, background 0.25s ease, transform 0.25s cubic-bezier(0.25, 1, 0.5, 1);
    padding: 2px 4px;
    border-radius: 5px;
    margin-left: -4px;
    margin-right: -4px;
}

.checkbox-item:hover {
    color: var(--accent-color);
    background: rgba(30, 107, 69, 0.04);
    transform: translateX(2px);
}

.control-label {
    font-size: 0.76rem;
    font-weight: 500;
    cursor: pointer;
    flex-grow: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    user-select: none;
    transition: color 0.2s;
}

.control-label--wrap {
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
    line-height: 1.3;
}

.checkbox-item:hover .control-label {
    color: var(--accent-color);
}

.layer-block {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0 6px;
    margin-bottom: 2px;
    padding-bottom: 2px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.layer-block .checkbox-item {
    flex: 1;
    min-width: 0;
    margin-bottom: 0;
}

.layer-block:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.slider-container {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-left: 28px;
    margin-top: 3px;
    flex-basis: 100%;
    opacity: 0.8;
    animation: slideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-6px);
        max-height: 0;
    }

    to {
        opacity: 0.8;
        transform: translateY(0);
        max-height: 40px;
    }
}

.slider-icon {
    font-size: 11px;
    color: #666;
}

.opacity-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    background: var(--border-color);
    border-radius: 2px;
    outline: none;
}

.opacity-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--accent-color);
    cursor: pointer;
    transition: background .15s ease;
}

.opacity-slider::-webkit-slider-thumb:hover {
    background: var(--accent-light);
}

.color-picker-hidden {
    position: absolute;
    width: 0;
    height: 0;
    opacity: 0;
    pointer-events: none;
}

.color-pen-btn {
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    color: #94a3b8;
    font-size: 0.7rem;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.25s, color 0.25s, transform 0.25s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.25s;
}

.color-pen-btn:hover {
    background: rgba(255, 255, 255, 0.4);
    color: var(--accent-color);
    transform: scale(1.15) rotate(8deg);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.color-pen-btn:active {
    transform: scale(0.95);
}

.legend-detail {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 0;
    flex-shrink: 0;
}

.legend-swatch {
    width: 10px;
    height: 10px;
    border-radius: 2px;
    flex-shrink: 0;
}

.legend-swatch-line {
    width: 22px;
    height: 0;
    border-radius: 0;
    background: none !important;
}

.legend-label {
    font-size: 0.62rem;
    color: #94a3b8;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.legend-gradient-row {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0;
    flex-shrink: 0;
    width: 80px;
}

.legend-gradient-bar {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.legend-bound {
    font-size: 0.55rem;
    color: #94a3b8;
    white-space: nowrap;
    min-width: 12px;
    text-align: center;
}

.sidebar-toggle {
    position: absolute;
    top: 35px;
    left: calc(var(--sidebar-width) + 19px);
    z-index: 1001;
    width: 28px;
    height: 44px;
    background: rgba(10, 24, 15, 0.78);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(78, 200, 120, 0.2);
    border-left: none;
    border-radius: 0 8px 8px 0;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    cursor: pointer;
    box-shadow: 3px 0 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: left 0.4s cubic-bezier(0.25, 1, 0.5, 1), transform 0.25s cubic-bezier(0.25, 1, 0.5, 1), background 0.25s, color 0.25s;
}

.sidebar-toggle i {
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.sidebar-toggle:hover {
    background: var(--accent-color);
    color: #ffffff;
    box-shadow: 6px 0 16px rgba(0, 0, 0, 0.25);
    width: 32px;
}

.sidebar-toggle:hover i {
    transform: translateX(2px);
}

.sidebar-toggle:active i {
    transform: translateX(0) scale(0.9);
}

.sidebar-toggle.collapsed {
    left: 0;
    top: 90px;
    border-radius: 0 8px 8px 0;
}

.main-footer {
    height: 36px;
    background: var(--bg-dark);
    border-top: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    z-index: 1100;
    box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.18);
    transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
    position: relative;
    flex-shrink: 0;
}

.main-footer.collapsed {
    height: 0;
    min-height: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
    border: none;
    pointer-events: none;
    overflow: hidden;
}

.footer-left p {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.45);
    font-weight: 400;
    letter-spacing: 0.4px;
}

.footer-crs {
    font-family: 'Courier New', monospace;
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.35);
    letter-spacing: 0.5px;
}

.footer-cc {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.40);
}

.footer-cc i {
    font-size: 0.70rem;
}

.footer-btn {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 3px 12px;
    border-radius: 5px;
    font-size: 0.72rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.footer-btn:hover {
    background: var(--accent-color);
    border-color: var(--accent-color);
    color: #ffffff;
}

.footer-toggle-btn {
    position: absolute;
    top: -22px;
    left: 50%;
    transform: translateX(-50%);
    width: 44px;
    height: 22px;
    background: var(--bg-dark);
    border: none;
    border-radius: 12px 12px 0 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    box-shadow: 0 -4px 6px rgba(0, 0, 0, 0.15);
    z-index: 10;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.footer-toggle-btn i {
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.footer-toggle-btn:hover {
    background: #1a221b;
    color: #ffffff;
    height: 26px;
    top: -26px;
    box-shadow: 0 -6px 12px rgba(0, 0, 0, 0.25);
}

.footer-toggle-btn:hover i {
    transform: translateY(-2px) scale(1.1);
}

.footer-toggle-btn:active i {
    transform: translateY(0) scale(0.95);
}


.reveal-btn {
    position: absolute;
    color: rgba(255, 255, 255, 0.8);
    border: none;
    width: 44px;
    height: 22px;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1200;
    font-size: 11px;
    box-shadow: var(--shadow-md);
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    animation: revealPulse 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes revealPulse {
    from {
        opacity: 0;
        transform: translateX(-50%) scaleX(0.7);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) scaleX(1);
    }
}

#reveal-header {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 0 0 12px 12px;
    background: linear-gradient(135deg, #1e6b45 0%, #155235 100%);
}

#reveal-footer {
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 12px 12px 0 0;
    background: var(--bg-dark);
}

.reveal-btn:hover {
    background: var(--accent-color);
    color: #ffffff;
    height: 28px;
}

.leaflet-zoom-anim .leaflet-zoom-animated {
    transition: transform 0.22s cubic-bezier(0.25, 0.46, 0.45, 0.94) !important;
}

.leaflet-left .leaflet-control {
    margin-left: calc(var(--sidebar-width) + 80px);
    transition: margin-left 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.sidebar-collapsed-map .leaflet-left .leaflet-control {
    margin-left: 20px !important;
}

.leaflet-control-zoom a {
    color: var(--text-main) !important;
}

.leaflet-bar {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.8) !important;
    border-radius: 10px !important;
    overflow: hidden;
}

.leaflet-bar a {
    background-color: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(8px);
    color: var(--text-main) !important;
    transition: background-color 0.18s, color 0.18s, transform 0.12s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.18s !important;
    user-select: none;
}

.leaflet-bar a:hover {
    background-color: rgba(240, 247, 243, 0.98) !important;
    color: var(--accent-color) !important;
    transform: scale(1.08) !important;
    box-shadow: 0 2px 10px rgba(30, 107, 69, 0.18) !important;
}

.leaflet-bar a:active {
    background-color: var(--accent-pale) !important;
    color: var(--accent-color) !important;
    transform: scale(0.93) !important;
    transition-duration: 0.07s !important;
}

.gm-compass {
    cursor: default;
    line-height: 0;
    filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.25));
    margin-top: 6px;
}

.gm-scale {
    background: rgba(10, 24, 15, 0.72);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(78, 200, 120, 0.15);
    border-radius: var(--radius-sm);
    padding: 5px 12px 9px;
    font-family: var(--font-body);
    font-weight: 500;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.80);
    box-shadow: var(--shadow-md);
    margin-bottom: 24px !important;
    text-align: center;
}

.gm-scale-bar {
    height: 4px;
    background: transparent;
    margin-top: 5px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.7);
    border-left: 2px solid rgba(255, 255, 255, 0.7);
    border-right: 2px solid rgba(255, 255, 255, 0.7);
    box-sizing: content-box;
}

.map-toolbar {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-top: 3px solid var(--accent-color);
    border-radius: 0 0 var(--radius-md) var(--radius-md);
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    box-shadow: var(--shadow-md);
    margin-right: 16px !important;
    margin-top: 8px !important;
    min-width: 148px;
}

.toolbar-sep {
    height: 1px;
    background: var(--border-color);
    margin: 3px 4px;
    opacity: 0.7;
}

.tool-btn {
    background: transparent;
    border: 1px solid transparent;
    border-radius: 9px;
    padding: 7px 10px;
    width: 100%;
    height: auto;
    color: var(--text-main);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    transition: all 0.25s cubic-bezier(0.25, 1, 0.5, 1);
    position: relative;
    text-align: left;
}

.tool-btn i {
    font-size: 14px;
    color: var(--accent-color);
    pointer-events: none;
    width: 16px;
    text-align: center;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.tool-label {
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 500;
    color: var(--text-main);
    pointer-events: none;
    white-space: nowrap;
}

.tool-btn:hover {
    background: var(--bg-section);
    border-color: var(--border-color);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transform: translateX(2px);
}

.tool-btn:hover i {
    transform: scale(1.15);
}

.tool-btn:active {
    transform: translateX(1px) scale(0.98);
}

.tool-btn:hover .tool-label {
    color: var(--accent-color);
}

.tool-btn.active {
    background: var(--accent-color);
    border-color: var(--accent-hover);
    box-shadow: 0 2px 10px var(--glow-color);
}

.tool-btn.active i,
.tool-btn.active .tool-label {
    color: #ffffff;
}

.tool-info {
    background: #ffffff;
    border-radius: 10px;
    padding: 11px 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12), 0 0 0 1.5px var(--border-color);
    font-family: var(--font-body);
    font-size: 13.5px;
    font-weight: 500;
    color: var(--text-main);
    max-width: 380px;
    text-align: center;
    margin-bottom: 30px !important;
    animation: slideUpFade 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    border-left: 3.5px solid var(--accent-color);
}

@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tool-info i {
    margin-right: 8px;
    color: var(--accent-color);
    font-size: 14px;
}

.tool-info .fa-spinner {
    color: var(--accent-light);
}

.tool-info b {
    color: var(--text-main);
}

.mouse-tooltip {
    position: absolute;
    background: rgba(10, 24, 15, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: rgba(255, 255, 255, 0.92);
    padding: 9px 14px;
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 12.5px;
    pointer-events: none;
    z-index: 9999;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
    border: 1px solid rgba(78, 200, 120, 0.15);
    white-space: nowrap;
}

.mouse-tooltip b {
    font-size: 13.5px;
    color: var(--accent-light);
}

.tooltip-hint {
    display: block;
    font-size: 10.5px;
    color: rgba(255, 255, 255, 0.45);
    margin-top: 3px;
}

.custom-popup .leaflet-popup-content-wrapper {
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

.custom-popup .leaflet-popup-content {
    margin: 16px;
    font-family: var(--font-body);
    font-size: 14px;
    color: #1e293b;
    line-height: 1.5;
}

.custom-popup .leaflet-popup-tip {
    background: rgba(255, 255, 255, 0.95);
}

.elevation-panel {
    position: absolute;
    bottom: 80px;
    right: 25px;
    width: 600px;
    height: 240px;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 15px;
    box-shadow: var(--shadow-premium);
    z-index: 2000;
    display: none;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.elevation-panel.active {
    display: flex;
    transform: translateY(0);
    opacity: 1;
}

.elevation-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #f8fafc;
    font-family: var(--font-heading);
    font-size: 0.95rem;
    margin-bottom: 10px;
    padding: 0 5px;
}

.elevation-header i {
    color: var(--accent-light);
}

.elevation-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.export-chart-btn {
    background: rgba(30, 41, 59, 0.7);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #f8fafc;
    padding: 4px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: var(--font-body);
}

.export-chart-btn:hover {
    background: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-1px);
}

.export-chart-btn i {
    color: inherit;
    font-size: 0.8rem;
}

#close-elevation {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 1.1rem;
    transition: color 0.2s;
}

#close-elevation:hover {
    color: #f8fafc;
}

#elevationChart {
    width: 100% !important;
    height: 100% !important;
}

@media (max-width: 800px) {
    .elevation-panel {
        width: calc(100% - 30px);
        height: 180px;
        right: 15px;
        bottom: 60px;
        border-radius: 14px;
        padding: 10px;
    }
}

.context-menu {
    position: absolute;
    background: rgba(12, 28, 18, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(78, 200, 120, 0.18);
    border-radius: var(--radius-md);
    padding: 6px 0;
    min-width: 215px;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.04);
    z-index: 10000;
    display: none;
    flex-direction: column;
    animation: scaleIn 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.context-menu-item {
    padding: 9px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s;
    font-family: var(--font-body);
}

.context-menu-item:hover {
    background: rgba(78, 200, 120, 0.12);
    color: #ffffff;
}

.context-menu-item i {
    width: 18px;
    text-align: center;
    color: var(--accent-light);
    font-size: 13px;
}

.context-menu-item.danger {
    color: #fc8181;
}

.context-menu-item.danger i {
    color: #fc8181;
}

.context-menu-item.danger:hover {
    background: rgba(252, 129, 129, 0.12);
}

.context-menu-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 3px 12px;
}

.coords-bar {
    position: absolute;
    bottom: 8px;
    right: 12px;
    background: rgba(10, 24, 15, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(78, 200, 120, 0.18);
    border-radius: var(--radius-sm);
    padding: 4px 14px;
    font-family: var(--font-body);
    font-size: 0.70rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.82);
    z-index: 800;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    pointer-events: none;
    white-space: nowrap;
}

.coords-bar i {
    color: var(--accent-light);
    margin-right: 4px;
    font-size: 0.72rem;
}

.zoom-display {
    color: rgba(255, 255, 255, 0.45);
    font-size: 0.75rem;
    border-left: 1px solid var(--border-color);
    padding-left: 14px;
}

.splash-cc {
    margin: 12px 0 0;
    font-size: 0.80rem;
    color: rgba(0, 0, 0, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex-wrap: wrap;
    text-align: center;
}

.splash-cc i {
    font-size: 0.90rem;
    color: rgba(0, 0, 0, 0.65);
}

.basemap-group {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
    padding: 1px 0;
}

.basemap-radio-item {
    display: flex;
    align-items: center;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.15s;
}

.basemap-radio-item input[type="radio"] {
    display: none;
}

.basemap-radio-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 4px 3px;
    border-radius: 5px;
    width: 100%;
    font-size: 0.60rem;
    font-weight: 500;
    color: var(--text-main);
    border: 1px solid transparent;
    transition: background 0.15s, border-color 0.15s;
}

.basemap-radio-inner i {
    font-size: 11px;
    color: var(--accent-color);
    width: 14px;
    text-align: center;
    flex-shrink: 0;
}

.basemap-radio-item:hover .basemap-radio-inner {
    background: rgba(0, 0, 0, 0.05);
}

.basemap-radio-item input[type="radio"]:checked+.basemap-radio-inner {
    background: rgba(26, 82, 118, 0.1);
    border-color: rgba(26, 82, 118, 0.3);
    color: var(--accent-color);
    font-weight: 600;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.4s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    padding: 40px;
    border-radius: 20px;
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    font-family: var(--font-body);
    transform: scale(0.95) translateY(10px);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.info-modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 24px;
}

@media (max-width: 768px) {
    .info-modal-body {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

.modal-overlay.active .modal-content {
    transform: scale(1) translateY(0);
}

.modal-content h2 {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    color: var(--accent-color);
    margin-bottom: 20px;
    padding-right: 24px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.05);
    padding-bottom: 12px;
}

.modal-content p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 12px;
    color: var(--text-main);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 1.8rem;
    color: var(--text-muted);
    cursor: pointer;
    line-height: 1;
    transition: color 0.25s ease, transform 0.25s ease;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--accent-color);
    background: rgba(0, 0, 0, 0.05);
    transform: rotate(90deg);
}

.dark-btn-north {
    margin-top: 10px;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-color);
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.25, 1, 0.5, 1);
}

.dark-btn-north i {
    color: var(--text-main);
    font-size: 14px;
    transition: transform 0.25s, color 0.25s;
}

.dark-btn-north:hover {
    background: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.dark-btn-north:hover i {
    transform: rotate(-15deg) scale(1.1);
    color: var(--accent-color);
}

.dark-btn-north:active {
    transform: translateY(1px) scale(0.95);
}

.modal-list {
    list-style: none;
    padding: 0;
    margin: 0 0 12px 0;
}

.modal-list li {
    font-size: 0.9rem;
    color: var(--text-main);
    line-height: 1.7;
    padding-left: 16px;
    position: relative;
}

.modal-list li::before {
    content: '›';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
}

.modal-section {
    background: var(--bg-section);
    border-radius: var(--radius-sm);
    padding: 14px 16px;
    margin-bottom: 10px;
    border-left: 3px solid var(--accent-color);
    animation: fadeInUp 0.3s ease both;
}

.modal-section-title {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent-color);
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-section-title i {
    font-size: 0.8rem;
    width: 16px;
    text-align: center;
}

.modal-section-text {
    font-size: 0.85rem;
    color: var(--text-main);
    margin: 0;
    line-height: 1.5;
}

.modal-tools-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-bottom: 8px;
}

.modal-tool {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    color: var(--text-main);
    padding: 5px 8px;
    background: #ffffff;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    transition: background 0.2s, border-color 0.2s;
}

.modal-tool:hover {
    background: var(--accent-pale);
    border-color: var(--accent-light);
}

.modal-tool i {
    color: var(--accent-color);
    font-size: 0.75rem;
    width: 14px;
    text-align: center;
}

.modal-docs-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.doc-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 14px;
    border-radius: 7px;
    border: 1px solid var(--border-color);
    background: #ffffff;
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
    text-decoration: none;
}

.doc-btn i {
    color: #c0392b;
    font-size: 0.9rem;
}

.doc-btn:hover:not(:disabled) {
    background: #fef2f2;
    border-color: #c0392b;
    color: #c0392b;
}

.doc-btn-disabled,
.doc-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.modal-tool kbd,
.modal-section-hint kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    border: 1px solid #d1d5db;
    border-bottom: 2px solid #9ca3af;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--text-muted);
    padding: 1px 5px;
    margin-left: auto;
    min-width: 20px;
    text-align: center;
}

.modal-section-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin: 0;
    text-align: center;
}

.modal-section-hint kbd {
    margin-left: 0;
    margin-right: 2px;
}

.leaflet-control-minimap {
    margin-bottom: 0px !important;
}


.arcgis-cluster-dot {
    border-radius: 50%;
    border: 2px solid;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.40);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-body);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.arcgis-cluster-dot:hover {
    transform: scale(1.18);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.55);
}

.leaflet-cluster-anim .leaflet-marker-icon,
.leaflet-cluster-anim .leaflet-marker-shadow {
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
}

.marker-cluster-small,
.marker-cluster-medium,
.marker-cluster-large {
    background: transparent !important;
}

.marker-cluster-small div,
.marker-cluster-medium div,
.marker-cluster-large div {
    background: transparent !important;
    color: transparent !important;
}

.sidebar-tabs {
    display: flex;
    background: var(--bg-section);
    border-bottom: 2px solid var(--border-color);
    flex-shrink: 0;
    padding: 0 6px;
    gap: 4px;
}

.sidebar-tab {
    flex: 1;
    background: none;
    border: none;
    border-bottom: 2.5px solid transparent;
    margin-bottom: -2px;
    color: var(--text-muted);
    font-family: var(--font-body);
    font-size: 10.5px;
    font-weight: 600;
    padding: 8px 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s cubic-bezier(0.25, 1, 0.5, 1);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    border-radius: 8px 8px 0 0;
    position: relative;
    overflow: hidden;
}

.sidebar-tab:hover {
    color: var(--accent-color);
    background: rgba(30, 107, 69, 0.08);
}

.sidebar-tab.active {
    color: var(--accent-color);
    border-bottom-color: var(--accent-color);
    background: #ffffff;
    font-weight: 700;
}

.sidebar-tab.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2.5px;
    background: var(--accent-color);
}

.sidebar-page {
    display: none;
    opacity: 0;
    transform: translateY(6px);
}

.sidebar-page.active {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 0;
    opacity: 1;
    transform: translateY(0);
    animation: fadeInUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.layer-order-hint {
    font-size: 11px;
    color: var(--text-muted);
    margin: -4px 0 12px 0;
    line-height: 1.6;
    padding: 8px 10px;
    background: var(--bg-section);
    border-radius: 8px;
    border-left: 3px solid var(--accent-color);
}

.layer-order-panel {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.layer-order-row {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #ffffff;
    border: 1.5px solid var(--border-color);
    border-radius: 9px;
    padding: 9px 12px;
    cursor: grab;
    user-select: none;
    transition: background 0.15s, border-color 0.15s, opacity 0.15s, box-shadow 0.15s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.layer-order-row:hover {
    background: var(--bg-section);
    border-color: var(--accent-light);
    box-shadow: 0 2px 8px rgba(30, 107, 69, 0.1);
}

.layer-order-row.dragging {
    opacity: 0.45;
    cursor: grabbing;
    box-shadow: 0 8px 24px rgba(30, 107, 69, 0.18);
}

.layer-order-row.drag-over {
    background: rgba(82, 183, 136, 0.12);
    border-color: var(--accent-color);
    border-style: dashed;
    box-shadow: 0 0 0 2px rgba(30, 107, 69, 0.15);
}

.drag-handle {
    color: var(--text-muted);
    font-size: 13px;
    flex-shrink: 0;
    cursor: grab;
    opacity: 0.55;
    transition: opacity 0.15s, color 0.15s;
}

.layer-order-row:hover .drag-handle {
    opacity: 1;
    color: var(--accent-color);
}

.order-sym {
    display: inline-block;
    flex-shrink: 0;
    vertical-align: middle;
}

.layer-order-num {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--bg-section);
    border: 1.5px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    color: var(--text-muted);
    flex-shrink: 0;
}

.layer-order-label {
    font-size: 11.5px;
    color: var(--text-main);
    flex: 1;
    min-width: 0;
    font-weight: 500;
    line-height: 1.3;
}

.layer-order-badge {
    font-size: 9px;
    color: #ffffff;
    background: var(--accent-color);
    border-radius: 4px;
    padding: 2px 7px;
    flex-shrink: 0;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.layer-order-badge.badge-top {
    background: var(--accent-color);
}

.layer-order-badge.badge-bot {
    background: #94a3b8;
}

.sidebar-close-mobile {
    display: none;
}

.sidebar-backdrop {
    display: none;
}

@media (max-width: 1024px) {
    :root {
        --sidebar-width: 260px;
    }

    .main-header {
        padding: 0 16px;
    }

    .header-title {
        font-size: 1.05rem;
    }

    .header-subtitle {
        font-size: 0.6rem;
        letter-spacing: 1.5px;
    }

    .main-footer {
        padding: 0 16px;
    }

    .map-toolbar {
        min-width: 44px;
        padding: 4px;
        margin-right: 8px !important;
    }

    .tool-label {
        display: none;
    }

    .tool-btn {
        justify-content: center;
        padding: 8px;
    }
}

@media (max-width: 768px) {
    :root {
        --sidebar-width: 100%;
    }

    .main-header {
        height: 52px;
        padding: 0 46px 0 12px;
        gap: 10px;
        justify-content: flex-start;
    }

    .header-docs {
        display: none;
    }

    .header-info {
        position: static;
        transform: none;
        flex: 1;
        text-align: center;
        pointer-events: none;
        min-width: 0;
        overflow: hidden;
    }

    .header-logo-link img {
        height: 30px;
        padding: 3px 4px;
    }

    .header-logo-sep {
        height: 20px;
    }

    .header-title {
        font-size: 0.9rem;
    }

    .header-subtitle {
        display: none;
    }

    .header-toggle-btn {
        width: 32px;
        height: 32px;
        font-size: 11px;
    }

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 100%;
        border-radius: 0;
        z-index: 2500;
        border: none;
        transform: translateX(-100%);
    }

    .sidebar:not(.collapsed) {
        transform: translateX(0);
    }

    .sidebar.collapsed {
        transform: translateX(-100%);
    }

    .sidebar-toggle {
        position: fixed;
        top: auto;
        bottom: 92px;
        left: 10px;
        width: 44px;
        height: 44px;
        border-radius: 50%;
        border: 1px solid rgba(78, 200, 120, 0.3);
        font-size: 16px;
        z-index: 2000;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    }

    .sidebar-toggle.collapsed {
        top: auto;
        left: 10px;
        bottom: 92px;
        border-radius: 50%;
    }

    .sidebar-header {
        padding: 16px 14px 12px;
    }

    .sidebar-header-icon {
        width: 32px;
        height: 32px;
        font-size: 0.85rem;
    }

    .sidebar-header h2 {
        font-size: 0.85rem;
    }

    .sidebar-content {
        padding: 0;
    }

    .control-group {
        padding: 10px 12px;
    }

    .checkbox-item {
        padding: 6px 8px;
        min-height: 40px;
    }

    .switch {
        width: 48px;
        height: 26px;
    }

    .slider:before {
        height: 20px;
        width: 20px;
    }

    input:checked+.slider:before {
        transform: translateX(22px);
    }

    .control-label {
        font-size: 0.9rem;
    }

    .sidebar-tab {
        padding: 12px 6px;
        font-size: 10.5px;
    }

    .sidebar-close-mobile {
        display: flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        top: 14px;
        right: 12px;
        width: 34px;
        height: 34px;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.15);
        border: 1px solid rgba(255, 255, 255, 0.2);
        color: rgba(255, 255, 255, 0.8);
        font-size: 1rem;
        cursor: pointer;
        z-index: 10;
    }

    .sidebar-backdrop {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.4);
        z-index: 2400;
    }

    .sidebar-backdrop.active {
        display: block;
    }

    .leaflet-left .leaflet-control {
        margin-left: 10px !important;
    }

    .sidebar-collapsed-map .leaflet-left .leaflet-control {
        margin-left: 10px !important;
    }

    .leaflet-control-zoom {
        margin-top: 10px !important;
    }

    .leaflet-bar a {
        width: 36px !important;
        height: 36px !important;
        line-height: 36px !important;
        font-size: 18px !important;
    }

    .map-toolbar,
    .map-toolbar.leaflet-control {
        position: fixed !important;
        bottom: 28px !important;
        left: 0 !important;
        right: 0 !important;
        top: auto !important;
        width: 100% !important;
        flex-direction: row;
        justify-content: space-around;
        border-radius: 0;
        border-top: 2px solid var(--accent-color);
        border-left: none;
        border-right: none;
        border-bottom: none;
        margin: 0 !important;
        padding: 6px 8px;
        padding-bottom: calc(6px + env(safe-area-inset-bottom, 0px));
        z-index: 1500;
        min-width: unset;
        background: rgba(255, 255, 255, 0.98);
        box-sizing: border-box;
    }

    .tool-label {
        display: none;
    }

    .toolbar-sep {
        display: none;
    }

    .tool-btn {
        justify-content: center;
        padding: 10px;
        width: auto;
        flex: 0 0 auto;
    }

    .tool-btn i {
        font-size: 18px;
    }

    .tool-info {
        max-width: calc(100% - 20px);
        margin: 0 10px 60px 10px !important;
        font-size: 12px;
    }

    .main-footer {
        height: 28px;
        padding: 0 10px;
    }

    .footer-left p {
        font-size: 0.6rem;
    }

    .footer-crs {
        font-size: 0.55rem;
    }

    .footer-btn {
        padding: 2px 8px;
        font-size: 0.65rem;
    }

    .footer-toggle-btn {
        display: none;
    }

    .coords-bar {
        bottom: 122px;
        font-size: 0.62rem;
        padding: 3px 10px;
        gap: 8px;
    }

    .gm-scale {
        margin-bottom: 8px !important;
        font-size: 10px;
        padding: 4px 8px 6px;
    }

    .gm-compass svg,
    .gm-compass img {
        width: 28px !important;
        height: 28px !important;
    }

    .modal-content {
        padding: 24px 18px;
        max-width: 95%;
        max-height: 85vh;
        overflow-y: auto;
        border-radius: 14px;
    }

    .modal-content h2 {
        font-size: 1.15rem;
    }

    .modal-tools-grid {
        grid-template-columns: 1fr;
    }

    .modal-section {
        padding: 10px 12px;
    }

    .modal-close {
        top: 10px;
        right: 14px;
        font-size: 1.5rem;
    }

    .elevation-panel {
        bottom: 54px;
        right: 10px;
        left: 10px;
        width: auto;
        height: 170px;
        border-radius: 12px;
        padding: 10px;
    }

    .elevation-header {
        font-size: 0.8rem;
        margin-bottom: 6px;
    }

    .export-chart-btn {
        padding: 3px 8px;
        font-size: 0.68rem;
    }

    .context-menu {
        min-width: 180px;
    }

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

    .custom-popup .leaflet-popup-content {
        margin: 10px;
        font-size: 12px;
    }

    .reveal-btn {
        width: 36px;
        height: 18px;
        font-size: 9px;
    }

    .splash-screen img {
        max-height: 60px;
    }

    .splash-progress-wrapper {
        width: 280px;
    }
}

@media (max-width: 480px) {
    .main-header {
        height: 44px;
        padding: 0 40px 0 8px;
        gap: 8px;
    }

    .header-logo-link img {
        height: 26px;
        padding: 2px 3px;
    }

    .header-logos {
        gap: 6px;
    }

    .header-logo-sep {
        display: none;
    }

    .header-title {
        font-size: 0.78rem;
    }

    .header-subtitle {
        display: none;
    }

    .header-info {
        position: static;
        transform: none;
    }

    .header-toggle-btn {
        right: 6px;
        width: 28px;
        height: 28px;
    }

    .main-footer {
        height: 24px;
        padding: 0 6px;
    }

    .footer-left p {
        font-size: 0.55rem;
    }

    .footer-crs {
        display: none;
    }

    .map-toolbar,
    .map-toolbar.leaflet-control {
        bottom: 24px !important;
    }

    .sidebar-toggle {
        bottom: 86px;
    }

    .coords-bar {
        bottom: 126px;
        font-size: 0.58rem;
        padding: 2px 8px;
        gap: 6px;
    }

    .zoom-display {
        display: none;
    }

    .tool-btn i {
        font-size: 15px;
    }

    .tool-btn {
        padding: 8px 6px;
    }
}

.sidebar-search {
    padding: 10px 12px 4px;
}

.search-input-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    border: 2px solid var(--accent-color);
    border-radius: var(--radius-md);
    padding: 9px 12px;
    box-shadow: 0 4px 12px rgba(30, 107, 69, 0.15);
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

.search-input-wrapper:focus-within {
    box-shadow: 0 6px 16px rgba(30, 107, 69, 0.25);
    transform: translateY(-1px);
    border-color: var(--accent-hover);
}

.search-input-wrapper i {
    color: var(--accent-color);
    font-size: 14px;
    flex-shrink: 0;
}

.search-input-wrapper input {
    flex: 1;
    border: none;
    background: transparent;
    outline: none;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text-main);
    font-weight: 500;
}

.search-input-wrapper input::placeholder {
    color: var(--text-muted);
    font-weight: 400;
}

.search-results {
    margin-top: 4px;
}

.search-result-item {
    padding: 6px 10px;
    font-size: 0.83rem;
    color: var(--text-main);
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: background var(--t-fast);
}

.search-result-item:hover {
    background: var(--accent-pale);
    color: var(--accent-color);
}

.terrasse-popup-wrap .leaflet-popup-content-wrapper {
    background: var(--bg-dark);
    border: 1px solid rgba(78, 200, 120, 0.25);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-premium);
    padding: 0;
}

.terrasse-popup-wrap .leaflet-popup-content {
    margin: 0;
}

.terrasse-popup-wrap .leaflet-popup-tip-container {
    display: none;
}

.terrasse-popup {
    padding: 12px 14px;
    min-width: 160px;
}

.terrasse-popup-title {
    font-family: var(--font-heading);
    font-weight: 600;
    color: var(--accent-light);
    margin-bottom: 8px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.terrasse-popup-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.82rem;
    padding: 3px 0;
    color: rgba(255, 255, 255, 0.8);
}

.terrasse-popup-row span {
    color: rgba(255, 255, 255, 0.55);
}

.terrasse-popup-row b {
    color: #fff;
}

.terrasse-popup-wrap .leaflet-popup-close-button {
    color: rgba(255, 255, 255, 0.5) !important;
    top: 6px !important;
    right: 8px !important;
}

.gm-scale-ratio {
    display: block;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.55);
    text-align: center;
    margin-top: 2px;
}

.compare-divider {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 3px;
    background: rgba(255, 255, 255, 0.9);
    cursor: ew-resize;
    z-index: 800;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.4);
    transform: translateX(-50%);
}

.compare-handle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    color: var(--accent-color);
    font-size: 12px;
}

.tool-btn.compare-active {
    background: var(--accent-color);
    color: #fff;
}

.compare-toggle-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px 8px;
    border-bottom: 1px solid var(--border-color);
}

/* Compare panel : reveal animé */
#compare-sidebar-panel {
    display: block;
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    padding: 0 12px !important;
    pointer-events: none;
    background: var(--bg-section);
    border-bottom: 1px solid var(--border-color);
    transition:
        max-height var(--t-slow) var(--ease-expo),
        opacity var(--t-std) var(--ease-std),
        padding var(--t-std) var(--ease-std);
}

#compare-sidebar-panel.open {
    max-height: 620px;
    opacity: 1;
    padding: 4px 12px 10px !important;
    pointer-events: auto;
}

#sidebar-page-1.compare-mode .sidebar-search,
#sidebar-page-1.compare-mode .control-group {
    display: none;
}

.cmp-sb-table {
    width: 100%;
    border-collapse: collapse;
}

.cmp-sb-table th {
    padding: 6px 4px 4px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-align: center;
}

.cmp-th-left {
    color: #1a6fa0;
}

.cmp-th-right {
    color: #b36020;
}

.cmp-sb-table td {
    padding: 4px 4px;
    border-bottom: 1px solid var(--border-color);
    font-size: 12px;
    color: #2d3a30;
}

.cmp-td-name {
    text-align: left;
}

.cmp-td-check {
    text-align: center;
}

.cmp-td-check input[type="radio"],
.cmp-td-check input[type="checkbox"] {
    width: 15px;
    height: 15px;
    cursor: pointer;
    accent-color: var(--accent-color);
}

.cmp-section-row td {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: #6b8c7a;
    padding: 8px 4px 3px;
    border-bottom: none;
    background: none;
}

.cmp-row-inactive td {
    opacity: 0.45;
}

.cmp-row-inactive .cmp-td-name::after {
    content: ' (inactif)';
    font-size: 10px;
    color: #9ab;
}

.floating-legend {
    background: rgba(10, 24, 15, 0.82);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(78, 200, 120, 0.2);
    border-radius: var(--radius-md);
    padding: 8px 12px;
    min-width: 130px;
    pointer-events: auto;
    margin-bottom: 32px !important;
}

.floating-legend-title {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent-light);
    margin-bottom: 6px;
}

.floating-legend-item {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 11.5px;
    color: rgba(255, 255, 255, 0.85);
    padding: 2px 0;
}

.floating-legend-sym {
    width: 16px;
    height: 10px;
    border-radius: 2px;
    flex-shrink: 0;
}

.floating-legend-empty {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
    font-style: italic;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideFromLeft {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes revealScale {
    from {
        opacity: 0;
        transform: scale(0.96) translateY(8px);
        filter: blur(4px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
        filter: blur(0);
    }
}

@keyframes shimmerPass {
    from {
        transform: translateX(-100%);
    }

    to {
        transform: translateX(350%);
    }
}

@keyframes glowPulse {

    0%,
    100% {
        box-shadow: 0 2px 8px rgba(30, 107, 69, 0.28);
    }

    50% {
        box-shadow: 0 4px 22px rgba(30, 107, 69, 0.55);
    }
}

@keyframes microConfirm {
    0% {
        transform: scale(1);
    }

    35% {
        transform: scale(1.06);
    }

    100% {
        transform: scale(1);
    }
}

.splash-logos img:nth-child(1) {
    animation: revealScale var(--t-slow) calc(var(--stagger) * 2) var(--ease-expo) both;
}

.splash-logos img:nth-child(3) {
    animation: revealScale var(--t-slow) calc(var(--stagger) * 4) var(--ease-expo) both;
}

.splash-logos img:nth-child(5) {
    animation: revealScale var(--t-slow) calc(var(--stagger) * 6) var(--ease-expo) both;
}

.splash-logo-sep {
    animation: fadeIn var(--t-fast) calc(var(--stagger) * 3) var(--ease-expo) both;
}

.splash-title {
    animation: fadeUp var(--t-slow) calc(var(--stagger) * 9) var(--ease-expo) both;
}

.splash-cc {
    animation: fadeUp var(--t-std) calc(var(--stagger) * 11) var(--ease-quart) both;
}

.splash-progress-wrapper {
    animation: fadeUp var(--t-std) calc(var(--stagger) * 13) var(--ease-quart) both;
}

.splash-progress-fill {
    position: relative;
    overflow: hidden;
}

.splash-progress-fill::after {
    content: '';
    position: absolute;
    inset: 0;
    width: 38%;
    background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.35) 50%, transparent 100%);
    animation: shimmerPass 2s ease-in-out infinite;
    pointer-events: none;
}

.sidebar-page.active .control-group {
    animation: fadeUp var(--t-std) var(--ease-expo) both;
}

.sidebar-page.active .control-group:nth-child(1) {
    animation-delay: calc(var(--stagger) * 0);
}

.sidebar-page.active .control-group:nth-child(2) {
    animation-delay: calc(var(--stagger) * 1);
}

.sidebar-page.active .control-group:nth-child(3) {
    animation-delay: calc(var(--stagger) * 2);
}

.sidebar-page.active .control-group:nth-child(4) {
    animation-delay: calc(var(--stagger) * 3);
}

.sidebar-page.active .control-group:nth-child(5) {
    animation-delay: calc(var(--stagger) * 4);
}

.layer-order-row {
    animation: slideFromLeft var(--t-std) var(--ease-expo) both;
}

.layer-order-row:nth-child(1) {
    animation-delay: calc(var(--stagger) * 0);
}

.layer-order-row:nth-child(2) {
    animation-delay: calc(var(--stagger) * 1);
}

.layer-order-row:nth-child(3) {
    animation-delay: calc(var(--stagger) * 2);
}

.layer-order-row:nth-child(4) {
    animation-delay: calc(var(--stagger) * 3);
}

.layer-order-row:nth-child(5) {
    animation-delay: calc(var(--stagger) * 4);
}

.layer-order-row:nth-child(6) {
    animation-delay: calc(var(--stagger) * 5);
}

.layer-block {
    transition:
        background var(--t-fast) var(--ease-std),
        transform var(--t-std) var(--ease-quart);
}

.layer-block:hover {
    background: rgba(30, 107, 69, 0.035);
    transform: translateX(3px);
}

.control-group {
    transition:
        box-shadow var(--t-fast) var(--ease-std),
        transform var(--t-std) var(--ease-quart);
}

.control-group:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.sidebar-header {
    position: relative;
    overflow: hidden;
}

.sidebar-header::after {
    content: '';
    position: absolute;
    inset: 0;
    width: 48%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.09), transparent);
    transform: translateX(-220%);
    transition: transform 0.65s var(--ease-quart);
    pointer-events: none;
}

.sidebar:hover .sidebar-header::after {
    transform: translateX(310%);
}

input:checked+.slider {
    animation: microConfirm var(--t-fast) var(--ease-spring);
}

.basemap-radio-item input[type="radio"]:checked+.basemap-radio-inner {
    animation: microConfirm var(--t-fast) var(--ease-spring);
}

.tool-btn.active {
    animation: glowPulse 3s ease-in-out infinite;
}

.leaflet-bar a {
    transition:
        background-color var(--t-micro) var(--ease-std),
        color var(--t-micro) var(--ease-std),
        transform var(--t-fast) var(--ease-spring),
        box-shadow var(--t-fast) var(--ease-std) !important;
}

.leaflet-bar a:hover {
    background-color: rgba(240, 247, 243, 0.98) !important;
    color: var(--accent-color) !important;
    transform: scale(1.08) !important;
    box-shadow: 0 2px 12px rgba(30, 107, 69, 0.20) !important;
}

.leaflet-bar a:active {
    background-color: var(--accent-pale) !important;
    color: var(--accent-color) !important;
    transform: scale(0.91) !important;
    transition-duration: 60ms !important;
}

.modal-overlay {
    transition: opacity var(--t-std) var(--ease-std), visibility var(--t-std);
}

.modal-content {
    transform: scale(0.97) translateY(14px);
    transition: transform var(--t-slow) var(--ease-expo);
}

.modal-overlay.active .modal-content {
    transform: scale(1) translateY(0);
}

.modal-overlay.active .modal-section {
    animation: fadeUp var(--t-std) var(--ease-expo) both;
}

.modal-overlay.active .modal-section:nth-child(1) {
    animation-delay: 0.10s;
}

.modal-overlay.active .modal-section:nth-child(2) {
    animation-delay: 0.17s;
}

.modal-overlay.active .modal-section:nth-child(3) {
    animation-delay: 0.24s;
}

.modal-overlay.active .modal-section:nth-child(4) {
    animation-delay: 0.31s;
}

.modal-overlay.active .modal-section:nth-child(5) {
    animation-delay: 0.38s;
}

.elevation-panel.active {
    animation: revealScale var(--t-slow) var(--ease-expo) both;
}

@keyframes coordsReveal {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.coords-bar {
    animation: coordsReveal var(--t-slow) 0.5s var(--ease-expo) both;
}

.tool-info {
    animation: fadeUp var(--t-std) var(--ease-expo);
}

.mouse-tooltip {
    animation: fadeIn var(--t-micro) var(--ease-quart) both;
}

.context-menu-item {
    opacity: 0;
    animation: slideFromLeft var(--t-fast) var(--ease-expo) forwards;
}

.context-menu-item:nth-child(1) {
    animation-delay: calc(var(--stagger) * 0.5 * 0);
}

.context-menu-item:nth-child(2) {
    animation-delay: calc(var(--stagger) * 0.5 * 1);
}

.context-menu-item:nth-child(3) {
    animation-delay: calc(var(--stagger) * 0.5 * 2);
}

.context-menu-item:nth-child(4) {
    animation-delay: calc(var(--stagger) * 0.5 * 3);
}

.context-menu-item:nth-child(5) {
    animation-delay: calc(var(--stagger) * 0.5 * 4);
}

.context-menu-item:nth-child(6) {
    animation-delay: calc(var(--stagger) * 0.5 * 5);
}

.footer-btn i {
    transition: transform var(--t-fast) var(--ease-spring);
}

.footer-btn:hover i {
    transform: rotate(14deg) scale(1.12);
}

.header-logo-link img {
    transition:
        transform var(--t-std) cubic-bezier(0.175, 0.885, 0.32, 1.275),
        box-shadow var(--t-fast) var(--ease-std);
}

.header-logo-link:hover img {
    transform: translateY(-2px) scale(1.06);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28);
}

/* ============================================================
   ENHANCED ANIMATIONS — Pro & Modern
   ============================================================ */

/* ── Toggle switch : spring physics ── */
.slider {
    transition:
        background-color var(--t-std) var(--ease-std),
        box-shadow var(--t-fast) var(--ease-std);
}

.slider:before {
    transition:
        transform var(--t-std) var(--ease-spring),
        box-shadow var(--t-fast) var(--ease-std),
        background var(--t-fast);
    will-change: transform;
}

input:checked+.slider {
    box-shadow: 0 0 0 3px var(--glow-color);
}

input:checked+.slider:before {
    box-shadow: 0 2px 6px rgba(30, 107, 69, 0.35);
}

.switch:hover .slider:before {
    box-shadow: 0 0 0 5px rgba(30, 107, 69, 0.12);
}

/* ── Compare divider : états hover et drag ── */
.compare-divider {
    transition:
        background var(--t-fast) var(--ease-std),
        box-shadow var(--t-fast) var(--ease-std),
        width var(--t-fast) var(--ease-std);
    will-change: left;
}

.compare-divider:hover,
.compare-divider.dragging {
    width: 4px;
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.18), 0 0 28px rgba(255, 255, 255, 0.45), 0 0 60px rgba(30, 107, 69, 0.25);
}

.compare-handle {
    transition:
        transform var(--t-fast) var(--ease-spring),
        box-shadow var(--t-fast) var(--ease-std);
    will-change: transform;
}

.compare-divider:hover .compare-handle,
.compare-divider.dragging .compare-handle {
    transform: translate(-50%, -50%) scale(1.18);
    box-shadow: 0 6px 22px rgba(0, 0, 0, 0.45);
}

.compare-divider.dragging .compare-handle {
    transform: translate(-50%, -50%) scale(1.28);
    background: #ffffff;
    color: var(--accent-hover);
}

/* ── Compare table rows : entrée en stagger ── */
#compare-sidebar-panel.open .cmp-sb-table tbody tr {
    animation: fadeUp var(--t-fast) var(--ease-expo) both;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(1) {
    animation-delay: 40ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(2) {
    animation-delay: 60ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(3) {
    animation-delay: 80ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(4) {
    animation-delay: 100ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(5) {
    animation-delay: 120ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(6) {
    animation-delay: 140ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(7) {
    animation-delay: 160ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(8) {
    animation-delay: 180ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(9) {
    animation-delay: 200ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(10) {
    animation-delay: 220ms;
}

#compare-sidebar-panel.open .cmp-sb-table tbody tr:nth-child(11) {
    animation-delay: 240ms;
}

/* ── Layer blocks : glow accent au hover ── */
.layer-block {
    border-radius: var(--radius-sm);
    transition:
        background var(--t-fast) var(--ease-std),
        box-shadow var(--t-fast) var(--ease-std),
        transform var(--t-std) var(--ease-quart);
}

.layer-block:hover {
    background: rgba(30, 107, 69, 0.05);
    box-shadow: inset 3px 0 0 var(--accent-light);
    transform: translateX(3px);
}

.layer-block:hover .control-label {
    color: var(--accent-color);
    transition: color var(--t-fast) var(--ease-std);
}

/* ── Checkbox item : feedback tactile ── */
.checkbox-item .switch {
    transition: transform var(--t-fast) var(--ease-spring);
}

.checkbox-item:hover .switch {
    transform: scale(1.08);
}

/* ── Tool buttons : icône animée ── */
.tool-btn {
    transition:
        background var(--t-fast) var(--ease-std),
        color var(--t-fast) var(--ease-std),
        border-color var(--t-fast) var(--ease-std),
        box-shadow var(--t-fast) var(--ease-std),
        transform var(--t-std) var(--ease-spring);
    will-change: transform;
}

.tool-btn:hover {
    transform: translateY(-2px);
}

.tool-btn:active {
    transform: translateY(0) scale(0.94);
    transition-duration: 60ms;
}

.tool-btn i {
    transition: transform var(--t-std) var(--ease-spring);
}

.tool-btn:hover i {
    transform: scale(1.2) rotate(-6deg);
}

.tool-btn.active i {
    transform: scale(1.1);
}

/* ── Sidebar toggle ── */
.sidebar-toggle {
    transition:
        left var(--t-slow) var(--ease-expo),
        background var(--t-fast) var(--ease-std),
        color var(--t-fast) var(--ease-std),
        transform var(--t-std) var(--ease-spring),
        box-shadow var(--t-fast) var(--ease-std);
}

.sidebar-toggle:hover {
    transform: scale(1.12);
}

.sidebar-toggle:active {
    transform: scale(0.93);
    transition-duration: 60ms;
}

/* ── Sidebar : entrée avec ombre et glassmorphism ── */
.sidebar {
    transition:
        transform var(--t-slow) var(--ease-expo),
        box-shadow var(--t-std) var(--ease-std);
    will-change: transform;
}

/* ── Section headers : underline slide ── */
.control-group h2 {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.control-group h2::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-light);
    border-radius: 2px;
    transition: width var(--t-std) var(--ease-expo);
}

.control-group:hover h2::after {
    width: 100%;
}

/* ── Search input focus ring ── */
.sidebar-search .search-input-wrapper {
    transition:
        border-color var(--t-fast) var(--ease-std),
        box-shadow var(--t-fast) var(--ease-std);
    border-radius: var(--radius-sm);
}

.sidebar-search .search-input-wrapper:focus-within {
    border-color: var(--accent-light);
    box-shadow: 0 0 0 3px var(--glow-color);
}

.sidebar-search input {
    transition: color var(--t-fast);
}

/* ── Search results : stagger ── */
.search-result-item {
    animation: fadeUp var(--t-fast) var(--ease-expo) both;
}

/* ── Basemap radio select : ripple ── */
.basemap-radio-item {
    transition:
        background var(--t-fast) var(--ease-std),
        border-color var(--t-fast) var(--ease-std),
        transform var(--t-std) var(--ease-spring),
        box-shadow var(--t-fast) var(--ease-std);
    will-change: transform;
}

.basemap-radio-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}

.basemap-radio-item:active {
    transform: scale(0.96);
    transition-duration: 60ms;
}

/* ── Floating legend : entrée + items ── */
.floating-legend {
    animation: revealScale var(--t-std) var(--ease-expo) both;
    transition: opacity var(--t-fast) var(--ease-std);
}

.floating-legend-item {
    animation: fadeUp var(--t-fast) var(--ease-expo) both;
}

.floating-legend-item:nth-child(1) {
    animation-delay: 0ms;
}

.floating-legend-item:nth-child(2) {
    animation-delay: 30ms;
}

.floating-legend-item:nth-child(3) {
    animation-delay: 60ms;
}

.floating-legend-item:nth-child(4) {
    animation-delay: 90ms;
}

.floating-legend-item:nth-child(5) {
    animation-delay: 120ms;
}

.floating-legend-item:nth-child(6) {
    animation-delay: 150ms;
}

.floating-legend-item:nth-child(7) {
    animation-delay: 180ms;
}

/* ── Clusters : entrée en bounce ── */
.arcgis-cluster-dot {
    animation: clusterPop var(--t-std) var(--ease-spring) both;
}

@keyframes clusterPop {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ── Leaflet popups ── */
.leaflet-popup-content-wrapper {
    animation: revealScale var(--t-std) var(--ease-expo) both;
    transition:
        box-shadow var(--t-fast) var(--ease-std),
        transform var(--t-fast) var(--ease-std);
}

/* ── Leaflet zoom/attribution ── */
.leaflet-control-zoom {
    animation: fadeUp var(--t-slow) 0.3s var(--ease-expo) both;
}

/* ── Barre d'outils ── */
.leaflet-top .leaflet-control:first-child {
    animation: slideFromLeft var(--t-slow) 0.15s var(--ease-expo) both;
}

/* ── Layer order drag row ── */
.layer-order-row {
    transition:
        background var(--t-fast) var(--ease-std),
        border-color var(--t-fast) var(--ease-std),
        box-shadow var(--t-fast) var(--ease-std),
        transform var(--t-fast) var(--ease-spring),
        opacity var(--t-fast) var(--ease-std);
}

.layer-order-row:hover {
    transform: translateX(3px);
}

.layer-order-row.dragging-over {
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(30, 107, 69, 0.18);
    border-color: var(--accent-light);
}

/* ── Color pen btn : rotation ── */
.color-pen-btn {
    transition: background var(--t-fast), color var(--t-fast), transform var(--t-std) var(--ease-spring);
}

.color-pen-btn:hover {
    transform: scale(1.15) rotate(-15deg);
}

/* ── Opacity slider thumb ── */
.opacity-slider {
    transition: opacity var(--t-fast);
}

.opacity-slider::-webkit-slider-thumb {
    transition:
        transform var(--t-std) var(--ease-spring),
        box-shadow var(--t-fast) var(--ease-std);
    will-change: transform;
}

.opacity-slider:hover::-webkit-slider-thumb,
.opacity-slider:active::-webkit-slider-thumb {
    transform: scale(1.35);
    box-shadow: 0 0 0 5px var(--glow-color);
}

/* ── Scrollbar plus fine et colorée ── */
::-webkit-scrollbar {
    width: 4px;
    height: 4px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
    transition: background var(--t-fast);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-light);
}

/* ── Keyframes supplémentaires ── */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(100%);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes popIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ── will-change sur les éléments animés fréquemment ── */
.sidebar,
.sidebar-toggle,
.compare-divider,
.compare-handle,
.tool-btn,
.modal-content,
.elevation-panel {
    will-change: transform;
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ═══════════════════════════════════════════════════
   DARK MODE
   ═══════════════════════════════════════════════════ */
[data-theme="dark"] {
    --bg-sidebar: #030504;
    --bg-panel: #080a08;
    --text-main: #d8e2d4;
    --text-sub: #aabda1;
    --text-muted: #697a6e;
    --border-color: #141915;
    --accent-pale: #040a06;
    --bg-section: #020302;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.85);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.95);
    --shadow-premium: 0 8px 32px rgba(0, 0, 0, 0.95);
    --glow-color: rgba(77, 184, 122, 0.15);
}

[data-theme="dark"] body,
[data-theme="dark"] html {
    background: #000000;
    color: var(--text-main);
}

[data-theme="dark"] .sidebar {
    background: #0d110d;
    border-color: var(--border-color);
    box-shadow: 2px 0 32px rgba(0, 0, 0, 0.70);
}

[data-theme="dark"] .sidebar-tabs {
    background: #080b08;
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .sidebar-tab {
    color: var(--text-muted);
}

[data-theme="dark"] .sidebar-tab.active {
    color: var(--accent-light);
    border-bottom-color: var(--accent-light);
}

[data-theme="dark"] .control-group {
    background: #0a0e0a;
    border-color: var(--border-color);
}

[data-theme="dark"] .control-group h2 {
    color: var(--text-muted);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .layer-block {
    border-color: var(--border-color);
    background: #0e1410;
}

[data-theme="dark"] .layer-block:hover {
    background: #121c14;
    border-color: #2a4032;
}

[data-theme="dark"] .control-label {
    color: var(--text-main);
}

[data-theme="dark"] .search-input-wrapper {
    background: #0b0f0b;
    border-color: var(--border-color);
}

[data-theme="dark"] .search-input-wrapper input {
    background: transparent;
    color: var(--text-main);
}

[data-theme="dark"] .search-input-wrapper input::placeholder {
    color: var(--text-muted);
}

[data-theme="dark"] .search-results {
    background: #0c110c;
    border-color: var(--border-color);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.75);
}

[data-theme="dark"] .search-result-item:hover {
    background: #111911;
}

[data-theme="dark"] .basemap-radio-inner {
    background: #0e1410;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .basemap-radio-item input:checked+.basemap-radio-inner {
    background: var(--accent-pale);
    border-color: var(--accent-color);
    color: var(--accent-light);
}

[data-theme="dark"] .compare-toggle-wrap {
    color: var(--text-main);
}

[data-theme="dark"] #compare-sidebar-panel {
    background: #0e1410;
    border-color: var(--border-color);
}

[data-theme="dark"] .compare-select {
    background: #0b0f0b;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .modal-overlay {
    background: rgba(0, 0, 0, 0.80);
}

[data-theme="dark"] .modal-content {
    background: #0d110d;
    border-color: rgba(30, 107, 69, 0.25);
    box-shadow: 0 24px 72px rgba(0, 0, 0, 0.90);
    color: var(--text-main);
}

[data-theme="dark"] .modal-content h2 {
    color: var(--accent-light);
}

[data-theme="dark"] .modal-content p {
    color: var(--text-main);
}

[data-theme="dark"] .modal-close {
    color: var(--text-muted);
}

[data-theme="dark"] .modal-close:hover {
    color: #e0e0e0;
}

[data-theme="dark"] .modal-section {
    background: #080c08;
    border-left-color: var(--accent-color);
}

[data-theme="dark"] .modal-section-title {
    color: var(--accent-light);
}

[data-theme="dark"] .modal-section-text {
    color: var(--text-main);
}

[data-theme="dark"] .modal-tool {
    background: #0b0f0b;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .modal-tool i {
    color: var(--accent-light);
}

[data-theme="dark"] .map-toolbar {
    background: rgba(5, 7, 5, 0.97) !important;
    border-color: #192219 !important;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.80) !important;
}

[data-theme="dark"] .tool-btn {
    color: var(--text-muted);
}

[data-theme="dark"] .tool-btn i {
    color: #4db87a;
}

[data-theme="dark"] .tool-btn:hover {
    background: #101810;
    border-color: #2a3f2a;
    color: var(--text-main);
}

[data-theme="dark"] .tool-btn:hover i {
    color: #6dd49a;
}

[data-theme="dark"] .tool-btn.active {
    background: #0a1a0e;
    border-color: var(--accent-color);
}

[data-theme="dark"] .tool-btn.active i {
    color: var(--accent-light);
}

[data-theme="dark"] .toolbar-sep {
    background: #1a211a;
}

[data-theme="dark"] .elevation-panel {
    background: #0c110c;
    border-color: var(--border-color);
    color: var(--text-main);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.70);
}

[data-theme="dark"] .elevation-header {
    background: #080b08;
    border-bottom-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .coords-bar {
    background: rgba(3, 5, 3, 0.95);
    border-color: var(--border-color);
    color: var(--text-muted);
}

[data-theme="dark"] .sidebar-toggle {
    background: #0d110d;
    border-color: var(--border-color);
    color: var(--text-muted);
}

[data-theme="dark"] .sidebar-toggle:hover {
    color: var(--text-main);
    background: #111811;
}

[data-theme="dark"] .leaflet-bar a {
    background: #0c110c;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .leaflet-bar a:hover {
    background: #111811;
    color: var(--accent-light);
}

[data-theme="dark"] .leaflet-popup-content-wrapper,
[data-theme="dark"] .leaflet-popup-tip {
    background: #0d110d;
    color: var(--text-main);
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.75);
}

[data-theme="dark"] ::-webkit-scrollbar-track {
    background: #070a07;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: #1e2820;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}

[data-theme="dark"] .modal-tool kbd,
[data-theme="dark"] .modal-section-hint kbd {
    background: #080c08;
    border-color: #1a241a;
    border-bottom-color: #222e22;
    color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════
   PRINT MODAL
   ═══════════════════════════════════════════════════ */
.print-modal-content {
    max-width: 460px;
}

.print-form {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 20px;
}

.print-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-top: 6px;
}

.print-input {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text-main);
    background: var(--bg-section);
    transition: border-color var(--t-fast), box-shadow var(--t-fast);
}

.print-input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px var(--glow-color);
}

.print-orientation {
    display: flex;
    gap: 10px;
    margin-top: 4px;
}

.print-orient-opt {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 12px;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 0.88rem;
    color: var(--text-main);
    background: var(--bg-section);
    transition: border-color var(--t-fast), background var(--t-fast), color var(--t-fast);
}

.print-orient-opt input {
    display: none;
}

.print-orient-opt:has(input:checked) {
    border-color: var(--accent-color);
    background: var(--accent-pale);
    color: var(--accent-color);
    font-weight: 600;
}

.print-orient-opt i {
    font-size: 0.95rem;
}

.print-btn {
    width: 100%;
    padding: 11px 16px;
    background: var(--accent-color);
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background var(--t-fast), transform var(--t-fast) var(--ease-spring), box-shadow var(--t-fast);
}

.print-btn:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(30, 107, 69, 0.3);
}

.print-btn:active {
    transform: scale(0.98);
}

[data-theme="dark"] .print-input {
    background: #0a0e0a;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .print-orient-opt {
    background: #0a0e0a;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .print-orient-opt:has(input:checked) {
    background: var(--accent-pale);
    border-color: var(--accent-color);
    color: var(--accent-light);
}

/* ── Print theme swatches ── */
.print-themes {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 2px;
}

.print-theme-opt {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 6px 11px 6px 8px;
    border: 1.5px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.8rem;
    color: var(--text-sub);
    background: var(--bg-panel);
    transition: border-color 0.15s, background 0.15s, color 0.15s;
    user-select: none;
}

.print-theme-opt input {
    display: none;
}

.print-theme-opt:has(input:checked) {
    border-color: var(--accent-color);
    background: var(--accent-pale);
    color: var(--accent-light);
    font-weight: 600;
}

.pt-swatch {
    display: inline-block;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 1.5px solid rgba(0, 0, 0, 0.18);
    flex-shrink: 0;
}

/* ── Print option checkboxes ── */
.print-opts-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin-top: 2px;
}

.print-opt-chk {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 6px 10px;
    border: 1.5px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.8rem;
    color: var(--text-sub);
    background: var(--bg-panel);
    transition: border-color 0.15s, background 0.15s, color 0.15s;
    user-select: none;
}

.print-opt-chk input {
    display: none;
}

.print-opt-chk:has(input:checked) {
    border-color: var(--accent-color);
    background: var(--accent-pale);
    color: var(--accent-light);
    font-weight: 600;
}

.print-opt-chk i {
    font-size: 0.8rem;
    opacity: 0.7;
}

[data-theme="dark"] .print-theme-opt {
    background: #0d1f16;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .print-theme-opt:has(input:checked) {
    background: var(--accent-pale);
    border-color: var(--accent-color);
    color: var(--accent-light);
}

[data-theme="dark"] .print-opt-chk {
    background: #0d1f16;
    border-color: var(--border-color);
    color: var(--text-main);
}

[data-theme="dark"] .print-opt-chk:has(input:checked) {
    background: var(--accent-pale);
    border-color: var(--accent-color);
    color: var(--accent-light);
}

/* ═══════════════════════════════════════════════════
   INFO MODAL — wider + smaller font
   ═══════════════════════════════════════════════════ */
.info-modal {
    max-width: 900px;
    padding: 28px 32px;
    font-size: 0.82rem;
}

.info-modal h2 {
    font-size: 1.15rem;
    margin-bottom: 10px;
}

.info-modal>p {
    font-size: 0.82rem;
    margin-bottom: 8px;
}

.info-modal .modal-section {
    padding: 10px 14px;
    margin-bottom: 8px;
}

.info-modal .modal-section-title {
    font-size: 0.78rem;
}

.info-modal .modal-section-text {
    font-size: 0.80rem;
}

.info-modal .modal-section-hint {
    font-size: 0.72rem;
    text-align: left;
}

.info-modal .modal-tools-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 5px;
}

.info-modal .modal-tool {
    font-size: 0.78rem;
    padding: 5px 8px;
}

.info-modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 16px;
    align-items: start;
}

.info-modal .modal-cluster-list li {
    font-size: 0.80rem;
}

.info-modal .modal-cluster-list {
    margin-top: 6px;
}