/* =========================================================
   Motor Route Manager – Dark theme match  v1.6
   Full-width · glass cards · orange accents · IranYekan
   ========================================================= */

@font-face {
    font-family: 'IranYekan';
    src: url('../fonts/Iranyekan.ttf') format('truetype');
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

.mrm-section,
.mrm-card,
.mrm-modal,
.mrm-single-wrap {
    direction: rtl;
    font-family: 'IranYekan', Tahoma, 'Segoe UI', system-ui, sans-serif;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
}
.mrm-section *,
.mrm-card *,
.mrm-modal * { box-sizing: border-box; }

.mrm-section {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 40px 0 56px;
    color: #e8edf5;
    background: transparent;
    position: relative;
    overflow: hidden;
}

/* subtle decorative blobs behind section */
.mrm-section::before {
    content: '';
    position: absolute;
    width: 420px;
    height: 420px;
    border-radius: 50%;
    background: rgba(249, 115, 22, .08);
    filter: blur(90px);
    top: -120px;
    left: 10%;
    pointer-events: none;
    z-index: 0;
}
.mrm-section::after {
    content: '';
    position: absolute;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: rgba(59, 130, 246, .06);
    filter: blur(80px);
    bottom: -80px;
    right: 5%;
    pointer-events: none;
    z-index: 0;
}

.mrm-toolbar {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 28px;
    flex-wrap: wrap;
    width: 100%;
    padding: 0 4vw;
}

.mrm-filters { display: flex; gap: 8px; flex-wrap: wrap; }
.mrm-filter {
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .1);
    color: #94a3b8;
    padding: 10px 20px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: all .2s ease;
    backdrop-filter: blur(8px);
}
.mrm-filter:hover { background: rgba(255,255,255,.1); color: #f1f5f9; }
.mrm-filter.is-active {
    background: linear-gradient(135deg, #f97316, #ea580c);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 6px 20px rgba(249, 115, 22, .35);
}

.mrm-arrows { display: flex; gap: 8px; }
.mrm-arrow {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,.12);
    background: rgba(255,255,255,.06);
    color: #e2e8f0;
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: all .2s ease;
    opacity: .35;
    pointer-events: none;
    backdrop-filter: blur(8px);
}
.mrm-arrow.is-on {
    opacity: 1;
    pointer-events: auto;
}
.mrm-arrow.is-on:hover {
    background: #f97316;
    border-color: #f97316;
    color: #fff;
    transform: scale(1.06);
    box-shadow: 0 6px 18px rgba(249, 115, 22, .4);
}

.mrm-viewport {
    position: relative;
    z-index: 1;
    overflow: hidden;
    width: 100%;
    max-width: 100%;
    padding: 0 4vw;
}
.mrm-track {
    display: flex;
    gap: 24px;
    will-change: transform;
    width: 100%;
}

.mrm-card--slide {
    flex: 0 0 calc((100% - 48px) / 3);
    max-width: calc((100% - 48px) / 3);
    min-width: 0;
}
.mrm-card--slide.is-hidden { display: none !important; }
.mrm-single-wrap {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
    padding: 24px 4vw;
}

.mrm-dots {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    gap: 7px;
    margin-top: 22px;
}
.mrm-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,.25);
    cursor: pointer;
    padding: 0;
    transition: all .25s ease;
}
.mrm-dot.is-active {
    background: #f97316;
    width: 26px;
    border-radius: 8px;
    box-shadow: 0 0 12px rgba(249, 115, 22, .45);
}

/* ========== CARD – glass ========== */
.mrm-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, .25),
        inset 0 1px 0 rgba(255, 255, 255, .06);
    backdrop-filter: blur(14px) saturate(1.15);
    -webkit-backdrop-filter: blur(14px) saturate(1.15);
    transition: transform .35s cubic-bezier(.22, 1, .36, 1), box-shadow .35s ease, border-color .25s;
    display: flex;
    flex-direction: column;
}
.mrm-card:hover {
    transform: translateY(-8px);
    border-color: rgba(249, 115, 22, .35);
    box-shadow:
        0 16px 48px rgba(0, 0, 0, .35),
        0 0 0 1px rgba(249, 115, 22, .15),
        0 0 40px rgba(249, 115, 22, .08);
}

.mrm-card__media {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: #0a0c12;
}
.mrm-gal { position: absolute; inset: 0; }
.mrm-gal__slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity .5s ease;
}
.mrm-gal__slide.is-active { opacity: 1; }

.mrm-card__shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(7, 9, 15, .92) 0%,
        rgba(7, 9, 15, .25) 45%,
        rgba(7, 9, 15, .1) 100%
    );
    pointer-events: none;
    z-index: 1;
}

.mrm-card__status {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 3;
    font-size: 11px;
    font-weight: 800;
    padding: 6px 12px;
    border-radius: 999px;
    backdrop-filter: blur(8px);
    letter-spacing: .3px;
}
.mrm-card__status--planned {
    background: rgba(249, 115, 22, .9);
    color: #fff;
}
.mrm-card__status--completed {
    background: rgba(34, 197, 94, .9);
    color: #fff;
}

.mrm-gal__btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, .85);
    color: #0f172a;
    display: grid;
    place-items: center;
    cursor: pointer;
    opacity: 0;
    transition: opacity .2s, transform .2s;
}
.mrm-card__media:hover .mrm-gal__btn { opacity: 1; }
.mrm-gal__prev { left: 10px; }
.mrm-gal__next { right: 10px; }
.mrm-gal__btn:hover { background: #fff; transform: translateY(-50%) scale(1.1); }

.mrm-gal__dots {
    position: absolute;
    bottom: 68px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    gap: 5px;
}
.mrm-gal__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, .4);
    cursor: pointer;
    padding: 0;
    transition: .2s;
}
.mrm-gal__dot.is-active {
    background: #f97316;
    width: 16px;
    border-radius: 6px;
}

.mrm-card__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2;
    padding: 18px 20px 16px;
}
.mrm-card__date {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, .85);
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 6px;
}
.mrm-card__title {
    margin: 0;
    color: #fff;
    font-size: 20px;
    font-weight: 800;
    line-height: 1.3;
    text-shadow: 0 2px 14px rgba(0, 0, 0, .5);
}

.mrm-card__body {
    padding: 18px 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    flex: 1;
}

.mrm-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
.mrm-info__item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .06);
    transition: border-color .2s, background .2s;
}
.mrm-info__item:hover {
    background: rgba(249, 115, 22, .08);
    border-color: rgba(249, 115, 22, .2);
}
.mrm-info__icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: rgba(249, 115, 22, .15);
    color: #fb923c;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}
.mrm-info__label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 2px;
}
.mrm-info__val {
    display: block;
    font-size: 13px;
    font-weight: 800;
    color: #f1f5f9;
    line-height: 1.35;
}
.mrm-rem {
    font-style: normal;
    font-weight: 600;
    color: #94a3b8;
    font-size: 11px;
}
.mrm-ok {
    font-style: normal;
    font-weight: 600;
    color: #4ade80;
    font-size: 11px;
}

.mrm-card__map-wrap {
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .1);
    height: 140px;
    background: #0f172a;
}
.mrm-mini-map {
    width: 100%;
    height: 100%;
    z-index: 0;
}
.mrm-mini-map .leaflet-control-container { display: none !important; }

.mrm-card__actions { margin-top: auto; }
.mrm-btn {
    width: 100%;
    border: none;
    border-radius: 14px;
    padding: 13px 18px;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: all .25s ease;
    font-family: inherit;
}
.mrm-btn--primary {
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #fff;
    box-shadow: 0 8px 24px rgba(249, 115, 22, .35);
}
.mrm-btn--primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(249, 115, 22, .45);
}
.mrm-btn--disabled,
.mrm-btn--muted {
    background: rgba(255, 255, 255, .06);
    color: #64748b;
    cursor: not-allowed;
    box-shadow: none;
    border: 1px solid rgba(255, 255, 255, .08);
}

/* Modal glass */
.mrm-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: .25s;
    font-family: 'IranYekan', Tahoma, sans-serif;
}
.mrm-modal.is-open { opacity: 1; visibility: visible; }
.mrm-modal__bg {
    position: absolute;
    inset: 0;
    background: rgba(5, 7, 13, .7);
    backdrop-filter: blur(8px);
}
.mrm-modal__box {
    position: relative;
    background: rgba(15, 18, 28, .92);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 24px;
    padding: 28px 24px;
    width: 92%;
    max-width: 420px;
    box-shadow: 0 28px 64px rgba(0, 0, 0, .45);
    backdrop-filter: blur(20px);
    transform: translateY(20px) scale(.97);
    transition: .3s cubic-bezier(.22, 1, .36, 1);
    color: #e8edf5;
}
.mrm-modal.is-open .mrm-modal__box { transform: none; }
.mrm-modal__x {
    position: absolute;
    top: 14px;
    left: 14px;
    width: 36px;
    height: 36px;
    border: none;
    background: rgba(255,255,255,.08);
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    color: #94a3b8;
    display: grid;
    place-items: center;
    transition: .2s;
}
.mrm-modal__x:hover { background: rgba(255,255,255,.14); color: #fff; }
.mrm-modal__head { margin-bottom: 20px; }
.mrm-modal__h {
    margin: 0 0 4px;
    font-size: 20px;
    font-weight: 800;
    color: #f8fafc;
}
.mrm-modal__p {
    margin: 0;
    font-size: 13px;
    color: #94a3b8;
    font-weight: 600;
}
.mrm-f { margin-bottom: 14px; }
.mrm-f label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #cbd5e1;
    margin-bottom: 6px;
}
.mrm-f input,
.mrm-f textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid rgba(255,255,255,.12);
    border-radius: 12px;
    font-size: 14px;
    font-family: inherit;
    background: rgba(255,255,255,.05);
    color: #f1f5f9;
    transition: .15s;
}
.mrm-f input:focus,
.mrm-f textarea:focus {
    outline: none;
    border-color: #f97316;
    background: rgba(255,255,255,.08);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, .15);
}
.mrm-submit {
    width: 100%;
    margin-top: 4px;
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #fff;
    border: none;
    padding: 14px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    box-shadow: 0 6px 20px rgba(249, 115, 22, .3);
    transition: .2s;
}
.mrm-submit:hover { transform: translateY(-1px); }
.mrm-submit:disabled { opacity: .6; cursor: not-allowed; transform: none; }
.mrm-modal__hint {
    margin: 12px 0 0;
    font-size: 12px;
    color: #64748b;
    text-align: center;
}
.mrm-msg {
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 10px;
}
.mrm-msg.is-ok { background: rgba(34,197,94,.15); color: #86efac; }
.mrm-msg.is-err { background: rgba(239,68,68,.15); color: #fca5a5; }

.mrm-empty {
    text-align: center;
    padding: 48px 20px;
    color: #94a3b8;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 20px;
    font-size: 14px;
    margin: 0 4vw;
}

/* Responsive */
@media (min-width: 1400px) {
    .mrm-card__media { height: 260px; }
    .mrm-card__map-wrap { height: 160px; }
    .mrm-card__title { font-size: 22px; }
}

@media (max-width: 1100px) {
    .mrm-card--slide {
        flex: 0 0 calc((100% - 24px) / 2);
        max-width: calc((100% - 24px) / 2);
    }
}

@media (max-width: 700px) {
    .mrm-card--slide {
        flex: 0 0 90%;
        max-width: 90%;
    }
    .mrm-card__media { height: 210px; }
    .mrm-card__title { font-size: 18px; }
    .mrm-card__map-wrap { height: 120px; }
    .mrm-info { gap: 10px; }
    .mrm-gal__btn { opacity: 1; }
    .mrm-section { padding: 28px 0 40px; }
}

@media (max-width: 400px) {
    .mrm-info { grid-template-columns: 1fr; }
    .mrm-card__body { padding: 14px; }
}
