/* Drive-sheet workspace modal — the instructor portal embedded in an iframe.
   Shared by the booking page (instructor schedule) and the admin portal.
   Dark-mode overrides for these classes live in theme.css. */

.drive-sheet-modal[hidden] { display: none; }
.drive-sheet-modal {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, .64);
    backdrop-filter: blur(4px);
}
.drive-sheet-modal-dialog {
    width: min(1180px, calc(100vw - 40px));
    height: min(880px, calc(100vh - 40px));
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid rgba(255,255,255,.65);
    border-radius: 16px;
    box-shadow: 0 24px 70px rgba(15, 23, 42, .32);
}
.drive-sheet-modal-header {
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 16px 12px 20px;
    background: white;
    border-bottom: 1px solid #e2e8f0;
}
.drive-sheet-modal-header h2 {
    margin: 0;
    color: #0f172a;
    font-size: 17px;
    line-height: 1.3;
}
.drive-sheet-modal-close {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border: 1px solid #e2e8f0;
    border-radius: 9px;
    background: white;
    color: #475569;
    cursor: pointer;
}
.drive-sheet-modal-close:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .28);
    outline-offset: 2px;
}
.drive-sheet-modal-body {
    position: relative;
    flex: 1;
    min-height: 0;
}
.drive-sheet-modal-frame {
    width: 100%;
    height: 100%;
    display: block;
    border: 0;
    background: #f8fafc;
}
.drive-sheet-modal-frame[hidden] { display: none; }
.drive-sheet-modal-loading {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: #64748b;
    background: #f8fafc;
}
.drive-sheet-modal-loading[hidden] { display: none; }
.drive-sheet-modal-loading i { color: var(--primary-color); font-size: 24px; }
body.drive-sheet-modal-open { overflow: hidden; }

@media (max-width: 640px) {
    .drive-sheet-modal { padding: 0; }
    .drive-sheet-modal-dialog {
        width: 100vw;
        height: 100vh;
        border: 0;
        border-radius: 0;
    }
}
