﻿/* Dial In Doctor - video consultation.
   Shared by the doctor's clinical workspace and the patient portal so the call
   looks and behaves identically on both sides of it. Self-contained: it defines
   its own variables rather than depending on whichever stylesheet loaded it. */

:root {
    --v-brand: #2B8ECA;
    --v-brand-dark: #1F6E9E;
    --v-ink: #16202C;
    --v-soft: #5A6675;
    --v-line: #E3E8EF;
    --v-surface: #FFFFFF;
    --v-canvas: #F5F8FC;
    --v-warn: #B45309;
    --v-danger: #C2413B;
    --v-radius: 12px;
}
/* ------------------------------------------------------------------- video */
/* Shared by the doctor workspace and the patient portal, so the call looks and
   behaves identically on both sides. */

.video-shell {
    display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 16px;
    margin-bottom: 22px;
}
.video-main { min-width: 0; }

.video-stage {
    position: relative; background: #10161F; border-radius: var(--v-radius);
    overflow: hidden; aspect-ratio: 16 / 9;
}
.video-remote { width: 100%; height: 100%; object-fit: cover; display: block; background: #10161F; }
.video-local {
    position: absolute; right: 12px; bottom: 12px; width: 26%; max-width: 190px;
    aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px;
    border: 2px solid rgba(255,255,255,.35); background: #000;
}
.video-overlay {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    background: linear-gradient(180deg, rgba(16,22,31,.86), rgba(16,22,31,.94)); color: #fff; text-align: center;
}
.video-overlay-inner { max-width: 420px; padding: 20px; }
.video-state { font-size: 18px; font-weight: 600; }
.video-hint { font-size: 14px; color: #C9D3DE; margin: 8px 0 0; }
.video-reconnect {
    position: absolute; top: 12px; left: 50%; transform: translateX(-50%);
    background: var(--v-warn); color: #fff; padding: 6px 14px; border-radius: 999px; font-size: 13px;
}

.video-bar {
    display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
    background: var(--v-surface); border: 1px solid var(--v-line); border-top: 0;
    border-radius: 0 0 var(--v-radius) var(--v-radius); padding: 12px 14px;
}
.video-bar-left { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--v-soft); }
.video-timer { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.video-controls { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

.vbtn {
    min-height: 44px; padding: 10px 16px; border-radius: 8px; font: inherit; font-weight: 600;
    border: 1px solid var(--v-line); background: var(--v-surface); color: var(--v-ink); cursor: pointer;
}
.vbtn:hover { background: var(--v-canvas); }
.vbtn.off { background: #FBEDEC; border-color: #F0C4C2; color: var(--v-danger); }
.vbtn-primary { background: var(--v-brand); border-color: var(--v-brand); color: #fff; }
.vbtn-primary:hover { background: var(--v-brand-dark); }
.vbtn-danger { background: var(--v-danger); border-color: var(--v-danger); color: #fff; }
.vbtn[disabled] { opacity: .5; cursor: not-allowed; }

.video-devices { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px; }
.video-devices label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--v-soft); }
.video-devices select { padding: 8px 10px; border: 1px solid var(--v-line); border-radius: 8px; font: inherit; }

.video-side {
    background: var(--v-surface); border: 1px solid var(--v-line);
    border-radius: var(--v-radius); padding: 16px; align-self: start;
}
.video-side h3 { margin: 0 0 10px; font-size: 14px; text-transform: uppercase; letter-spacing: .04em; color: var(--v-soft); }
.video-facts { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; margin: 0 0 14px; font-size: 14px; }
.video-facts dt { color: var(--v-soft); }
.video-facts dd { margin: 0; text-align: right; }
.video-side-actions { display: flex; flex-direction: column; gap: 8px; }
.video-note { margin: 12px 0 0; font-size: 13px; }


@media (max-width: 980px) {
    /* Video first, clinical panels underneath. On a tablet the doctor is
       holding the device; the call must not be squeezed into a column. */
    .video-shell { grid-template-columns: 1fr; }
    .video-side { order: 2; }
}

@media (max-width: 760px) {
    /* Portrait stage on a phone, and controls that span the width so they stay
       reachable with a thumb. */
    .video-stage { aspect-ratio: 3 / 4; }
    .video-local { width: 34%; }
    .video-controls { margin-left: 0; width: 100%; }
    .vbtn { flex: 1 1 auto; }
    .video-facts { font-size: 13px; }
}
