.mr-app {
    max-width: 1080px;
    margin: 0 auto;
    padding: 1.8rem 1rem 2.8rem;
    font-family: 'Inter', sans-serif;
}

.mr-hero {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.mr-pill {
    margin: 0;
    display: inline-block;
    border-radius: 999px;
    border: 1px solid rgba(255, 107, 181, 0.45);
    color: #ff8dc7;
    background: rgba(233, 30, 140, 0.12);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    padding: 0.35rem 0.75rem;
    text-transform: uppercase;
}

.mr-hero h1 {
    margin: 0.8rem 0 0.6rem;
    color: #fff;
    font-size: 2rem;
}

.mr-sub {
    color: rgba(255, 255, 255, 0.72);
    line-height: 1.7;
    margin: 0;
    max-width: 680px;
}

.mr-actions {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    min-width: 210px;
}

.mr-btn {
    border: 1px solid transparent;
    border-radius: 999px;
    padding: 0.6rem 0.95rem;
    font-size: 0.86rem;
    font-weight: 700;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.mr-btn:hover { transform: translateY(-1px); }
.mr-btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.mr-btn-active {
    background: rgba(129, 140, 248, 0.18) !important;
    border-color: rgba(129, 140, 248, 0.55) !important;
    color: #e6e9ff !important;
}

.mr-btn-primary {
    color: rgba(255, 255, 255, 0.96);
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.22);
}

.mr-btn-secondary {
    color: rgba(255, 255, 255, 0.95);
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.18);
}

.mr-btn-link {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.16);
}

.mr-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.mr-panel {
    border: 1px solid rgba(255, 255, 255, 0.09);
    margin-bottom: 1rem;
    position: relative;
}

.mr-panel h2 {
    margin: 0 0 0.85rem;
    color: #fff;
    font-size: 1.15rem;
}

.mr-kv {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.42rem 0;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
}

.mr-kv span {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
}

.mr-kv strong {
    color: #fff;
    font-size: 0.86rem;
    max-width: 62%;
    text-align: right;
    overflow-wrap: anywhere;
}

.mr-status {
    margin-top: 0.8rem;
    border-radius: 10px;
    padding: 0.58rem 0.65rem;
    font-size: 0.82rem;
    font-weight: 600;
}

.mr-info { background: rgba(59, 130, 246, 0.12); color: #93c5fd; border: 1px solid rgba(147, 197, 253, 0.28); }
.mr-success { background: rgba(16, 185, 129, 0.13); color: #86efac; border: 1px solid rgba(134, 239, 172, 0.25); }
.mr-error { background: rgba(239, 68, 68, 0.14); color: #fca5a5; border: 1px solid rgba(252, 165, 165, 0.25); }

.mr-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    margin-bottom: 0.65rem;
    flex-wrap: wrap;
}

.mr-note {
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.86rem;
    line-height: 1.6;
}

.mr-placement-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
    margin-top: 0.8rem;
}

.mr-placement {
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    padding: 0.9rem;
}

.mr-placement h3 {
    margin: 0 0 0.4rem;
    color: #fff;
    font-size: 0.95rem;
}

.mr-placement p {
    margin: 0 0 0.6rem;
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.8rem;
    line-height: 1.5;
}

.mr-chip-row {
    display: flex;
    gap: 0.35rem;
    flex-wrap: wrap;
    margin-bottom: 0.55rem;
}

.mr-chip {
    border-radius: 999px;
    font-size: 0.72rem;
    padding: 0.22rem 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.84);
    background: rgba(255, 255, 255, 0.06);
}

.mr-action-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem;
}

.mr-scene-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.mr-scene-canvas {
    width: 100%;
    min-height: 260px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 12px;
    background: radial-gradient(circle at 20% 20%, rgba(90, 105, 240, 0.18), rgba(4, 7, 15, 0.95));
}

.mr-diagnostics {
    margin-top: 0.6rem;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.8rem;
    border: 1px dashed rgba(255, 255, 255, 0.16);
    border-radius: 10px;
    padding: 0.45rem 0.65rem;
    overflow-wrap: anywhere;
}

.mr-preview-hint {
    margin-top: -0.2rem;
}

.mr-preview-state {
    display: inline-block;
    margin: 0.15rem 0 0.65rem;
    border-radius: 999px;
    border: 1px solid rgba(248, 113, 113, 0.45);
    color: #fecaca;
    background: rgba(127, 29, 29, 0.25);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 0.34rem 0.64rem;
}

.mr-preview-state-on {
    border-color: rgba(74, 222, 128, 0.45);
    color: #bbf7d0;
    background: rgba(20, 83, 45, 0.28);
}

.mr-input {
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    font-size: 0.82rem;
    padding: 0.42rem 0.52rem;
    min-width: 130px;
}

.mr-input::placeholder {
    color: rgba(255, 255, 255, 0.44);
}

.mr-location-inline {
    margin: 0.15rem 0 0.65rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.mr-location-inline strong {
    color: #bfdbfe;
    font-size: 0.82rem;
}

.mr-proximity-notice {
    position: absolute;
    right: 2rem;
    margin-top: 0.15rem;
    border-radius: 999px;
    border: 1px solid rgba(251, 113, 133, 0.45);
    background: rgba(136, 19, 55, 0.28);
    color: #fecdd3;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding: 0.34rem 0.62rem;
    opacity: 0;
    transform: translateY(-3px);
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.mr-proximity-show {
    opacity: 1;
    transform: translateY(0);
}

.mr-ad-card {
    margin-top: 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.04);
    overflow: hidden;
    display: none;
}

.mr-ad-card-show {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
}

.mr-ad-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    min-height: 210px;
}

.mr-ad-body {
    padding: 0.9rem;
}

.mr-ad-body h3 {
    margin: 0;
    color: #fff;
    font-size: 1rem;
}

.mr-admin-grid {
    margin-top: 0.7rem;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
}

.mr-admin-grid label {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.8rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

#mr-admin-placement {
    min-width: 220px;
}

@media (max-width: 920px) {
    .mr-hero { flex-direction: column; }
    .mr-actions { min-width: 0; }
    .mr-grid { grid-template-columns: 1fr; }
    .mr-placement-list { grid-template-columns: 1fr; }
    .mr-proximity-notice { right: 1rem; }
    .mr-ad-card-show { grid-template-columns: 1fr; }
    .mr-admin-grid { grid-template-columns: 1fr; }
}
