@keyframes mmoc-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.mmoc-wrap,
.mmoc-wrap * {
    box-sizing: border-box;
}

.mmoc-wrap {
    --mmoc-bg: #ffffff;
    --mmoc-bg-soft: #f8fafc;
    --mmoc-border: #e5e7eb;
    --mmoc-border-strong: #d1d5db;
    --mmoc-text: #111827;
    --mmoc-text-soft: #6b7280;
    --mmoc-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
    --mmoc-radius: 14px;
    --mmoc-asphalt: #9ca3af;
    --mmoc-orange: #FF9800;
    --mmoc-brown: #5D4037;
    --mmoc-green: #8BC34A;
    --mmoc-yellow: #FFEB3B;
    --mmoc-gray: #9CA3AF;
    --mmoc-cta: #ff4903;
    --mmoc-cta-hover: #e24000;
    --mmoc-upload-bg: none;
    max-width: 900px;
    margin: 0 auto;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--mmoc-text);
}

.mmoc-layout {
    display: grid;
    gap: 20px;
}

.mmoc-card {
    position: relative;
    background: var(--mmoc-bg);
    border: 1px solid var(--mmoc-border);
    border-radius: var(--mmoc-radius);
    box-shadow: var(--mmoc-shadow);
    overflow: hidden;
}

.mmoc-card__inner {
    padding: 24px;
}

.mmoc-upload-card {
    background:
        linear-gradient(135deg, rgba(7, 12, 23, 0.78), rgba(13, 28, 43, 0.68)),
        var(--mmoc-upload-bg) center center / cover no-repeat;
}

.mmoc-upload-card .mmoc-card__inner {
    padding: 32px 24px;
}

 .mmoc-upload-card .mmoc-heading,
.mmoc-upload-card .mmoc-subtitle,
.mmoc-upload-card .mmoc-label,
.mmoc-upload-card .mmoc-selected-file,
.mmoc-upload-card .mmoc-selected-file strong {
    color: #ffffff;
}

.mmoc-upload-card .mmoc-heading {
    color: var(--mmoc-cta);
}

.mmoc-upload-card .mmoc-subtitle,
.mmoc-upload-card .mmoc-selected-file {
    color: rgba(255,255,255,0.82);
}

.mmoc-wrap h1::before,
.mmoc-wrap h2::before,
.mmoc-wrap h3::before,
.mmoc-wrap h4::before,
.mmoc-wrap .mmoc-heading::before,
.mmoc-wrap .mmoc-heading::after {
    display: none !important;
    content: none !important;
}

.mmoc-heading {
    margin: 0;
    font-size: 24px;
    line-height: 1.2;
    font-weight: 600;
    color: var(--mmoc-text);
}

.mmoc-card__head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 18px;
}

.mmoc-subtitle {
    margin: 8px 0 0;
    font-size: 15px;
    line-height: 1.6;
    color: var(--mmoc-text-soft);
}

.mmoc-upload-grid {
    display: grid;
    gap: 18px;
}


.mmoc-file-input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.mmoc-dropzone {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 196px;
    padding: 28px;
    border: 1.5px dashed var(--mmoc-border-strong);
    border-radius: 14px;
    background: linear-gradient(180deg, #fcfdff 0%, #f8fafc 100%);
    text-align: center;
    transition: border-color .2s ease, background .2s ease, transform .2s ease, box-shadow .2s ease;
}

.mmoc-dropzone:hover,
.mmoc-dropzone.is-active {
    border-color: #94a3b8;
    background: linear-gradient(180deg, #ffffff 0%, #f6f9fc 100%);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.05);
}

.mmoc-dropzone__content {
    pointer-events: none;
    max-width: 460px;
}

.mmoc-dropzone__icon {
    width: 54px;
    height: 54px;
    margin: 0 auto 16px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    background: #eff6ff;
    color: #2563eb;
    box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.08);
    font-size: 24px;
    font-weight: 700;
}

.mmoc-dropzone__title {
    margin: 0;
    font-size: 22px;
    line-height: 1.25;
    font-weight: 600;
    color: var(--mmoc-text);
}

.mmoc-dropzone__text {
    margin: 10px 0 0;
    font-size: 15px;
    line-height: 1.6;
    color: var(--mmoc-text-soft);
}

.mmoc-dropzone__meta {
    margin-top: 16px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,0.9);
    border: 1px solid var(--mmoc-border);
    color: var(--mmoc-text-soft);
    font-size: 13px;
}

.mmoc-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
}

.mmoc-selected-file {
    min-height: 20px;
    font-size: 14px;
    color: var(--mmoc-text-soft);
}

.mmoc-selected-file strong {
    color: var(--mmoc-text);
    font-weight: 600;
}

.mmoc-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 12px 18px;
    border: 0;
    border-radius: 12px;
    background: var(--mmoc-cta);
    color: #fff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease, opacity .2s ease;
    box-shadow: 0 12px 28px rgba(255, 73, 3, 0.28);
}

.mmoc-button:hover {
    transform: translateY(-1px);
    background: var(--mmoc-cta-hover);
    box-shadow: 0 16px 32px rgba(255, 73, 3, 0.32);
}

.mmoc-button:disabled {
    opacity: .55;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.mmoc-map-shell {
    position: relative;
}

.mmoc-map-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 16px;
}

.mmoc-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border: 1px solid var(--mmoc-border);
    border-radius: 999px;
    background: #fff;
    color: var(--mmoc-text-soft);
    font-size: 13px;
    line-height: 1.4;
}

.mmoc-chip__dot {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: #cbd5e1;
}

.mmoc-map-card .mmoc-card__inner {
    padding-bottom: 18px;
}

.mmoc-map {
    height: 420px;
    width: 100%;
    border-radius: 14px;
    border: 1px solid var(--mmoc-border);
    overflow: hidden;
    z-index: 1;
    background: #f8fafc;
}

.mmoc-map-loading {
    position: absolute;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(3px);
    border-radius: 14px;
    z-index: 400;
}

.mmoc-map-loading.is-visible {
    display: flex;
}

.mmoc-loading-card {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border: 1px solid rgba(209, 213, 219, 0.9);
    border-radius: 14px;
    background: rgba(255,255,255,0.92);
    color: #0f172a;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.12);
}

.mmoc-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 3px solid #dbeafe;
    border-top-color: #2563eb;
    border-radius: 50%;
    animation: mmoc-spin 0.8s linear infinite;
    flex: 0 0 18px;
}

.mmoc-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 18px;
}

.mmoc-legend-item {
    --mmoc-legend-accent: #cbd5e1;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 11px 15px;
    background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(248,250,252,0.96) 100%);
    border: 1px solid rgba(203, 213, 225, 0.95);
    border-radius: 999px;
    color: #475569;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}

.mmoc-legend-item:hover {
    transform: translateY(-1px);
    border-color: rgba(148, 163, 184, 0.8);
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.09);
}

.mmoc-legend-item::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--mmoc-legend-accent);
    box-shadow: 0 0 0 5px rgba(148, 163, 184, 0.16);
    flex: 0 0 8px;
}

.mmoc-legend-line {
    display: inline-block;
    width: 26px;
    height: 6px;
    border-radius: 999px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.16);
}

.mmoc-legend-line--unknown {
    background: transparent;
    border-top: 2px dashed #a1a1aa;
    height: 0;
    width: 24px;
    border-radius: 0;
    box-shadow: none;
}

.mmoc-legend-item--verhard { --mmoc-legend-accent: #b7bdc6; }
.mmoc-legend-item--gravel  { --mmoc-legend-accent: #ff9800; }
.mmoc-legend-item--modder  { --mmoc-legend-accent: #5d4037; }
.mmoc-legend-item--gras    { --mmoc-legend-accent: #8bc34a; }
.mmoc-legend-item--zand    { --mmoc-legend-accent: #f2d64b; }
.mmoc-legend-item--unknown { --mmoc-legend-accent: #a1a1aa; }

.mmoc-stats-card {
    display: block;
}

.mmoc-stats-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 18px;
}

.mmoc-stats-total {
    margin: 0;
    color: var(--mmoc-text-soft);
    font-size: 15px;
    line-height: 1.6;
}

.mmoc-stats-grid {
    display: none;
    gap: 16px;
}

.mmoc-warning {
    display: none;
    margin: -4px 0 18px;
    padding: 12px 14px;
    border: 1px solid #fed7aa;
    border-radius: 12px;
    background: #fff7ed;
    color: #9a3412;
    font-size: 14px;
    line-height: 1.5;
}

.mmoc-stat-row {
    display: grid;
    gap: 8px;
}

.mmoc-stat-meta {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: baseline;
    font-size: 14px;
}

.mmoc-stat-name {
    font-weight: 500;
    color: var(--mmoc-text);
}

.mmoc-stat-value {
    color: var(--mmoc-text-soft);
    white-space: nowrap;
}

.mmoc-stat-bar {
    width: 100%;
    height: 20px;
    background: #edf1f5;
    border-radius: 2px;
    overflow: hidden;
}

.mmoc-stat-fill {
    width: 0;
    height: 100%;
    border-radius: 2px;
    transition: width .65s cubic-bezier(.22,1,.36,1);
}

.mmoc-empty {
    margin: 0;
    color: var(--mmoc-text-soft);
    font-size: 15px;
}

@media (max-width: 767px) {
    .mmoc-card__inner {
        padding: 18px;
    }

    .mmoc-heading {
        font-size: 21px;
    }

    .mmoc-upload-card .mmoc-card__inner {
        padding: 24px 18px;
    }

    .mmoc-dropzone {
        min-height: 178px;
        padding: 24px 18px;
    }

    .mmoc-dropzone__title {
        font-size: 20px;
    }

    .mmoc-actions {
        align-items: stretch;
    }

    .mmoc-button {
        width: 100%;
    }

    .mmoc-map {
        height: 360px;
    }

    .mmoc-stat-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .mmoc-stat-value {
        white-space: normal;
    }
}
