.app-legal-dialog {
    width: min(900px, calc(100vw - 32px));
    height: min(88vh, 900px);
    max-width: none;
    max-height: none;
    padding: 0;
    overflow: hidden;
    border: 1px solid #454545;
    border-radius: 14px;
    background: #1c1c1c;
    color: #f2f2f2;
    box-shadow: 0 24px 70px rgba(0, 0, 0, .75);
}

.app-legal-dialog::backdrop {
    background: rgba(0, 0, 0, .82);
}

.app-legal-dialog[open] {
    display: flex;
    flex-direction: column;
}

.app-legal-dialog__header {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 16px;
    border-bottom: 1px solid #3a3a3a;
}

.app-legal-dialog__header h2 {
    margin: 0;
    font-size: 1.15rem;
}

.app-legal-dialog__close {
    min-height: 42px;
    padding: 8px 14px;
    border: 1px solid #555;
    border-radius: 8px;
    background: #303030;
    color: #fff;
    cursor: pointer;
    font: inherit;
}

.app-legal-dialog__close:hover,
.app-legal-dialog__close:focus-visible {
    background: #414141;
}

.app-legal-dialog__frame {
    display: block;
    flex: 1 1 auto;
    width: 100%;
    min-height: 0;
    border: 0;
    background: #111;
}

@media (max-width: 600px) {
    .app-legal-dialog {
        width: calc(100vw - 16px);
        height: 92vh;
        border-radius: 10px;
    }

    .app-legal-dialog__header {
        padding: 10px 12px;
    }
}
